Public Member Functions | Private Attributes | List of all members
xbot::AccelerationLimiter Class Reference

An acceleration limiter for the xbot. More...

#include <acceleration_limiter.hpp>

Public Member Functions

 AccelerationLimiter ()
 
void init (bool enable_acceleration_limiter, float linear_acceleration_max_=0.5, float angular_acceleration_max_=3.5, float linear_deceleration_max_=-0.5 *1.2, float angular_deceleration_max_=-3.5 *1.2)
 
bool isEnabled () const
 
std::vector< float > limit (const std::vector< float > &command)
 Limits the input velocity commands if gatekeeper is enabled. More...
 
std::vector< float > limit (const float &vx, const float &wz)
 

Private Attributes

float angular_acceleration_max
 
float angular_deceleration_max
 
float command_vx
 
float command_wz
 
bool is_enabled
 
short last_radius
 
short last_speed
 
ecl::TimeStamp last_timestamp
 
float last_vx
 
float last_wz
 
float linear_acceleration_max
 
float linear_deceleration_max
 

Detailed Description

An acceleration limiter for the xbot.

This class will check incoming velocity commands and limit them if the change since the last incoming command is great.

Right now, this hasn't got any configurable parameters for the user - that might be an option to provide for users in the future. Ideally

Definition at line 50 of file acceleration_limiter.hpp.

Constructor & Destructor Documentation

xbot::AccelerationLimiter::AccelerationLimiter ( )
inline

Definition at line 52 of file acceleration_limiter.hpp.

Member Function Documentation

void xbot::AccelerationLimiter::init ( bool  enable_acceleration_limiter,
float  linear_acceleration_max_ = 0.5,
float  angular_acceleration_max_ = 3.5,
float  linear_deceleration_max_ = -0.5*1.2,
float  angular_deceleration_max_ = -3.5*1.2 
)
inline

Definition at line 57 of file acceleration_limiter.hpp.

bool xbot::AccelerationLimiter::isEnabled ( ) const
inline

Definition at line 68 of file acceleration_limiter.hpp.

std::vector<float> xbot::AccelerationLimiter::limit ( const std::vector< float > &  command)
inline

Limits the input velocity commands if gatekeeper is enabled.

What is the limit?

Parameters
command: translation and angular velocity components in a 2-dim vector.

Definition at line 77 of file acceleration_limiter.hpp.

std::vector<float> xbot::AccelerationLimiter::limit ( const float &  vx,
const float &  wz 
)
inline

Definition at line 79 of file acceleration_limiter.hpp.

Member Data Documentation

float xbot::AccelerationLimiter::angular_acceleration_max
private

Definition at line 135 of file acceleration_limiter.hpp.

float xbot::AccelerationLimiter::angular_deceleration_max
private

Definition at line 135 of file acceleration_limiter.hpp.

float xbot::AccelerationLimiter::command_vx
private

Definition at line 133 of file acceleration_limiter.hpp.

float xbot::AccelerationLimiter::command_wz
private

Definition at line 133 of file acceleration_limiter.hpp.

bool xbot::AccelerationLimiter::is_enabled
private

Definition at line 126 of file acceleration_limiter.hpp.

short xbot::AccelerationLimiter::last_radius
private

Definition at line 128 of file acceleration_limiter.hpp.

short xbot::AccelerationLimiter::last_speed
private

Definition at line 127 of file acceleration_limiter.hpp.

ecl::TimeStamp xbot::AccelerationLimiter::last_timestamp
private

Definition at line 130 of file acceleration_limiter.hpp.

float xbot::AccelerationLimiter::last_vx
private

Definition at line 132 of file acceleration_limiter.hpp.

float xbot::AccelerationLimiter::last_wz
private

Definition at line 132 of file acceleration_limiter.hpp.

float xbot::AccelerationLimiter::linear_acceleration_max
private

Definition at line 134 of file acceleration_limiter.hpp.

float xbot::AccelerationLimiter::linear_deceleration_max
private

Definition at line 134 of file acceleration_limiter.hpp.


The documentation for this class was generated from the following file:


xbot_driver
Author(s): Roc, wangpeng@droid.ac.cn
autogenerated on Sat Oct 10 2020 03:27:38