PDA

View Full Version : How to detect if a SB2 is on?



jasontemple
2007-11-20, 12:01
Greetings all,
I've got 3 SB2 (2 wired, one wireless). I'd like to be able to detect if they are powered on from another PC (linux box). Is there a socket connection that can be made to determine that? Ping always reports a reply from these always-on devices. Could there be a socket connection check to see if the SB2 is up?

pfarrell
2007-11-20, 12:08
jasontemple wrote:
> Greetings all,
> I've got 3 SB2 (2 wired, one wireless). I'd like to be able to
> detect if they are powered on from another PC (linux box). Is there a
> socket connection that can be made to determine that?

The HTML interface on the SlimServer will show you how many devices it
knows about. Typically in a drop down box on the upper right side.

This is "alive and talking to the SlimServer" which may not be the same
as "on" in your question

kdf
2007-11-20, 12:09
In your SlimServer/SqueezeCenter web UI, look in Help->Technical Information->Command Line Interface. You'll find all that and more. For sending the commands you work through a telnet connection or use something like netcat (nc) to do each as a standalone command.

-kdf

jasontemple
2007-11-20, 12:22
In your SlimServer/SqueezeCenter web UI, look in Help->Technical Information->Command Line Interface. You'll find all that and more. For sending the commands you work through a telnet connection or use something like netcat (nc) to do each as a standalone command.

-kdf

That's exactly what I was looking for! Thanks kdf!

jasontemple
2007-11-20, 13:04
In case anyone is curious, it's quite straightforward.
nc localhost 9090
status
00%3A04%3A20%3A05%3A7b%3A6c status exit player_name%3A192.168.1.102 player_connected%3A1 power%3A0 signalstrength%3A0

and you can read power 0 for off and power 1 for on. very easy.

The plan is to use a fit-pc (5W linux box) to run the slimserver on and have it wake-on-lan the old disk array in the basement when needed (and shutdown when players detach).

again thanks all...