ROS API

From Mobility Base SDK - Wiki
Jump to: navigation, search

Vehicle

The cmd_vel topic should be used for normal operation. Only use the cmd_vel_raw topic if your application requires quick acceleration and your code has been tested.

Subscribed Topics

/mobility_base/cmd_vel (geometry_msgs/Twist)

  • 5 Hz timeout
  • 1 m/s2 and 1π rad/s2 acceleration limit
  Direction           Range                Unit
                 Min         Max 
   linear.x     -1.5         1.5           m/s
   linear.y     -1.5         1.5           m/s
   angular.z    -2.1(0.67π)  2.1(-0.67π)   rad/s

/mobility_base/cmd_vel_raw (geometry_msgs/Twist)

  • 5 Hz timeout
  • 4 m/s2 and 3π rad/s2 acceleration limit
  Direction           Range                Unit
                 Min         Max 
   linear.x     -1.5         1.5           m/s
   linear.y     -1.5         1.5           m/s
   angular.z    -2.1(0.67π)  2.1(-0.67π)   rad/s

Published Topics

/mobility_base/twist (geometry_msgs/TwistStamped)

  • 250 Hz
  Direction           Range                Unit
                 Min         Max 
   linear.x     -1.5         1.5           m/s
   linear.y     -1.5         1.5           m/s
   angular.z    -2.1(0.67π)  2.1(-0.67π)   rad/s

/mobility_base/wrench (geometry_msgs/WrenchStamped)

  • 250 Hz
   Direction        Range         Unit
                Min       Max 
   force.x     -0.3175    0.3175     N
   force.y     -0.3175    0.3175     N
   torque.z    -50        50         Nm

/mobility_base/mode (mobility_base_core_msgs/Mode)

  • 2 Hz or on change
  • Latched topic
    MODE_ESTOP             – ESTOP enabled.
    MODE_DISABLED          – mobility base disabled, No control on motion
    MODE_BATTERY_LIMP_HOME - Battery low, motion is possible with minimum velocity
    MODE_BATTERY_CRITICAL  - Battery is critically low, motion impossible, mobility base will be shut down in no time
    MODE_MOTOR_FAULT       - motor fault
    MODE_WIRELESS          - Control wireless.
    MODE_TIMEOUT           - command receiving timed out in manual mode, control mode will change to computer mode
    MODE_VELOCITY          – low acceleration
    MODE_VELOCITY_RAW      – high acceleration

Services

/mobility_base/get_max_speed (mobility_base_core_msgs/GetMaxSpeed)

/mobility_base/set_max_speed (mobility_base_core_msgs/SetMaxSpeed)

Joints

Published Topics

/mobility_base/joint_states (sensor_msgs/JointState)

  • 250 Hz
                 Range             Unit
             Min        Max
Position    -10π(31.4)  10π(-31.4)  rad
Velocity    -18.137     18.137      rad/s
Effort      -50         50          Nm

/tf (tf/tfMessage)

  • 30 Hz

Wireless Joystick

Subscribed Topics

/mobility_base/suppress_wireless (std_msgs/Empty)

  • The wireless joystick will be ignored as long as messages are received on this topic
  • 5 Hz timeout
  • rostopic pub /mobility_base/suppress_wireless std_msgs/Empty -r 10

Published Topics

/mobility_base/joystick (geometry_msgs/TwistStamped)

  • 50 Hz
  Direction           Range                Unit
                 Min         Max 
   linear.x     -1.5         1.5           m/s
   linear.y     -1.5         1.5           m/s
   angular.z    -2.1(0.67π)  2.1(-0.67π)   rad/s

/mobility_base/joystick_raw (mobility_base_core_msgs/JoystickRaw)

  • 50 Hz

Bumpers

Published Topics

/mobility_base/bumper_states (mobility_base_core_msgs/BumperState)

  • 10 Hz or on change
  • Latched topic

Battery

Published Topics

/mobility_base/battery (mobility_base_core_msgs/BatteryState)

  • 0.5 Hz
  • Latched topic

IMU

The mobility base includes a 3-axis accelerometer, gyroscope, and magnetometer. Calibration is stored in non-volatile memory.

A problem with the IMU data has been identified. Until further notice, the magnetometer topic is not published, and accelerometer is set to NAN. Gyroscope data is not affected by this issue.

Published Topics

/mobility_base/imu/data_raw (sensor_msgs/Imu)

  • 100 Hz
              Range            Unit
         Min        Max
Accel   -0.01913    0.01913    m/s2
        -8.0        8.0        g
Gyro    -2.44       2.44       rad/s
        -2000       2000       deg/s


/mobility_base/imu/mag (sensor_msgs/MagneticField)

  • 100 Hz
               Range             Unit
           Min         Max
Magneto   -0.00016    0.00016    gauss
          -2.0        2.0        gauss

/mobility_base/imu/is_calibrated (std_msgs/Bool)

  • Latched topic
  • One new message for every call of /mobility_base/imu/calibrate

Services

/mobility_base/imu/calibrate (std_srvs/Empty)

Floor Camera

The floor camera publishes monochrome 640x480 images at 15Hz (frequency can be configured, follow the link for more details Config) using the standard ROS message types. The image_proc package is used to rectify the raw image using the camera_info calibration. The floor camera is intended for use with the QR Codes to provide fine localization at supported workstations. The camera is calibrated before shipment, and re-calibration is not recommended.

Published Topics

Raw Image /mobility_base/floor_camera/image_raw (sensor_msgs/Image)

Rectified Image /mobility_base/floor_camera/image_rect (sensor_msgs/Image)

Camera Intrinsics /mobility_base/floor_camera/camera_info (sensor_msgs/CameraInfo)

Services

/mobility_base/floor_camera/set_camera_info (sensor_msgs/SetCameraInfo)