MavProxy MavLink Forwarding
Overview
MavProxy allows the user to forward MavLink messages to other devices in the network over UDP. In this page we go over how to set up MavProxy to connect to other devices such as an antenna, what to watch out for when parsing the UDP message, and how to set up the Mission Planner SITL simulation to work with MavProxy.
Setting Up MavProxy
Download and install MavProxy Download and Installation — MAVProxy documentation
This tutorial was tested on Windows but Linux should work the same
To test if you are able to receive MavLink messages from the drone, enter the command
mavproxy --master=udp:x.x.x.x:port_number
withx.x.x.x:port_number
replaced with the ip and port number that the MavLink messages are being sent through.You should now see a connection with data about the drone in the mavproxy GUI
We will now forward the MavLink messages to other devices in our network. You can exit out of
MavProxy by using
ctrl+c
on the terminal until it's closedEnsure that your devices are connected to the same network that the device running MavProxy is connected to.
Enter the command
mavproxy --master=udp:x.x.x.x:port_number --out x.x.x.x:port_number
with the firstx.x.x.x:port_number
again replaced with the ip and port number that the MavLink messages are being sent through, and the secondx.x.x.x:port_number
replaced with the IP of the device that the data is being forwarded to and any free port on that device.
Setting Up Mission Planner SITL with MavProxy
Follow this tutorial on how to set up a Mission Planner SITL simulation, in the MAVLink forwarding section follow steps 1, 2, and 4: Mission Planner Simulated Ardupilot | MAVLink forwarding
The port and IP you selected will be the one you use for the --master field. For example,
mavproxy --master=udp:127.0.0.1:14550 --out x.x.x.x:port_number
If you are running into issues, try using a different port as 14550 is a common MAVLink port.