Introduction

Various elements of Device Profiles in EdgeX v1.x are either deprecated, redundant, or refer to functionality which is not planned to be implemented. For v2 ("Ireland") it was determined that these elements should be removed and the device profiles simplified where possible. This document describes the changes made to device profiles in v2, with examples.

The Device Profile

Device Resources

  • The isHidden field is added. Setting this to true causes the core-command service to block access to this resource
  • A device resource property previously consisted of value and units structures, it now contains the value properties directly
  • The units structure is replaced by a units field in the value properties
  • Other changes in the value properties:
    • Legacy fields size, precision, lsb are removed
    • The floatEncoding field is also removed. Floats in v2 are represented in e-notation only (ie, the base64 option is no longer available)
    • The type field is renamed to valueType

Example:

          properties:
            value:
                { type: "Uint64", readWrite: "R" }
            units:
                { defaultValue: "things" }


becomes

        properties:
            { valueType: "Uint64", readWrite: "R", units: "things" }

Device Commands

  • The get and set lists are replaced by a single resourceOperations list
  • A new field readWrite is added to control availability of read and write operations
  • isHidden field added (same as in device resources)
  • In the resource operations:
    • parameter renamed to defaultValue
    • Deprecated field object removed (use deviceResource)
    • Legacy fields operation, index, resource, deviceCommand, secondary and property removed

Example:

    name: rotation
    get:
      - { deviceResource: "Xrotation" }
      - { deviceResource: "Yrotation" }
      - { deviceResource: "Zrotation" }

becomes

    name: rotation
    readWrite: "R"
    resourceOperations:
      - { deviceResource: "Xrotation" }
      - { deviceResource: "Yrotation" }
      - { deviceResource: "Zrotation" }

Core Commands

The coreCommands section is removed entirely. Its functionality is provided by the new isVisible fields in device resources and device commands.

  • No labels