-
Notifications
You must be signed in to change notification settings - Fork 0
Full Development Bringup
Marshall Vielmetti edited this page Jan 17, 2025
·
3 revisions
This is a tutorial and explanation on how to bringup the development environment from scratch. The following commands must be run in 3 different terminals.
- Start the uXRCE-Agent This reflects the 'airside' code. It starts a MicroXRCe instance listening on port 8888 (default)
MicroXRCEAgent udp4 -p 8888
- Start the PX4-Sitl simulator This is a software in the loop simulation of the code that will actually run on the PX4 flight controller. In the PX4-Autopilot dependency folder:
make px4_sitl gz_x500
- Connect mavros This reflects how the groundstation code will interact with PX4. Fcu_url is the address of the flight controller. Because we are running the software simulator locally, its the loopback address (127.0.0.1) at the default port of 14557.
ros2 launch mavros px4.launch fcu_url:="udp://:[email protected]:14557"
To make sure everything is working as expected, run:
ros2 topic list
You should see a series of topics prepended with 'mavros' and some with 'fmu'.
Now, side by side, run:
ros2 topic echo /mavros/global_position/global
ros2 topic echo /fmu/out/vehicle_global_position
You should see two different data formats, but if you check the latitude and longitude they should be the same.