hi there,
it's been a while, but i'm back using the wonderful waveshield again! firstly, in case anyone is searching for keywords "waveshield v1.0" and "uno" and "strange", i can tell you that when i tested the dap_hc sketch on an arduino uno + waveshield v1.0, i could only hear the first part of the first file playing. so i switched the uno for a duemilanova 328 and now it works fine.
but now i have another problem:
so dap_hc works fine, but when i tried running wavehc_play6, i get the following error:
Couldn't open file FILENAME.WAV
this only happens when i press the first button. this button is wired to pin 14 (A0) and connected to ground with a 10K resistor. all other buttons are wired similarly, to the other analog pins, but return nothing at all, no error, no sound.
anyone have any clue as to what it might be?
waveshield works but couldn't open file
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- adafruit_support_bill
- Posts: 88096
- Joined: Sat Feb 07, 2009 10:11 am
Re: waveshield works but couldn't open file
"Couldn't open file FILENAME.WAV"
That doesn't look like output from the standard wavehc_play6 sketch:
Can you post the exact sketch you are using? (Use the "Code" button above the message edit box.)
That doesn't look like output from the standard wavehc_play6 sketch:
Can you post the exact sketch you are using? (Use the "Code" button above the message edit box.)
-
- Posts: 63
- Joined: Wed Jan 28, 2009 6:48 am
Re: waveshield works but couldn't open file
hi ladyada,
thanks for your feedback - that is indeed the code i was using, only with my filenames instead of 1.WAV, 2.WAV, etc. just be 100% sure, i copy-pasted it again, and ran it before i remembered to change the filenames. interestingly enough, i get this:
WaveHC with 6 buttons
Free RAM: 637
Using partition 1, type is FAT16
Ready!
Couldn't open file 1.WAV
could it be to do with using a v1.0 waveshield? so strange that it works with dap_hc and not this one. hmm... gonna poke around in the code a bit...
thanks for your feedback - that is indeed the code i was using, only with my filenames instead of 1.WAV, 2.WAV, etc. just be 100% sure, i copy-pasted it again, and ran it before i remembered to change the filenames. interestingly enough, i get this:
WaveHC with 6 buttons
Free RAM: 637
Using partition 1, type is FAT16
Ready!
Couldn't open file 1.WAV
could it be to do with using a v1.0 waveshield? so strange that it works with dap_hc and not this one. hmm... gonna poke around in the code a bit...
-
- Posts: 63
- Joined: Wed Jan 28, 2009 6:48 am
Re: waveshield works but couldn't open file
gah, darnit, it was a problem with the filenames! stupid human error! thanks for looking into it anyway, ladyada...
<crawls away in shame>
<crawls away in shame>
-
- Posts: 63
- Joined: Wed Jan 28, 2009 6:48 am
Re: waveshield works but couldn't open file
ok, at the risk of coming across as a nut, i'll ask another question here... about the SD card error codes.
it turns out that the initial problem i had with the Uno is also happening with the Duemilanova, only it doesn't happen quite so quickly. when i run dap_hc, the soundfiles stop playing after 30sec or so (different each time) and i get:
SD I/O error: 10
i had a look in SdReader.h and it has a handy comment: "card returned an error token instead of read data".
although i'm not sure what that means... loose connection? something out of synch?
it turns out that the initial problem i had with the Uno is also happening with the Duemilanova, only it doesn't happen quite so quickly. when i run dap_hc, the soundfiles stop playing after 30sec or so (different each time) and i get:
SD I/O error: 10
i had a look in SdReader.h and it has a handy comment: "card returned an error token instead of read data".
although i'm not sure what that means... loose connection? something out of synch?
- adafruit_support_bill
- Posts: 88096
- Joined: Sat Feb 07, 2009 10:11 am
Re: waveshield works but couldn't open file
Could be a bad connection. Make sure the card is firmly seated in the holder. If you post photos of the front & back of the board we can take a look for any assembly problems.i'm not sure what that means... loose connection? something out of synch?
Another possibility is an error on the card itself, or a card compatibility problem. Try a different card if you have one.
-
- Posts: 63
- Joined: Wed Jan 28, 2009 6:48 am
Re: waveshield works but couldn't open file
ok, i've taken pics of the front and the back:
large image of the front
large image of the back
and also i should mention, i got the kit with one of the 0.1µF capacitors missing (got it via a friend, who lost the part) so i used a very similar one (also 0.1µF, also has 104 printed on it) for C7. could that be the problem?
large image of the capacitor
tomorrow i'll have access to another SD card, so i'll try that and let you know what happens. thanks for your help so far!
large image of the front
large image of the back
and also i should mention, i got the kit with one of the 0.1µF capacitors missing (got it via a friend, who lost the part) so i used a very similar one (also 0.1µF, also has 104 printed on it) for C7. could that be the problem?
large image of the capacitor
tomorrow i'll have access to another SD card, so i'll try that and let you know what happens. thanks for your help so far!
- adafruit_support_bill
- Posts: 88096
- Joined: Sat Feb 07, 2009 10:11 am
Re: waveshield works but couldn't open file
The soldering looks good and the replacement capacitor is fine. The only areas of suspicion are the 2nd and 4th pins from the left on the SD card holder and the end of R6 nearest the card holder. They look a little rough which could indicate a 'cold joint'. Since this is the area where most card communication problems occur, we should make sure they are good. Retouch those joints with a clean, hot iron and make sure the solder flows well between the pin and the pad underneath.
-
- Posts: 63
- Joined: Wed Jan 28, 2009 6:48 am
Re: waveshield works but couldn't open file
hey, thanks for taking such a close look!
i've resoldered those points you mentioned, but still the same problem. tomorrow i'll test it with a different SD card - that could well be the problem. i'll report back once i've tested!
i've resoldered those points you mentioned, but still the same problem. tomorrow i'll test it with a different SD card - that could well be the problem. i'll report back once i've tested!
-
- Posts: 63
- Joined: Wed Jan 28, 2009 6:48 am
Re: waveshield works but couldn't open file
just wanted to update this thread to say that it turned out to be a problem with the SD card all along. funny that it worked differently with the different (duemillenove vs uno) boards.
-
- Posts: 8
- Joined: Tue Jan 17, 2012 8:40 am
Re: waveshield works but couldn't open file
I really like this wave shield, but found one thing lacking for me. The current configuration only lets you read files from the card. In my case, I wanted to also store information onto the card, but there is no "write". I'm guessing this was done to save space, but is becoming a problem for me as I'm having to hack the thing up to include the ability to write information.
As a future release - write support would be a great addition.
As a future release - write support would be a great addition.
- adafruit_support_bill
- Posts: 88096
- Joined: Sat Feb 07, 2009 10:11 am
Re: waveshield works but couldn't open file
The AF_Wave and WaveHC libraries are specifically optimized for streaming WAV files to the DAC. But the regular SD library works with the card as well and gives you both read and write access.
- fat16lib
- Posts: 595
- Joined: Wed Dec 24, 2008 1:54 pm
Re: waveshield works but couldn't open file
I wrote two libraries for the Wave Shield, WaveHC and WaveRP.
WaveRP uses SdFat and can play and record audio files. It also allow files to be written using the standard SdFat API.
WaveRP is located here http://code.google.com/p/waverp/downloads/list.
WaveRP uses SdFat and can play and record audio files. It also allow files to be written using the standard SdFat API.
WaveRP is located here http://code.google.com/p/waverp/downloads/list.
- adafruit_support_bill
- Posts: 88096
- Joined: Sat Feb 07, 2009 10:11 am
Re: waveshield works but couldn't open file
Thanks again fat16lib
Please be positive and constructive with your questions and comments.