Camera and Light Control with Mavros

Hey Blue Robotics,

I am interested in controlling the lights and camera tilt of the BlueROV through mavros. I have the heavy addition of the BlueROV2 so my lights and camera servo are connected to the aux outputs of the BlueROV. I was thinking to use mavros_msgs/ActuatorControl Documentation but I was not sure if Ardusub supported this. Also, I was not sure what group mix value I would use in the message or the range is acceptable in the controls list of the message.
I have been looking at this github link. GitHub - patrickelectric/bluerov_ros_playground: Scripts to help BlueRov integration with ROS but there does not seem to be any implementation of what I am talking about. I was wondering if you guys have any idea about this or if this is possible right now.

Thanks,
Brandon

Hi Darrel,

The easier way to accomplish what are you looking for is to use the manual control topic to send camera tilt and light inputs.

Okay, but how do you do that because the message structure of the ManualControl message does not make it clear.

mavros_msgs/ManualControl

std_msgs/Header header
float32 x
float32 y
float32 z
float32 r
uint16 buttons

Or if you know where any documentation for this would be that would be helpful.

Thank you,
Brandon

See here
https://mavlink.io/en/messages/common.html#MANUAL_CONTROL

Okay, thanks. according to that documentation in looks looks like it is for vehicle control. Is there a way to use that specifies light and camera control. Thank you.

Hi Darrel,

Check your vehicle configuration and the joystick button that is used to control the light, you can use this same button in MANUAL_CONTROL message. There is no message for light control.

Cool, thank you. I think that this will work for me

I have gotten this method to work. Do you know of a way to monitor the position (or pwm signal) of the camera while it is attached to the aux outputs?

Hi Darrel,

Take a look in SERVO_OUTPUT_RAW message.

The aux channels (9+) are not available due to a bug:
https://github.com/ArduPilot/ardupilot/issues/9799

Hey Patrick,

Okay, thanks for letting me know.

Brandon