Other than some simple flashing LEDs this is my first Arduino project. I came up with an idea on the fly (in this thread actually) to build something that would play sounds and possibly flash LEDs when someone walks up to it or by it. I thought it might be difficult at first but this past weekend I decided to give it a go.
I started out with a cheap mp3 player:
The way it works is to turn it on you press and hold play for a little over a second to turn it on. It takes a few seconds to power up. Then it has all the standard buttons you would expect. Forward/Back, Volume, etc... I figured if I could bypass the play and forward button I could control it with the Arduino.
So I ripped it apart:
And lucky for me you can see in the next pic the 2 far right buttons are the play and forward track buttons. If they had been next to the battery it would have been a lot tougher.
Looking at the buttons I saw some open contacts that were not being used. Measured with a milti meeter to make sure they worked and they did.
I took some magnet wire (24 gauge I think) cause it was tiny and flexible and did my best to solder to the tiny contacts.
It took a lot of time and the solder joints were not very strong. 2 wires fell off and had to be reattached. Finally I bent them down and taped them in place to reduce the stress on them.
Even after this the far left one fell off and had to be redone but I think they're all pretty good now.
I hooked it up to a breadboard with buttons to test it out. WARNING: Very boring video here. (Takes a bit to load.)
Next I moved to the Arduino with protoboard. Got some 2n2222a transistors and various resisters and tried to hook it up but I couldn't get it to work. I hooked up an LED and the Arduino would make that work but I couldn't make them switch the mp3 player on or forward the tracks. It dawned on me later that I wasn't using a common ground and that was probably my problem. But I figured finding ground on the player would be difficult. Instead I opted for relays. I went to my local electronics surplus store (Halted Electronics) and picked up these relays.
Got it wired up right and it worked flawlessly.
I wrote a little code and got it running in a loop:
Turn on Play Pause Forward a random # of tracks Power down Pause
I had also ordered some Sharp IR sensors so next I plugged that in and added some code. I honestly thought that would be the hardest part but I had that working in about 10 minutes.
Here is the whole setup:
I'll post the code in the next post.
Any feedback is appreciated.