Unify Framework UCL MQTT Reference 1.7.0
All Files Pages
OccupancySensing Cluster

The following commands and attributes are accepted as JSON payloads for the OccupancySensing cluster.



OccupancySensing Attributes

The following attribute topics are used to retrieve the OccupancySensing cluster state.


OccupancySensing/Occupancy Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/Occupancy/Reported
[PREFIX]/OccupancySensing/Attributes/Occupancy/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster Occupancy Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "OccupancySensingOccupancy"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for Occupancy attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/Occupancy/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/Occupancy/Desired { "value": <DESIRED_OCCUPANCY>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/Occupancy/Reported { "value": <REPORTED_OCCUPANCY>}



OccupancySensing/OccupancySensorType Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/OccupancySensorType/Reported
[PREFIX]/OccupancySensing/Attributes/OccupancySensorType/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster OccupancySensorType Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "OccupancySensingOccupancySensorType"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for OccupancySensorType attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/OccupancySensorType/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/OccupancySensorType/Desired { "value": <DESIRED_OCCUPANCY_SENSOR_TYPE>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/OccupancySensorType/Reported { "value": <REPORTED_OCCUPANCY_SENSOR_TYPE>}



OccupancySensing/OccupancySensorTypeBitmap Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/OccupancySensorTypeBitmap/Reported
[PREFIX]/OccupancySensing/Attributes/OccupancySensorTypeBitmap/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster OccupancySensorTypeBitmap Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "OccupancySensingOccupancySensorTypeBitmap"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for OccupancySensorTypeBitmap attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/OccupancySensorTypeBitmap/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/OccupancySensorTypeBitmap/Desired { "value": <DESIRED_OCCUPANCY_SENSOR_TYPE_BITMAP>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/OccupancySensorTypeBitmap/Reported { "value": <REPORTED_OCCUPANCY_SENSOR_TYPE_BITMAP>}



OccupancySensing/PIROccupiedToUnoccupiedDelay Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/PIROccupiedToUnoccupiedDelay/Reported
[PREFIX]/OccupancySensing/Attributes/PIROccupiedToUnoccupiedDelay/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster PIROccupiedToUnoccupiedDelay Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for PIROccupiedToUnoccupiedDelay attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/PIROccupiedToUnoccupiedDelay/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PIROccupiedToUnoccupiedDelay/Desired { "value": <DESIRED_PIR_OCCUPIED_TO_UNOCCUPIED_DELAY>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PIROccupiedToUnoccupiedDelay/Reported { "value": <REPORTED_PIR_OCCUPIED_TO_UNOCCUPIED_DELAY>}



OccupancySensing/PIRUnoccupiedToOccupiedDelay Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedDelay/Reported
[PREFIX]/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedDelay/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster PIRUnoccupiedToOccupiedDelay Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for PIRUnoccupiedToOccupiedDelay attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedDelay/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedDelay/Desired { "value": <DESIRED_PIR_UNOCCUPIED_TO_OCCUPIED_DELAY>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedDelay/Reported { "value": <REPORTED_PIR_UNOCCUPIED_TO_OCCUPIED_DELAY>}



OccupancySensing/PIRUnoccupiedToOccupiedThreshold Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedThreshold/Reported
[PREFIX]/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedThreshold/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster PIRUnoccupiedToOccupiedThreshold Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for PIRUnoccupiedToOccupiedThreshold attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedThreshold/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedThreshold/Desired { "value": <DESIRED_PIR_UNOCCUPIED_TO_OCCUPIED_THRESHOLD>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PIRUnoccupiedToOccupiedThreshold/Reported { "value": <REPORTED_PIR_UNOCCUPIED_TO_OCCUPIED_THRESHOLD>}



OccupancySensing/UltrasonicOccupiedToUnoccupiedDelay Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/UltrasonicOccupiedToUnoccupiedDelay/Reported
[PREFIX]/OccupancySensing/Attributes/UltrasonicOccupiedToUnoccupiedDelay/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster UltrasonicOccupiedToUnoccupiedDelay Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for UltrasonicOccupiedToUnoccupiedDelay attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/UltrasonicOccupiedToUnoccupiedDelay/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/UltrasonicOccupiedToUnoccupiedDelay/Desired { "value": <DESIRED_ULTRASONIC_OCCUPIED_TO_UNOCCUPIED_DELAY>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/UltrasonicOccupiedToUnoccupiedDelay/Reported { "value": <REPORTED_ULTRASONIC_OCCUPIED_TO_UNOCCUPIED_DELAY>}



OccupancySensing/UltrasonicUnoccupiedToOccupiedDelay Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedDelay/Reported
[PREFIX]/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedDelay/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster UltrasonicUnoccupiedToOccupiedDelay Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for UltrasonicUnoccupiedToOccupiedDelay attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedDelay/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedDelay/Desired { "value": <DESIRED_ULTRASONIC_UNOCCUPIED_TO_OCCUPIED_DELAY>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedDelay/Reported { "value": <REPORTED_ULTRASONIC_UNOCCUPIED_TO_OCCUPIED_DELAY>}



OccupancySensing/UltrasonicUnoccupiedToOccupiedThreshold Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedThreshold/Reported
[PREFIX]/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedThreshold/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster UltrasonicUnoccupiedToOccupiedThreshold Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for UltrasonicUnoccupiedToOccupiedThreshold attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedThreshold/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedThreshold/Desired { "value": <DESIRED_ULTRASONIC_UNOCCUPIED_TO_OCCUPIED_THRESHOLD>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/UltrasonicUnoccupiedToOccupiedThreshold/Reported { "value": <REPORTED_ULTRASONIC_UNOCCUPIED_TO_OCCUPIED_THRESHOLD>}



OccupancySensing/PhysicalContactOccupiedToUnoccupiedDelay Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/PhysicalContactOccupiedToUnoccupiedDelay/Reported
[PREFIX]/OccupancySensing/Attributes/PhysicalContactOccupiedToUnoccupiedDelay/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster PhysicalContactOccupiedToUnoccupiedDelay Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for PhysicalContactOccupiedToUnoccupiedDelay attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/PhysicalContactOccupiedToUnoccupiedDelay/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PhysicalContactOccupiedToUnoccupiedDelay/Desired { "value": <DESIRED_PHYSICAL_CONTACT_OCCUPIED_TO_UNOCCUPIED_DELAY>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PhysicalContactOccupiedToUnoccupiedDelay/Reported { "value": <REPORTED_PHYSICAL_CONTACT_OCCUPIED_TO_UNOCCUPIED_DELAY>}



OccupancySensing/PhysicalContactUnoccupiedToOccupiedDelay Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedDelay/Reported
[PREFIX]/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedDelay/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster PhysicalContactUnoccupiedToOccupiedDelay Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for PhysicalContactUnoccupiedToOccupiedDelay attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedDelay/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedDelay/Desired { "value": <DESIRED_PHYSICAL_CONTACT_UNOCCUPIED_TO_OCCUPIED_DELAY>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedDelay/Reported { "value": <REPORTED_PHYSICAL_CONTACT_UNOCCUPIED_TO_OCCUPIED_DELAY>}



OccupancySensing/PhysicalContactUnoccupiedToOccupiedThreshold Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedThreshold/Reported
[PREFIX]/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedThreshold/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster PhysicalContactUnoccupiedToOccupiedThreshold Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for PhysicalContactUnoccupiedToOccupiedThreshold attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/+/+/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedThreshold/+'
# Example output
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedThreshold/Desired { "value": <DESIRED_PHYSICAL_CONTACT_UNOCCUPIED_TO_OCCUPIED_THRESHOLD>}
ucl/by-unid/<UNID>/ep0/OccupancySensing/Attributes/PhysicalContactUnoccupiedToOccupiedThreshold/Reported { "value": <REPORTED_PHYSICAL_CONTACT_UNOCCUPIED_TO_OCCUPIED_THRESHOLD>}



OccupancySensing/ClusterRevision Attribute

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Attributes/ClusterRevision/Reported
[PREFIX]/OccupancySensing/Attributes/ClusterRevision/Desired

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster ClusterRevision Attribute Properties",
"type": "object",
"properties": {
"value": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see desired/reported value for ClusterRevision attribute under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/<UNID>/<EP>/OccupancySensing/Attributes/ClusterRevision/+'
# Example output
ucl/by-unid/<UNID>/<EP>/OccupancySensing/Attributes/ClusterRevision/Desired { "value": <DESIRED_CLUSTER_REVISION> }
ucl/by-unid/<UNID>/<EP>/OccupancySensing/Attributes/ClusterRevision/Reported { "value": <REPORTED_CLUSTER_REVISION> }



OccupancySensing Command Support

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/SupportedCommands
[PREFIX]/OccupancySensing/SupportedGeneratedCommands

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Command Support Properties",
"type": "object",
"properties": {
"value": {
"type": "array",
"items" : {
"type": "string",
"enum": [
]
}
}
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To see supported commands for OccupancySensing cluster under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/<UNID>/<EP>/OccupancySensing/SupportedCommands'
# Example output
ucl/by-unid/<UNID>/<EP>/OccupancySensing/SupportedCommands { "value": [] }

To see supported generated commands for OccupancySensing cluster under the by-unid topic space:

mosquitto_sub -t 'ucl/by-unid/<UNID>/<EP>/OccupancySensing/SupportedGeneratedCommands'
# Example output
ucl/by-unid/<UNID>/<EP>/OccupancySensing/SupportedGeneratedCommands { "value": [] }



OccupancySensing Commands



OccupancySensing/WriteAttributes Command

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Commands/WriteAttributes

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster WriteAttributes Command Properties",
"type": "object",
"properties": {
"PIROccupiedToUnoccupiedDelay": {
"type": "integer"
},
"PIRUnoccupiedToOccupiedDelay": {
"type": "integer"
},
"PIRUnoccupiedToOccupiedThreshold": {
"type": "integer"
},
"UltrasonicOccupiedToUnoccupiedDelay": {
"type": "integer"
},
"UltrasonicUnoccupiedToOccupiedDelay": {
"type": "integer"
},
"UltrasonicUnoccupiedToOccupiedThreshold": {
"type": "integer"
},
"PhysicalContactOccupiedToUnoccupiedDelay": {
"type": "integer"
},
"PhysicalContactUnoccupiedToOccupiedDelay": {
"type": "integer"
},
"PhysicalContactUnoccupiedToOccupiedThreshold": {
"type": "integer"
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To update all OccupancySensing attributes under the by-unid topic space:

mosquitto_pub -t 'ucl/by-unid/<UNID>/<EP>/OccupancySensing/Commands/WriteAttributes' -m '{ "PIROccupiedToUnoccupiedDelay": <PIR_OCCUPIED_TO_UNOCCUPIED_DELAY_VALUE> ,"PIRUnoccupiedToOccupiedDelay": <PIR_UNOCCUPIED_TO_OCCUPIED_DELAY_VALUE> ,"PIRUnoccupiedToOccupiedThreshold": <PIR_UNOCCUPIED_TO_OCCUPIED_THRESHOLD_VALUE> ,"UltrasonicOccupiedToUnoccupiedDelay": <ULTRASONIC_OCCUPIED_TO_UNOCCUPIED_DELAY_VALUE> ,"UltrasonicUnoccupiedToOccupiedDelay": <ULTRASONIC_UNOCCUPIED_TO_OCCUPIED_DELAY_VALUE> ,"UltrasonicUnoccupiedToOccupiedThreshold": <ULTRASONIC_UNOCCUPIED_TO_OCCUPIED_THRESHOLD_VALUE> ,"PhysicalContactOccupiedToUnoccupiedDelay": <PHYSICAL_CONTACT_OCCUPIED_TO_UNOCCUPIED_DELAY_VALUE> ,"PhysicalContactUnoccupiedToOccupiedDelay": <PHYSICAL_CONTACT_UNOCCUPIED_TO_OCCUPIED_DELAY_VALUE> ,"PhysicalContactUnoccupiedToOccupiedThreshold": <PHYSICAL_CONTACT_UNOCCUPIED_TO_OCCUPIED_THRESHOLD_VALUE> }'

‍NOTE: Specify only the list of attributes to write in this command. Unspecified attributes will not be updated.



OccupancySensing/ForceReadAttributes Command

MQTT Topic Pattern:

[PREFIX]/OccupancySensing/Commands/ForceReadAttributes

MQTT Payload JSON Schema:

{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "OccupancySensing Cluster ForceReadAttributes Command Properties",
"type": "object",
"properties": {
"value": {
"type": "array"
"items": {
"type": "string",
"enum": [
"Occupancy",
"OccupancySensorType",
"OccupancySensorTypeBitmap",
"PIROccupiedToUnoccupiedDelay",
"PIRUnoccupiedToOccupiedDelay",
"PIRUnoccupiedToOccupiedThreshold",
"UltrasonicOccupiedToUnoccupiedDelay",
"UltrasonicUnoccupiedToOccupiedDelay",
"UltrasonicUnoccupiedToOccupiedThreshold",
"PhysicalContactOccupiedToUnoccupiedDelay",
"PhysicalContactUnoccupiedToOccupiedDelay",
"PhysicalContactUnoccupiedToOccupiedThreshold"
]
}
}
},
"required": [
"value"
]
}

Example Mosquitto CLI Tool Usage

To force read all OccupancySensing attributes under the by-unid topic space (by sending an empty array):

mosquitto_pub -t 'ucl/by-unid/<UNID>/<EP>/OccupancySensing/Commands/ForceReadAttributes' -m '{ "value": [] }'

To force read one of the OccupancySensing attributes under the by-unid topic space:

mosquitto_pub -t 'ucl/by-unid/<UNID>/<EP>/OccupancySensing/Commands/ForceReadAttributes' -m '{ "value": ["Occupancy"] }'