• Welcome to Randomland - The Forum. Please login or sign up.
 
Apr 29, 2024, 01:40 AM

News:

Get Out, See Green!


Audio Playback Circuit Board

Started by Brad, Jun 13, 2013, 09:12 PM

Previous topic - Next topic

Brad

Here is the python script which does the sound effects and music playing. The music is the most complicated part. The same button starts and stops the music and it plays in a playlist which loops forever.

To be able to stop the music I needed to use the subprocess module which allows you to keep a reference to the process so you can kill it. The os.system runs every process in a new terminal so you can't easily find the right PID to kill. Using subprocess is really easy (just look at my script.)

Posted from my Pi.

Brad

So I need to find a really small amp to use for the speakers. It has to be small so it can fit up inside the top part of the pirate ship cabin.

I've been looking at something like this http://www.amazon.com/LP-2020A-Lepai-Tripath-Class-T-Amplifier/dp/B0049P6OTI/ref=sr_1_1?ie=UTF8&qid=1372951111&sr=8-1&keywords=mini+amplifier. It takes the pc audio in and has decent output. Probably good enough to run a few speakers.

I'd love to have something with a ton of watts, but they don't really seem to come in a small size and without a receiver. Everything is built for a home audio which means they are all large flat rectangular things.

Brad

Buttons have arrived speakers and amp are in the mail.

We have settled on 5 buttons total. With 3 different functions. One plays a cannon firing sound with occasional after sounds (water splashing, cannonball crashing, "stop blowing holes in my ship!"). Another plays misc sound effects. The last controls the music.

Up top there will be two buttons (cannon and sounds). On the mast near the second steering wheel is another sound effect button. The canon itself has a cannon sound button on it. Finally the music start/stop button is in the cabin out of reach of small children.

I am guessing this thing will be completed in about a week.

Brad

I setup the Pirate Pi version 1.2 prototype yesterday. This version removes the sound effects button and uses a USB stick for the sound effect/music storage.



Here is a really crappy phone video of the pirate ship in action. The panels still have two buttons from previous setup which had a second button specifically for sound effects. The blue button inside the cabin is for turning on/off the music. You can also see the rats nest of wires we've got setup. The speakers outside are all weather proof. I soldered a little circuit together which connects the pi to the button wiring and has the protection resistors on it.

The next boat is actually a bit larger and the final version of the sound effect system is going to be inside of a small box with power, two wire connectors, 3.5mm audio, and a usb port for outside connections. All the other stuff like the protection circuit will be contained in the box.

Nick

Wow. That is massively impressive. The detail on that ship is awesome, I can hardly imagine the amount of work that took. Does it have lights for at night? 

How did you end up running all the wiring? Standard conduit?

Brad

Yeah it does have lights. Two on the top outside and one in the cabin.

The conduit is some flexible PVC type stuff with cat 5 cable in it. We are changing the wiring around for next time as we don't need as many buttons. Also the next version won't have anything run under the boat.

I have ordered enough parts to do the sound system for 3 more ships. The next one they make is going on a trailer to take to shows and stuff.

Nick

Cool and more cool. I need to make something. It is 1/100 as awesome I will be happy.

Are they becoming shipwrights? :)

Brad

They've got some marketing people coming on Friday to look at the ship. I guess the marketing guys were pretty excited about it. Not much out there with this level of detail apparently.

They definitely would like to just keep on making ships yeah, if they can sell them.

zourtney

That ship is ridiculously awesome. And the buttons and sound effects looked like they turned out really well. Makes me want to do more Pi and wood projects...I've been trying a few but nothing impressive  :P