2 Wheel Self-Balancing Robot: Eric Wang
2 Wheel Self-Balancing Robot: Eric Wang
Robot
Eric Wang
Segway
Handle (Boston Dynamics)
Development Board: WiPy 2.0
● ESP32 dual core microcontroller
● Wifi
● MicroPython
Sensors: MPU9250
● Accelerometer
● Gyroscope
● Magnetometer
Motor Controller: DRV8833
2 H-Bridges - can drive 2 DC motors or
1 stepper motor
Circuit Diagram
Esp 32
Balancing
Move motors in direction of tilt
● Gyroscope has noise and θ will drift over long periods of time
Determining Tilt Angle With Accelerometer
Accelerometer coord system
accel z
accel y +z
θ
+y
https://maker.pro/projects/arduino/build-arduino-self-balancing-robot
Placement of Parts
● Heaviest part on top
○ Reduces angular acceleration due to gravity - slower fall
○ PID controller can make adjustments before robot has tilted too far
Demo Video