Description
A measurement produced by a sensor. FOr example, the amount of smoke measured by a smoke detector, or the amount of carbon monoxide measured by a carbon monoxide detector, and so forth.
Fields
Key | Type | Description |
---|---|---|
device
|
Device |
The device reporting the Required |
state
|
FieldPath |
The specific state data to check. Required |
is
|
Dynamic |
Checks if the state data is equal to a value. Optional To use this field, all the following fields CANNOT be used: isNot, greaterThanOrEqualTo, greaterThan, lessThanOrEqualTo, lessThan |
isNot
|
Dynamic |
Checks if the state data is not equal to a value. Optional To use this field, all the following fields CANNOT be used: is, greaterThanOrEqualTo, greaterThan, lessThanOrEqualTo, lessThan |
greaterThan
|
Dynamic |
Checks if the state data is greater than (>) a value. Optional To use this field, all the following fields CANNOT be used: isNot, is, greaterThanOrEqualTo |
greaterThanOrEqualTo
|
Dynamic |
Checks if the state data is greater than or equal to (>=) a value. Optional To use this field, all the following fields CANNOT be used: isNot, is, greaterThan |
lessThan
|
Dynamic |
Checks if the state data is less than (<) a value. Optional To use this field, all the following fields CANNOT be used: isNot, is, lessThanOrEqualTo |
lessThanOrEqualTo
|
Dynamic |
Checks if the state data is less than or equal to (<=) a value. Optional To use this field, all the following fields CANNOT be used: isNot, is, lessThan |
for
|
Duration |
Checks if the state has already remained for a certain duration. Only applicable for Starters, cannot be used with Conditions. Optional |
suppressFor
|
Duration |
Suppress the triggering of the starter for a specified time period. Optional |
SensorState State Data
Key | Type | Description |
---|---|---|
currentSensorStateData
|
Optional |
|
_string_
|
CurrentSensorStateData |
Optional |
currentSensorState
|
String |
Optional |
rawValue
|
Number |
Optional |
Examples
starters:
- type: device.state.SensorState
device: My Device - Room Name
state: currentSensorStateData.SmokeLevel.currentSensorState
is: high
starters:
- type: device.state.SensorState
device: My Device - Room Name
state: currentSensorStateData.SmokeLevel.rawValue
greaterThan: 200
starters:
- type: device.state.SensorState
device: My Device - Room Name
state: currentSensorStateData.CarbonMonoxideLevel.currentSensorState
is: carbon monoxide detected