Robot Xylophone

My daughter's school gave every student an eight-note xylophone for christmas. I decided to make some upgrades. Here's the video.

The xylophone is completely unmodified and sits on top of a wooden frame. All the wood in this project was scrap.

[Photo of the xylophone's top]

Each of the eight notes is struck from underneath by a 12V DC push-pull solenoid with a 4mm stroke. They sell online for $1 each. The solenoids are clamped into shallow grooves cut into the wood. A strip of non-slip fabric keeps them from sliding around.

[Photo of the xylophone's solenoids]

The underside houses the electronics. An eight-channel relay board switches the solenoids on and off. Using relays is gross overkill, but at $8 for the pre-made board, it was a quick and easy solution. Each channel has a backlash diode to discharge the solenoid, since I found that the collapsing magnetic field created an electromagnetic pulse that induced a reset on the microcontroller every time a note was played.

[Photo of the xylophone's bottom]

The microcontroller is an Arduino clone, called a "Boarduino". It has no mounting holes, so had to be epoxied to the wooden frame. In addition to the eight outputs, there's one input used for the play button.

[Photo of the xylophone's arduino]

The Arduino software simply plays one tune after another, waiting for the play button between tunes. I programed "Twinkle Twinkle Little Star", "Mary Had a Little Lamb", "Frère Jacques", and "Ode to Joy". My manager at work contributed "Cripple Creek" (here's an MP3 of how it sounds).

This was a fun one-day project. Total cost was about $20. My daughter seems to like it.

-------------------------------------
Last modified: 8 July 2019