Universal Plug And Play UPn P Universal Plug

  • Slides: 24
Download presentation
Universal Plug And Play UPn. P Universal Plug And Play Myungho Choi © Realtime

Universal Plug And Play UPn. P Universal Plug And Play Myungho Choi © Realtime Embedded Systems Laboratory Inha University © 2002, Myungho Choi, RESL, Inha University Page : 1

Universal Plug And Play Contents • • • Introduction Components of a UPn. P

Universal Plug And Play Contents • • • Introduction Components of a UPn. P Network UPn. P protocol Overview How UPn. P Works Summary Reference © 2002, Myungho Choi, RESL, Inha University Page : 2

Universal Plug And Play Introduction • Home Network Purpose – PC를 비롯한 가정내의 정보가전기기들을

Universal Plug And Play Introduction • Home Network Purpose – PC를 비롯한 가정내의 정보가전기기들을 하나의 네트워크로 통합하여 일원적으로 관리 – 미들웨어 관련 기술 Ø UPn. P • MS, Compaq, Intel, Philips… Ø Jini • Sun Ø HAVI • Samsung, Sony, Philips, Sun… • 가정내 AV기기를 접속하는 기술 © 2002, Myungho Choi, RESL, Inha University Page : 3

Universal Plug And Play Introduction • Designed to support zero-configuration • Easy to Use,

Universal Plug And Play Introduction • Designed to support zero-configuration • Easy to Use, Standard Based, Flexible – Smooth Integration with Legacy Systems, non-IP Network, and Peripheral Devices A Mixed-Media, Multiple-Vendor Network © 2002, Myungho Choi, RESL, Inha University Page : 4

Universal Plug And Play Introduction • Fundamental Principles – Open Protocols Ø Use Internet

Universal Plug And Play Introduction • Fundamental Principles – Open Protocols Ø Use Internet open protocol model – Independent of any particular physical medium – Flexible Platform for APIs and Tools Ø Language- and OS- neutral – Take Advantage of the Web Proximity Services using the Browser © 2002, Myungho Choi, RESL, Inha University Page : 5

Universal Plug And Play Components of a UPn. P Network UPn. P Control Points,

Universal Plug And Play Components of a UPn. P Network UPn. P Control Points, Devices, and Services © 2002, Myungho Choi, RESL, Inha University Page : 6

Universal Plug And Play Components of a UPn. P Network • Devices – Container

Universal Plug And Play Components of a UPn. P Network • Devices – Container of services and nested devices – Different sets of services and embedded devices Ø Standardization on the set of services that a particular device type will provide – All of abovementioned information is captured in an XML device description document that the device must host – The device description also lists the properties associated with the device Ø ex> device name, icons… © 2002, Myungho Choi, RESL, Inha University Page : 7

Universal Plug And Play Components of a UPn. P Network • Services – The

Universal Plug And Play Components of a UPn. P Network • Services – The smallest unit of control – Expose actions and models its state with state variables – Similar to the device description, this information is part of an XML service description standardized – Device may contain multiple services – Consist of a state table, a control server and an event server © 2002, Myungho Choi, RESL, Inha University Page : 8

Universal Plug And Play Components of a UPn. P Network • Control Points –

Universal Plug And Play Components of a UPn. P Network • Control Points – Controller capable of discovering and controlling other devices – Devices will incorporate control point functionality (and viceversa) to enable true peer-to-peer networking © 2002, Myungho Choi, RESL, Inha University Page : 9

Universal Plug And Play UPn. P protocol Overview • Using open, standard protocols such

Universal Plug And Play UPn. P protocol Overview • Using open, standard protocols such as TCP/IP, HTTP and XML • Other technologies can participate in the UPn. P network through a UPn. P bridge or proxy A Bridged UPn. P Network © 2002, Myungho Choi, RESL, Inha University Page : 10

Universal Plug And Play UPn. P protocol Overview The UPn. P Protocol Stack ©

Universal Plug And Play UPn. P protocol Overview The UPn. P Protocol Stack © 2002, Myungho Choi, RESL, Inha University Page : 11

Universal Plug And Play How UPn. P Works • • • Addressing Discovery Description

Universal Plug And Play How UPn. P Works • • • Addressing Discovery Description Control Eventing Presentation 3 Control 4 Eventing 5 Presentation 2 Description 1 Discovery 0 Addressing © 2002, Myungho Choi, RESL, Inha University Page : 12

Universal Plug And Play How UPn. P Works • Addressing – Each device must

Universal Plug And Play How UPn. P Works • Addressing – Each device must have a Dynamic Host Configuration Protocol (DHCP) client Ø If no DHCP server is available, the device must use AUTO-IP to get an address – A device may have a friendly name for a device Ø In that case, a device may include a DNS client and may support dynamic DNS registration for its own name to address mapping – What steps does it take? Ø Pick an address Ø Check to see if it is used (ARP) Ø Periodically check for DHCP server © 2002, Myungho Choi, RESL, Inha University Page : 13

Universal Plug And Play How UPn. P Works • Discovery – Handled by SSDP

Universal Plug And Play How UPn. P Works • Discovery – Handled by SSDP – When a device is added to the network, SSDP allows that device to advertise its services to control points on the network – When a control point is added to the network, SSDP allows that control point to search for devices of interest on the network Ø Discovery uses a multicast variant of HTTP (HTTPMU) for device advertisements and control point searches Ø Discovery uses a unicast variant of HTTP (HTTPU) for responses to searches. © 2002, Myungho Choi, RESL, Inha University Page : 14

Universal Plug And Play How UPn. P Works NOTIFY * HTTP/1. 1 HOST: 239.

Universal Plug And Play How UPn. P Works NOTIFY * HTTP/1. 1 HOST: 239. 255. 250: 1900 CACHE-CONTROL: max-age = seconds until advertisement expires LOCATION: URL for UPn. P description for root device NT: search target NTS: ssdp: alive USN: advertisement UUID M-SEARCH * HTTP/1. 1 HOST: 239. 255. 250: 1900 MAN: "ssdp: discover" MX: seconds to delay response ST: search target HTTP/1. 1 200 OK CACHE-CONTROL: max-age = seconds until advertisement expires LOCATION: URL for UPn. P description for root device ST: search target USN: advertisement UUID © 2002, Myungho Choi, RESL, Inha University Advertising Searching Responding Page : 15

Universal Plug And Play How UPn. P Works • Description – Including vendor-specific, manufacturer

Universal Plug And Play How UPn. P Works • Description – Including vendor-specific, manufacturer information – Including a list of any embedded devices or services, as well as URLs for control, eventing, and presentation – Expressed in XML © 2002, Myungho Choi, RESL, Inha University Page : 16

Universal Plug And Play How UPn. P Works <? xml version="1. 0"? > <root

Universal Plug And Play How UPn. P Works <? xml version="1. 0"? > <root xmlns="urn: schemas-upnp-org: device-1 -0"> <URLBase>base URL for all relative URLs</URLBase> <device> <friendly. Name>short user-friendly title</friendly. Name> <manufacturer>manufacturer name</manufacturer> <manufacturer. URL>URL to manufacturer site</manufacturer. URL> <model. Description>long user-friendly title</model. Description> <model. Name>model name</model. Name> <model. Number>model number</model. Number> <model. URL>URL to model site</model. URL> <serial. Number>manufacturer's serial number</serial. Number> <UDN>uuid: UUID</UDN> <UPC>Universal Product Code</UPC> <device. Type>urn: schemas-upnp-org: device. Type</device. Type> <service. List> <service> <service. Type>urn: schemas-upnp-org: service. Type: v</service. Type> <service. Id>urn: upnp-org: service. Id: service. ID</service. Id> <SCPDURL>URL to service description</SCPDURL> <control. URL>URL for control</control. URL> <event. Sub. URL>URL for eventing</event. Sub. URL> </service> Declarations for other services (if any) go here </service. List> <device. List>Description of embedded devices (if any) go here</device. List> <icon. List> <icon> <mimetype>image/format</mimetype> <width>horizontal pixels</width> <height>vertical pixels</height> <depth>color depth</depth> <url>URL to icon</url> </icon> XML to declare other icons, if any, go here </icon. List> <presentation. URL>URL for presentation</presentation. URL> </device> <spec. Version> <major>1</major> <minor>0</minor> </spec. Version> </root> © 2002, Myungho Choi, RESL, Inha University Description Page : 17

Universal Plug And Play How UPn. P Works • Control – To learn more

Universal Plug And Play How UPn. P Works • Control – To learn more about the service, a control point must retrieve a detailed UPn. P description for each service – To control a device, a control point sends an action request to a device’s service – Control messages are also expressed in XML using SOAP – In response to the control message, the service returns action specific values or fault codes © 2002, Myungho Choi, RESL, Inha University Page : 18

Universal Plug And Play How UPn. P Works POST path of control URL HTTP/1.

Universal Plug And Play How UPn. P Works POST path of control URL HTTP/1. 1 HOST: host of control URL: port of control URL CONTENT-TYPE: text/xml; charset="utf-8" SOAPACTION: "urn: schemas-upnp-org: service. Type: v#action. Name" <s: Envelope xmlns: s="http: //schemas. xmlsoap. org/soap/envelope/" s: encoding. Style="http: //schemas. xmlsoap. org/soap/encoding/"> <s: Body> <u: action. Name xmlns: u="urn: schemas-upnp-org: service. Type: v"> <argument. Name>in arg value</argument. Name> other in args and their values (if any) go here </u: action. Name> </s: Body> </s: Envelope> Invoke Action HTTP/1. 1 200 OK CONTENT-TYPE: text/xml; charset="utf-8" <s: Envelope xmlns: s="http: //schemas. xmlsoap. org/soap/envelope/" s: encoding. Style="http: //schemas. xmlsoap. org/soap/encoding/"> <s: Body> <u: action. Name. Response xmlns: u="urn: schemas-upnp-org: service. Type: v"> <argument. Name>out arg value</argument. Name> other out args and their values (if any) go here </u: action. Name. Response> </s: Body> </s: Envelope> © 2002, Myungho Choi, RESL, Inha University Action Result Page : 19

Universal Plug And Play How UPn. P Works • Eventing – The service publishes

Universal Plug And Play How UPn. P Works • Eventing – The service publishes updates when state of device changes, and a control point may subscribe to receive this information – The service publishes updates by sending event messages Ø Event messages contain the names of one of more state variables and the current value of those variables Ø Event messages are also expressed in XML and formatted using GENA © 2002, Myungho Choi, RESL, Inha University Page : 20

Universal Plug And Play How UPn. P Works SUBSCRIBE publisher path HTTP/1. 1 HOST:

Universal Plug And Play How UPn. P Works SUBSCRIBE publisher path HTTP/1. 1 HOST: publisher host: publisher port CALLBACK: <delivery URL> NT: upnp: event TIMEOUT: Second-requested subscription duration HTTP/1. 1 200 OK SID: uuid: subscription-UUID TIMEOUT: Second-actual subscription duration NOTIFY delivery path HTTP/1. 1 HOST: delivery host: delivery port CONTENT-TYPE: text/xml NT: upnp: event NTS: upnp: propchange SID: uuid: subscription-UUID SEQ: event key <e: propertyset xmlns: e="urn: schemas-upnp-org: event-1 -0"> <e: property> <variable. Name>new value</variable. Name> </e: property> Other variable names and values (if any) go here </e: propertyset> © 2002, Myungho Choi, RESL, Inha University Subscribing Subscription Notify Page : 21

Universal Plug And Play How UPn. P Works • Presentation – Control point controls

Universal Plug And Play How UPn. P Works • Presentation – Control point controls device and/or views device status using HTML UI – Requires getting an address, discovery, and description (Does not require control or eventing) © 2002, Myungho Choi, RESL, Inha University Page : 22

Universal Plug And Play Summary • UPn. P is – – Based on the

Universal Plug And Play Summary • UPn. P is – – Based on the proven approach of Internet protocols Tailored by a Forum for device (service) types That are API, OS, physical network neutral For discovery, description, control, eventing, and presentation (simple HTML UI) © 2002, Myungho Choi, RESL, Inha University Page : 23

Universal Plug And Play Reference • http: //www. upnp. org • http: //www. w

Universal Plug And Play Reference • http: //www. upnp. org • http: //www. w 3. org/XML/ • http: //www. ietf. org © 2002, Myungho Choi, RESL, Inha University Page : 24