Dancing Robot

A two-wheeled robot that balances using PID control, and responds intelligently to sound input.

As part of a Year 2 Electronics module, teams of 4 people had to develop a robot that could self balance, and ‘dance’ by responding to live music.

This was achieved through the completion of different milestones, which covered Bluetooth motor control, live beat detection, a combination of these to choreograph dance moves, and finally autonomous self-balancing using PID control.

My primary contribution in the project was in developing the beat detection program, and implementing it into the rest of the code (Milestones 2 & 3). I also wrote a global script which was used for efficient wireless debugging while we developed other areas of the project.


Instead of using the Arduino platform, which might be expected for this task, we were using a custom PyBench. This was made from a PyBoard, and also included an array of other components, including a bluetooth receiver, OLED screen, microphone, motor drivers, a gyroscope and an accelerometer. The PyBench was mounted on a two-wheeled motor chassis that could be stabilised or left to balance freely. I learnt to comfortably program and manipulate this system using Python.


The full code for this project can be found on my Github: https://github.com/felixm34/dancing-robot

Year 2 Electronics - Robot sensor array
Back to Design Engineer