13 #ifndef KOBUKI_ACCELERATION_LIMITER_HPP_ 14 #define KOBUKI_ACCELERATION_LIMITER_HPP_ 63 void init(
bool enable_acceleration_limiter
64 ,
double linear_acceleration_max_= 0.5,
double angular_acceleration_max_= 3.5
65 ,
double linear_deceleration_max_=-0.5*1.2,
double angular_deceleration_max_=-3.5*1.2)
83 std::vector<double>
limit(
const std::vector<double> &command) {
return limit(command[0], command[1]); }
85 std::vector<double>
limit(
const double &vx,
const double &wz)
89 ecl::TimeStamp curr_timestamp;
93 double linear_acceleration = ((double)(vx -
last_vx)) / duration;
94 double angular_acceleration = ((double)(wz -
last_wz)) / duration;
119 last_timestamp = curr_timestamp;
124 std::vector<double> ret_val;
double angular_deceleration_max
double angular_acceleration_max
double linear_acceleration_max
std::vector< double > limit(const std::vector< double > &command)
Limits the input velocity commands if gatekeeper is enabled.
std::vector< double > limit(const double &vx, const double &wz)
double linear_deceleration_max
ecl::TimeStamp last_timestamp
An acceleration limiter for the kobuki.
void init(bool enable_acceleration_limiter, double linear_acceleration_max_=0.5, double angular_acceleration_max_=3.5, double linear_deceleration_max_=-0.5 *1.2, double angular_deceleration_max_=-3.5 *1.2)