Hi there,

After setting up Squeezebox Server on a 24/7 server running Ubuntu,
connecting a SQ3 and a SQ boom to it, I use SqueezeboxSlave as a daemon
on the server itself.
All works perfectly, so I'm up to the next step: turning on the powered
speakers connected to the server automatically when squeezeslave starts
to play anything.
So far I've managed to connect a 220v relay to the com port of the
server using salvaged electronics parts and I can successfully switch
the speakers on and off from the commandline by starting and stopping a
program.

What I want to do is to monitor the state of Squeezeslave, preferably
with a bash script, and switch the speakers on when it is playing
anything, and switch them off when it stops. With the Boom in use as an
alarmclock, and synced with SQslave, I can then have music throughout my
house when drinking my morning coffee. :) (and maybe let the relay turn
the lights on or something...)

How can I poll the play/stop state of Squeezeslave?
Can I poll SB Server directly? The m3u playlist in
/var/lib/squeezeboxserver/prefs/ tells me the playlist update date/time
and therefore the moment it starts playing, but how do I know when it
stops? 
Or can I catch a signal from the lcdproc option?

I'll be very happy to hear anyones thoughts on this. 


Cheers,
Lister

Btw, is someone interested in the schematics and program for the
comport relay?


-- 
Lister
------------------------------------------------------------------------
Lister's Profile: http://forums.slimdevices.com/member.php?userid=34158
View this thread: http://forums.slimdevices.com/showthread.php?t=71077

_______________________________________________
discuss mailing list
discuss@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/discuss

Reply via email to