Wave Shield and LEDs

Adafruit Ethernet, Motor, Proto, Wave, Datalogger, GPS Shields - etc!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
vwguy16
 
Posts: 1
Joined: Fri Aug 29, 2014 12:45 pm

Wave Shield and LEDs

Post by vwguy16 »

I have a sketch that is set to play a flashing led sequence by way of a button press...it works great.
Today I integrated the code to get wavs playing.. if I add the call to play the wav....it plays the wav just fine but doesnt blink the leds. If i disable the wav play function the led flashes again.

I read somewhere that it might be a timer conflict?

im running it on an uno..and after the wave shield has gobbled up all the pins it needs to function i think im left with 4.. 6,7,8,9. ive tried to change the pins around but no luck.

Might anyone have any ideas what the problem could be ?

User avatar
pburgess
 
Posts: 4161
Joined: Sun Oct 26, 2008 2:29 am

Re: Wave Shield and LEDs

Post by pburgess »

If you're using the playcomplete() function from one of the WaveHC examples, that function "blocks" until the WAV is done playing. If you look inside that function, you can see how it starts the WAV playback then just sits in a loop checking wave.isplaying. You'll need to kind of deconstruct that into your own code, so it can do the LED flashing while the WAV plays.

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino Shields from Adafruit”