coherence.upnp.devices.control_point (module)

Control Point

DeviceQuery

A convenient class that allow us to create request queries to control point.

ControlPoint

Takes care of managing the different devices detected by our instance of class Coherence.

XMLRPC

A resource that implements XML-RPC.

Note

XML-RPC is a remote procedure call (RPC) protocol which uses XML to encode its calls and HTTP as a transport mechanism. “XML-RPC” also refers generically to the use of XML for remote procedure call, independently of the specific protocol.

See also

XML-RPC information extracted from: https://en.wikipedia.org/wiki/XML-RPC

class DeviceQuery(type, pattern, callback, timeout=0, oneshot=True)[source]

Bases: eventdispatcher.eventdispatcher.EventDispatcher

Changed in version 0.9.0: Introduced inheritance from EventDispatcher Changed fired to use EventDispatcher’s properties

fired
fire(device)[source]
check(device)[source]
class ControlPoint(coherence, auto_client=None)[source]

Bases: eventdispatcher.eventdispatcher.EventDispatcher, coherence.log.LogAble

Changed in version 0.9.0: Introduced inheritance from EventDispatcher, emitted events changed:

  • Coherence.UPnP.ControlPoint.{client.device_type}.detected => control_point_client_detected’
  • Coherence.UPnP.ControlPoint.{client.device_type}.removed => control_point_client_removed

Changed queries to use EventDispatcher’s properties

logCategory = 'controlpoint'
queries
shutdown()[source]
auto_client_append(device_type)[source]
browse(device)[source]
process_queries(device)[source]
add_query(query)[source]
static check_louie(receiver, signal, method='connect')[source]

Check if the connect or disconnect method’s arguments are valid in order to automatically convert to EventDispatcher’s bind

New in version 0.9.0.

connect(receiver, signal=None, sender=None, weak=True)[source]

Wrapper method around the deprecated method louie.connect.

Warning

This will probably be removed at some point, if you use the connect method you should migrate to the new event system EventDispatcher.

Changed in version 0.9.0: Added EventDispatcher’s compatibility for some basic signals

disconnect(receiver, signal=None, sender=None, weak=True)[source]

Wrapper method around the deprecated method louie.disconnect

Warning

This will probably be removed at some point, if you use the disconnect method you should migrate to the new event system EventDispatcher.

Changed in version 0.9.0: Added EventDispatcher’s compatibility for some basic signals

get_devices()[source]
get_device_with_id(id)[source]
get_device_by_host(host)[source]
check_device(device)[source]
completed(client, udn)[source]
remove_client(udn, client)[source]
propagate(event)[source]
put_resource(url, path)[source]
class XMLRPC(control_point)[source]

Bases: twisted.web.xmlrpc.XMLRPC

xmlrpc_list_devices()[source]
xmlrpc_mute_device(device_id)[source]
xmlrpc_unmute_device(device_id)[source]
xmlrpc_set_volume(device_id, volume)[source]
xmlrpc_play(device_id)[source]
xmlrpc_pause(device_id)[source]
xmlrpc_stop(device_id)[source]
xmlrpc_next(device_id)[source]
xmlrpc_previous(device_id)[source]
xmlrpc_set_av_transport_uri(device_id, uri)[source]
xmlrpc_create_object(device_id, container_id, arguments)[source]
xmlrpc_import_resource(device_id, source_uri, destination_uri)[source]
xmlrpc_put_resource(url, path)[source]
xmlrpc_ping()[source]
startXMLRPC(control_point, port)[source]