Device Element

<device>

The <device> element defines the device class, and is the top-most element within a device class file. The <device> element is required, and only one <device> element can be defined per class file.

The following table lists the attributes for the <device> element.

 
AttributeDescriptionRequired/Optional
brandManufacturer name of the device manufacturer. The manufacturer name may be used by client applications or users to identify the manufacturer of a device. The example applications specify Echelon as the manufacturer.Optional
nameName of the device. The name may be used by client applications or users as a default logical identifier for a device. The logical name is not required to be unique. A client application or user can change the name to uniquely identify the device. Below are the default names defined by the example applications:
  • Appliance Module
  • Blinds
  • DIO
  • EnvSensor
  • Gas Valve
  • Keypad
  • Lamp Module
  • LED
  • Occupancy Sensor
  • Sun Blind Actuator
  • Switch
  • Washing Machine
Required
pidProgram ID for the device class. The program ID is a 64-bit unique identifier for the device application. The program ID is used by the IzoT Server to associate a device class file with a discovered device. The program ID is defined by the device application and is reported by the device when queried by the IzoT Server.Required
typeDevice type. The device type is used by client applications to identify devices, and may be displayed to users. You can specify any type. Below are the device types defined by the example applications:
  • blinds
  • color_lamp_controller
  • dimmer
  • dio
  • environment_sensor
  • keypad
  • occupancy
  • switch
  • thermostat
  • washer
Required

Example

<device pid="9FFFFF05006F0002" name="LED" type="color_lamp_controller" brand="Echelon">
  <attributes>
    <attribute ... >
      <nvs>
        <nv ... />
      </nvs>
    </attribute>
  </attributes>
  <nvs>
    <nv ... >
      <byte ... >
        <attribute ... />
      </byte>
    </nv>
  </nvs>
</device>

XML Schema Definition

  <xs:element name="device">
    <xs:complexType>
      <xs:sequence>
        <xs:element ref="attributes" />
        <xs:element ref="nvs" />
      </xs:sequence>
      <xs:attribute name="pid" use="required" >
        <xs:simpleType>
          <xs:restriction base="xs:hexBinary">
            <xs:length value="16" />
          </xs:restriction>
        </xs:simpleType>
      </xs:attribute>     
      <xs:attribute name="name" type="xs:string" use="required" />
      <xs:attribute name="type" type="xs:NMTOKEN" use="required" />
      <xs:attribute name="brand" type="xs:string" use="optional" />
    </xs:complexType>
  </xs:element>