Code for PIR sensor + Adafruit Wave Shield

Simply put, I want a PIR motion sensor to trigger a randomly selected .wav file and lights when activated. I’ve looked through forum posts, adafruit tutorials, and some other guides but I don’t think I’ve found code for this quite yet. I’m wondering if anyone happens to know of a link to some, and then I will try it and troubleshoot from there.

For clarity, so far I have built the wave shield and tested it successfully, and I have gotten the PIR sensor to work reliably to trigger lights. It is the combination of the two that I haven’t found. I did try and successfully run the “Halloween Pumpkin” code by Lada Ada, which holds lights on and flickers them depending on the speaker output. If anyone advises that that is a good starting point to modify, I’ll try that.

I’m attaching a picture of my current setup with is using test LED’s. Ultimately there is a laser pointer that I will also hook up.

Thanks!

Playing a random file from a wave shield is a common project. You should find many of these on this forum. I would advise you to start with such a code. Then adding the PIR sensor as a trigger is just as simple as a triggering off a button.

Top hit from searching:-
Playing a random file from a wave shield Arduino
was one from here:-