From OpenHome
Contents |
Sender Service
Overview
The Sender service indicates the presence of a Songcast sender and provides information concerning that sender.
A Songcast sender broadcasts music on a network in a way that is playable by a Songcast receiver.
If a device's Product service reports an attribute "Sender", then that device is guaranteed to bear the Sender service. Alternatively, Songcast senders can be discovered independently of the Product service by checking for the openhome.org.sender attribute on the Device service.
If the Sender service is available, all its properties and actions must be fully implemented.
Evented Properties
Audio
true if audio is currently available from this Sender; false otherwise.
Metadata
Provides basic information about the sender in OpenHome Metadata format.
{ "Title" : "[sender name]", "Origin" : "openhome.org.sender", "Uri" : "[ohz uri. ohu/ohm if ohz is not supported]", "Artwork" : "[uri to icon for sender]", "Channel" : "Songcast" }
Status
Reports the status of the sender:
- Enabled - sender enabled by user configuration (default)
- Disabled - sender disabled by user configuration
- Blocked - audio from another sender detected on the same channel (mis-configuration)
Actions
Audio
Arguments: (out bool audio)
Return the value of the Audio property.
Metadata
Arguments: (out string metadata)
Return the value of the Metadata property.
Status
Arguments: (out string status)
Return the value of the Status property.
UPnP Service Description
For devices supporting the UPnP protocol, the service description is
name: "Sender"
domain: "openhome.org.eriskay"
version: "1"
<?xml version="1.0"?> <scpd xmlns="urn:schemas-upnp-org:service-1-0"> <specVersion> <major>1</major> <minor>0</minor> </specVersion> <actionList> <action> <name>Audio</name> <argumentList> <argument> <name>Value</name> <direction>out</direction> <relatedStateVariable>Audio</relatedStateVariable> </argument> </argumentList> </action> <action> <name>Metadata</name> <argumentList> <argument> <name>Value</name> <direction>out</direction> <relatedStateVariable>Metadata</relatedStateVariable> </argument> </argumentList> </action> <action> <name>Status</name> <argumentList> <argument> <name>Value</name> <direction>out</direction> <relatedStateVariable>Status</relatedStateVariable> </argument> </argumentList> </action> </actionList> <serviceStateTable> <stateVariable sendEvents="yes"> <name>Audio</name> <dataType>boolean</dataType> </stateVariable> <stateVariable sendEvents="yes"> <name>Metadata</name> <dataType>string</dataType> </stateVariable> <stateVariable sendEvents="yes"> <name>Status</name> <dataType>string</dataType> <allowedValueList> <allowedValue>Enabled</allowedValue> <allowedValue>Disabled</allowedValue> <allowedValue>Blocked</allowedValue> </allowedValueList> </stateVariable> </serviceStateTable> </scpd>