Skip to content
Home

BB-8-Style Robot with Internal Omni-Wheel Drive

Dates
Mar 2026 – Jun 2026
Role
Electronics and software
Tech
C++, ESP32, FreeRTOS, PID Control, Sensor Fusion, Next.js, TypeScript, PlatformIO, WebSockets
The BB-8-style spherical robot

What it is

A self-balancing sphere in the style of BB-8, driven from the inside by a 3-wheel omni-drive.

What I built

I designed the electronics and wrote all the software. That meant deriving the omni-drive inverse kinematics and building a cascaded heading-hold and yaw-rate PID stack with IMU sensor fusion.

The inverse kinematics is a 3x3 mapping of body velocity to per-wheel RPM, with tilt compensation and proportional saturation. Each wheel runs its own PID loop with anti-windup and derivative-on-measurement.

The firmware uses a dual-core FreeRTOS architecture that keeps the Next.js/WebSocket teleoperation stack apart from the control loop. It includes an arm/disarm/kill safety state machine, motor-safe over-the-air updates, and a Python PID-tuning and telemetry toolchain.

The interesting problem

Tuning the PID. It was my first time doing it, and it is kind of an art.