sonos is a wrapper arround the php class PHPSonos to control sonos player via urls from a home automation server.
Checkout repository to a directory of your php enabled webserver (in this case 'sonos'). Download PHPSonos from here, extract the file scripts/PHPSonos.inc.php from zip and copy to same directory
Configuration is done in config.php. Add your zones and favourite Radiostations. Config path for messages must be accesible from sonos player.
Be sure your webserver can write in this directory (here 'sonos'), current playing radiostation is saved in a text file.
(for url compatibility to my old script 'action' can also be 'do')
###Play
http://yourserver/sonos/index.php?zone=kitchen&action=Play
###Stop
http://yourserver/sonos/index.php?zone=kitchen&action=Stop
###Toggle between play and stop
http://yourserver/sonos/index.php?zone=kitchen&action=TogglePlayStop
###Volume up / down
http://yourserver/sonos/index.php?zone=kitchen&action=VolumeUp
http://yourserver/sonos/index.php?zone=kitchen&action=VolumeDown
###Mute
http://yourserver/sonos/index.php?zone=kitchen&action=Mute
###Next radio from list
http://yourserver/sonos/index.php?zone=kitchen&action=nextRadio
###Play message
http://yourserver/sonos/index.php?zone=kitchen&action=sendMessage&messageId=1&volume=20
Stops current playing radio/list, plays the message 1.mp3, continues previously played radio/list
http://yourserver/sonos//index.php?zone=kitchen&action=sendMessage&message=Hello world&volume=55&lang=en
Stops current playing radio/list, plays the message "Hello world", continues previously played radio/list
None (feel free to write pull requests if you found bugs)
*write tests
- Forum users of IP-Symcon for PHPSonos Class