#include <MobilityBasePlugin.h>
Public Member Functions | |
void | Load (physics::ModelPtr _parent, sdf::ElementPtr sdf) |
MobilityBasePlugin () | |
~MobilityBasePlugin () | |
Static Public Attributes | |
static _CONST double | ACCEL_INSTANT_VXY = 0.5 |
static _CONST double | ACCEL_INSTANT_WZ = 0.5 * M_PI |
static _CONST double | ACCEL_LIMIT_FAST_VXY = 4.0 |
static _CONST double | ACCEL_LIMIT_FAST_WZ = 3.0 * M_PI |
static _CONST double | ACCEL_LIMIT_SLOW_VXY = 1.0 |
static _CONST double | ACCEL_LIMIT_SLOW_WZ = 1.0 * M_PI |
static _CONST double | CMD_TIMEOUT = 0.2 |
static _CONST double | GAIN_X = 1.0 |
static _CONST double | GAIN_Y = 1.0 |
static _CONST double | GAIN_Z = 1.0 |
static _CONST unsigned int | NUM_ROLLERS = 12 |
static _CONST unsigned int | NUM_WHEELS = 4 |
static _CONST double | PUB_FREQ_BUMPERS = 10.0 |
static _CONST double | PUB_FREQ_IMU = 100.0 |
static _CONST double | PUB_FREQ_JOYSTICK = 50.0 |
static _CONST double | PUB_FREQ_MODE = 2.0 |
static _CONST double | PUB_FREQ_VEHICLE = 250.0 |
static _CONST double | RADIANS_PER_SECOND_MAX = 14000 * (2.0 * M_PI / (200 * 48.5 / 2)) |
static _CONST double | TORQUE_MAX_ALARM = 5.0 |
static _CONST double | TORQUE_MAX_GLOBAL = 50.0 |
static _CONST double | WHEEL_BASE_LENGTH = 0.505466 |
static _CONST double | WHEEL_BASE_WIDTH = 0.680466 |
static _CONST double | WHEEL_RADIUS = 8.0 / 2 * 0.0254 |
Protected Member Functions | |
virtual void | FiniChild () |
virtual void | UpdateChild (const common::UpdateInfo &_info) |
Private Member Functions | |
void | omniFromCartesian (double vx, double vy, double wz, double w[4]) const |
void | omniToCartesian (const double w[4], double *vx, double *vy, double *wz) const |
void | publishMode (const ros::Time &stamp) |
void | recvCmdVel (const geometry_msgs::Twist::ConstPtr &msg) |
void | recvCmdVelRaw (const geometry_msgs::Twist::ConstPtr &msg) |
void | recvSuppressWireless (const std_msgs::Empty::ConstPtr &msg) |
void | spin () |
Static Private Member Functions | |
static double | limitDelta (double input, double previous, double limit) |
static bool | omniSaturate (double limit, double speeds[4]) |
Private Attributes | |
std::string | child_frame_id_ |
math::Vector3 | cmd_vel_ |
math::Vector3 | cmd_vel_history_ |
boost::mutex | cmd_vel_mutex_ |
math::Vector3 | cmd_vel_raw_ |
boost::mutex | cmd_vel_raw_mutex_ |
common::Time | cmd_vel_raw_stamp_ |
common::Time | cmd_vel_stamp_ |
bool | fast_ |
bool | first_update_ |
const char * | frame_id_ |
physics::JointPtr | joint_rollers_ [NUM_WHEELS][NUM_ROLLERS] |
sensor_msgs::JointState | joint_state_rollers_ |
sensor_msgs::JointState | joint_state_wheels_ |
physics::JointPtr | joint_wheels_ [NUM_WHEELS] |
physics::LinkPtr | link_base_footprint_ |
mobility_base_core_msgs::Mode::_mode_type | mode_ |
physics::ModelPtr | model_ |
ros::NodeHandle * | nh_ |
double | omni_a_ |
double | omni_b_ |
double | omni_c_ |
std::string | parent_frame_id_ |
PubMultiQueue | pmq_ |
PubQueue < mobility_base_core_msgs::BumperState > ::Ptr | pmq_bumper_states_ |
PubQueue< sensor_msgs::Imu >::Ptr | pmq_imu_data_ |
PubQueue< std_msgs::Bool >::Ptr | pmq_imu_is_calibrated_ |
PubQueue < sensor_msgs::MagneticField > ::Ptr | pmq_imu_mag_ |
PubQueue < sensor_msgs::JointState > ::Ptr | pmq_joint_states_ |
PubQueue < geometry_msgs::TwistStamped > ::Ptr | pmq_joystick_ |
PubQueue < mobility_base_core_msgs::Mode > ::Ptr | pmq_mode_ |
PubQueue < geometry_msgs::TwistStamped > ::Ptr | pmq_twist_ |
PubQueue < geometry_msgs::WrenchStamped > ::Ptr | pmq_wrench_ |
common::Time | previous_stamp_ |
ros::Publisher | pub_bumper_states_ |
ros::Publisher | pub_imu_data_ |
ros::Publisher | pub_imu_is_calibrated_ |
ros::Publisher | pub_imu_mag_ |
ros::Publisher | pub_joint_states_ |
ros::Publisher | pub_joystick_ |
ros::Publisher | pub_mode_ |
ros::Publisher | pub_twist_ |
ros::Publisher | pub_wrench_ |
boost::thread * | spinner_thread_ |
common::Time | stamp_bumpers_ |
common::Time | stamp_imu_ |
common::Time | stamp_joystick_ |
common::Time | stamp_mode_ |
common::Time | stamp_vehicle_ |
ros::Subscriber | sub_cmd_vel_ |
ros::Subscriber | sub_cmd_vel_raw_ |
tf::TransformBroadcaster * | tf_broadcaster_ |
event::ConnectionPtr | update_connection_ |
physics::WorldPtr | world_ |
Definition at line 77 of file MobilityBasePlugin.h.
Definition at line 40 of file MobilityBasePlugin.cpp.
Definition at line 49 of file MobilityBasePlugin.cpp.
void gazebo::MobilityBasePlugin::FiniChild | ( | ) | [protected, virtual] |
Definition at line 58 of file MobilityBasePlugin.cpp.
static double gazebo::MobilityBasePlugin::limitDelta | ( | double | input, |
double | previous, | ||
double | limit | ||
) | [inline, static, private] |
Definition at line 224 of file MobilityBasePlugin.h.
void gazebo::MobilityBasePlugin::Load | ( | physics::ModelPtr | _parent, |
sdf::ElementPtr | sdf | ||
) |
Definition at line 84 of file MobilityBasePlugin.cpp.
void gazebo::MobilityBasePlugin::omniFromCartesian | ( | double | vx, |
double | vy, | ||
double | wz, | ||
double | w[4] | ||
) | const [private] |
Definition at line 64 of file MobilityBasePlugin.cpp.
static bool gazebo::MobilityBasePlugin::omniSaturate | ( | double | limit, |
double | speeds[4] | ||
) | [inline, static, private] |
Definition at line 203 of file MobilityBasePlugin.h.
void gazebo::MobilityBasePlugin::omniToCartesian | ( | const double | w[4], |
double * | vx, | ||
double * | vy, | ||
double * | wz | ||
) | const [private] |
Definition at line 78 of file MobilityBasePlugin.cpp.
void gazebo::MobilityBasePlugin::publishMode | ( | const ros::Time & | stamp | ) | [private] |
Definition at line 455 of file MobilityBasePlugin.cpp.
void gazebo::MobilityBasePlugin::recvCmdVel | ( | const geometry_msgs::Twist::ConstPtr & | msg | ) | [private] |
Definition at line 437 of file MobilityBasePlugin.cpp.
void gazebo::MobilityBasePlugin::recvCmdVelRaw | ( | const geometry_msgs::Twist::ConstPtr & | msg | ) | [private] |
Definition at line 446 of file MobilityBasePlugin.cpp.
void gazebo::MobilityBasePlugin::recvSuppressWireless | ( | const std_msgs::Empty::ConstPtr & | msg | ) | [private] |
void gazebo::MobilityBasePlugin::spin | ( | ) | [private] |
Definition at line 464 of file MobilityBasePlugin.cpp.
void gazebo::MobilityBasePlugin::UpdateChild | ( | const common::UpdateInfo & | _info | ) | [protected, virtual] |
Definition at line 199 of file MobilityBasePlugin.cpp.
_CONST double gazebo::MobilityBasePlugin::ACCEL_INSTANT_VXY = 0.5 [static] |
Definition at line 94 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::ACCEL_INSTANT_WZ = 0.5 * M_PI [static] |
Definition at line 95 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::ACCEL_LIMIT_FAST_VXY = 4.0 [static] |
Definition at line 90 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::ACCEL_LIMIT_FAST_WZ = 3.0 * M_PI [static] |
Definition at line 91 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::ACCEL_LIMIT_SLOW_VXY = 1.0 [static] |
Definition at line 92 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::ACCEL_LIMIT_SLOW_WZ = 1.0 * M_PI [static] |
Definition at line 93 of file MobilityBasePlugin.h.
Definition at line 198 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::CMD_TIMEOUT = 0.2 [static] |
Definition at line 89 of file MobilityBasePlugin.h.
Definition at line 134 of file MobilityBasePlugin.h.
Definition at line 149 of file MobilityBasePlugin.h.
boost::mutex gazebo::MobilityBasePlugin::cmd_vel_mutex_ [private] |
Definition at line 136 of file MobilityBasePlugin.h.
Definition at line 139 of file MobilityBasePlugin.h.
boost::mutex gazebo::MobilityBasePlugin::cmd_vel_raw_mutex_ [private] |
Definition at line 141 of file MobilityBasePlugin.h.
common::Time gazebo::MobilityBasePlugin::cmd_vel_raw_stamp_ [private] |
Definition at line 140 of file MobilityBasePlugin.h.
common::Time gazebo::MobilityBasePlugin::cmd_vel_stamp_ [private] |
Definition at line 135 of file MobilityBasePlugin.h.
bool gazebo::MobilityBasePlugin::fast_ [private] |
Definition at line 196 of file MobilityBasePlugin.h.
bool gazebo::MobilityBasePlugin::first_update_ [private] |
Definition at line 131 of file MobilityBasePlugin.h.
const char* gazebo::MobilityBasePlugin::frame_id_ [private] |
Definition at line 193 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::GAIN_X = 1.0 [static] |
Definition at line 105 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::GAIN_Y = 1.0 [static] |
Definition at line 106 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::GAIN_Z = 1.0 [static] |
Definition at line 107 of file MobilityBasePlugin.h.
physics::JointPtr gazebo::MobilityBasePlugin::joint_rollers_[NUM_WHEELS][NUM_ROLLERS] [private] |
Definition at line 128 of file MobilityBasePlugin.h.
sensor_msgs::JointState gazebo::MobilityBasePlugin::joint_state_rollers_ [private] |
Definition at line 156 of file MobilityBasePlugin.h.
sensor_msgs::JointState gazebo::MobilityBasePlugin::joint_state_wheels_ [private] |
Definition at line 155 of file MobilityBasePlugin.h.
physics::JointPtr gazebo::MobilityBasePlugin::joint_wheels_[NUM_WHEELS] [private] |
Definition at line 127 of file MobilityBasePlugin.h.
physics::LinkPtr gazebo::MobilityBasePlugin::link_base_footprint_ [private] |
Definition at line 129 of file MobilityBasePlugin.h.
mobility_base_core_msgs::Mode::_mode_type gazebo::MobilityBasePlugin::mode_ [private] |
Definition at line 150 of file MobilityBasePlugin.h.
physics::ModelPtr gazebo::MobilityBasePlugin::model_ [private] |
Definition at line 125 of file MobilityBasePlugin.h.
ros::NodeHandle* gazebo::MobilityBasePlugin::nh_ [private] |
Definition at line 153 of file MobilityBasePlugin.h.
_CONST unsigned int gazebo::MobilityBasePlugin::NUM_ROLLERS = 12 [static] |
Definition at line 84 of file MobilityBasePlugin.h.
_CONST unsigned int gazebo::MobilityBasePlugin::NUM_WHEELS = 4 [static] |
Definition at line 83 of file MobilityBasePlugin.h.
double gazebo::MobilityBasePlugin::omni_a_ [private] |
Definition at line 190 of file MobilityBasePlugin.h.
double gazebo::MobilityBasePlugin::omni_b_ [private] |
Definition at line 191 of file MobilityBasePlugin.h.
double gazebo::MobilityBasePlugin::omni_c_ [private] |
Definition at line 192 of file MobilityBasePlugin.h.
Definition at line 197 of file MobilityBasePlugin.h.
Definition at line 178 of file MobilityBasePlugin.h.
PubQueue<mobility_base_core_msgs::BumperState>::Ptr gazebo::MobilityBasePlugin::pmq_bumper_states_ [private] |
Definition at line 186 of file MobilityBasePlugin.h.
PubQueue<sensor_msgs::Imu>::Ptr gazebo::MobilityBasePlugin::pmq_imu_data_ [private] |
Definition at line 179 of file MobilityBasePlugin.h.
PubQueue<std_msgs::Bool>::Ptr gazebo::MobilityBasePlugin::pmq_imu_is_calibrated_ [private] |
Definition at line 180 of file MobilityBasePlugin.h.
PubQueue<sensor_msgs::MagneticField>::Ptr gazebo::MobilityBasePlugin::pmq_imu_mag_ [private] |
Definition at line 181 of file MobilityBasePlugin.h.
PubQueue<sensor_msgs::JointState>::Ptr gazebo::MobilityBasePlugin::pmq_joint_states_ [private] |
Definition at line 185 of file MobilityBasePlugin.h.
PubQueue<geometry_msgs::TwistStamped>::Ptr gazebo::MobilityBasePlugin::pmq_joystick_ [private] |
Definition at line 183 of file MobilityBasePlugin.h.
PubQueue<mobility_base_core_msgs::Mode>::Ptr gazebo::MobilityBasePlugin::pmq_mode_ [private] |
Definition at line 187 of file MobilityBasePlugin.h.
PubQueue<geometry_msgs::TwistStamped>::Ptr gazebo::MobilityBasePlugin::pmq_twist_ [private] |
Definition at line 182 of file MobilityBasePlugin.h.
PubQueue<geometry_msgs::WrenchStamped>::Ptr gazebo::MobilityBasePlugin::pmq_wrench_ [private] |
Definition at line 184 of file MobilityBasePlugin.h.
common::Time gazebo::MobilityBasePlugin::previous_stamp_ [private] |
Definition at line 130 of file MobilityBasePlugin.h.
Definition at line 174 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::PUB_FREQ_BUMPERS = 10.0 [static] |
Definition at line 102 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::PUB_FREQ_IMU = 100.0 [static] |
Definition at line 100 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::PUB_FREQ_JOYSTICK = 50.0 [static] |
Definition at line 101 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::PUB_FREQ_MODE = 2.0 [static] |
Definition at line 103 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::PUB_FREQ_VEHICLE = 250.0 [static] |
Definition at line 99 of file MobilityBasePlugin.h.
Definition at line 167 of file MobilityBasePlugin.h.
Definition at line 168 of file MobilityBasePlugin.h.
Definition at line 169 of file MobilityBasePlugin.h.
Definition at line 173 of file MobilityBasePlugin.h.
Definition at line 171 of file MobilityBasePlugin.h.
Definition at line 175 of file MobilityBasePlugin.h.
Definition at line 170 of file MobilityBasePlugin.h.
Definition at line 172 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::RADIANS_PER_SECOND_MAX = 14000 * (2.0 * M_PI / (200 * 48.5 / 2)) [static] |
Definition at line 88 of file MobilityBasePlugin.h.
boost::thread* gazebo::MobilityBasePlugin::spinner_thread_ [private] |
Definition at line 160 of file MobilityBasePlugin.h.
common::Time gazebo::MobilityBasePlugin::stamp_bumpers_ [private] |
Definition at line 147 of file MobilityBasePlugin.h.
common::Time gazebo::MobilityBasePlugin::stamp_imu_ [private] |
Definition at line 145 of file MobilityBasePlugin.h.
common::Time gazebo::MobilityBasePlugin::stamp_joystick_ [private] |
Definition at line 146 of file MobilityBasePlugin.h.
common::Time gazebo::MobilityBasePlugin::stamp_mode_ [private] |
Definition at line 148 of file MobilityBasePlugin.h.
common::Time gazebo::MobilityBasePlugin::stamp_vehicle_ [private] |
Definition at line 144 of file MobilityBasePlugin.h.
Definition at line 163 of file MobilityBasePlugin.h.
Definition at line 164 of file MobilityBasePlugin.h.
Definition at line 154 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::TORQUE_MAX_ALARM = 5.0 [static] |
Definition at line 97 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::TORQUE_MAX_GLOBAL = 50.0 [static] |
Definition at line 96 of file MobilityBasePlugin.h.
Definition at line 124 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::WHEEL_BASE_LENGTH = 0.505466 [static] |
Definition at line 87 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::WHEEL_BASE_WIDTH = 0.680466 [static] |
Definition at line 86 of file MobilityBasePlugin.h.
_CONST double gazebo::MobilityBasePlugin::WHEEL_RADIUS = 8.0 / 2 * 0.0254 [static] |
Definition at line 85 of file MobilityBasePlugin.h.
physics::WorldPtr gazebo::MobilityBasePlugin::world_ [private] |
Definition at line 126 of file MobilityBasePlugin.h.