Valery, the team leader, had a pre-existing interest in IMU data and music data. To combine the two and create an implementable project she thought it would be fun to create a dance rater. What happens if we take the Fourier transform of both and compare the result?

What it does

The dance rater visually displays a score telling the user how well they moved to the beat of a song.

User Instructions

The user puts on the Data Collection Apparatus (DCA). They select a song from the song from the song library and move to the beat. The DCA then determines whether the user is moving to the beat of the music.

How we created it

Physical Display

The display was assembled using a cut down 2x4 and a vinyl block. The handle was built with two wooden strips and a balsa wood block. All pieces were primed, painted, and then assembled using nails and ventilation tape.

Data Collection

Acceleration data was gathered using MMA8451 IC's. Sensor nodes were created using two Arduino Unos, which communicated to the sensors using I2C. The usage of two sensors allowed us to use 4 sensors simultaneously, bypassing a I2C address limitation. The sensor nodes were linked to the primary processing node with UART over USB to our processing computer.

Signal Processing

The signal processing component was written in C++, residing on a laptop. We created two threads using the std::thread library, one for collecting and packaging the data from the sensor nodes, and another for performing the signal processing. First we collect data from the song, then we put it through a beat detection algorithm. The algorithm is able to detect different types of songs, and slower or faster beats. This way, if a song is faster or slower paced, the algorithm can adjust to those differences. The accelerometer data was processed by putting the data through a low pass filter. We collected data on dancing and were able to determine if someone was dancing based on the magnitude of acceleration. This data was then compared against the detected beats in order to determine if their dancing matched the beat.


We used DotStar lightstrips to display user scores. The DotStar was connected to a third Arduino Uno, which received data over a third UART channel from the PC.

Challenges we ran into

Originally we wanted to use a raspberry pi instead of Tyler's computer to keep it simple and portable, however the raspberry pi has bad hardware for SPI communication for the dotstar LED strip and bad hardware for I^2C for the acceleratometers. We tried using the MyoArmband, but could not get it to sync. We moved to using 'black boxes' aka arduinos to get input into the data processing and to output to the LED strip. This meant we ended up learning more about different OSs and how Serial works. Also who knew I2C had a maximum bus length limitation? Only Tyler.

Accomplishments that we're proud of

What we learned

Tyler learned how to use the C++ std::thread library. Leif learned how to make header files in cpp and how to filter beats in music. Emily learned about 1960's Pop Art and how to solder and Valery learned that accelerometer data does not have high frequencies, that only windows uses a carriage return, and how to SSH into a Pi. This is useful to know in case we ever want to processes movement data again, or use a Pi without the burn of i/o connected to the Pi.

What's next for DANCE . . . can you?

Built With

  • arduino
  • c++
  • dotstar
  • duct-tape
  • led-strip
  • wires
  • wood
  • wood-glue
Share this project: