Inverted Pendulum Robot Firmware