Home        Store        Docs        Blog

Simulating Manual Control using Mavros

(Patrick José Pereira) #61

Hello Juan,

I’m glad that my comments were useful for you.

I can see from the state topic that the vehicle is armed in manual mode, are you able to control this ROV via QGroundControl ?
You’ll not be able to control the motors individually with rc/override, take a look about it here:

(Juan Cely) #62

Hi Patrick, Yes, i can move motors using the interface to test and using a joystick. About the topics named Bluerobotic, Is it necesary to install any package more? When I send info using rostopic pub /mavros/rc/override mavros_msgs/OverrideRCIn "channels: [1600, 1500, 1500, 1500, 1500, 1500, 1500, 1500]" -r 10 I got nothing, without the -r 10 at end I receive publishing and latching message. Press ctrl-C to terminate I am sure the PX4 config is ok, maybe I can use bad the connections. Please anyone who can explain me please. Sorry!


(Juan Cely) #63

Hi everyone!!!

I’m glad, after a lot of things the ROV is working! The solution was a stupid. We have had the SYSID MYGCS bad all time. The default value is 255 or 240, the correct value is 1, for my case.

If anyone has doubts, the corrects steps are the follow:

  1. Launching, please verify the port and baudrate:

roslaunch mavros apm.launch

  1. Setting the stream rate, in my case 10 Hz is OK.

rosservice call /mavros/set_stream_rate 0 10 1

  1. Arming the ROV

rosservice call /mavros/cmd/arming "value: true"

  1. In my case, I was sure and was writting the cero value. I have just 4 motors. ATENTION: I compiled a version of Ardusub with a specific frame. If it is your case modify the frame parameter for custom in QGC.

rostopic pub -r 20 /mavros/rc/override mavros_msgs/OverrideRCIn "channels: [1500, 1500, 1500, 1500, 0, 0, 0, 0]"

  1. If you set another velocity for each motor you can send specific value according to the max to min parameters. For example: I want to move the 2nd motor, I use:

rostopic pub -r 20 /mavros/rc/override mavros_msgs/OverrideRCIn "channels: [1500, 1750, 1500, 1500, 0, 0, 0, 0]"

Finally, I can say, I solved my problem!

Thanks a lot to @jwalser and @patrickelectric for your help!