Class SteeringLimiter

Class Documentation

class SteeringLimiter

Public Functions

SteeringLimiter(double min_position = NAN, double max_position = NAN, double min_velocity = NAN, double max_velocity = NAN, double min_acceleration = NAN, double max_acceleration = NAN)

Constructor.

Parameters:
  • min_position[in] Minimum position [m] or [rad]

  • max_position[in] Maximum position [m] or [rad]

  • min_velocity[in] Minimum velocity [m/s] or [rad/s]

  • max_velocity[in] Maximum velocity [m/s] or [rad/s]

  • min_acceleration[in] Minimum acceleration [m/s^2] or [rad/s^2]

  • max_acceleration[in] Maximum acceleration [m/s^2] or [rad/s^2]

double limit(double &p, double p0, double p1, double dt)

Limit the position, velocity and acceleration.

Parameters:
  • p[inout] position [m] or [rad]

  • p0[in] Previous position to p [m] or [rad]

  • p1[in] Previous position to p0 [m] or [rad]

  • dt[in] Time step [s]

Returns:

Limiting factor (1.0 if none)

double limit_position(double &p)

Limit the jerk.

Parameters:
  • p[inout] position [m] or [rad]

  • p0[in] Previous position to p [m] or [rad]

  • p1[in] Previous position to p0 [m] or [rad]

  • dt[in] Time step [s]

Returns:

Limiting factor (1.0 if none)

double limit_velocity(double &p, double p0, double dt)

Limit the velocity.

Parameters:

p[inout] position [m]

Returns:

Limiting factor (1.0 if none)

double limit_acceleration(double &p, double p0, double p1, double dt)

Limit the acceleration.

Parameters:
  • p[inout] Position [m] or [rad]

  • p0[in] Previous position [m] or [rad]

  • dt[in] Time step [s]

Returns:

Limiting factor (1.0 if none)