F1TENTH Autonomous Racing

First place internationally with self-driving RC cars

This project started as coursework and ended with a first-place finish at the F1TENTH (now RoboRacer) autonomous racing competition at the International Conference on Robotics & Automation (ICRA) 2022. The F1TENTH platform is a 1/10th scale autonomous racecar; the competition involves both a time trial and head-to-head racing against an opponent, so the solution needed to go fast and handle adversarial situations. This was a team effort where I personally was in charge of devising and implementing new ideas to gain an edge over the competition.

1) An F1TENTH race car, equipped with LiDAR and an NVIDIA Jetson computer. (Credit to PennToday for the image.) 2) The car in simulation using MPC to stay within the track's bounds. The receding horizon shows the ideal path as a line and the MPC-tweaked points. Color indicates the desired speed, with green being high and red being low.

The natural starting point was PID for steering, which does a remarkable amount of heavy lifting before you ever need anything fancier. For head-to-head racing, I implemented dynamically-created half-plane barriers to reason about the opposing car and decide when to overtake using a model-predictive control (MPC) scheme, seen below here. Unfortunately, the onboard NVIDIA Jetson wasn’t powerful enough to handle the MPC controller I wrote at a high enough frequency, meaning it was unsuitable for hardware deployment.

A video showing the MPC controller working with opponent avoidance in simulation.

I also attempted an Antilock Brake System (ABS) to avoid sliding while braking by releasing the brakes when slipping was detected, but it turned out to be slower than simply braking hard—sometimes the mechanically simple answer wins. Still, it was neat how it made the single-gear electronic car sound like it was downshifting into a corner.

The most productive implementation was parameterizing the racing line corner-by-corner using continuous curvature spirals (to ensure smooth steering), encoding braking distances and turn entry/exit points based on the car’s actual dynamics just like a driver honing a lap. This allowed for a great amount of tweaking and easy setup between tracks: all we had to do was define the length of a “straight” and the angle of the next turn. This was a triumph in translating real-world knowledge into engineering inputs.