The solenoids require 12V. For this project to work, you will need to provide 12V via the Metro RP2350 DC jack.
Plug a 12V power supply into the DC jack on the Metro RP2350 to power up the toy robot xylophone. The xylophone has two modes: live MIDI mode and music box mode. The mode is defined by the variable music_box
at the top of the code.
Live MIDI mode lets you send MIDI messages over USB MIDI to the xylophone. If you're using this mode, you'll also need a data USB C cable for MIDI input.
Music box mode lets you load MIDI files (.mid) onto the CIRCUITPY drive and play them back with the xylophone. You don't need a USB cable for this mode to work.
The xylophone only has the notes of a C major scale, so any notes that are sent to it outside of C major will not play.
A few simple MIDI files are included in the project bundle for music box mode. To play a file, press the BOOT button on the Metro. A file will be randomly chosen and played back on the xylophone. The code adapts to however many MIDI files you have on the CIRCUITPY drive, so you can create your own files for playback.
Page last edited May 21, 2025
Text editor powered by tinymce.