My First Robot

November 2022

Backstory

I’ve been playing with electronics and microcontrollers for years, but for a long time I never actually built a “real” robot.

When I got the chance to participate in the National Robotics Olympiad, I decided to finally build one.

The timing wasn’t ideal. I was in the middle of my final exams, so most of the work happened in between study sessions and during travel. I wrote the firmware on train. (it was pre AI coding era)

image

Somehow, between exams, travel, and a lot of late nights, Durbar came to life.

What Durbar can do

Durbar is a small robot platform that you can drive, program, and monitor from a phone.

  • Drive it from a mobile app
    The robot is controlled over Bluetooth Low Energy (BLE) using a React Native app. You can steer, switch modes, and trigger different behaviors directly from the app.

  • Programmable workflows
    Instead of just “go forward” or “turn left”, you can create small workflows:
    for example, move forward, check distance, turn if an obstacle is close, log some data, and repeat.

  • Live monitoring
    The robot sends telemetry back to the app: sensor readings, internal state, and debugging info. You can see what’s happening inside the robot in real time.

  • Sensor data on your phone
    Durbar has multiple sensors: ultrasonic distance, temperature, humidity, smoke, and more.

All of this is streamed to the phone so you don’t need a laptop just to see what the robot is sensing.

image

It’s not a factory robot, but for a personal project and competition robot, it packs quite a lot into a small chassis.

Architecture in plain language

Under the hood, Durbar has two microcontrollers that share the work:

Primary computer (ESP32)

The ESP32 is the main controller that talks to everything:

  • Handles BLE communication with the mobile app
  • Receives commands and workflows
  • Decides what the robot should do next
  • Sends back telemetry and sensor data

This runs on custom firmware written in C++

Secondary computer (Arduino Nano)

The Arduino Nano acts as a dedicated sensor and I/O helper:

  • Reads data from the different sensors
  • Processes it and sends it to the ESP32
  • Offloads low‑level work so the ESP32 can focus on logic and communication

Its firmware is also written in C++

You can think of it like this:

  • Phone app ↔ ESP32 (BLE and decisions)
  • ESP32 ↔ Arduino Nano (sensors and low‑level control)
  • Arduino Nano ↔ physical world (motors, sensors, environment)
image

This separation made development easier. If a sensor reading looked wrong, it was usually on the Arduino side. If the robot behaved strangely, it was usually the ESP32 logic or the app.

The mobile app

The controller app is built using React Native and communicates with the ESP32 over BLE.

From the app, you can:

  • Connect to the robot over BLE
  • Drive the robot like an RC car
  • Create and send small “programs” or workflows
  • See live sensor data and status updates

The app code is open source here

Tapping a button on the phone and seeing a physical robot respond immediately is still one of the most satisfying parts of the project.

image

If you’re curious about the code or want to build something similar:


I made this project back in 2022, so the code is not as clean as it could be. But it was a fun project to build and learn about robotics.

And if you want to chat about robotics, microcontrollers, or side projects, you can reach me on X.