My first Seed product and I’m less than impressed with what I’ve seen so far let’s hope this can be changed.
I’ve spent quite a while tonight working with what I’ve seen in this thread with no success. I’m using the following method although I’ve gotten both to compile and load :
Method 2: Use Fat16 library
This method will use an open source library Fat16 library. There are two sketches in this demo: Using MusicPlayRandomly sketch, you can make the music play randomly.And using MusicPlayWithName, you can specify which song to be played by name.(Note: The demo can’t co-exist with demo 1 in the libraries)
Make sure there are songs in the micro sd card.
Download File:MusicShieldNewSDLib.zip and Fat16_lib for music shield.
[Under Linux] Copy libraries/Fat16/Fat16util.h to libraries/Fat16/Fat16Util.h (note util vs Util). The includes have the wrong case and this is easiest workaround.
Uncompress these two packages and put them in Arduino-1.0 program: …\arduino-1.0\libraries
Select the corresponding Arduino board, like Arduino UNO or Duemilanove or others.
[Ignore this if under Linux] Download a new portpins.h file and replace the default portpins.h file of Arduino-1.0 program: …\arduino-1.0\hardware\tools\avr\avr\include\avr
Run the arduino program compile and upload the sketch of MusicShieldNewSdLib into Arduino board.
- my sd is formated to FAT32
- I know the file name I’m using in play by name demo matches my file (2.wav)
- Arduino Uno
- IDE 1.0.1
I see the following in the serial monitor indicating that the program is running but consistently fails when trying to use the provided library to access the card / file:
err failed
SD error: 2error: open file failed
SD error: 2error: open file failed
SD error: 2error: open file failed
SD erroerror: card.init failed
SD error: 2error: open file failed
SD error: 2error: open file failed
SD error: 2error: open file failed
SD error: 2error: open file failed
SD error: 2error: open file failed
SD error: 2error: open file failed
SD error: 2error: open file failed
…
… SD error: 2error: open file failed continues forever…
Any lead on what might be the issue here?