dkj10738 wrote:Help, I am having a similar problem. My audio plays fine from the CL, but as soon as I run the code from the tutorial, it starts playing one of the MP3 files incessantly. This happens even if I don't connect a ribbon cable to the GPIO pins. I am stuck.
So I'm a complete n00b at this but as far as I can tell the program actually works by playing the sound file when the circuit is broken by pressing the button... basically, pressing the button removes changes a given pin from receiving electricity to not receiving electricity. The status of not receiving electricity is what tells the program to play the music file.
If you're able to play the mp3 file fine from the command line but when you start the program it just starts playing instantly (and repeatedly) then it sounds like you might not have your circuit built right. Again, being completely new to this I may be way off track but here are a few things I noticed working on this myself:
1) if you got the opaque (not clear) breadboard with your starter kit, it is actually split two ways: long way for the middle part and short way for the outer (top and bottom) parts. There is a split along the channel that runs down the length of the board as far as the middle section is concerned, as well as a split between the left and right side where the red and blue lines on the top and bottom have a break in them. If your circuit is trying to pull voltage from one of the channels on the LEFT side of this break in the red/blue lines, but you actually plugged your ribbon/cobbler into the RIGHT side, then you need to use wires to bridge the gap between the left and right sides. A better solution IMO is just to make sure that all the wires/resistors that plug into the area between the blue and red lines are all on the same side of the middle split between these lines.
2) It made a difference for me which way the resistors were facing. Full disclosure, I might not have had them plugged in all the way to begin with, but I didn't get it to work until I had all the resistors facing the same direction and that means the brown stripe closer to the button and the gold stripe plugged into the voltage area (between red/blue lines)
3) this doesn't really apply to YOUR issue since you got the files to play on command line, but Midori, the built in browser on the GUI, does NOT download mp3 files correctly... this was my main issue. I went through the additional audio set-up recommended in one of the replies to the other issues but wanted to reiterate here that Midori browser does not download mp3 files correctly. I had to, from the command line, use the wget function: wget http:\\www.somewebsite.com\filename.mp3
Anyway, those were my big issues.
er... uhm... Please help?