20 PID(
float Kp,
float Ki,
float Kd): Kp(Kp), Ki(Ki), Kd(Kd) {}
28 float Run(
float Input,
float DeltaTime)
104 void RunControlSteering();
107 bool RunControlFullStop();
108 void RunControlReverse();
109 void RunControlSpeed();
110 void RunControlAcceleration();
111 void UpdateVehicleControlCommand();
115 PID SpeedController =
PID(0.15f, 0.0f, 0.25f);
116 PID AccelerationController =
PID(0.01f, 0.0f, 0.01f);
121 float TargetSteer = 0.0;
122 float TargetSteerSpeed = 0.0;
123 float TargetSpeed = 0.0;
124 float TargetAcceleration = 0.0;
125 float TargetJerk = 0.0;
128 float MaxAccel = 3.0f;
129 float MaxDecel = 8.0f;
133 float Throttle = 0.0f;
135 bool bReverse =
false;
138 float SpeedControlAccelDelta = 0.0f;
139 float SpeedControlAccelTarget = 0.0f;
141 float AccelControlPedalDelta = 0.0f;
142 float AccelControlPedalTarget = 0.0f;
145 float DeltaTime = 0.0f;
148 float VehicleMaxSteering = 0.0f;
150 float VehicleSteer = 0.0f;
151 float VehicleSpeed = 0.0f;
152 float VehicleAcceleration = 0.0f;
154 float LastVehicleSpeed = 0.0f;
155 float LastVehicleAcceleration = 0.0f;
PID(float Kp, float Ki, float Kd)
void SetTargetPoint(float Point)
FVehicleAckermannControl UserTargetPoint
float Run(float Input, float DeltaTime)
Base class for CARLA wheeled vehicles.