tbd.pi
Posts: 34
Joined: Sat Aug 11, 2012 11:21 am
Location: NJ,USA
Contact: Website

Triggering from GPIO

Wed Oct 29, 2014 5:18 pm

I have an Audio Fx sound board from Adafruit, and it has 10 channels from which I can trigger sounds. I have a momentary switch hooked up and it works great, I can press the switch, trigger the sound. But now I'm looking to do this from software. If I hook up GPIO #23 (for example) with a wire to the device it will just keep playing the sound file. So, I'm guessing that I need the default of the GPIO pin to be 0v, correct? Or do I need to put something in-between the GPIO and the sound board?

Tarcas
Posts: 740
Joined: Thu Jan 09, 2014 5:38 am
Location: USA

Re: Triggering from GPIO

Thu Oct 30, 2014 1:28 am

I would use a transistor or relay, so that when you trigger that with the GPIO pin, it bridges the same contacts that the switch does. Although, I am a little unclear on the board that you're using. Can you post a link to the spec sheet?

tbd.pi
Posts: 34
Joined: Sat Aug 11, 2012 11:21 am
Location: NJ,USA
Contact: Website

Re: Triggering from GPIO

Thu Oct 30, 2014 2:03 pm

I don't know about a tech sheet, this is the board I am using http://www.adafruit.com/products/2133

tbd.pi
Posts: 34
Joined: Sat Aug 11, 2012 11:21 am
Location: NJ,USA
Contact: Website

Re: Triggering from GPIO

Fri Oct 31, 2014 4:44 am

Seems I don't need anything extra.If I just put a wire to the board and output 0 for about 50ms, that's sufficient to do what I need. Fun, because I spent 3 hours trying to learn about this, got a transistor working, then just thought "what if"..

Now I have about 5 hours until my daughter wakes up and expects "this halloween project" to be together. I wrote my best essays in school the night before, I wonder what I can pull out for halloween to not disappoint a 5 year old?

Return to “Automation, sensing and robotics”