All work

CoffeeBot

A coffee delivery robot with an arm, line tracking and obstacle avoidance.

When
2024
Kind
Autonomous delivery robot
Role
Solo build: design, wiring, firmware
Stack
Arduino Uno, C++, TB6612FNG, HC-SR04, TCRT5000, MG90S, JDY-16

CoffeeBot is a coffee delivery robot with autonomy where it counts: it follows a line to the right table, steers around obstacles, and carries the cup in the claw of a four-link arm. I designed, wired and programmed it on my own during my final year at the Federal University of Technology Akure.

ways to drive it: IR remote, phone over Bluetooth, or on its own
3
where it turns away and where it backs off
25 / 15 cm
requirements met in testing
8 of 8
the whole bill of materials
₦256,000
On this page
  1. Why a robot waiter
  2. The build
  3. How it thinks
  4. Three ways to drive it
  5. In use: a delivery run
  6. Results

Why a robot waiter

At peak hours a cafe fills with queues, and during COVID every hand-off was a contact. Delivery robots already exist, but the ones I found were expensive and fully automatic, with no way for staff to take over. CoffeeBot aimed at both gaps: a low-cost build, and an operator mode alongside the autonomy.

The build

A LAFVIN four-wheel robot-arm chassis in black acrylic carries an Arduino Uno under a TB6612FNG motor shield, with the left and right motor pairs on separate channels so the robot can steer in any direction.

Two 3.7 V lithium cells in series give 7.4 V, which an LM2596 buck converter steps down to 5 V for the logic. Three MG90S servos move the base, the arm and the claw. An HC-SR04 ultrasonic sensor looks ahead, three TCRT5000 infrared sensors read the floor, a JDY-16 module talks to the phone, and an IR receiver takes the remote.

The finished CoffeeBot on a table, arm raised
Fig. 1The finished robot.
CoffeeBot from above, showing the boards, battery and arm
Fig. 2From above: battery, controller stack and arm.
Block diagram linking sensors, Arduino, motor driver, servos, motors and battery
Fig. 3Sensors report to the Uno; power, servos and motors run through the driver.
Diagram of the robot arm's four links, labelled L1 to L4
Fig. 4The arm's four links, L1 to L4, from the claw down to the turntable.
Two 3.7 volt cells feeding an LM2596 buck converter to 5 volts
Fig. 57.4 V stepped down to 5 V.

How it thinks

Line tracking reads three sensors: the centre alone on the line drives straight; the centre with the left or right pivots gently; an outer sensor alone turns harder; all three on the line means stop.

Obstacle avoidance measures ahead continuously. Past 25 cm it drives on; under 25 cm it turns left; under 15 cm it backs away. In follow mode it keeps a guide object between 15 and 20 cm, slowing as it closes in and reversing if it gets too near.

Flowchart for obstacle avoidance with 25 and 15 centimetre decisions
Fig. 6Obstacle avoidance: the 25 cm and 15 cm decisions.
Flowchart for following a guide object at set distances
Fig. 7Follow mode: speed by distance band.

Three ways to drive it

On its own, it follows the line. From the infrared remote, every button has a job, from driving to opening the claw. From a phone, a Bluetooth app sends the same commands through the JDY-16, so a member of staff can take over from across the room.

Infrared remote with each button's action labelled
Fig. 8Every button on the remote, mapped.
Phone app interface for driving the robot
Fig. 9The Bluetooth control app.

In use: a delivery run

Lunch rush. A barista sets a cup in the claw and starts CoffeeBot on the line that runs to table four. It follows the tape, three sensors reading the floor. A chair has been pushed into the path: at 25 cm the robot turns away, and it would back off at 15.

At the table it stops where all three sensors see the line, and the claw opens only there. When a customer waves it over somewhere the line doesn't go, the barista takes over from the phone.

A worked example of the use CoffeeBot was designed for.

Results

The finished robot detects obstacles in its route, answers the remote and the phone app, follows an established path, picks up an object and releases it only at the delivery point, rotates its arm through a full circle, and follows a guide object: every requirement set at the design stage.

Warehouse systemNext project: Inventory routing model