◆ BangBangTrajectory1D()
◆ generate()
| void generate |
( |
double |
initial_pos, |
|
|
double |
final_pos, |
|
|
double |
initial_vel, |
|
|
double |
max_vel, |
|
|
double |
max_accel, |
|
|
double |
max_decel |
|
) |
| |
Generate a 1D trajectory from the initial position to the final position with the given initial velocity and kinematic constraints.
- Note
- This method will overwrite the existing trajectory.
-
The generated trajectory will always have a final velocity of 0
- Parameters
-
| initial_pos | Starting position of the trajectory |
| final_pos | Destination. Where the trajectory should end at |
| initial_vel | The velocity at the start of the trajectory |
| max_vel | The maximum velocity (magnitude) the trajectory could have. Must be non-zero. |
| max_accel | The maximum acceleration the trajectory could have. Must be non-zero. |
| max_decel | The maximum deceleration the trajectory could have. Must be non-zero. |
◆ getAcceleration()
| double getAcceleration |
( |
double |
t_sec | ) |
const |
|
overridevirtual |
◆ getMinMaxPositions()
| std::pair< double, double > getMinMaxPositions |
( |
| ) |
const |
Get the minimum and maximum positions that the trajectory will reach
- Returns
- A pair where the first value is the minimum and the second value is the maximum positions
◆ getNumTrajectoryParts()
| size_t getNumTrajectoryParts |
( |
| ) |
const |
Get the number of trajectory parts that make up the generated trajectory.
- Returns
- The number of trajectory parts
◆ getPosition()
| double getPosition |
( |
double |
t_sec | ) |
const |
|
overridevirtual |
◆ getTotalTime()
| double getTotalTime |
( |
| ) |
const |
|
inlineoverridevirtual |
◆ getTrajectoryPart()
Get the trajectory part at index that makes up the generated trajectory
- Note
- Crashes if index is out of bound
- Returns
- Trajectory parts
◆ getVelocity()
| double getVelocity |
( |
double |
t_sec | ) |
const |
|
overridevirtual |
The documentation for this class was generated from the following files:
- src/software/ai/navigator/trajectory/bang_bang_trajectory_1d.h
- src/software/ai/navigator/trajectory/bang_bang_trajectory_1d.cpp