|
Apartment Navigation
Gazebo Sim plugin for apartment robot navigation
|
Gazebo Sim plugin for differential drive robot via cmd_vel. More...
Public Member Functions | |
| void | Configure (const gz::sim::Entity &p_entity, const std::shared_ptr< const sdf::Element > &_sdf, gz::sim::EntityComponentManager &p_ecm, gz::sim::EventManager &_eventMgr) override |
| Called once when the plugin is loaded. | |
| void | PreUpdate (const gz::sim::UpdateInfo &p_info, gz::sim::EntityComponentManager &p_ecm) override |
| Called every simulation step before physics integration. Called repeadedly, even when simulation is paused. | |
Gazebo Sim plugin for differential drive robot via cmd_vel.
Subscribes to /model/<name>/cmd_vel (gz.msgs.Twist) and uses differential drive kinematics to map to left and right wheel angular velocities:
Register in your SDF with:
|
inlineoverride |
Called once when the plugin is loaded.
Resolves the model entity and subscribes to its cmd_vel topic.
| p_entity | SDF entity that owns this plugin. |
| _sdf | Parsed SDF element (unused). |
| p_ecm | Entity-component manager for the simulation world. |
| _eventMgr | Event manager (unused). |
|
inlineoverride |
Called every simulation step before physics integration. Called repeadedly, even when simulation is paused.
Reads the latest velocity command (under mutex) and applies differential drive kinematics to compute left and right wheel velocities, then commands both wheels via JointVelocityCmd components.
| p_info | Simulation step metadata (time, paused flag, …). |
| p_ecm | Entity-component manager for the simulation world. |