For an art project, we would like to create with a friend a fountain synchronized with a surround sound composition.
We have 5 water pumps to sync with the volume of 5 different speakers.
We succeeded to make the pump work together and automate them with an Arduino UNO.
The next step is synchronisation with the sound. The sound is recorded, and each channel playbacks its own.
We are Arduino newbies, so we opted to "fake" sync them:
-writing a code for each pump, matching in time the sound level of each channel.
-start the pumps and the playback at the same time with the UNO.
-automate the process to loop.
We've acquired an Onkyo HT-R538 5.1 Surround System and playback for the moment the sound from a computer. The Onkyo HT-R538 receiver has HDMI and optical inputs, and we would preferably use an external media player. One which support 5.1 encoded files.
Would it be possible to control such a player with an Arduino board?
Or should we build it from scratch ourselves?
We've been researching a lot but didn't find enough information to get going.
More information on our project which may be useful:
-the sound composition is about 3 minutes, 48000 Hz, 16 bits (AAC)
-we are using 12V DC pumps.
-our installation will be checked by a certified electrician, safety first.
-this is the type of media player we though about:
Maybe. If there is a remote it's possible to send & receive IR commands so you'd have to figure-out how to send a "play" command for that particular player.
It depends on the player and if you can figure-out how to start it automatically when the Arduino pump-sequence starts.
A "pro" setup at an amusement park or casino would probably work the same way, with separate synchronized audio and fountains (and/or lights), all started by the same "trigger". Or with MIDI audio, MIDI can also be used to control lights and other things.
...A long time ago I "hacked" CD player by adding relays in parallel with the play & stop buttons and this particular machine had a play LED and I tapped-into that for feedback so the control circuit could "know "if it was playing or not.
But, it might be easier to make the pumps react to the sound. But, there will probably be a delay from the mechanical inertia in the pump & water so you might have to program the pumps to come-on a little before the sound.... Or, if the pumps can keep the system constantly pressurized a valve can "snap-on" faster.
For sound activated effects, the Arduino Uno has 7 analog inputs so with 5.1 that's one extra.
An op-amp peak detector on each analog input makes your software easier. A peak detector puts-out a varying DC voltage proportional to the peak signal level. That way you can read the voltage 10 times per second (or so) instead of reading 6 audio waveforms thousands of times per second and finding the peak or "loudness".
If you connect to the speaker outputs you'll need a voltage divider (resistors) to knock-down the voltage, and an over-voltage protection circuit "wouldn't hurt" (just a diode if you already have a volage divider).
...I've made a few sound activated lighting effects and I always use a line-level input through a peak detector. But mine are mono or stereo and with a 5.1 setup you might not have access to the separate analog line-level audio signals.
Hi @DVDdoug !
I've seen some of your projects while researching , that has been very helpful.
I've researched about peak detector, how to input the line voltage, offset around 2,5V...
It seems easier (and maybe safer) to do in this case than the IR hack you suggested, thank you for that!