42 std::string& frame_id)
override 57 bool stop(
bool isEmergencyStop)
override 60 0.0 , 0 , isEmergencyStop ? 0.1 : 1.0 ,
78 const double relative_heading_radians)
override 83 relative_heading_radians,
128 std::string& frame_id)
override 143 bool stop(
bool isEmergencyStop)
override mrpt::kinematics::CVehicleVelCmd::Ptr getStopCmd() override
Gets the emergency stop command for the current robot.
double m_simul_time_start
for getNavigationTime
bool changeSpeeds(const mrpt::kinematics::CVehicleVelCmd &vel_cmd) override
Sends a velocity command to the robot.
void resetNavigationTimer() override
See CRobot2NavInterface::resetNavigationTimer()
mrpt::kinematics::CVehicleVelCmd::Ptr getEmergencyStopCmd() override
Gets the emergency stop command for the current robot.
mrpt::system::TTimeStamp now()
A shortcut for system::getCurrentTime.
void resetNavigationTimer() override
See CRobot2NavInterface::resetNavigationTimer()
double getNavigationTime() override
See CRobot2NavInterface::getNavigationTime().
bool stop(bool isEmergencyStop) override
Stop the robot right now.
void sendVelRampCmd(double vel, double dir, double ramp_time, double rot_speed)
Sends a velocity cmd to the holonomic robot.
mrpt::kinematics::CVehicleSimul_Holo & m_simul
const mrpt::math::TTwist2D & getCurrentGTVel() const
Returns the instantaneous, ground truth velocity vector (vx,vy,omega) in world coordinates.
const mrpt::math::TPose2D & getCurrentGTPose() const
Returns the instantaneous, ground truth pose in world coordinates.
Virtual base for velocity commands of different kinematic models of planar mobile robot...
2D twist: 2D velocity vector (vx,vy) + planar angular velocity (omega)
mrpt::Clock::time_point TTimeStamp
A system independent time type, it holds the the number of 100-nanosecond intervals since January 1...
double getNavigationTime() override
See CRobot2NavInterface::getNavigationTime().
void sendVelCmd(const CVehicleVelCmd &cmd_vel) override
Sends a velocity command to the robot.
CRobot2NavInterface implemented for a simulator object based on mrpt::kinematics::CVehicleSimul_DiffD...
CRobot2NavInterfaceForSimulator_DiffDriven(mrpt::kinematics::CVehicleSimul_DiffDriven &simul)
constexpr double DEG2RAD(const double x)
Degrees to radians.
Simulates the kinematics of a differential-driven planar mobile robot/vehicle, including odometry err...
double getTime() const
Get the current simulation time.
mrpt::kinematics::CVehicleVelCmd::Ptr getAlignCmd(const double relative_heading_radians) override
Gets a motion command to make the robot to align with a given relative heading, without translating...
bool getCurrentPoseAndSpeeds(mrpt::math::TPose2D &curPose, mrpt::math::TTwist2D &curVel, mrpt::system::TTimeStamp ×tamp, mrpt::math::TPose2D &curOdometry, std::string &frame_id) override
Get the current pose and velocity of the robot.
bool stop(bool isEmergencyStop) override
Stop the robot right now.
TCLAP::CmdLine cmd("system_control_rate_timer_example")
Kinematic simulator of a holonomic 2D robot capable of moving in any direction, with "blended" veloci...
double m_simul_time_start
for getNavigationTime
CRobot2NavInterface implemented for a simulator object based on mrpt::kinematics::CVehicleSimul_Holo...
mrpt::kinematics::CVehicleSimul_DiffDriven & m_simul
bool getCurrentPoseAndSpeeds(mrpt::math::TPose2D &curPose, mrpt::math::TTwist2D &curVel, mrpt::system::TTimeStamp ×tamp, mrpt::math::TPose2D &curOdometry, std::string &frame_id) override
Get the current pose and velocity of the robot.
mrpt::kinematics::CVehicleVelCmd::Ptr getStopCmd() override
Gets the emergency stop command for the current robot.
std::shared_ptr< CVehicleVelCmd > Ptr
The pure virtual interface between a real or simulated robot and any CAbstractNavigator-derived class...
mrpt::kinematics::CVehicleVelCmd::Ptr getEmergencyStopCmd() override
Gets the emergency stop command for the current robot.
const mrpt::math::TPose2D & getCurrentOdometricPose() const
Returns the current pose according to (noisy) odometry.
bool changeSpeeds(const mrpt::kinematics::CVehicleVelCmd &vel_cmd) override
Sends a velocity command to the robot.
Kinematic model for Ackermann-like or differential-driven vehicles.
CRobot2NavInterfaceForSimulator_Holo(mrpt::kinematics::CVehicleSimul_Holo &simul)
int signWithZero(T x)
Returns the sign of X as "0", "1" or "-1".
void sendVelCmd(const CVehicleVelCmd &cmd_vel) override
Sends a velocity command to the robot.