Autonomous shopping cart
A self-driving shopping cart prototype built in 48 hours, with navigation, voice interaction and RFID item scanning.
C++ArduinoRFID
- Wrote the A* pathfinding that modelled the store layout and found the shortest route between items.
- Added real-time obstacle avoidance based on the Dynamic Window Approach and Velocity Obstacles, so the cart reroutes around people.
- Integrated motors, sensors and the Arduino with the rest of the team's software into a working prototype.
Step 1 of 5
Shopping list
Each item maps to a location in the store.
Step 2 of 5
Store grid
The store layout is modelled as a grid, with shelves as blocked cells.
Step 3 of 5
A* search
A* finds the shortest route between items, always expanding the cell with the lowest cost so far plus estimated distance to go.
Step 4 of 5
Obstacle avoidance
Ideas from the Dynamic Window Approach and Velocity Obstacles let the cart notice something in its way and reroute in real time.
Step 5 of 5
Motors
The route becomes motor commands on the Arduino, with sensors feeding back what's around the cart.
Try it
The cart at the top of the homepage runs a smaller version of the same planner.
- The cart
- A shopper who wanders into aisles
- Cells A* expanded before choosing a route
- Cells still waiting in the open set
- The route it chose
- Items on the shopping list
UNIHACK 2025
Forty-eight hours, five people, and one shopping cart that drives itself to the items on your list. It combined embedded hardware, navigation, voice interaction and RFID scanning to identify items as they went in.
My part: getting around the store
I built the navigation. The store layout became a grid, and A-star worked out the shortest route between grocery locations. Then came the harder problem: people. Using ideas from the Dynamic Window Approach and Velocity Obstacles, the cart could spot something in its path and reroute around it in real time.
Try it
The cart at the top of the homepage runs a simplified version in your browser: eight-directional A-star with an octile-distance heuristic, no cutting corners around shelves, and a wandering shopper that makes the cart replan when they step onto its route. I wrote more about it in Why there's a shopping cart on my homepage.
History
-
Built in 48 hours at UNIHACK 2025 with a team of five.