Control the BlueOV with MavROS

Hello,
I have installed the BlueOS and the ROS docker extension developed. I have problem running the mavros override commands.

rostopic echo /mavros/rc/override
[WARN] [1738759410.693170]: Inbound TCP/IP connection failed: connection from sender terminated before handshake header received. 106 bytes were received. Please check sender for additional details.

Although it is connected to ROS and can read the state:

/rostopic echo /mavros/state
header:
seq: 1371
stamp:
secs: 1738760099
nsecs: 445740692
frame_id: ‘’
connected: True
armed: True
guided: False
manual_input: True
mode: “MANUAL”
system_status: 5

Also, the channels are empty when I run:

rostopic echo /mavros/rc/in
header:
seq: 428
stamp:
secs: 1738758981
nsecs: 502236096
frame_id: ‘’
rssi: 255
channels:

FYI, the BlueOS is working on the browser without problems and I updated it to the latest version. I’m testing it in air with an external 10A power supply. All the sensors were calibrated.

Please, if anyone have a solution for this issue.

@patrickelectric, please let me know if you are familair with this problem.

Hi MAtia,

Just to be sure, the rostopic is failing on the surface computer or via the mavros extension in the browser ?

Thanks Patrick for your quick response.

This issue is happening via the MAVROS extension in the browser of BlueOS. I’m accessing the BlueOS interface through the browser on my PC.

FYI, I’m able to arm and disarm on MAVROS without errors. I’m using the latest version of Blueos on Raspberry pi 4b.

Here is the Docker.

To see the servo rc values, you should be using /mavros/rc/out

Thank you, yes when I used it, it showed the values:

rostopic echo /mavros/rc/out
header:
seq: 271
stamp:
secs: 1738851060
nsecs: 858153344
frame_id: ‘’
channels: [1500, 1500, 1500, 1500, 1500, 1500, 1500, 1500, 1100, 1503, 0, 0, 0, 0, 0, 0]

But when I try to write change the motor inputs, it still gives an error:

rostopic pub -r 10 /mavros/rc/override mavros_msgs/OverrideRCIn ‘{channels: [1600, 1500, 1500, 1500, 1500, 1500, 1500, 1500, 1100, 1503, 0, 0, 0, 0, 0, 0, 0, 0]}’
[WARN] [1738851558.988501]: Inbound TCP/IP connection failed: connection from sender terminated before handshake header received. 106 bytes were received. Please check sender for additional details.

Do you know what is the correct code for this?

Sorry, I’m new to Mavros, so I am not sure if the commands I’m using are correct or not. Would you kindly direct me towards some resources of the proper codes for the BlueROV. My aim is to control the thrust of the motors of the BlueROV2 heavy to follow specific paths.

Thank you

You should be using high level controls to set the desired position for your vehicle to follow a path.
But, if you want to control the motors directly, you can follow this guide.

Thank you so much for sharing the guide. I followed it except for step4. (4. Select the bottom left corner terminal, hit control-c, and change the fcu_url adding the “ids” parameter,…). Because when I hit control-c, it doesn’t show fcu-url command. so instead I pasted the command, I don’t know if this is right.

I’m aiming to do model-based control, that is why I need to control each thrsuter.

Thank you again

You should hit or hold ctrl+c and edit the command to the following:

while true; do sleep 10; /ros_entrypoint.sh roslaunch mavros apm.launch fcu_url:=tcp://0.0.0.0:5777@/?ids=255,240; done