I just finished building a music box / light show / jewelry box for my friend Sophie. An Arduino compatible microcontroller is used to generate the music box sound and to control the lights. The Arduino code emulates the sound of an old mechanical box which used a rotating drum with tabs that plucked tune metal tines to produce the note. The code is capable of three note polyphony. This is very easy to build for anyone who can read a schematic. Pictures of the build and links to the Arduino sketch can be had at the link below.
http://www.craigandheather.net/celemusicbox.html
http://www.craigandheather.net/celemusicbox.html
































Visit Our Store »
Go Pro Today »




The switch is available at: https://www.sparkfun.com/products/10289
Hi,
All the support files are contained in a jar file available here: http://craigandheather.net/docs/musicboxsupport.jar.
Note this jar is not executable; it is just an archive of all of the support programs. Unjar this file to get at its contents.
Good luck,
Craig Lindley
Good Luck,
Craig Lindley
http://nutsvolts.texterity.com/nutsvolts/201204?pg=28&search_term=music%20box#pg28
http://www.youtube.com/watch?v=eFyTW3ht7hc&feature=youtu.be
I designed my own custom Arduino and am still learning about microcontrollers, but I found that the response of my Arduino is slower than an Uno; when I upload your code to my Arduino, the songs play almost twice as slow as on an Uno. I'm using an external 8MHz crystal on my board; do you think adding a 16MHz crystal like the Uno would get rid of this problem?
Thanks for your help!
but i don't understand nothing of this kind of stuff (electronics and such things...)
but i think i'm gonna try, a friend of mine wishes she had a music box, as i can't find one and the ones i do are too expensive, i'd try this :) and it's better when it's made from us as a gift :)
i looked up for the Pro-Micro Arduino microcontroller you used in the site you mentioned, they have two, you used the 5V/16MHz one right?
could you somehow provide me/us a step-by-step for the electronic part? i mean, how do you set up the chip to play the musics you want? :x
At the present time the music box plays the three songs that I picked. To make it play other songs you will need to download the music box support jar file from the nuts and volts magazine (nutsvolts.com) website for the April 2012 issue where I wrote about how the music box works.
The jar file you download is not executable. You must unjar this file to get to the various programs inside. The midi parser is the file you will need to run on a midi file of the song you want the music box to play. The data spit out by the java code must be copied and pasted into the Arduino code and the code recompiled.
Hope this helps.
thanks alot!
(in time, i'll probably be back with more questions :P)
A nice display.
I'm a little confused by your schematic. Where is the power input? (I think I see it now... it is powered from the USB port?)
Can you explain the RC network between the 'RAW' pin and the Grounds? (Is it some kind of power conditioning for the LPD8806's?)
Thanks!