Sorry if I was not clear, the bluerov2_node, is like any other ROS node program, provides ROS abstraction for the ROV with topics to subscribe and publish. The user script is just a simple python example of how to program and control the ROV without the ROS node.
There is a difference between ROS and BlueROV ROS node, ROS node is a node abstraction for the robot, like BlueROV2/topics, I would recommend you to read and follow the ROS tutorial. The user script uses ROS mavros abstraction to communicate with the vehicle, without dealing and using the BlueROV2 ROS node abstraction.
Thanks! I thought you have to run both to get everything working.
However, now when Im running SITL and just the BlueROV node, I cant make the Gazebo model move either by publishing to /BlueRov2/setpoint_velocity/cmd_vel or /BlueRov2/rc_channel4/set_pwm. I could do it with the user script.
I think I answered the question to that one - in that it seems that the BlueRov2 node still needs mavros to be running to send the rc_override commands on to mavlink - at least in SITL.
Will it work without mavros when using the actual hardware?
Both uses mavros since the BlueROV2 communicates via mavlink, for more information you can check mavros official documentation: http://wiki.ros.org/mavros
Alright, so I picked the bridge.py apart to get it to work, and discovered the following:
My system refused to take rc_override commands UNLESS the master is specified as updin:0.0.0.0:14550
Which begs some clarification:
What is the nuance in which address form to use? I have seen many variants
udp:192.168.2.1:14550 (I think this SHOULD work, but does not)
udp:127.0.0.1:14550 (I think this is for SITL)
tcp:192.168.2.1:14550 (unsure why this does not work)
udp://:14550@127.0.0.1:14549 (this REALLY confuses me, because it doesnt even have an address at the beginning and I cant find out what the @ sign means)
If you could clarify that would be great, or confirm if I just need to ask the Mavlink people.
Thanks for the clarification. As far as udp:192.168.2.1:14550, my computer is set to that IP address and the sub definitely has 192.168.2.2 set because I can get into the companion website via 192.168.2.2:2700 and verified on the mavlink page.
It seems strange to me that mavlink requires you specify the address of the topside machine running pymavlink and not the address of the companion you want to talk to.