Issues Running MAVROS Inside ArduPilot Docker Container on Raspberry Pi 5

System Information:

I’m trying to run MAVROS inside the ArduPilot Docker container on my Raspberry Pi 5 (Raspberry Pi OS, Bookworm) with a Cube Orange+ flight controller connected via UART (TELEM2) on /dev/ttyAMA10. I built the container using ardupilot/ardupilot-dev-ros and started it with serial access. Inside the container, I confirmed that /dev/ttyAMA10 exists and is receiving MAVLink data (cat /dev/ttyAMA10 shows random characters). However, MAVROS was missing in the container, so I installed it manually (apt install -y ros-humble-mavros ros-humble-mavros-extras ros-humble-mavros-msgs). When I try to launch MAVROS (ros2 launch mavros apm.launch fcu_url:=serial:/dev/ttyAMA10:57600), it crashes immediately with exit code -6. I checked GeographicLib installation (it was missing, so I installed it using install_geographiclib_datasets.sh), and I also ran ros2 param list | grep mavros, but no MAVROS parameters appear, suggesting MAVROS is not loading correctly. My questions: :one: Why does MAVROS keep crashing inside this Docker container? :two: Does the ardupilot/ardupilot-dev-ros image fully support MAVROS, or does it require additional setup? :three: Is there a better way to run MAVROS inside this Docker container? Any help would be greatly appreciated

[ERROR] [mavros_node-1]: process has died [pid 1045017, exit code -6, cmd ‘/home/drone/ros2_ws/install/mavros/lib/mavros/mavros_node --ros-args -r __ns:=/mavros --params-file /tmp/launch_params_8bonqd5s --params-file /tmp/launch_params_f4bbwg1z --params-file /tmp/launch_params_oc0ldzj6 --params-file /tmp/launch_params_w1ndo4hm --params-file /tmp/launch_params_vo9b79qx --params-file /home/drone/ros2_ws/install/mavros/share/mavros/launch/apm_pluginlists.yaml --params-file /home/drone/ros2_ws/install/mavros/share/mavros/launch/apm_config.yaml’].

Hi @onalege,

I can’t help I’m afraid because I’m not familiar with mavros but in any case, I’ve moved this post to the Companion Computers section because it was incorrectly put in the Blog section so it appeared on the front page of ardupilot.org