#include <SlipLaunchController.h>
|
| | TorqueControllerSlipLaunch (float slip_ratio, int16_t initial_speed_target) |
| |
| | TorqueControllerSlipLaunch () |
| | default constructor for slip launch controller: DEFAULT_SLIP_RATIO = 0.2, DEFAULT_LAUNCH_SPEED_TARGET = 1500(rpm) More...
|
| |
| void | calc_launch_algo (const VectornavData_s &vn_data) override |
| | Increases speed target during launch linearly according to slip ratio to keep the cars wheels spinning faster than the velocity for increased traction. More...
|
| |
| | BaseLaunchController (int16_t initial_speed_target) |
| | Constructor for parent launch controller. More...
|
| |
| void | tick (const SysTick_s &tick, const PedalsSystemData_s &pedalsData, const float wheel_rpms[], const VectornavData_s &vn_data) |
| | ticks launch controller to progress through launch states when conditions are met. The conditions are explained above the launch states enum. all launch controllers use this class' implementation of tick. tick conatains the current system tick controlled by main.cpp pedalsData conatins the brake and accelerator values wheel_rpms[] contains how fast each wheel is spinning, order of wheels in this array is defined in SharedDataTypes.h and Utility.h vn_data contains vector states of the car that will be provided to the calc_launch_algo method called in the LAUNCHING state of this set of modes More...
|
| |
| LaunchStates_e | get_launch_state () |
| |
| virtual void | calc_launch_algo (const VectornavData_s &vn_data)=0 |
| | calculates how speed target (the speed the car is trying to achieve during launch) is set and/or increased during launch This updates internal speed target variable launch_speed_target_ More...
|
| |
| TorqueControllerOutput_s | evaluate (const SharedCarState_s &state) override |
| | all launch controllers share the same evaluate method implemented in this class implementation. More...
|
| |
| virtual TorqueControllerOutput_s | evaluate (const SharedCarState_s &state)=0 |
| | This mehod must be implemented by every controller in the Tc Muxer. This is called in the Muxer whenever the drivetrain command is obtained. TorqueControllerMux.cpp to see that in every tick of the system, the active controller must be ticked through this method. More...
|
| |
Definition at line 10 of file SlipLaunchController.h.
◆ TorqueControllerSlipLaunch() [1/2]
| TorqueControllerSlipLaunch::TorqueControllerSlipLaunch |
( |
float |
slip_ratio, |
|
|
int16_t |
initial_speed_target |
|
) |
| |
|
inline |
SLIP LAUNCH CONTROLLER This launch controller is based off of a specified slip constant. It will at all times attempt to keep the wheelspeed at this certain higher percent of the body velocity of the car to keep it in constant slip
- Parameters
-
| slip_ratio | specified launch rate in m/s^2 |
| initial_speed_target | the initial speed commanded to the wheels |
Definition at line 24 of file SlipLaunchController.h.
◆ TorqueControllerSlipLaunch() [2/2]
| TorqueControllerSlipLaunch::TorqueControllerSlipLaunch |
( |
| ) |
|
|
inline |
default constructor for slip launch controller: DEFAULT_SLIP_RATIO = 0.2, DEFAULT_LAUNCH_SPEED_TARGET = 1500(rpm)
Definition at line 28 of file SlipLaunchController.h.
TorqueControllerSlipLaunch()
default constructor for slip launch controller: DEFAULT_SLIP_RATIO = 0.2, DEFAULT_LAUNCH_SPEED_TARGET...
const float DEFAULT_SLIP_RATIO
const int16_t DEFAULT_LAUNCH_SPEED_TARGET
◆ calc_launch_algo()
| void TorqueControllerSlipLaunch::calc_launch_algo |
( |
const VectornavData_s & |
vn_data | ) |
|
|
overridevirtual |
Increases speed target during launch linearly according to slip ratio to keep the cars wheels spinning faster than the velocity for increased traction.
- Parameters
-
| vn_data | This controller needs velocity data for to keep updating increasing the speed according to the slip ratio |
Implements BaseLaunchController.
Definition at line 47 of file LaunchControllerAlgos.cpp.
48{
49
50
51
52
54
55
56
57
58
59
60
62
64
65
67}
constexpr const float METERS_PER_SECOND_TO_RPM
float launch_speed_target_
◆ slip_ratio_
| float TorqueControllerSlipLaunch::slip_ratio_ |
|
private |
The documentation for this class was generated from the following files: