Index: Slim/Control/Command.pm =================================================================== RCS file: /home/cvs/cvsroot/g2/server/Slim/Control/Command.pm,v retrieving revision 1.2 diff -u -p -B -r1.2 Command.pm --- Slim/Control/Command.pm 14 Jul 2004 19:12:12 -0000 1.2 +++ Slim/Control/Command.pm 20 Jul 2004 00:46:41 -0000 @@ -71,6 +71,8 @@ sub execute { # title ? # duration ? # signalstrength ? + # sync + # playlist play (item can be a song, playlist or directory. synonym: load) # playlist insert (item can be a song, playlist or directory. synonym: insertlist) @@ -159,7 +161,7 @@ sub execute { $p3 = $p2client->model(); } } - } + } } elsif ($p0 eq "pref") { if (defined($p2) && $p2 ne '?' && !$::nosetup) { @@ -316,7 +318,26 @@ sub execute { } $client->power($p1); } - + } elsif ($p0 eq "sync") { + if (!defined $p1){ + } elsif ($p1 eq "?") { + $p1 = Slim::Player::Sync::syncname($client) + } elsif ($p1 eq "-") { + Slim::Player::Sync::unsync($client); + #$p0 = "unsync"; + #$p1 = undef; + } else { + my $buddy; + if (Slim::Player::Client::getClient($p1)) { + $buddy = Slim::Player::Client::getClient($p1); + } else { + my @clients = Slim::Player::Client::clients(); + if (defined $clients[$p1]) { + $buddy = $clients[$p1]; + } + } + Slim::Player::Sync::sync($buddy, $client) if defined $buddy; + } } elsif ($p0 eq "playlist") { # here are all the commands that add/insert/replace songs/directories/playlists on the current playlist if ($p1 =~ /^(play|load|append|add|resume|insert|insertlist)$/) { Index: HTML/EN/html/docs/crestronCLI.html =================================================================== RCS file: /home/cvs/cvsroot/g2/server/HTML/EN/html/docs/crestronCLI.html,v retrieving revision 1.1.1.1 diff -u -p -B -r1.1.1.1 crestronCLI.html --- HTML/EN/html/docs/crestronCLI.html 6 Jul 2004 13:43:37 -0000 1.1.1.1 +++ HTML/EN/html/docs/crestronCLI.html 20 Jul 2004 00:46:41 -0000 @@ -128,6 +128,16 @@ where:

Request: "04:20:00:12:23:45 sleep 300<CR>"
Response: "04:20:00:12:23:45 sleep 300<CR>"


+

sync <number|-|?>

+

The "sync" command specifies the player to synchronise with the given playerID. You may query which players are +already synced with this player by passing in a "?" parameter. To unsync a player, simply use the - parameter.

+

Examples:

+
+

Request: "04:20:00:12:23:45 sync ?<CR>"
Response: "04:20:00:12:23:45 sync Squeeze1<CR>"

+

Request: "04:20:00:12:23:45 sync 1<CR>"
Response: "04:20:00:12:23:45 sync 1<CR>"

+

Request: "04:20:00:12:23:45 sync -<CR>"
Response: "04:20:00:12:23:45 unsync<CR>"

+
+

power <0|1|?>

The "power" command turns the player on or off.

Examples: