Developer:Davaar:ProductService

From LinnDocs
Revision as of 13:24, 22 November 2010 by Eamonnb (talk | contribs) (Manufacturer)
Jump to: navigation, search

Architecture Overview

The Product service manages fundamental network presentation attributes for the Product such as Name and Room. It also handles Standby state and source control.

Network Attributes

Linked Products

A physical product may contain more than one Product and thus be presented as more than one Product service on the network. An example of this would be a preamplifier with an embedded DS source. In this scenario the two Product services are Linked (internally grouped). Linked Products share certain key parameters such as Standby and Room (ie changing Standby on one Product will automatically change the Standby state on all other Products in that Linked group).

Manufacturer

There are four Manufacturer attributes; Name, Info, Url and ImageUri.

Name

Name conatins the Manufacturer name (example: Linn). Name is read only.

Info

Info contains more Manufacturer information (example Linn Products Ltd). Info is read only.

Url

Url contains the Manufacturer website address (example www.linn.co.uk). Url is read only.

ImageUri
Manufacturer Action

The Manufacturer action returns all four Manufacturer attributes.

Model

There are four Model attributes; Name, Info, Url and ImageUri.

Name
Info
Url
ImageUri
Model Action

The Model action returns all four Model attributes.

Product

There are five Product attributes; Room, Name, Info, Url and ImageUri.

Room

This is the name of the room where the Product is located. Room is used to group the Product with other Products in the same physical room. The Upnp Friendly Name is derived by combining Room and Name in the format {Room : Name}. Products which are Linked always share the same Room name. Room is set to Main Room by default.

Name

This is the Product name. The Upnp Friendly Name is derived by combining Room and Name in the format {Room : Name}. By default the Name is the same as the Model.

Info
Url
ImageUri
Product Action

The Product action returns all five Product attributes.

Standby

This is the Standby state of the physical product. Standby can be changed using the SetStandby function. Products which are Linked always share the same Standby state.

Source Control

The Product service maintains a list of all sources within the Product. The size of this list is fixed for each Product and reported by the SourceCount function. Each source can then be referenced by its unique source index* in the list. Only one source, and thus one index, can be active at any given time. When a new source is selected the previous source is automatically deactivated before activating the new source. [* source index is zero based, ie 0,1,2,3,4,5..n, where n=listsize-1]

Source Index

The current (ie currently active) source can be changed by source index or source name. The function SetSourceIndex is used to change the current source by index. If the index is out of range an error will be reported. SetSourceIndexByName is used to change to the source whose name matches that specified. If a source of the specified name does not exist, the source will not change and no error will be reported.

SourceCount

SourceCount returns the number of sources that exist in the Product (ie the source list size). SourceCount is read only.

Source Specific Parameters

Each source has four fundamental parameters, SourceSystemName, SourceName, SourceVisible and SourceType.

SourceSystemName

SourceSystemName is a unique name string used to identify each source. SourceSystemName is read only. It can only be read via the Source action.

SourceName

SourceName is a unique name string assigned to each source. In the default state, for a given source index, SourceName matches SourceSystemName. It can be read via the Source action, or the SourceXml action.

SourceType

SourceType is a unique type string assigned to each source. SourceType is read only. It can be read via the Source action, or the SourceXml action.

SourceVisible

SourceVisible is a unique flag assigned to each source. This flag is used to indicate whether the source is to be displayed (front panel, GUI etc) when browsing through the source list. It can be read via the Source action, or the SourceXml action.

Note - a source's "visibility" does not affect its ability to be selected/activated via the functions SetSourceIndex and SetCurrentSourceByName.

SourceXml

SourceXml returns a list of all source specific parameters, for every source, in XML format.

SourceXmlChangeCount

SourceXmlChangeCount returns a count indicating the number of times SourceXml has been updated since power on. This is useful for control points that do not support eventing.

Source

Source returns all source parameters for a given source index.

API Reference

Product Service Description (XML)

Migration Guide

Upnp Action Name Changes

None.

Obsolete Functions

The following actions, which relate to configuration, have been removed from the Product service:

Network Attribute Actions
  • SetName
  • SetRoom
Source Control Actions
  • SetStartupSourceIndex
  • StartupSourceIndex
  • SetStartupSourceIndexByName
  • SetStartupSourceEnabled
  • StartupSourceEnabled
Source Specific Actions
  • SetSourceVisible
  • SetSourceName
  • SourceAttributes