Ackermann Kinematic Modeling for AWS DeepRacer
AWS DeepRacer uses Ackermann front-wheel steering to turn wheels on the inside and outside of a turn. This mean that the left and right front wheels generally turn at different angles.
In AWS DeepRacer, the calibration is done on the center value.
As the Ackermann mechanism lets all wheels drive on circles with a common center point, its kinematics can be approximated by those of a tricycle with rear-wheel drive.
Let the car have the shape of a box with length L between rear and front axis. Let the center point of the common circle described by all wheels be distance R from the car’s longitudinal center line.
Then, the steering angle δ is given by
Let the robot coordinate system
be centered on the car’s rear axis. Then,
is the car’s speed given by the speed of the car’s engine. We can now derive expressions for the car’s position in world coordinates
(Remember: as the car is non-holonomic we can derive the kinematics only for speeds, the derivative of position, without integrating)
The last expression directly follows from the rule that the tangent of an angle is equivalent to the ratio of its opposite to adjacent edges. At this point it is worth recalling that
no matter what, as a simple model does not allow the robot to skid. Therefore, the steering angle
only affects the rotation of the car.
At this point, you have expressions for predicting the movement of the car’s bounding box through space as a function of speed and steering angle. The angles of the left and the right wheel,
and
can be calculated using the fact that all wheels of the car rotate around circles with a common center point. With the distance between the two front wheels
we can therefore write
with
again following the rule tangent = opposite / adjacent.
This is important to calculate the resulting wheel angles and to test whether they are within the constraints of the actual vehicle.