Arduino Forum

Using Arduino => Audio => Topic started by: wolf0 on Mar 03, 2016, 10:08 pm

Title: arduino uno + adafruit wave shield
Post by: wolf0 on Mar 03, 2016, 10:08 pm
Hi,

I've a question about programming adafruit wave shield. I've already read examples on adafruit site,but I can't find how to set the file I want to play on the arduino. The sequence i want to make is: servo movement (I've already write the code), music and servo movement (I have to make and iron man missile luncher). Thanks!
Title: Re: arduino uno + adafruit wave shield
Post by: wolf0 on Mar 08, 2016, 01:17 pm
Anyone have never made something like that?
Title: Re: arduino uno + adafruit wave shield
Post by: Grumpy_Mike on Mar 10, 2016, 12:51 pm
A file will have a name. You have to use that name in the call to play the file.

The file name can be a constant or looked up from a list, or generated from some numeric value.

Post the code you have got so far with your unsuccessful attempt at generating this file name. Use code tags and read the how to use this forum sticky post if you don't know what that means
Title: Re: arduino uno + adafruit wave shield
Post by: wolf0 on Mar 11, 2016, 01:17 pm
Thanks for your help! I find this code on adafruit shield website
https://learn.adafruit.com/adafruit-wave-shield-audio-shield-for-arduino/play6-hc
I'm new in the arduino world,I don't know where I have to insert the file name for playing. The code is very long and there are several parts,my question is:what part of this code I need to play a single file? Thanks !
Title: Re: arduino uno + adafruit wave shield
Post by: Grumpy_Mike on Mar 11, 2016, 03:33 pm
The call :-
Code: [Select]
playcomplete("fileName.WAV");
Will play the sound in the WAV file called fileName.

Replace the word fileName with the name of the file you want to play. Note it has to be the correct format of WAV file.