[coherence-dev] howto add custom services/devices
Frank Scholz
fs at beebits.net
Thu Jan 7 12:27:19 CET 2010
Hi Arrigo,
> I need to add a new device with a custom service (providing zoning
> features for a multi-room player).
> I am guessing if there is a clean way to do it using plugins.
adding vendor defined actions and variables is very easy to add
via the backends.
You can see some example here:
http://coherence-project.org/browser/trunk/Cadre/cadre/renderer.py#L430
Adding a complete new service needs a bit more work.
You need to subclass for example the MediaServer class
http://coherence-project.org/browser/trunk/Coherence/coherence/upnp/devices/media_server.py
create the necessary Service classes by copying for example
http://coherence-project.org/browser/trunk/Coherence/coherence/upnp/services/servers/connection_manager_server.py
and then instantiating the device yourself, like this
http://coherence-project.org/browser/trunk/Cadre/cadre/base.py#L97
This may do sound more difficult than it actually is. ;-)
If you could provide me with some more details we could us this to
create some skeleton code in the wiki to serve as an example for
further reference.
Regards,
Frank
More information about the coherence-dev
mailing list