This is a cool little self-balancing robot that doesn’t use any fancy accelerometers or gyroscopes. You might even have all the parts needed to make one of these right now.
This is a very simple robot that uses a simple switch as a sensor and stands on only two wheels with inverted pendulum mechanism. When the robot is going to fall the motor starts and moves the robot to the direction it is going to fall, so the motor torque about the center of gravity that is higher than the motor makes the robot balanced.
Read more about making a Simple Balancing Robot