Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add tcp server support to MavLinkTest #3386

Merged
merged 1 commit into from
Feb 12, 2021
Merged

add tcp server support to MavLinkTest #3386

merged 1 commit into from
Feb 12, 2021

Conversation

lovettchris
Copy link
Member

Fixes: #
adds tcp server support to mavlinktest

About

PX4 SITL mode make px4_sitl_default none_iris now expects a TCP connection by default. This makes it possible for mavlinktest to accept these TCP connections from PX4.

How Has This Been Tested?

command line test

Usage:

MavLinkTest.exe -server -tcp:localhost:4560

@jonyMarino jonyMarino merged commit 1f7eb6b into master Feb 12, 2021
@jonyMarino jonyMarino deleted the clovett/tcpserver branch March 10, 2022 18:37
@Dprasad20
Copy link

I am getting following error on ubuntu 18.04 while trying to build PX4_SITL:

:~/PX4/PX4-Autopilot$ make px4_sitl_default none_iris
ninja: error: unknown target 'none_iris'
Makefile:227: recipe for target 'px4_sitl_default' failed
make: *** [px4_sitl_default] Error 1

But I am able to build it by following command:
make px4_sitl_default none
but then I am not able to connect AirSim with PX4 (I am starting PX4 using make px4_sitl_default none), following is the output of PX4_SITL:


| ___ \ \ \ / / / |
| |/ / \ V / / /| |
| __/ / \ / /
| |
| | / /^\ \ ___ |
_| / / |_/

px4 starting.

INFO [px4] startup script: /bin/sh etc/init.d-posix/rcS 0
INFO [param] selected parameter default file parameters.bson
INFO [param] importing from 'parameters.bson'
INFO [parameters] BSON document size 138 bytes, decoded 138 bytes (INT32:2, FLOAT:4)
INFO [param] selected parameter backup file parameters_backup.bson
INFO [dataman] data manager file './dataman' size is 7866640 bytes
INFO [simulator_sih] Simulation loop with 250 Hz (4000 us sim time interval)
INFO [simulator_sih] Simulation with 1.0x speedup. Loop with (4000 us wall time interval)
INFO [lockstep_scheduler] setting initial absolute time to 4000 us
INFO [commander] LED: open /dev/led0 failed (22)
No autostart ID found
etc/init.d-posix/rcS: 263: etc/init.d-posix/rcS: microdds_client: not found
INFO [mavlink] mode: Normal, data rate: 4000000 B/s on udp port 18570 remote port 14550
INFO [mavlink] mode: Onboard, data rate: 4000000 B/s on udp port 14580 remote port 14540
INFO [mavlink] mode: Onboard, data rate: 4000 B/s on udp port 14280 remote port 14030
INFO [mavlink] mode: Gimbal, data rate: 400000 B/s on udp port 13030 remote port 13280
INFO [logger] logger started (mode=all)
INFO [logger] Start file log (type: full)
INFO [logger] [logger] ./log/2022-11-09/14_18_58.ulg
INFO [logger] Opened full log file: ./log/2022-11-09/14_18_58.ulg
INFO [mavlink] MAVLink only on localhost (set param MAV_{i}BROADCAST = 1 to enable network)
INFO [mavlink] MAVLink only on localhost (set param MAV
{i}_BROADCAST = 1 to enable network)
INFO [px4] Startup script returned successfully
pxh> INFO [mavlink] partner IP: 127.0.0.1
WARN [health_and_arming_checks] Preflight Fail: Accel 0 uncalibrated
WARN [health_and_arming_checks] Preflight Fail: Compass 0 uncalibrated
INFO [health_and_arming_checks] Preflight Fail: No manual control input
WARN [health_and_arming_checks] Preflight Fail: No connection to the ground control station
INFO [tone_alarm] home set
WARN [health_and_arming_checks] Preflight Fail: Accel 0 uncalibrated
WARN [health_and_arming_checks] Preflight Fail: Compass 0 uncalibrated
INFO [health_and_arming_checks] Preflight Fail: No manual control input
WARN [health_and_arming_checks] Preflight Fail: Accel 0 uncalibrated
WARN [health_and_arming_checks] Preflight Fail: Compass 0 uncalibrated
INFO [health_and_arming_checks] Preflight Fail: No manual control input
WARN [health_and_arming_checks] Preflight Fail: Accel 0 uncalibrated
WARN [health_and_arming_checks] Preflight Fail: Compass 0 uncalibrated
INFO [health_and_arming_checks] Preflight Fail: No manual control input

and the AirSim has the following output on the screen :
Disconnecting mavlink vehicle...
waiting for mavlink vehicle
waiting for TCP connection on port 4560, local IP 127.0.0.1

I have followed this link for setup: https://microsoft.github.io/AirSim/px4_sitl/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants