Home        Store        Docs        Blog

Connect bluerov2 with mavros to see data of sensors

Hi, my name is Matheus, I start work with Bluerov2, and I would like to see bluerov sensor data, I would like to use mavros, because, on my work we use more ros, and I’m learning ros, so when I try to use command “roslaunch mavros apm.launch” just show:

matheus@Prez:~$ roslaunch mavros apm.launch
… logging to /home/matheus/.ros/log/61b35a30-58d0-11ea-9236-782bcbee21ab/roslaunch-Prez-21058.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://Prez:41665/

SUMMARY

CLEAR PARAMETERS

  • /mavros/

PARAMETERS

  • /mavros/cmd/use_comp_id_system_control: False
  • /mavros/conn/heartbeat_mav_type: ONBOARD_CONTROLLER
  • /mavros/conn/heartbeat_rate: 1.0
  • /mavros/conn/system_time_rate: 1.0
  • /mavros/conn/timeout: 10.0
  • /mavros/conn/timesync_rate: 10.0
  • /mavros/distance_sensor/rangefinder_pub/field_of_view: 0.0
  • /mavros/distance_sensor/rangefinder_pub/frame_id: lidar
  • /mavros/distance_sensor/rangefinder_pub/id: 0
  • /mavros/distance_sensor/rangefinder_pub/send_tf: False
  • /mavros/distance_sensor/rangefinder_pub/sensor_position/x: 0.0
  • /mavros/distance_sensor/rangefinder_pub/sensor_position/y: 0.0
  • /mavros/distance_sensor/rangefinder_pub/sensor_position/z: -0.1
  • /mavros/distance_sensor/rangefinder_sub/id: 1
  • /mavros/distance_sensor/rangefinder_sub/orientation: PITCH_270
  • /mavros/distance_sensor/rangefinder_sub/subscriber: True
  • /mavros/fake_gps/eph: 2.0
  • /mavros/fake_gps/epv: 2.0
  • /mavros/fake_gps/fix_type: 3
  • /mavros/fake_gps/geo_origin/alt: 408.0
  • /mavros/fake_gps/geo_origin/lat: 47.3667
  • /mavros/fake_gps/geo_origin/lon: 8.55
  • /mavros/fake_gps/gps_rate: 5.0
  • /mavros/fake_gps/mocap_transform: True
  • /mavros/fake_gps/satellites_visible: 5
  • /mavros/fake_gps/tf/child_frame_id: fix
  • /mavros/fake_gps/tf/frame_id: map
  • /mavros/fake_gps/tf/listen: False
  • /mavros/fake_gps/tf/rate_limit: 10.0
  • /mavros/fake_gps/tf/send: False
  • /mavros/fake_gps/use_mocap: True
  • /mavros/fake_gps/use_vision: False
  • /mavros/fcu_protocol: v2.0
  • /mavros/fcu_url: /dev/ttyACM0:57600
  • /mavros/gcs_url:
  • /mavros/global_position/child_frame_id: base_link
  • /mavros/global_position/frame_id: map
  • /mavros/global_position/gps_uere: 1.0
  • /mavros/global_position/rot_covariance: 99999.0
  • /mavros/global_position/tf/child_frame_id: base_link
  • /mavros/global_position/tf/frame_id: map
  • /mavros/global_position/tf/global_frame_id: earth
  • /mavros/global_position/tf/send: False
  • /mavros/global_position/use_relative_alt: True
  • /mavros/image/frame_id: px4flow
  • /mavros/imu/angular_velocity_stdev: 0.0003490659 // 0…
  • /mavros/imu/frame_id: base_link
  • /mavros/imu/linear_acceleration_stdev: 0.0003
  • /mavros/imu/magnetic_stdev: 0.0
  • /mavros/imu/orientation_stdev: 1.0
  • /mavros/landing_target/camera/fov_x: 2.0071286398
  • /mavros/landing_target/camera/fov_y: 2.0071286398
  • /mavros/landing_target/image/height: 480
  • /mavros/landing_target/image/width: 640
  • /mavros/landing_target/land_target_type: VISION_FIDUCIAL
  • /mavros/landing_target/listen_lt: False
  • /mavros/landing_target/mav_frame: LOCAL_NED
  • /mavros/landing_target/target_size/x: 0.3
  • /mavros/landing_target/target_size/y: 0.3
  • /mavros/landing_target/tf/child_frame_id: camera_center
  • /mavros/landing_target/tf/frame_id: landing_target
  • /mavros/landing_target/tf/listen: False
  • /mavros/landing_target/tf/rate_limit: 10.0
  • /mavros/landing_target/tf/send: True
  • /mavros/local_position/frame_id: map
  • /mavros/local_position/tf/child_frame_id: base_link
  • /mavros/local_position/tf/frame_id: map
  • /mavros/local_position/tf/send: False
  • /mavros/local_position/tf/send_fcu: False
  • /mavros/mission/pull_after_gcs: True
  • /mavros/mocap/use_pose: True
  • /mavros/mocap/use_tf: False
  • /mavros/odometry/estimator_type: 3
  • /mavros/odometry/frame_tf/desired_frame: ned
  • /mavros/plugin_blacklist: ['actuator_contro…
  • /mavros/plugin_whitelist:
  • /mavros/px4flow/frame_id: px4flow
  • /mavros/px4flow/ranger_fov: 0.118682
  • /mavros/px4flow/ranger_max_range: 5.0
  • /mavros/px4flow/ranger_min_range: 0.3
  • /mavros/safety_area/p1/x: 1.0
  • /mavros/safety_area/p1/y: 1.0
  • /mavros/safety_area/p1/z: 1.0
  • /mavros/safety_area/p2/x: -1.0
  • /mavros/safety_area/p2/y: -1.0
  • /mavros/safety_area/p2/z: -1.0
  • /mavros/setpoint_accel/send_force: False
  • /mavros/setpoint_attitude/reverse_thrust: False
  • /mavros/setpoint_attitude/tf/child_frame_id: target_attitude
  • /mavros/setpoint_attitude/tf/frame_id: map
  • /mavros/setpoint_attitude/tf/listen: False
  • /mavros/setpoint_attitude/tf/rate_limit: 50.0
  • /mavros/setpoint_attitude/use_quaternion: False
  • /mavros/setpoint_position/mav_frame: LOCAL_NED
  • /mavros/setpoint_position/tf/child_frame_id: target_position
  • /mavros/setpoint_position/tf/frame_id: map
  • /mavros/setpoint_position/tf/listen: False
  • /mavros/setpoint_position/tf/rate_limit: 50.0
  • /mavros/setpoint_raw/thrust_scaling: 1.0
  • /mavros/setpoint_velocity/mav_frame: LOCAL_NED
  • /mavros/startup_px4_usb_quirk: False
  • /mavros/sys/disable_diag: False
  • /mavros/sys/min_voltage: 10.0
  • /mavros/target_component_id: 1
  • /mavros/target_system_id: 1
  • /mavros/tdr_radio/low_rssi: 40
  • /mavros/time/time_ref_source: fcu
  • /mavros/time/timesync_avg_alpha: 0.6
  • /mavros/time/timesync_mode: MAVLINK
  • /mavros/vibration/frame_id: base_link
  • /mavros/vision_pose/tf/child_frame_id: vision_estimate
  • /mavros/vision_pose/tf/frame_id: map
  • /mavros/vision_pose/tf/listen: False
  • /mavros/vision_pose/tf/rate_limit: 10.0
  • /mavros/vision_speed/listen_twist: True
  • /mavros/vision_speed/twist_cov: True
  • /mavros/wheel_odometry/child_frame_id: base_link
  • /mavros/wheel_odometry/count: 2
  • /mavros/wheel_odometry/frame_id: map
  • /mavros/wheel_odometry/send_raw: True
  • /mavros/wheel_odometry/send_twist: False
  • /mavros/wheel_odometry/tf/child_frame_id: base_link
  • /mavros/wheel_odometry/tf/frame_id: map
  • /mavros/wheel_odometry/tf/send: True
  • /mavros/wheel_odometry/use_rpm: False
  • /mavros/wheel_odometry/vel_error: 0.1
  • /mavros/wheel_odometry/wheel0/radius: 0.05
  • /mavros/wheel_odometry/wheel0/x: 0.0
  • /mavros/wheel_odometry/wheel0/y: -0.15
  • /mavros/wheel_odometry/wheel1/radius: 0.05
  • /mavros/wheel_odometry/wheel1/x: 0.0
  • /mavros/wheel_odometry/wheel1/y: 0.15
  • /rosdistro: melodic
  • /rosversion: 1.14.3

NODES
/
mavros (mavros/mavros_node)

ROS_MASTER_URI=http://localhost:11311

process[mavros-1]: started with pid [21074]
[ INFO] [1582746946.602636569]: FCU URL: /dev/ttyACM0:57600
[ INFO] [1582746946.604267997]: serial0: device: /dev/ttyACM0 @ 57600 bps
[FATAL] [1582746946.604469552]: FCU: DeviceError:serial:open: No such file or directory
================================================================================REQUIRED process [mavros-1] has died!
process has finished cleanly
log file: /home/matheus/.ros/log/61b35a30-58d0-11ea-9236-782bcbee21ab/mavros-1*.log
Initiating shutdown!

[mavros-1] killing on exit
shutting down processing monitor…
… shutting down processing monitor complete
done

and how I don’t understand very well about the bluerov and about the mavros, I would like anybody to help me.

Hi Matheus!

I’m working in the exact same thing!

I recommend you to use the ROS package developed by patrick here.
I have a fork of this same package that I use in python 3.6 with ROS melodic (here). I have to say that my package is prepared for my personal preferences and my configuration in the ROV, but maybe you’ll find it useful. The changes required for this python and ROS version are not huge though.

The node already reads the camera and IMU data. Only the barometer is not directly included. With the help of patrick (see this topic) I made my own node to read the barometer, you can find it here. (In the develop branch I’m developing some further functionalities for the node, in case it is of your interest).

Hope it helps. :slightly_smiling_face:
Let me know if you make some progress of your own! :smile:

3 Likes

Hi, thank you for the help, I can see some data with the command:

“roslaunch bluerov_ros_playground user_mav.launch”

but I can’t see what this data is, and I would like to have on the archive txt and, I would like to know what are data.

Thank you.

edit:
I would like to don’t simulation the bluerov2, and I just to read the sensors, and salve the data.

Hi Matheus,

What is your goal? Does you really need ROS?

Hi Matheus.
There are various ways to save the data:

  • Using logging capabilities provided by ROS, i.e., rosbag.
  • Using whatever logging function that the programming language you’re using provides. Python provides builtin functions to sabe txt files. Pandas is an interesting library for that too.

That’s really up to you and what you’re planning to do.

Documentation about the info that the topics provide is available here. Also you can check the mavros documentation.

1 Like

thank you, I had help from a friend and we got it to do, we see all sensors on topic and capture with rosbag.