How to get multiple speakers to play in sync (ie, Pandora or MP3)

Ok! So I set a test scene with the following luup:

socket=require('socket') local client = socket.connect('192.168.1.5', 9001) client:send("00:04:XX:XX:XX:XX:01 playlist play pandora://3292813334574865065.mp3\n") client:send("00:04:XX:XX:XX:XX:02 playlist play pandora://3292813334574865065.mp3\n") local result=client:receive()

(I censored the MAC addresses in my post)

This triggers two radios in my home to start playing a Pandora playlist. Of course, they don’t both turn on at the same time, and the track is different on each. So how can I trigger the radios to all play at once, and to play the same source in sync so that you aren’t getting different tracks or out of sync music as you walk around?

Syncing 2 devices to Pandora is an exercise in the impossible.

can you expand on this? what are the devices? how much difference is there?

can you expand on this? what are the devices? how much difference is there?[/quote]

Apologies. I was quite tired last night.

Speakers == Logitech Squeezebox Radios

When the script is ran, one will turn on and the other will come up maybe a few seconds later. As each one loads up Pandora separately, it doesn’t even land on the same track. To replicate this, grab a laptop and your phone and sit them side by side. Then load Pandora on each and click on the same station. Each will be fed a unique playlist as Pandora doesn’t stream the tracks in real time. So when any gadget logs in, it starts randomly in the playlist somewhere for that station.

So the idea would be to maybe sync the speakers during the session, like Logitech’s Media Server can do (running on a PC on the network) so that they’d play the same tunes at once maybe? Then unsync them with another scene when you are done with listening. This way they are back to being independent from each other (so one person doesn’t come back later to turn on one speaker causing them all to go on and bother anyone).

In the end, it doesn’t have to be Pandora. It can be a local playlist.

can you expand on this? what are the devices? how much difference is there?[/quote]

Apologies. I was quite tired last night.

Speakers == Logitech Squeezebox Radios

When the script is ran, one will turn on and the other will come up maybe a few seconds later. As each one loads up Pandora separately, it doesn’t even land on the same track. To replicate this, grab a laptop and your phone and sit them side by side. Then load Pandora on each and click on the same station. Each will be fed a unique playlist as Pandora doesn’t stream the tracks in real time. So when any gadget logs in, it starts randomly in the playlist somewhere for that station.

So the idea would be to maybe sync the speakers during the session, like Logitech’s Media Server can do (running on a PC on the network) so that they’d play the same tunes at once maybe? Then unsync them with another scene when you are done with listening. This way they are back to being independent from each other (so one person doesn’t come back later to turn on one speaker causing them all to go on and bother anyone).

In the end, it doesn’t have to be Pandora. It can be a local playlist.[/quote]

when you say “When the script is ran, one will turn on”
does this mean from a powered off / sleep state, or just that it’s already on and you mean outputting music?
What i was thinking was if you could perhaps send something (test mp3 or something) to pre-power it up, so start and stop and then launch into whatever you want.
that way they are both powered up and ready.
although, if you say when running pandora they land on different tracks.
that seems to me like a pandora thing. i don’t know that you can code around that.

here are a few links that may help you with some ideas
http://www.danplanet.com/blog/2014/11/26/multi-room-audio-with-multicast-rtp/
http://www.hackerposse.com/~rozzin/journal/whole-home-pulseaudio.html

You can’t. It’s a Pandora problem…

That’s correct mvader. I’m ok with the radios not turning on at the exact same time. Just being able to play the same content in sync of each other. It doesn’t have to be Pandora. I just used that as the example since that was what I was trying to do at the time. It can be a playlist or anything else, as long as I can make them both playback the same media in sync.

to answer your other question, they turn on once the command to play something is sent. So they are beginning in an off state.