BuysDB.nl

Home of Buys de Barbanson

Ackermann steering in javascript

Hobby project: get a car to drive and steer.

I always wanted to program a car driving. I underestimated the complexity of this when I started, there are many translations involved, and I programmed this at a time when I didn't know about linear algebra. This implementation is written in javascript and uses the HTML 5 canvas to render on. This implementation uses the ackermann steering principle to move the car. Thus by this principle all axles point to a single center point which is also visualized in the simulation. Use the arrows on the keyboard to steer the car. The other cars will follow you and go right through you as I didn't bother implementing collision detection. Click

Screenshot of the Ackermann steering implementation in javascript
Link to this article