During weekdays I stream a local radio station to the B&O Essence in the bedroom, set volume correctly to avoid falling out of the bed and turn it off again 30 min. later. Same in the kitchen for the SA-NS310. In the bathroom I have a motion sensor that does the same thing, turns on the internet radio Sony SA-NS310 and off again if no motion was detected for 10 min.
This is the primary thing I’d like to migrate to my openhab server like all the other stuff.
So min. needed would be:
stream internet radio station
set volume
start/stop
Secondly, a friend of mine is using his Sonos for text-to-speech stuff and also as an alarm if a door/window has been opened in his absence. Pretty cool stuff, but I don’t want to buy a Sonos just for that.
Any help would be much appreciated (I am surprised that no one really seems to have such a need and everyone is using Sonos only ).
I had a similar use case in mind with a Denon HEOS product, that I’m planning to buy in the near future. I was surprised as well that there was no generic UPnP binding whilst the Sonos binding uses UPnP under the hood. (https://github.com/openhab/openhab/wiki/Sonos-Binding)
IMO best to contact the author of the Sonos binding first to ask why a specific Sonos binding was written instead of a generic UPnP binding.
@digitaldan, are you the author of the Sonos binding? If so, can you give some insights why a specific Sonos binding was written instead of a generic UPnP binding?
Hi,
sorry, I have no idea.
I am trying to refactor the WeMo Bindung to make use of UPnP, which is a quite difficult task due to Belkins UPnP implementation.
For a more generic UPnP Binding one has to know, what kind of devices should be supported and what actions could be called. So the binding has to find out the device type and what actions make sense for that specific device.
Another approach would be to have the devices UDN and the action to be called as configuration parameters to the Item / channel, but this could lead into problems if one makes configurations that are senselsess, like calling non existing actions.
Hi Hans-Jörg, I am surprised to hear that basic stuff like volume, play, stop is not generic for all UPnP devices (it is supposed to be a standardized architecture ). Anyhow, thanks for looking into this, RegardsJP
Hi,
yes and no, it is generic for UPnP audio devices, but what about other UPnP capable devices ?
You might find services and actions which are not generic. How to handle those ?
@kristofdk Sorry for the late delay, I have the forum verbosity up way to high and was loosing messages.
I have worked on the binding a little to add favorite support, but did not write it (that would be @kgoderis ) . It was the first time I had used upnp and I have to admit, it wasn’t alot of fun In order to do things like select favorites, tracks, songs, group, ungroup, ect… we ended up having to reverse engineer what the SONOS controls were sending to the units. The XML is very complicated, seemed to use very specific sonos fields and has a very fragile flow of what its expects in reply to messages. So while I would imagine you might be able to do basic play/pause types of commands by the spec, anything more complicated seemed to use non standard fields and require very specific custom code.
The “SmartThings IDE” is an online IDE within the SmartThings environment.
The code itself will not work outside of it, but the mechanics (ie handling of DLNA) should be transferable to any language.
I thought it might be useful as a reference =)
I have now “worked” with the code of the Sonos 2.0 binding and I think it should be relatively easy (maybe even very easy) to add a generic support for DLNA media renderers because there is already almost everything implemented for the Sonos.
What could be done is to simply add a new thing type for generic DLNA media renderers.
This could offer standard controls: play; pause, stop, volume, mute for all DLNA devices. And track information could be retrieved too.
PS: I have already done this extension from Sonos to generic DLNA for the Vera platform. So I know that it works well for a large panel of things supporting UPnP / DLNA.
That would be really cool - Can you estimate already if it might also work with Gramofon (www.gramofon.com) players ? They support allplay by default, and in fact i’d be glad if those are supported, i have a bunch of them waiting for integration