@uboness/homebridge-mqtt 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/LICENSE +176 -0
- package/README.md +3587 -0
- package/config.schema.json +16 -0
- package/dist/Availability.d.ts +20 -0
- package/dist/Availability.d.ts.map +1 -0
- package/dist/Availability.js +69 -0
- package/dist/Availability.js.map +1 -0
- package/dist/DeviceTemplate.d.ts +34 -0
- package/dist/DeviceTemplate.d.ts.map +1 -0
- package/dist/DeviceTemplate.js +91 -0
- package/dist/DeviceTemplate.js.map +1 -0
- package/dist/Logger.d.ts +20 -0
- package/dist/Logger.d.ts.map +1 -0
- package/dist/Logger.js +33 -0
- package/dist/Logger.js.map +1 -0
- package/dist/Mqtt.d.ts +44 -0
- package/dist/Mqtt.d.ts.map +1 -0
- package/dist/Mqtt.js +148 -0
- package/dist/Mqtt.js.map +1 -0
- package/dist/MqttDevice.d.ts +40 -0
- package/dist/MqttDevice.d.ts.map +1 -0
- package/dist/MqttDevice.js +48 -0
- package/dist/MqttDevice.js.map +1 -0
- package/dist/MqttPlatform.d.ts +39 -0
- package/dist/MqttPlatform.d.ts.map +1 -0
- package/dist/MqttPlatform.js +153 -0
- package/dist/MqttPlatform.js.map +1 -0
- package/dist/common.d.ts +76 -0
- package/dist/common.d.ts.map +1 -0
- package/dist/common.js +190 -0
- package/dist/common.js.map +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -0
- package/dist/service/AirQualitySensor.d.ts +12 -0
- package/dist/service/AirQualitySensor.d.ts.map +1 -0
- package/dist/service/AirQualitySensor.js +47 -0
- package/dist/service/AirQualitySensor.js.map +1 -0
- package/dist/service/Battery.d.ts +12 -0
- package/dist/service/Battery.d.ts.map +1 -0
- package/dist/service/Battery.js +34 -0
- package/dist/service/Battery.js.map +1 -0
- package/dist/service/Button.d.ts +12 -0
- package/dist/service/Button.d.ts.map +1 -0
- package/dist/service/Button.js +27 -0
- package/dist/service/Button.js.map +1 -0
- package/dist/service/CO2Sensor.d.ts +12 -0
- package/dist/service/CO2Sensor.d.ts.map +1 -0
- package/dist/service/CO2Sensor.js +34 -0
- package/dist/service/CO2Sensor.js.map +1 -0
- package/dist/service/COSensor.d.ts +12 -0
- package/dist/service/COSensor.d.ts.map +1 -0
- package/dist/service/COSensor.js +34 -0
- package/dist/service/COSensor.js.map +1 -0
- package/dist/service/ContactSensor.d.ts +12 -0
- package/dist/service/ContactSensor.d.ts.map +1 -0
- package/dist/service/ContactSensor.js +28 -0
- package/dist/service/ContactSensor.js.map +1 -0
- package/dist/service/Door.d.ts +12 -0
- package/dist/service/Door.d.ts.map +1 -0
- package/dist/service/Door.js +42 -0
- package/dist/service/Door.js.map +1 -0
- package/dist/service/Doorbell.d.ts +12 -0
- package/dist/service/Doorbell.d.ts.map +1 -0
- package/dist/service/Doorbell.js +33 -0
- package/dist/service/Doorbell.js.map +1 -0
- package/dist/service/Fan.d.ts +16 -0
- package/dist/service/Fan.d.ts.map +1 -0
- package/dist/service/Fan.js +48 -0
- package/dist/service/Fan.js.map +1 -0
- package/dist/service/HumidifierDehumidifier.d.ts +16 -0
- package/dist/service/HumidifierDehumidifier.d.ts.map +1 -0
- package/dist/service/HumidifierDehumidifier.js +66 -0
- package/dist/service/HumidifierDehumidifier.js.map +1 -0
- package/dist/service/HumiditySensor.d.ts +12 -0
- package/dist/service/HumiditySensor.d.ts.map +1 -0
- package/dist/service/HumiditySensor.js +28 -0
- package/dist/service/HumiditySensor.js.map +1 -0
- package/dist/service/LeakSensor.d.ts +12 -0
- package/dist/service/LeakSensor.d.ts.map +1 -0
- package/dist/service/LeakSensor.js +28 -0
- package/dist/service/LeakSensor.js.map +1 -0
- package/dist/service/LightSensor.d.ts +12 -0
- package/dist/service/LightSensor.d.ts.map +1 -0
- package/dist/service/LightSensor.js +28 -0
- package/dist/service/LightSensor.js.map +1 -0
- package/dist/service/Lightbulb.d.ts +12 -0
- package/dist/service/Lightbulb.d.ts.map +1 -0
- package/dist/service/Lightbulb.js +39 -0
- package/dist/service/Lightbulb.js.map +1 -0
- package/dist/service/LockMechanism.d.ts +16 -0
- package/dist/service/LockMechanism.d.ts.map +1 -0
- package/dist/service/LockMechanism.js +42 -0
- package/dist/service/LockMechanism.js.map +1 -0
- package/dist/service/Microphone.d.ts +12 -0
- package/dist/service/Microphone.d.ts.map +1 -0
- package/dist/service/Microphone.js +30 -0
- package/dist/service/Microphone.js.map +1 -0
- package/dist/service/MotionSensor.d.ts +12 -0
- package/dist/service/MotionSensor.d.ts.map +1 -0
- package/dist/service/MotionSensor.js +28 -0
- package/dist/service/MotionSensor.js.map +1 -0
- package/dist/service/MqttService.d.ts +24 -0
- package/dist/service/MqttService.d.ts.map +1 -0
- package/dist/service/MqttService.js +3 -0
- package/dist/service/MqttService.js.map +1 -0
- package/dist/service/OccupancySensor.d.ts +12 -0
- package/dist/service/OccupancySensor.d.ts.map +1 -0
- package/dist/service/OccupancySensor.js +28 -0
- package/dist/service/OccupancySensor.js.map +1 -0
- package/dist/service/Outlet.d.ts +12 -0
- package/dist/service/Outlet.d.ts.map +1 -0
- package/dist/service/Outlet.js +33 -0
- package/dist/service/Outlet.js.map +1 -0
- package/dist/service/SecuritySystem.d.ts +16 -0
- package/dist/service/SecuritySystem.d.ts.map +1 -0
- package/dist/service/SecuritySystem.js +47 -0
- package/dist/service/SecuritySystem.js.map +1 -0
- package/dist/service/SmokeSensor.d.ts +12 -0
- package/dist/service/SmokeSensor.d.ts.map +1 -0
- package/dist/service/SmokeSensor.js +28 -0
- package/dist/service/SmokeSensor.js.map +1 -0
- package/dist/service/Speaker.d.ts +12 -0
- package/dist/service/Speaker.d.ts.map +1 -0
- package/dist/service/Speaker.js +30 -0
- package/dist/service/Speaker.js.map +1 -0
- package/dist/service/Switch.d.ts +12 -0
- package/dist/service/Switch.d.ts.map +1 -0
- package/dist/service/Switch.js +27 -0
- package/dist/service/Switch.js.map +1 -0
- package/dist/service/TemperatureSensor.d.ts +12 -0
- package/dist/service/TemperatureSensor.d.ts.map +1 -0
- package/dist/service/TemperatureSensor.js +28 -0
- package/dist/service/TemperatureSensor.js.map +1 -0
- package/dist/service/Thermostat.d.ts +18 -0
- package/dist/service/Thermostat.d.ts.map +1 -0
- package/dist/service/Thermostat.js +105 -0
- package/dist/service/Thermostat.js.map +1 -0
- package/dist/service/Window.d.ts +12 -0
- package/dist/service/Window.d.ts.map +1 -0
- package/dist/service/Window.js +42 -0
- package/dist/service/Window.js.map +1 -0
- package/dist/service/WindowCovering.d.ts +13 -0
- package/dist/service/WindowCovering.d.ts.map +1 -0
- package/dist/service/WindowCovering.js +98 -0
- package/dist/service/WindowCovering.js.map +1 -0
- package/dist/service/characteristic/active.d.ts +6 -0
- package/dist/service/characteristic/active.d.ts.map +1 -0
- package/dist/service/characteristic/active.js +6 -0
- package/dist/service/characteristic/active.js.map +1 -0
- package/dist/service/characteristic/airQuality.d.ts +8 -0
- package/dist/service/characteristic/airQuality.d.ts.map +1 -0
- package/dist/service/characteristic/airQuality.js +14 -0
- package/dist/service/characteristic/airQuality.js.map +1 -0
- package/dist/service/characteristic/archetype/BooleanValue.d.ts +19 -0
- package/dist/service/characteristic/archetype/BooleanValue.d.ts.map +1 -0
- package/dist/service/characteristic/archetype/BooleanValue.js +54 -0
- package/dist/service/characteristic/archetype/BooleanValue.js.map +1 -0
- package/dist/service/characteristic/archetype/Converter.d.ts +44 -0
- package/dist/service/characteristic/archetype/Converter.d.ts.map +1 -0
- package/dist/service/characteristic/archetype/Converter.js +122 -0
- package/dist/service/characteristic/archetype/Converter.js.map +1 -0
- package/dist/service/characteristic/archetype/EnumValue.d.ts +19 -0
- package/dist/service/characteristic/archetype/EnumValue.d.ts.map +1 -0
- package/dist/service/characteristic/archetype/EnumValue.js +81 -0
- package/dist/service/characteristic/archetype/EnumValue.js.map +1 -0
- package/dist/service/characteristic/archetype/NumericValue.d.ts +51 -0
- package/dist/service/characteristic/archetype/NumericValue.d.ts.map +1 -0
- package/dist/service/characteristic/archetype/NumericValue.js +120 -0
- package/dist/service/characteristic/archetype/NumericValue.js.map +1 -0
- package/dist/service/characteristic/archetype/OneZeroValue.d.ts +19 -0
- package/dist/service/characteristic/archetype/OneZeroValue.d.ts.map +1 -0
- package/dist/service/characteristic/archetype/OneZeroValue.js +55 -0
- package/dist/service/characteristic/archetype/OneZeroValue.js.map +1 -0
- package/dist/service/characteristic/archetype/common.d.ts +21 -0
- package/dist/service/characteristic/archetype/common.d.ts.map +1 -0
- package/dist/service/characteristic/archetype/common.js +48 -0
- package/dist/service/characteristic/archetype/common.js.map +1 -0
- package/dist/service/characteristic/archetype/index.d.ts +7 -0
- package/dist/service/characteristic/archetype/index.d.ts.map +1 -0
- package/dist/service/characteristic/archetype/index.js +23 -0
- package/dist/service/characteristic/archetype/index.js.map +1 -0
- package/dist/service/characteristic/batteryLevel.d.ts +6 -0
- package/dist/service/characteristic/batteryLevel.d.ts.map +1 -0
- package/dist/service/characteristic/batteryLevel.js +6 -0
- package/dist/service/characteristic/batteryLevel.js.map +1 -0
- package/dist/service/characteristic/brightness.d.ts +6 -0
- package/dist/service/characteristic/brightness.d.ts.map +1 -0
- package/dist/service/characteristic/brightness.js +6 -0
- package/dist/service/characteristic/brightness.js.map +1 -0
- package/dist/service/characteristic/carbonDioxideDetected.d.ts +6 -0
- package/dist/service/characteristic/carbonDioxideDetected.d.ts.map +1 -0
- package/dist/service/characteristic/carbonDioxideDetected.js +6 -0
- package/dist/service/characteristic/carbonDioxideDetected.js.map +1 -0
- package/dist/service/characteristic/carbonDioxideLevel.d.ts +6 -0
- package/dist/service/characteristic/carbonDioxideLevel.d.ts.map +1 -0
- package/dist/service/characteristic/carbonDioxideLevel.js +6 -0
- package/dist/service/characteristic/carbonDioxideLevel.js.map +1 -0
- package/dist/service/characteristic/carbonDioxidePeakLevel.d.ts +6 -0
- package/dist/service/characteristic/carbonDioxidePeakLevel.d.ts.map +1 -0
- package/dist/service/characteristic/carbonDioxidePeakLevel.js +6 -0
- package/dist/service/characteristic/carbonDioxidePeakLevel.js.map +1 -0
- package/dist/service/characteristic/carbonMonoxideDetected.d.ts +6 -0
- package/dist/service/characteristic/carbonMonoxideDetected.d.ts.map +1 -0
- package/dist/service/characteristic/carbonMonoxideDetected.js +6 -0
- package/dist/service/characteristic/carbonMonoxideDetected.js.map +1 -0
- package/dist/service/characteristic/carbonMonoxideLevel.d.ts +6 -0
- package/dist/service/characteristic/carbonMonoxideLevel.d.ts.map +1 -0
- package/dist/service/characteristic/carbonMonoxideLevel.js +6 -0
- package/dist/service/characteristic/carbonMonoxideLevel.js.map +1 -0
- package/dist/service/characteristic/carbonMonoxidePeakLevel.d.ts +6 -0
- package/dist/service/characteristic/carbonMonoxidePeakLevel.d.ts.map +1 -0
- package/dist/service/characteristic/carbonMonoxidePeakLevel.js +6 -0
- package/dist/service/characteristic/carbonMonoxidePeakLevel.js.map +1 -0
- package/dist/service/characteristic/chargingState.d.ts +9 -0
- package/dist/service/characteristic/chargingState.d.ts.map +1 -0
- package/dist/service/characteristic/chargingState.js +12 -0
- package/dist/service/characteristic/chargingState.js.map +1 -0
- package/dist/service/characteristic/colorTemperature.d.ts +10 -0
- package/dist/service/characteristic/colorTemperature.d.ts.map +1 -0
- package/dist/service/characteristic/colorTemperature.js +8 -0
- package/dist/service/characteristic/colorTemperature.js.map +1 -0
- package/dist/service/characteristic/contactSensorState.d.ts +6 -0
- package/dist/service/characteristic/contactSensorState.d.ts.map +1 -0
- package/dist/service/characteristic/contactSensorState.js +6 -0
- package/dist/service/characteristic/contactSensorState.js.map +1 -0
- package/dist/service/characteristic/coolingThresholdTemperature.d.ts +13 -0
- package/dist/service/characteristic/coolingThresholdTemperature.d.ts.map +1 -0
- package/dist/service/characteristic/coolingThresholdTemperature.js +16 -0
- package/dist/service/characteristic/coolingThresholdTemperature.js.map +1 -0
- package/dist/service/characteristic/currentAmbientLightLevel.d.ts +10 -0
- package/dist/service/characteristic/currentAmbientLightLevel.d.ts.map +1 -0
- package/dist/service/characteristic/currentAmbientLightLevel.js +8 -0
- package/dist/service/characteristic/currentAmbientLightLevel.js.map +1 -0
- package/dist/service/characteristic/currentFanState.d.ts +8 -0
- package/dist/service/characteristic/currentFanState.d.ts.map +1 -0
- package/dist/service/characteristic/currentFanState.js +11 -0
- package/dist/service/characteristic/currentFanState.js.map +1 -0
- package/dist/service/characteristic/currentHeatingCoolingState.d.ts +8 -0
- package/dist/service/characteristic/currentHeatingCoolingState.d.ts.map +1 -0
- package/dist/service/characteristic/currentHeatingCoolingState.js +11 -0
- package/dist/service/characteristic/currentHeatingCoolingState.js.map +1 -0
- package/dist/service/characteristic/currentHorizontalTiltAngle.d.ts +6 -0
- package/dist/service/characteristic/currentHorizontalTiltAngle.d.ts.map +1 -0
- package/dist/service/characteristic/currentHorizontalTiltAngle.js +6 -0
- package/dist/service/characteristic/currentHorizontalTiltAngle.js.map +1 -0
- package/dist/service/characteristic/currentHumidifierDehumidifierState.d.ts +8 -0
- package/dist/service/characteristic/currentHumidifierDehumidifierState.d.ts.map +1 -0
- package/dist/service/characteristic/currentHumidifierDehumidifierState.js +12 -0
- package/dist/service/characteristic/currentHumidifierDehumidifierState.js.map +1 -0
- package/dist/service/characteristic/currentPosition.d.ts +6 -0
- package/dist/service/characteristic/currentPosition.d.ts.map +1 -0
- package/dist/service/characteristic/currentPosition.js +6 -0
- package/dist/service/characteristic/currentPosition.js.map +1 -0
- package/dist/service/characteristic/currentRelativeHumidity.d.ts +6 -0
- package/dist/service/characteristic/currentRelativeHumidity.d.ts.map +1 -0
- package/dist/service/characteristic/currentRelativeHumidity.js +6 -0
- package/dist/service/characteristic/currentRelativeHumidity.js.map +1 -0
- package/dist/service/characteristic/currentTemperature.d.ts +13 -0
- package/dist/service/characteristic/currentTemperature.d.ts.map +1 -0
- package/dist/service/characteristic/currentTemperature.js +16 -0
- package/dist/service/characteristic/currentTemperature.js.map +1 -0
- package/dist/service/characteristic/currentVerticalTiltAngle.d.ts +6 -0
- package/dist/service/characteristic/currentVerticalTiltAngle.d.ts.map +1 -0
- package/dist/service/characteristic/currentVerticalTiltAngle.js +6 -0
- package/dist/service/characteristic/currentVerticalTiltAngle.js.map +1 -0
- package/dist/service/characteristic/faultMessage.d.ts +12 -0
- package/dist/service/characteristic/faultMessage.d.ts.map +1 -0
- package/dist/service/characteristic/faultMessage.js +26 -0
- package/dist/service/characteristic/faultMessage.js.map +1 -0
- package/dist/service/characteristic/heatingThresholdTemperature.d.ts +13 -0
- package/dist/service/characteristic/heatingThresholdTemperature.d.ts.map +1 -0
- package/dist/service/characteristic/heatingThresholdTemperature.js +16 -0
- package/dist/service/characteristic/heatingThresholdTemperature.js.map +1 -0
- package/dist/service/characteristic/holdPosition.d.ts +10 -0
- package/dist/service/characteristic/holdPosition.d.ts.map +1 -0
- package/dist/service/characteristic/holdPosition.js +20 -0
- package/dist/service/characteristic/holdPosition.js.map +1 -0
- package/dist/service/characteristic/hue.d.ts +10 -0
- package/dist/service/characteristic/hue.d.ts.map +1 -0
- package/dist/service/characteristic/hue.js +8 -0
- package/dist/service/characteristic/hue.js.map +1 -0
- package/dist/service/characteristic/index.d.ts +78 -0
- package/dist/service/characteristic/index.d.ts.map +1 -0
- package/dist/service/characteristic/index.js +90 -0
- package/dist/service/characteristic/index.js.map +1 -0
- package/dist/service/characteristic/leakDetected.d.ts +6 -0
- package/dist/service/characteristic/leakDetected.d.ts.map +1 -0
- package/dist/service/characteristic/leakDetected.js +6 -0
- package/dist/service/characteristic/leakDetected.js.map +1 -0
- package/dist/service/characteristic/lockCurrentState.d.ts +8 -0
- package/dist/service/characteristic/lockCurrentState.d.ts.map +1 -0
- package/dist/service/characteristic/lockCurrentState.js +12 -0
- package/dist/service/characteristic/lockCurrentState.js.map +1 -0
- package/dist/service/characteristic/lockPhysicalControls.d.ts +6 -0
- package/dist/service/characteristic/lockPhysicalControls.d.ts.map +1 -0
- package/dist/service/characteristic/lockPhysicalControls.js +6 -0
- package/dist/service/characteristic/lockPhysicalControls.js.map +1 -0
- package/dist/service/characteristic/lockTargetState.d.ts +6 -0
- package/dist/service/characteristic/lockTargetState.d.ts.map +1 -0
- package/dist/service/characteristic/lockTargetState.js +9 -0
- package/dist/service/characteristic/lockTargetState.js.map +1 -0
- package/dist/service/characteristic/motionDetected.d.ts +6 -0
- package/dist/service/characteristic/motionDetected.d.ts.map +1 -0
- package/dist/service/characteristic/motionDetected.js +6 -0
- package/dist/service/characteristic/motionDetected.js.map +1 -0
- package/dist/service/characteristic/mqttOnline.d.ts +4 -0
- package/dist/service/characteristic/mqttOnline.d.ts.map +1 -0
- package/dist/service/characteristic/mqttOnline.js +15 -0
- package/dist/service/characteristic/mqttOnline.js.map +1 -0
- package/dist/service/characteristic/mute.d.ts +6 -0
- package/dist/service/characteristic/mute.d.ts.map +1 -0
- package/dist/service/characteristic/mute.js +6 -0
- package/dist/service/characteristic/mute.js.map +1 -0
- package/dist/service/characteristic/no2Density.d.ts +6 -0
- package/dist/service/characteristic/no2Density.d.ts.map +1 -0
- package/dist/service/characteristic/no2Density.js +6 -0
- package/dist/service/characteristic/no2Density.js.map +1 -0
- package/dist/service/characteristic/obstructionDetected.d.ts +6 -0
- package/dist/service/characteristic/obstructionDetected.d.ts.map +1 -0
- package/dist/service/characteristic/obstructionDetected.js +6 -0
- package/dist/service/characteristic/obstructionDetected.js.map +1 -0
- package/dist/service/characteristic/occupancyDetected.d.ts +6 -0
- package/dist/service/characteristic/occupancyDetected.d.ts.map +1 -0
- package/dist/service/characteristic/occupancyDetected.js +6 -0
- package/dist/service/characteristic/occupancyDetected.js.map +1 -0
- package/dist/service/characteristic/on.d.ts +6 -0
- package/dist/service/characteristic/on.d.ts.map +1 -0
- package/dist/service/characteristic/on.js +6 -0
- package/dist/service/characteristic/on.js.map +1 -0
- package/dist/service/characteristic/outletInUse.d.ts +6 -0
- package/dist/service/characteristic/outletInUse.d.ts.map +1 -0
- package/dist/service/characteristic/outletInUse.js +6 -0
- package/dist/service/characteristic/outletInUse.js.map +1 -0
- package/dist/service/characteristic/ozoneDensity.d.ts +6 -0
- package/dist/service/characteristic/ozoneDensity.d.ts.map +1 -0
- package/dist/service/characteristic/ozoneDensity.js +6 -0
- package/dist/service/characteristic/ozoneDensity.js.map +1 -0
- package/dist/service/characteristic/pm10Density.d.ts +6 -0
- package/dist/service/characteristic/pm10Density.d.ts.map +1 -0
- package/dist/service/characteristic/pm10Density.js +6 -0
- package/dist/service/characteristic/pm10Density.js.map +1 -0
- package/dist/service/characteristic/pm25Density.d.ts +6 -0
- package/dist/service/characteristic/pm25Density.d.ts.map +1 -0
- package/dist/service/characteristic/pm25Density.js +6 -0
- package/dist/service/characteristic/pm25Density.js.map +1 -0
- package/dist/service/characteristic/positionState.d.ts +8 -0
- package/dist/service/characteristic/positionState.d.ts.map +1 -0
- package/dist/service/characteristic/positionState.js +11 -0
- package/dist/service/characteristic/positionState.js.map +1 -0
- package/dist/service/characteristic/programmableSwitchEvent.d.ts +14 -0
- package/dist/service/characteristic/programmableSwitchEvent.d.ts.map +1 -0
- package/dist/service/characteristic/programmableSwitchEvent.js +39 -0
- package/dist/service/characteristic/programmableSwitchEvent.js.map +1 -0
- package/dist/service/characteristic/relativeHumidityDehumidifierThreshold.d.ts +6 -0
- package/dist/service/characteristic/relativeHumidityDehumidifierThreshold.d.ts.map +1 -0
- package/dist/service/characteristic/relativeHumidityDehumidifierThreshold.js +6 -0
- package/dist/service/characteristic/relativeHumidityDehumidifierThreshold.js.map +1 -0
- package/dist/service/characteristic/relativeHumidityHumidifierThreshold.d.ts +6 -0
- package/dist/service/characteristic/relativeHumidityHumidifierThreshold.d.ts.map +1 -0
- package/dist/service/characteristic/relativeHumidityHumidifierThreshold.js +6 -0
- package/dist/service/characteristic/relativeHumidityHumidifierThreshold.js.map +1 -0
- package/dist/service/characteristic/rotationDirection.d.ts +6 -0
- package/dist/service/characteristic/rotationDirection.d.ts.map +1 -0
- package/dist/service/characteristic/rotationDirection.js +9 -0
- package/dist/service/characteristic/rotationDirection.js.map +1 -0
- package/dist/service/characteristic/rotationSpeed.d.ts +23 -0
- package/dist/service/characteristic/rotationSpeed.d.ts.map +1 -0
- package/dist/service/characteristic/rotationSpeed.js +88 -0
- package/dist/service/characteristic/rotationSpeed.js.map +1 -0
- package/dist/service/characteristic/saturation.d.ts +6 -0
- package/dist/service/characteristic/saturation.d.ts.map +1 -0
- package/dist/service/characteristic/saturation.js +6 -0
- package/dist/service/characteristic/saturation.js.map +1 -0
- package/dist/service/characteristic/securitySystemAlarmType.d.ts +20 -0
- package/dist/service/characteristic/securitySystemAlarmType.d.ts.map +1 -0
- package/dist/service/characteristic/securitySystemAlarmType.js +26 -0
- package/dist/service/characteristic/securitySystemAlarmType.js.map +1 -0
- package/dist/service/characteristic/securitySystemCurrentState.d.ts +8 -0
- package/dist/service/characteristic/securitySystemCurrentState.d.ts.map +1 -0
- package/dist/service/characteristic/securitySystemCurrentState.js +13 -0
- package/dist/service/characteristic/securitySystemCurrentState.js.map +1 -0
- package/dist/service/characteristic/securitySystemTargetState.d.ts +8 -0
- package/dist/service/characteristic/securitySystemTargetState.d.ts.map +1 -0
- package/dist/service/characteristic/securitySystemTargetState.js +12 -0
- package/dist/service/characteristic/securitySystemTargetState.js.map +1 -0
- package/dist/service/characteristic/smokeDetected.d.ts +6 -0
- package/dist/service/characteristic/smokeDetected.d.ts.map +1 -0
- package/dist/service/characteristic/smokeDetected.js +6 -0
- package/dist/service/characteristic/smokeDetected.js.map +1 -0
- package/dist/service/characteristic/so2Density.d.ts +6 -0
- package/dist/service/characteristic/so2Density.d.ts.map +1 -0
- package/dist/service/characteristic/so2Density.js +6 -0
- package/dist/service/characteristic/so2Density.js.map +1 -0
- package/dist/service/characteristic/statusFault.d.ts +6 -0
- package/dist/service/characteristic/statusFault.d.ts.map +1 -0
- package/dist/service/characteristic/statusFault.js +6 -0
- package/dist/service/characteristic/statusFault.js.map +1 -0
- package/dist/service/characteristic/statusLowBattery.d.ts +6 -0
- package/dist/service/characteristic/statusLowBattery.d.ts.map +1 -0
- package/dist/service/characteristic/statusLowBattery.js +6 -0
- package/dist/service/characteristic/statusLowBattery.js.map +1 -0
- package/dist/service/characteristic/statusTampered.d.ts +6 -0
- package/dist/service/characteristic/statusTampered.d.ts.map +1 -0
- package/dist/service/characteristic/statusTampered.js +6 -0
- package/dist/service/characteristic/statusTampered.js.map +1 -0
- package/dist/service/characteristic/swingMode.d.ts +6 -0
- package/dist/service/characteristic/swingMode.d.ts.map +1 -0
- package/dist/service/characteristic/swingMode.js +6 -0
- package/dist/service/characteristic/swingMode.js.map +1 -0
- package/dist/service/characteristic/targetFanState.d.ts +6 -0
- package/dist/service/characteristic/targetFanState.d.ts.map +1 -0
- package/dist/service/characteristic/targetFanState.js +9 -0
- package/dist/service/characteristic/targetFanState.js.map +1 -0
- package/dist/service/characteristic/targetHeatingCoolingState.d.ts +8 -0
- package/dist/service/characteristic/targetHeatingCoolingState.d.ts.map +1 -0
- package/dist/service/characteristic/targetHeatingCoolingState.js +12 -0
- package/dist/service/characteristic/targetHeatingCoolingState.js.map +1 -0
- package/dist/service/characteristic/targetHorizontalTiltAngle.d.ts +6 -0
- package/dist/service/characteristic/targetHorizontalTiltAngle.d.ts.map +1 -0
- package/dist/service/characteristic/targetHorizontalTiltAngle.js +6 -0
- package/dist/service/characteristic/targetHorizontalTiltAngle.js.map +1 -0
- package/dist/service/characteristic/targetHumidifierDehumidifierState.d.ts +8 -0
- package/dist/service/characteristic/targetHumidifierDehumidifierState.d.ts.map +1 -0
- package/dist/service/characteristic/targetHumidifierDehumidifierState.js +11 -0
- package/dist/service/characteristic/targetHumidifierDehumidifierState.js.map +1 -0
- package/dist/service/characteristic/targetPosition.d.ts +6 -0
- package/dist/service/characteristic/targetPosition.d.ts.map +1 -0
- package/dist/service/characteristic/targetPosition.js +6 -0
- package/dist/service/characteristic/targetPosition.js.map +1 -0
- package/dist/service/characteristic/targetRelativeHumidity.d.ts +6 -0
- package/dist/service/characteristic/targetRelativeHumidity.d.ts.map +1 -0
- package/dist/service/characteristic/targetRelativeHumidity.js +6 -0
- package/dist/service/characteristic/targetRelativeHumidity.js.map +1 -0
- package/dist/service/characteristic/targetTemerature.d.ts +13 -0
- package/dist/service/characteristic/targetTemerature.d.ts.map +1 -0
- package/dist/service/characteristic/targetTemerature.js +16 -0
- package/dist/service/characteristic/targetTemerature.js.map +1 -0
- package/dist/service/characteristic/targetVerticalTiltAngle.d.ts +6 -0
- package/dist/service/characteristic/targetVerticalTiltAngle.d.ts.map +1 -0
- package/dist/service/characteristic/targetVerticalTiltAngle.js +6 -0
- package/dist/service/characteristic/targetVerticalTiltAngle.js.map +1 -0
- package/dist/service/characteristic/temperatureDisplayUnits.d.ts +6 -0
- package/dist/service/characteristic/temperatureDisplayUnits.d.ts.map +1 -0
- package/dist/service/characteristic/temperatureDisplayUnits.js +9 -0
- package/dist/service/characteristic/temperatureDisplayUnits.js.map +1 -0
- package/dist/service/characteristic/vocDensity.d.ts +6 -0
- package/dist/service/characteristic/vocDensity.d.ts.map +1 -0
- package/dist/service/characteristic/vocDensity.js +6 -0
- package/dist/service/characteristic/vocDensity.js.map +1 -0
- package/dist/service/characteristic/volume.d.ts +6 -0
- package/dist/service/characteristic/volume.d.ts.map +1 -0
- package/dist/service/characteristic/volume.js +6 -0
- package/dist/service/characteristic/volume.js.map +1 -0
- package/dist/service/characteristic/waterLevel.d.ts +6 -0
- package/dist/service/characteristic/waterLevel.d.ts.map +1 -0
- package/dist/service/characteristic/waterLevel.js +6 -0
- package/dist/service/characteristic/waterLevel.js.map +1 -0
- package/dist/service/index.d.ts +4 -0
- package/dist/service/index.d.ts.map +1 -0
- package/dist/service/index.js +75 -0
- package/dist/service/index.js.map +1 -0
- package/dist/service/until.d.ts +36 -0
- package/dist/service/until.d.ts.map +1 -0
- package/dist/service/until.js +83 -0
- package/dist/service/until.js.map +1 -0
- package/dist/settings.d.ts +9 -0
- package/dist/settings.d.ts.map +1 -0
- package/dist/settings.js +12 -0
- package/dist/settings.js.map +1 -0
- package/package.json +63 -0
- package/tsconfig.json +26 -0
package/README.md
ADDED
|
@@ -0,0 +1,3587 @@
|
|
|
1
|
+
# Homebridge Mqtt Plugin
|
|
2
|
+
|
|
3
|
+
## !! Experimental !!
|
|
4
|
+
|
|
5
|
+
- [Core Ideas](#core-ideas)
|
|
6
|
+
- [Device Configuration](#device-configuration)
|
|
7
|
+
- [Settings](#settings)
|
|
8
|
+
- [Templates](#templates)
|
|
9
|
+
- [Converters Reference](#converters-reference)
|
|
10
|
+
- [Characteristics Reference](#characteristics-reference)
|
|
11
|
+
- [Services Reference](#services-reference)
|
|
12
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
13
|
+
- [battery](#battery)
|
|
14
|
+
- [button](#button)
|
|
15
|
+
- [co2-sensor](#co2-sensor)
|
|
16
|
+
- [contact-sensor](#contact-sensor)
|
|
17
|
+
- [co-sensor](#co-sensor)
|
|
18
|
+
- [door](#door)
|
|
19
|
+
- [doorbell](#doorbell)
|
|
20
|
+
- [fan](#fan)
|
|
21
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
22
|
+
- [humidity-sensor](#humidity-sensor)
|
|
23
|
+
- [leak-sensor](#leak-sensor)
|
|
24
|
+
- [lightbulb](#lightbulb)
|
|
25
|
+
- [light-sensor](#light-sensor)
|
|
26
|
+
- [lock](#lock)
|
|
27
|
+
- [microphone](#microphone)
|
|
28
|
+
- [motion-sensor](#motion-sensor)
|
|
29
|
+
- [occupancy-sensor](#occupancy-sensor)
|
|
30
|
+
- [outlet](#outlet)
|
|
31
|
+
- [security-system](#security-system)
|
|
32
|
+
- [smoke-sensor](#smoke-sensor)
|
|
33
|
+
- [speaker](#speaker)
|
|
34
|
+
- [switch](#switch)
|
|
35
|
+
- [temperature-sensor](#temperature-sensor)
|
|
36
|
+
- [thermostat](#thermostat)
|
|
37
|
+
- [window](#window)
|
|
38
|
+
- [window-covering](#window-covering)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
This plugin enables the configuration of devices (HomeKit accessories) that are driven by MQTT topics.
|
|
42
|
+
|
|
43
|
+
## Core Ideas
|
|
44
|
+
- Multiple brokers are supported
|
|
45
|
+
- Each broker defines:
|
|
46
|
+
- a unique id
|
|
47
|
+
- connection settings to a single MQTT broker
|
|
48
|
+
- `baseTopic` a "prefix" topic that will be prepended to all topics configured by the devices & templates
|
|
49
|
+
- device configurations - all driven by topics within the broker
|
|
50
|
+
- device templates - reusable device configuration segments (helps keep configuration clean and simple)
|
|
51
|
+
|
|
52
|
+
### Device Configuration
|
|
53
|
+
A device configuration is made out of:
|
|
54
|
+
- `id` - This identifies the device in homebridge, so it needs to be unique within the Homebridge instance.
|
|
55
|
+
- `type` - The primary service type
|
|
56
|
+
- `name` - Serves as both the primary service name and the HomeKit accessory name
|
|
57
|
+
- `deviceName` - If set, serves as the accessory name (used to separate the accessory and primary service names)
|
|
58
|
+
- `topics` - Defines the characteristics of the primary service and their associated (read/write) topics from/to which values will be read/written
|
|
59
|
+
- `services` - An array of additional (secondary) services that are part of the HomeKit accessory.
|
|
60
|
+
|
|
61
|
+
Here's an example of a simple lightbulb accessory that happens to have a built-in light sensor:
|
|
62
|
+
|
|
63
|
+
```json
|
|
64
|
+
{
|
|
65
|
+
"id": "my-ceiling-light",
|
|
66
|
+
"type": "lightbulb",
|
|
67
|
+
"name": "My Ceiling Lamp",
|
|
68
|
+
"topics": {
|
|
69
|
+
"on": {
|
|
70
|
+
"get": "my-home/my-room/my-ceiling-light/on",
|
|
71
|
+
"set": "my-home/my-room/my-ceiling-light/on/set",
|
|
72
|
+
"converter": "boolean"
|
|
73
|
+
},
|
|
74
|
+
"brightness": {
|
|
75
|
+
"get": "my-home/my-room/my-ceiling-light/brightness",
|
|
76
|
+
"set": "my-home/my-room/my-ceiling-light/brightness/set"
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
"services": [
|
|
80
|
+
{
|
|
81
|
+
"type": "light-sensor",
|
|
82
|
+
"name": "Light Sensor",
|
|
83
|
+
"topics": {
|
|
84
|
+
"ambientLevel": {
|
|
85
|
+
"get": "my-home/my-room/my-ceiling-light/lux",
|
|
86
|
+
"set": "my-home/my-room/my-ceiling-light/lux/set"
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
]
|
|
91
|
+
}
|
|
92
|
+
```
|
|
93
|
+
Each service type defines a set of required characteristics which must be configured within the `topics` configuration
|
|
94
|
+
(e.g. A `switch` service must define the `on` characteristic).
|
|
95
|
+
|
|
96
|
+
There may also be optional characteristics that a service can support (e.g. all sensor services support the
|
|
97
|
+
`statusLowBattery` characteristic, though it's optional).
|
|
98
|
+
|
|
99
|
+
The HomeKit Accessory Protocol (HAP) Specification define the services supported in homekit and their required/optional
|
|
100
|
+
characteristics. This plugin roughly follows these specifications with a few exceptions here and there.
|
|
101
|
+
|
|
102
|
+
In the example above, the configured MQTT topics hold the values that will eventually be read/published by
|
|
103
|
+
the relevant characteristics. MQTT values are strings and therefore we need a way to convert these values to the appropriate
|
|
104
|
+
type that is expected by each characteristic. This is the role of the `converter`. Each characteristic support a set of
|
|
105
|
+
converters that helps in converting different formats. For example, as in the above, by default, the `on` characteristic
|
|
106
|
+
expects `1` (for "on") and `0` (for "off") values. But if the MQTT value holds `true` and `false` instead, the `boolean`
|
|
107
|
+
converter will be able to handle it. What if the MQTT values is `YES` and `NO`? Well, there's a converter
|
|
108
|
+
for that too - a more generic one: `converter: { "on": "YES", "off": "NO" }` - in this case, we indicate which MQTT
|
|
109
|
+
values represent `on` and `off`.
|
|
110
|
+
|
|
111
|
+
Some systems (e.g. zigbee2mqtt) publish JSON values to their MQTT topic. To fetch a JSON value, you append
|
|
112
|
+
the "path" to the value within the JSON to the topic itself, using the `$` sign as a separator. For example,
|
|
113
|
+
the following hum characteristic configuration reads/writes the hue values from/to JSON values in the MQTT topics:
|
|
114
|
+
|
|
115
|
+
```json
|
|
116
|
+
{
|
|
117
|
+
"hue": {
|
|
118
|
+
"get": "zigbee2mqtt/Garage Led$color.hue", // reads from
|
|
119
|
+
"set": "zigbee2mqtt/Garage Led/set$color.hue" // publishes to
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
```
|
|
123
|
+
In the above, the topic is `zigbee2mqtt/Garage Led` holds a JSON object of the form:
|
|
124
|
+
```json
|
|
125
|
+
{
|
|
126
|
+
//...
|
|
127
|
+
"color": {
|
|
128
|
+
"hue": 212,
|
|
129
|
+
"saturation": 10,
|
|
130
|
+
"x": 0.3131,
|
|
131
|
+
"y": 0.3232
|
|
132
|
+
}
|
|
133
|
+
//...
|
|
134
|
+
}
|
|
135
|
+
```
|
|
136
|
+
With the `$` syntax, the plugin knows how to read it and extract the appropriate value.
|
|
137
|
+
|
|
138
|
+
Similarly, when publishing a value to the `zigbee2mqtt/Garage Led/set` topic, the plugin will create a JSON value of
|
|
139
|
+
the following form:
|
|
140
|
+
|
|
141
|
+
```json
|
|
142
|
+
{ "color": { "hue": 200 }}
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
At the moment, not all HAP services are supported by this plugins, but certainly a big chunk of the most common ones.
|
|
146
|
+
More services/characteristics may be added in the future.
|
|
147
|
+
|
|
148
|
+
There are many service types to choose from and many characteristic types as well, all of which are
|
|
149
|
+
|
|
150
|
+
## Settings
|
|
151
|
+
|
|
152
|
+
Here's an example of the plugin configuration:
|
|
153
|
+
|
|
154
|
+
```json
|
|
155
|
+
{
|
|
156
|
+
"name": "Mqtt",
|
|
157
|
+
"platform": "Mqtt",
|
|
158
|
+
"logger": {
|
|
159
|
+
"trace": false // change to 'true' to output extensive logs (only works when HB runs in debug mode)
|
|
160
|
+
},
|
|
161
|
+
"servers": [
|
|
162
|
+
{
|
|
163
|
+
"id": "knx",
|
|
164
|
+
"host": "mqtt.local",
|
|
165
|
+
"port": 1883,
|
|
166
|
+
"auth": { // optional, remove if your MQTT broker doesn't require authentication
|
|
167
|
+
"username": "<username>",
|
|
168
|
+
"password": "<password>"
|
|
169
|
+
},
|
|
170
|
+
"baseTopic": "knx",
|
|
171
|
+
"templates": [
|
|
172
|
+
// all the KNX device templates are configued here (see below)
|
|
173
|
+
],
|
|
174
|
+
"devices": [
|
|
175
|
+
// all the KNX devices are configured here
|
|
176
|
+
]
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
"id": "zigbee2mqtt",
|
|
180
|
+
"host": "mqtt.local",
|
|
181
|
+
"port": 1883,
|
|
182
|
+
"auth": { // optional, remove if your MQTT broker doesn't require authentication
|
|
183
|
+
"username": "<username>",
|
|
184
|
+
"password": "<password>"
|
|
185
|
+
},
|
|
186
|
+
"baseTopic": "z2m",
|
|
187
|
+
"templates": [
|
|
188
|
+
// all the z2m device templates are configued here (see below)
|
|
189
|
+
],
|
|
190
|
+
"devices": [
|
|
191
|
+
// all the z2m devices are configured here
|
|
192
|
+
]
|
|
193
|
+
}
|
|
194
|
+
]
|
|
195
|
+
}
|
|
196
|
+
```
|
|
197
|
+
In the example above, the plugin is configured with 2 brokers - one that holds all KNX devices values and another that
|
|
198
|
+
is the [zigbee2mqtt](https://www.zigbee2mqtt.io/) broker.
|
|
199
|
+
|
|
200
|
+
If you look closely thought, they are actually pointing to
|
|
201
|
+
the same server - they could point to different servers, but in this case it's the same server and the only thing that
|
|
202
|
+
really differentiate them is the `baseTopic` - all KNX values are under the `knx` base topic while all the `zigbee2mqtt`
|
|
203
|
+
topics are under the `z2m` base topic.
|
|
204
|
+
|
|
205
|
+
In this case, we could have also use a single MQTT connection by dropping the `baseTopic` setting and make sure that the
|
|
206
|
+
devices use the full MQTT topic paths in their configurations. So there are a lot of possibilities to design this in a
|
|
207
|
+
way to best fit your setup.
|
|
208
|
+
|
|
209
|
+
### Templates
|
|
210
|
+
|
|
211
|
+
We've seen above an example of a device configuration. These configurations may vary from simple to complex, depending on
|
|
212
|
+
the type of services (and the number of services) each device/accessory has. But event in its simplest form, like a simple
|
|
213
|
+
`switch` device with a single primary `switch` service that only has one `on` characteristic, when you have many of such
|
|
214
|
+
services defined, the configuration may look quite cumbersome. More over, it really depends on the setup you have at home,
|
|
215
|
+
but it is often the case that the same physical device types are used across the house, for example:
|
|
216
|
+
|
|
217
|
+
- If you have KNX installed in the house, the setups for all your switches in the house is most likely similar and the
|
|
218
|
+
only thing that changes between them is the KNX group addresses that are associated with them.
|
|
219
|
+
|
|
220
|
+
- If you have a Hue bridge at home, and you're using Hue motion sensor, it's very likely you have a bunch of those and
|
|
221
|
+
zigbee2mqtt will expose their state in similar ways (just under a different base topic)
|
|
222
|
+
|
|
223
|
+
There can be many examples as the two above, but the point is, with the normal device configuration as we've seen, you'll
|
|
224
|
+
find yourself copy-pasting configurations all over the place. This is where **Templates** enter the picture.
|
|
225
|
+
|
|
226
|
+
But first, lets say we have 2 Hue motion sensors in the house and we configure them without templates, here's how it might
|
|
227
|
+
look like:
|
|
228
|
+
|
|
229
|
+
```json
|
|
230
|
+
{
|
|
231
|
+
//...
|
|
232
|
+
"devices": [
|
|
233
|
+
{
|
|
234
|
+
"id": "garage-motion",
|
|
235
|
+
"name": "Garage Motion",
|
|
236
|
+
"type": "motion-sensor",
|
|
237
|
+
"topics": {
|
|
238
|
+
"motionDetected": {
|
|
239
|
+
"get": "Garage Motion$occupancy",
|
|
240
|
+
"converter": "boolean"
|
|
241
|
+
}
|
|
242
|
+
},
|
|
243
|
+
"services": [
|
|
244
|
+
{
|
|
245
|
+
"name": "Battery Level",
|
|
246
|
+
"type": "battery",
|
|
247
|
+
"topics": {
|
|
248
|
+
"batteryLevel": {
|
|
249
|
+
"get": "Garage Motion$battery"
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
"name": "Light Sensor",
|
|
255
|
+
"type": "light-sensor",
|
|
256
|
+
"topics": {
|
|
257
|
+
"ambientLevel": {
|
|
258
|
+
"get": "Garage Motion$illuminance_lux"
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
"name": "Temperature Sensor",
|
|
264
|
+
"type": "temperature-sensor",
|
|
265
|
+
"topics": {
|
|
266
|
+
"currentTemperature": {
|
|
267
|
+
"get": "Garage Motion$temperature"
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
]
|
|
272
|
+
},
|
|
273
|
+
{
|
|
274
|
+
"id": "stairs-motion",
|
|
275
|
+
"name": "Stairs Motion",
|
|
276
|
+
"type": "motion-sensor",
|
|
277
|
+
"topics": {
|
|
278
|
+
"motionDetected": {
|
|
279
|
+
"get": "Stairs Motion$occupancy",
|
|
280
|
+
"converter": "boolean"
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
"services": [
|
|
284
|
+
{
|
|
285
|
+
"name": "Battery Level",
|
|
286
|
+
"type": "battery",
|
|
287
|
+
"topics": {
|
|
288
|
+
"batteryLevel": {
|
|
289
|
+
"get": "Stairs Motion$battery"
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
"name": "Light Sensor",
|
|
295
|
+
"type": "light-sensor",
|
|
296
|
+
"topics": {
|
|
297
|
+
"ambientLevel": {
|
|
298
|
+
"get": "Stairs Motion$illuminance_lux"
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
},
|
|
302
|
+
{
|
|
303
|
+
"name": "Temperature Sensor",
|
|
304
|
+
"type": "temperature-sensor",
|
|
305
|
+
"topics": {
|
|
306
|
+
"currentTemperature": {
|
|
307
|
+
"get": "Stairs Motion$temperature"
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
}
|
|
311
|
+
]
|
|
312
|
+
}
|
|
313
|
+
]
|
|
314
|
+
}
|
|
315
|
+
```
|
|
316
|
+
Ouch... as you can see, just defining 2 motion sensors already looks quite cumbersome and complex. And even more annoying,
|
|
317
|
+
the two configurations are almost identical - the only thing that differs them is the base topic of the device (which makes
|
|
318
|
+
sense, because these are both Hue motion sensors, supporting the same characteristics and controlled by the same system (zigbee2mqtt)).
|
|
319
|
+
|
|
320
|
+
Surely we can do better - We can define a template for a hue motion sensor and have both devices point to it:
|
|
321
|
+
|
|
322
|
+
```json
|
|
323
|
+
{
|
|
324
|
+
"templates": [
|
|
325
|
+
{
|
|
326
|
+
"id": "hue-motion-sensor",
|
|
327
|
+
"type": "motion-sensor",
|
|
328
|
+
"topics": {
|
|
329
|
+
"motionDetected": {
|
|
330
|
+
"get": "{{baseTopic}}$occupancy",
|
|
331
|
+
"converter": "boolean"
|
|
332
|
+
}
|
|
333
|
+
},
|
|
334
|
+
"services": [
|
|
335
|
+
{
|
|
336
|
+
"name": "Battery Level",
|
|
337
|
+
"type": "battery",
|
|
338
|
+
"topics": {
|
|
339
|
+
"batteryLevel": {
|
|
340
|
+
"get": "{{baseTopic}}$battery"
|
|
341
|
+
}
|
|
342
|
+
}
|
|
343
|
+
},
|
|
344
|
+
{
|
|
345
|
+
"name": "Light Sensor",
|
|
346
|
+
"type": "light-sensor",
|
|
347
|
+
"topics": {
|
|
348
|
+
"ambientLevel": {
|
|
349
|
+
"get": "Stairs {{baseTopic}}$illuminance_lux"
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
"name": "Temperature Sensor",
|
|
355
|
+
"type": "temperature-sensor",
|
|
356
|
+
"topics": {
|
|
357
|
+
"currentTemperature": {
|
|
358
|
+
"get": "{{baseTopic}}$temperature"
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
]
|
|
363
|
+
}
|
|
364
|
+
],
|
|
365
|
+
"devices": [
|
|
366
|
+
{
|
|
367
|
+
"id": "garage-motion",
|
|
368
|
+
"name": "Garage Motion",
|
|
369
|
+
"baseTopic": "Garage Motion",
|
|
370
|
+
"template": "hue-motion-sensor"
|
|
371
|
+
},
|
|
372
|
+
{
|
|
373
|
+
"id": "stairs-motion",
|
|
374
|
+
"name": "Stairs Motion",
|
|
375
|
+
"baseTopic": "Stairs Motion",
|
|
376
|
+
"template": "hue-motion-sensor"
|
|
377
|
+
}
|
|
378
|
+
]
|
|
379
|
+
}
|
|
380
|
+
```
|
|
381
|
+
The template above defines the typical structure of a Hue motion sensor device and it uses parameter placeholders to
|
|
382
|
+
make it reusable. Then, when defining the devices, all that is required is to point to the template and provide a value
|
|
383
|
+
to the template parameters (`baseTopic` in this case). Now imagine you have 10 such motion sensors in the house - this
|
|
384
|
+
makes their configuration a breeze. More over, it's great for maintenance - if you need to change how you handle a motion
|
|
385
|
+
sensor, you just need to change the template and all motion sensor devices will automatically be updated.
|
|
386
|
+
|
|
387
|
+
It's also possible to use parameter placeholder in normal device configuration. For example
|
|
388
|
+
|
|
389
|
+
```json
|
|
390
|
+
{
|
|
391
|
+
"devices": [
|
|
392
|
+
{
|
|
393
|
+
"id": "garage-motion",
|
|
394
|
+
"name": "Garage Motion",
|
|
395
|
+
"type": "motion-sensor",
|
|
396
|
+
"topic": "Garage Motion",
|
|
397
|
+
"topics": {
|
|
398
|
+
"motionDetected": {
|
|
399
|
+
"get": "{{topic}}$occupancy",
|
|
400
|
+
"converter": "boolean"
|
|
401
|
+
}
|
|
402
|
+
},
|
|
403
|
+
"services": [
|
|
404
|
+
{
|
|
405
|
+
"name": "Battery Level",
|
|
406
|
+
"type": "battery",
|
|
407
|
+
"topics": {
|
|
408
|
+
"batteryLevel": {
|
|
409
|
+
"get": "{{topic}}$battery"
|
|
410
|
+
}
|
|
411
|
+
}
|
|
412
|
+
},
|
|
413
|
+
{
|
|
414
|
+
"name": "Light Sensor",
|
|
415
|
+
"type": "light-sensor",
|
|
416
|
+
"topics": {
|
|
417
|
+
"ambientLevel": {
|
|
418
|
+
"get": "{{topic}}$illuminance_lux"
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
},
|
|
422
|
+
{
|
|
423
|
+
"name": "Temperature Sensor",
|
|
424
|
+
"type": "temperature-sensor",
|
|
425
|
+
"topics": {
|
|
426
|
+
"currentTemperature": {
|
|
427
|
+
"get": "{{topic}}$temperature"
|
|
428
|
+
}
|
|
429
|
+
}
|
|
430
|
+
}
|
|
431
|
+
]
|
|
432
|
+
}
|
|
433
|
+
]
|
|
434
|
+
}
|
|
435
|
+
```
|
|
436
|
+
In the above example, we only need to define the `topic` of the accessory once in a parameter and
|
|
437
|
+
have all topics reference it. If the topic changes, we only need to change one place. Though again, the use
|
|
438
|
+
of templates has the potential of a greater added value overall.
|
|
439
|
+
|
|
440
|
+
## Converters Reference
|
|
441
|
+
|
|
442
|
+
### Booleans
|
|
443
|
+
- `boolean` - Converts "true" and "false" string values or `true` and `false` JSON values.
|
|
444
|
+
- `one-zero` - Converts "1" and "0" to `true` and `false` (also `1` and `0` numeric JSON values)
|
|
445
|
+
- `{ "on": "<on_value>", "off": "<off_value>" }` - Indicates the values that represent `true` (on) and `false` (off)
|
|
446
|
+
|
|
447
|
+
### Percentages (%)
|
|
448
|
+
- `homekit` - Homekit expects numbers between 0 - 100.
|
|
449
|
+
- `decimal` - Converts numbers between 0 - 1 (`0.34` indicates `34%`)
|
|
450
|
+
- `{ "min": <number>, "max": <number> }` - Translate any number between these bounds to a percentage value. Any number above the max will be converted to `max` and any number below the min will be converted to `min`.
|
|
451
|
+
|
|
452
|
+
### Hue
|
|
453
|
+
- `homekit` - Homekit expects numbers representing arc degrees (0 - 360)
|
|
454
|
+
- `percent-integer` - Converts a percentage value between 0 - 100
|
|
455
|
+
- `percent-decimal` - Converts a percentage value between 0 - 1
|
|
456
|
+
|
|
457
|
+
### Color Temperatures
|
|
458
|
+
- `homekit` - Homekit expects numbers in mirek units ($mirek = \frac{1,000,000}{Kelvin}$)
|
|
459
|
+
- `mirek` - same as `homekit`
|
|
460
|
+
- `kelvin` - Converts numbers in kelvin units
|
|
461
|
+
|
|
462
|
+
### Illuminance
|
|
463
|
+
- `homekit` - Homekit expects numbers in lux units
|
|
464
|
+
- `lux` - same as `homekit`
|
|
465
|
+
- `log-scale-lux` - Expects number in log scale values as used by Hue ($lux =(\frac{logscale-1}{10000})^{10}$)
|
|
466
|
+
|
|
467
|
+
### Temperatures
|
|
468
|
+
- `homekit` - Homekit expects temperature to be in Celsius
|
|
469
|
+
- `celsius` - same as `homekit`
|
|
470
|
+
- `fahrenheit` - Expects temperatures to be in Fahrenheit units
|
|
471
|
+
|
|
472
|
+
|
|
473
|
+
## Characteristics Reference
|
|
474
|
+
- [Common Characteristics](#common-characteristics)
|
|
475
|
+
- [Common Sensor Characteristics](#common-sensor-characteristics)
|
|
476
|
+
- [active](#code-stylecolor-greenactivecode)
|
|
477
|
+
- [airQuality](#code-stylecolor-greenairQualitycode)
|
|
478
|
+
- [ambientLightLevel](#code-stylecolor-greenambientLightLevelcode)
|
|
479
|
+
- [batteryLevel](#code-stylecolor-greenbatteryLevelcode)
|
|
480
|
+
- [brightness](#code-stylecolor-greenbrightnesscode)
|
|
481
|
+
- [co2Detected](#code-stylecolor-greenco2Detectedcode)
|
|
482
|
+
- [co2Level](#code-stylecolor-greenco2Levelcode)
|
|
483
|
+
- [co2PeakLevel](#code-stylecolor-greenco2PeakLevelcode)
|
|
484
|
+
- [coDetected](#code-stylecolor-greencoDetectedcode)
|
|
485
|
+
- [coLevel](#code-stylecolor-greencoLevelcode)
|
|
486
|
+
- [coPeakLevel](#code-stylecolor-greencoPeakLevelcode)
|
|
487
|
+
- [chargingState](#code-stylecolor-greenchargingStatecode)
|
|
488
|
+
- [colorTemperature](#code-stylecolor-greencolorTemperaturecode)
|
|
489
|
+
- [contactSensorState](#code-stylecolor-greencontactSensorStatecode)
|
|
490
|
+
- [coolingThreshold](#code-stylecolor-greencoolingThresholdcode)
|
|
491
|
+
- [currentFanState](#code-stylecolor-greencurrentFanStatecode)
|
|
492
|
+
- [currentHeatingCoolingState](#code-stylecolor-greencurrentHeatingCoolingStatecode)
|
|
493
|
+
- [currentHorizontalTiltAngle](#code-stylecolor-greencurrentHorizontalTiltAnglecode)
|
|
494
|
+
- [currentHumidifierDehumidifierState](#code-stylecolor-greencurrentHumidifierDehumidifierStatecode)
|
|
495
|
+
- [currentPosition](#code-stylecolor-greencurrentPositioncode)
|
|
496
|
+
- [currentRelativeHumidity](#code-stylecolor-greencurrentRelativeHumiditycode)
|
|
497
|
+
- [currentTemperature](#code-stylecolor-greencurrentTemperaturecode)
|
|
498
|
+
- [currentVerticalTiltAngle](#code-stylecolor-greencurrentVerticalTiltAnglecode)
|
|
499
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode)
|
|
500
|
+
- [heatingThreshold](#code-stylecolor-greenheatingThresholdcode)
|
|
501
|
+
- [holdPosition](#code-stylecolor-greenholdPositioncode)
|
|
502
|
+
- [hue](#code-stylecolor-greenhuecode)
|
|
503
|
+
- [leakDetected](#code-stylecolor-greenleakDetectedcode)
|
|
504
|
+
- [lockCurrentState](#code-stylecolor-greenlockCurrentStatecode)
|
|
505
|
+
- [lockPhysicalControls](#code-stylecolor-greenlockPhysicalControlscode)
|
|
506
|
+
- [lockTargetState](#code-stylecolor-greenlockTargetStatecode)
|
|
507
|
+
- [motionDetected](#code-stylecolor-greenmotionDetectedcode)
|
|
508
|
+
- [mute](#code-stylecolor-greenmutecode)
|
|
509
|
+
- [no2Density](#code-stylecolor-greenno2Densitycode)
|
|
510
|
+
- [obstructionDetected](#code-stylecolor-greenobstructionDetectedcode)
|
|
511
|
+
- [occupancyDetected](#code-stylecolor-greenoccupancyDetectedcode)
|
|
512
|
+
- [on](#code-stylecolor-greenoncode)
|
|
513
|
+
- [outletInUse](#code-stylecolor-greenoutletInUsecode)
|
|
514
|
+
- [ozoneDensity](#code-stylecolor-greenozoneDensitycode)
|
|
515
|
+
- [pm10Density](#code-stylecolor-greenpm10Densitycode)
|
|
516
|
+
- [pm25Density](#code-stylecolor-greenpm25Densitycode)
|
|
517
|
+
- [positionState](#code-stylecolor-greenpositionStatecode)
|
|
518
|
+
- [pressEvent](#code-stylecolor-greenpressEventcode)
|
|
519
|
+
- [dehumidifierThreshold](#code-stylecolor-greendehumidifierThresholdcode)
|
|
520
|
+
- [humidifierThreshold](#code-stylecolor-greenhumidifierThresholdcode)
|
|
521
|
+
- [rotationDirection](#code-stylecolor-greenrotationDirectioncode)
|
|
522
|
+
- [rotationSpeed](#code-stylecolor-greenrotationSpeedcode)
|
|
523
|
+
- [saturation](#code-stylecolor-greensaturationcode)
|
|
524
|
+
- [alarmType](#code-stylecolor-greenalarmTypecode)
|
|
525
|
+
- [securitySystemCurrentState](#code-stylecolor-greensecuritySystemCurrentStatecode)
|
|
526
|
+
- [securitySystemTargetState](#code-stylecolor-greensecuritySystemTargetStatecode)
|
|
527
|
+
- [smokeDetected](#code-stylecolor-greensmokeDetectedcode)
|
|
528
|
+
- [so2Density](#code-stylecolor-greenso2Densitycode)
|
|
529
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode)
|
|
530
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode)
|
|
531
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode)
|
|
532
|
+
- [swingMode](#code-stylecolor-greenswingModecode)
|
|
533
|
+
- [targetFanState](#code-stylecolor-greentargetFanStatecode)
|
|
534
|
+
- [targetHeatingCoolingState](#code-stylecolor-greentargetHeatingCoolingStatecode)
|
|
535
|
+
- [targetHorizontalTiltAngle](#code-stylecolor-greentargetHorizontalTiltAnglecode)
|
|
536
|
+
- [targetHumidifierDehumidifierState](#code-stylecolor-greentargetHumidifierDehumidifierStatecode)
|
|
537
|
+
- [targetPosition](#code-stylecolor-greentargetPositioncode)
|
|
538
|
+
- [targetRelativeHumidity](#code-stylecolor-greentargetRelativeHumiditycode)
|
|
539
|
+
- [targetTemperature](#code-stylecolor-greentargetTemperaturecode)
|
|
540
|
+
- [targetVerticalTiltAngle](#code-stylecolor-greentargetVerticalTiltAnglecode)
|
|
541
|
+
- [temperatureDisplayUnits](#code-stylecolor-greentemperatureDisplayUnitscode)
|
|
542
|
+
- [vocDensity](#code-stylecolor-greenvocDensitycode)
|
|
543
|
+
- [volume](#code-stylecolor-greenvolumecode)
|
|
544
|
+
- [waterLevel](#code-stylecolor-greenwaterLevelcode)
|
|
545
|
+
|
|
546
|
+
|
|
547
|
+
### Common Characteristics
|
|
548
|
+
|
|
549
|
+
The following characteristic are optional and may be configured on any service type
|
|
550
|
+
- [statusFault](#statusFault)
|
|
551
|
+
- [faultMessage](#code-stylecolor-greenfaultmessagecode)
|
|
552
|
+
|
|
553
|
+
### Common Sensor Characteristics
|
|
554
|
+
|
|
555
|
+
In addition to the above common characteristics, sensor devices may also support the following ones:
|
|
556
|
+
- [statusLowBattery](#statusLowBatter)
|
|
557
|
+
- [statusTampered](#statusTampered)
|
|
558
|
+
|
|
559
|
+
### <code style="color: green">active</code>
|
|
560
|
+
|
|
561
|
+
Indicates whether the service is currently active. By default, will look for values `0` or `1` where `1` indicates
|
|
562
|
+
`on`/`true` and `0` indicates `off`/`false`.
|
|
563
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
564
|
+
|
|
565
|
+
#### Services
|
|
566
|
+
- [speaker](#speaker)
|
|
567
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
568
|
+
|
|
569
|
+
#### Configuration
|
|
570
|
+
```json
|
|
571
|
+
{
|
|
572
|
+
"topics": {
|
|
573
|
+
"active": {
|
|
574
|
+
"get": "<read_topic>",
|
|
575
|
+
"set": "<write_topic>",
|
|
576
|
+
"converter"?: "boolean" | { "min": <number>, "max": <number> }
|
|
577
|
+
}
|
|
578
|
+
}
|
|
579
|
+
}
|
|
580
|
+
```
|
|
581
|
+
|
|
582
|
+
### <code style="color: green">airQuality</code>
|
|
583
|
+
|
|
584
|
+
Describes the subject assessment of air quality. By default, will look for the following values:
|
|
585
|
+
- `0` - indicates "unknown"
|
|
586
|
+
- `1` - indicates "excellent"
|
|
587
|
+
- `2` - indicates "good"
|
|
588
|
+
- `3` - indicates "fair"
|
|
589
|
+
- `4` - indicates "inferior"
|
|
590
|
+
- `5` - indicates "poor"
|
|
591
|
+
|
|
592
|
+
You can customize the read/published values using a value map converter (as shown below)
|
|
593
|
+
|
|
594
|
+
#### Services
|
|
595
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
596
|
+
|
|
597
|
+
#### Configuration
|
|
598
|
+
```json
|
|
599
|
+
{
|
|
600
|
+
"topics": {
|
|
601
|
+
"airQuality": {
|
|
602
|
+
"get": "<read_topic>",
|
|
603
|
+
"converter"?: {
|
|
604
|
+
"unknown"?: "<value representing 'unknown'>",
|
|
605
|
+
"excellent"?: "<value representing 'excellent'>",
|
|
606
|
+
"good"?: "<value representing 'good'>",
|
|
607
|
+
"fair"?: "<value representing 'fair'>",
|
|
608
|
+
"inferior"?: "<value representing 'inferior'>",
|
|
609
|
+
"poor"?: "<value representing 'poor'>"
|
|
610
|
+
}
|
|
611
|
+
}
|
|
612
|
+
}
|
|
613
|
+
}
|
|
614
|
+
```
|
|
615
|
+
|
|
616
|
+
|
|
617
|
+
### <code style="color: green">ambientLightLevel</code>
|
|
618
|
+
|
|
619
|
+
Indicates the current light level in `lux` numeric units.
|
|
620
|
+
Values can be converted using the [Illuminance](#illuminance) converter.
|
|
621
|
+
|
|
622
|
+
#### Services
|
|
623
|
+
- [light-sensor](#light-sensor)
|
|
624
|
+
|
|
625
|
+
#### Configuration
|
|
626
|
+
```json
|
|
627
|
+
{
|
|
628
|
+
"topics": {
|
|
629
|
+
"ambientLightLevel": {
|
|
630
|
+
"get": "<read_topic>",
|
|
631
|
+
"converter"?: log-scale-lux"
|
|
632
|
+
}
|
|
633
|
+
}
|
|
634
|
+
}
|
|
635
|
+
```
|
|
636
|
+
|
|
637
|
+
|
|
638
|
+
### <code style="color: green">batteryLevel</code>
|
|
639
|
+
|
|
640
|
+
Describes the current level of the battery in a numeric value representing a percentage.
|
|
641
|
+
Values can be converted using the [Percentages](#percentages-) converter.
|
|
642
|
+
|
|
643
|
+
#### Services
|
|
644
|
+
- [battery](#battery)
|
|
645
|
+
|
|
646
|
+
#### Configuration
|
|
647
|
+
```json
|
|
648
|
+
{
|
|
649
|
+
"topics": {
|
|
650
|
+
"batteryLevel": {
|
|
651
|
+
"get": "<read_topic>",
|
|
652
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
653
|
+
}
|
|
654
|
+
}
|
|
655
|
+
}
|
|
656
|
+
```
|
|
657
|
+
|
|
658
|
+
### <code style="color: green">brightness</code>
|
|
659
|
+
|
|
660
|
+
Describes a level of brightness in a numeric value representing a percentage.
|
|
661
|
+
Values can be converted using the [Percentages](#percentages) converter.
|
|
662
|
+
|
|
663
|
+
#### Services
|
|
664
|
+
- [lightbulb](#lightbulb)
|
|
665
|
+
- [doorbell](#doorbell)
|
|
666
|
+
|
|
667
|
+
#### Configuration
|
|
668
|
+
|
|
669
|
+
```json
|
|
670
|
+
{
|
|
671
|
+
"topics": {
|
|
672
|
+
"brightness": {
|
|
673
|
+
"get": "<read_topic>",
|
|
674
|
+
"get": "<write_topic>",
|
|
675
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
676
|
+
}
|
|
677
|
+
}
|
|
678
|
+
}
|
|
679
|
+
```
|
|
680
|
+
|
|
681
|
+
### <code style="color: green">co2Detected</code>
|
|
682
|
+
|
|
683
|
+
Indicates if a sensor detects abnormal levels of Carbon Dioxide. By default, will look for `0` (indicating "not detected")
|
|
684
|
+
or `1` (indicating "detected").
|
|
685
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
686
|
+
|
|
687
|
+
#### Services
|
|
688
|
+
- [co2-sensor](#co2-sensor)
|
|
689
|
+
|
|
690
|
+
#### Configuration
|
|
691
|
+
|
|
692
|
+
```json
|
|
693
|
+
{
|
|
694
|
+
"topics": {
|
|
695
|
+
"co2Detected": {
|
|
696
|
+
"get": "<read_topic>",
|
|
697
|
+
"converter"?: "boolean" | { "on": "'detected' value", "off": "'not-detected' value" }
|
|
698
|
+
}
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
```
|
|
702
|
+
|
|
703
|
+
|
|
704
|
+
### <code style="color: green">co2Level</code>
|
|
705
|
+
|
|
706
|
+
Indicates the detected level of Carbon Dioxide - a numeric value indicating parts per million (ppm).
|
|
707
|
+
|
|
708
|
+
#### Services
|
|
709
|
+
- [co2-sensor](#co2-sensor)
|
|
710
|
+
|
|
711
|
+
#### Configuration
|
|
712
|
+
|
|
713
|
+
```json
|
|
714
|
+
{
|
|
715
|
+
"topics": {
|
|
716
|
+
"co2Level": {
|
|
717
|
+
"get": "<read_topic>"
|
|
718
|
+
}
|
|
719
|
+
}
|
|
720
|
+
}
|
|
721
|
+
```
|
|
722
|
+
|
|
723
|
+
### <code style="color: green">co2PeakLevel</code>
|
|
724
|
+
|
|
725
|
+
Indicates the highest detected level of Carbon Dioxide detected by a sensor - a numeric value indicating parts per
|
|
726
|
+
million (ppm).
|
|
727
|
+
|
|
728
|
+
#### Services
|
|
729
|
+
- [co2-sensor](#co2-sensor)
|
|
730
|
+
|
|
731
|
+
#### Configuration
|
|
732
|
+
|
|
733
|
+
```json
|
|
734
|
+
{
|
|
735
|
+
"topics": {
|
|
736
|
+
"co2PeakLevel": {
|
|
737
|
+
"get": "<read_topic>"
|
|
738
|
+
}
|
|
739
|
+
}
|
|
740
|
+
}
|
|
741
|
+
```
|
|
742
|
+
|
|
743
|
+
|
|
744
|
+
### <code style="color: green">coDetected</code>
|
|
745
|
+
|
|
746
|
+
Indicates if a sensor detects abnormal levels of Carbon Monoxide. By default, will look for `0` (indicating "not detected")
|
|
747
|
+
or `1` (indicating "detected").
|
|
748
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
749
|
+
|
|
750
|
+
#### Services
|
|
751
|
+
- [co-sensor](#co-sensor)
|
|
752
|
+
|
|
753
|
+
#### Configuration
|
|
754
|
+
|
|
755
|
+
```json
|
|
756
|
+
{
|
|
757
|
+
"topics": {
|
|
758
|
+
"coDetected": {
|
|
759
|
+
"get": "<read_topic>",
|
|
760
|
+
"converter"?: "boolean" | { "on": "'detected' value", "off": "'not-detected' value" }
|
|
761
|
+
}
|
|
762
|
+
}
|
|
763
|
+
}
|
|
764
|
+
```
|
|
765
|
+
|
|
766
|
+
### <code style="color: green">coLevel</code>
|
|
767
|
+
|
|
768
|
+
Indicates the detected level of Carbon Monoxide - a numeric value indicating parts per million (ppm).
|
|
769
|
+
|
|
770
|
+
#### Services
|
|
771
|
+
- [co-sensor](#co-sensor)
|
|
772
|
+
|
|
773
|
+
#### Configuration
|
|
774
|
+
|
|
775
|
+
```json
|
|
776
|
+
{
|
|
777
|
+
"topics": {
|
|
778
|
+
"coLevel": {
|
|
779
|
+
"get": "<read_topic>"
|
|
780
|
+
}
|
|
781
|
+
}
|
|
782
|
+
}
|
|
783
|
+
```
|
|
784
|
+
|
|
785
|
+
### <code style="color: green">coPeakLevel</code>
|
|
786
|
+
|
|
787
|
+
Indicates the highest detected level of Carbon Monoxide detected by a sensor - a numeric value indicating parts per
|
|
788
|
+
million (ppm).
|
|
789
|
+
|
|
790
|
+
#### Services
|
|
791
|
+
- [co-sensor](#co-sensor)
|
|
792
|
+
|
|
793
|
+
#### Configuration
|
|
794
|
+
|
|
795
|
+
```json
|
|
796
|
+
{
|
|
797
|
+
"topics": {
|
|
798
|
+
"coPeakLevel": {
|
|
799
|
+
"get": "<read_topic>"
|
|
800
|
+
}
|
|
801
|
+
}
|
|
802
|
+
}
|
|
803
|
+
```
|
|
804
|
+
|
|
805
|
+
### <code style="color: green">chargingState</code>
|
|
806
|
+
|
|
807
|
+
Indicates whether the battery-ran device is currently charging or not.
|
|
808
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
809
|
+
|
|
810
|
+
#### Services
|
|
811
|
+
- [battery](#battery)
|
|
812
|
+
|
|
813
|
+
#### Configuration
|
|
814
|
+
|
|
815
|
+
```json
|
|
816
|
+
{
|
|
817
|
+
"topics": {
|
|
818
|
+
"chargingState": {
|
|
819
|
+
"get": "<read_topic>",
|
|
820
|
+
"converter"?: "boolean" | { "on": "'charging' value", "off": "'not-charging' value" }
|
|
821
|
+
}
|
|
822
|
+
}
|
|
823
|
+
}
|
|
824
|
+
```
|
|
825
|
+
|
|
826
|
+
|
|
827
|
+
### <code style="color: green">colorTemperature</code>
|
|
828
|
+
|
|
829
|
+
Describes color temperature - a numeric value in the mirek scale
|
|
830
|
+
Values can be converted using the [Color Temperatures](#color-temperatures) converter.
|
|
831
|
+
|
|
832
|
+
#### Services
|
|
833
|
+
- [lightbulb](#lightbulb)
|
|
834
|
+
|
|
835
|
+
#### Configuration
|
|
836
|
+
|
|
837
|
+
```json
|
|
838
|
+
{
|
|
839
|
+
"topics": {
|
|
840
|
+
"colorTemperature": {
|
|
841
|
+
"get": "<read_topic>",
|
|
842
|
+
"set": "<read_topic>",
|
|
843
|
+
"converter"?: "kelvin"
|
|
844
|
+
}
|
|
845
|
+
}
|
|
846
|
+
}
|
|
847
|
+
```
|
|
848
|
+
|
|
849
|
+
### <code style="color: green">contactSensorState</code>
|
|
850
|
+
|
|
851
|
+
Describes the state of a contact sensor. By default, will look for `0` (indicating "no contact") and `1` (indicating "contact")
|
|
852
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
853
|
+
|
|
854
|
+
#### Services
|
|
855
|
+
- [contact-sensor](#contact-sensor)
|
|
856
|
+
|
|
857
|
+
#### Configuration
|
|
858
|
+
|
|
859
|
+
```json
|
|
860
|
+
{
|
|
861
|
+
"topics": {
|
|
862
|
+
"contactSensorState": {
|
|
863
|
+
"get": "<read_topic>",
|
|
864
|
+
"converter"?: "boolean" | { "on": "'contact' value", "off": "'no-contact' value" }
|
|
865
|
+
}
|
|
866
|
+
}
|
|
867
|
+
}
|
|
868
|
+
```
|
|
869
|
+
|
|
870
|
+
|
|
871
|
+
### <code style="color: green">coolingThreshold</code>
|
|
872
|
+
|
|
873
|
+
Describes the cooling threshold in Celsius for accessories that support heating and cooling.
|
|
874
|
+
If the thermostat operates in an "auto" mode and the current temperature goes above this
|
|
875
|
+
threshold the thermostat will start cooling.
|
|
876
|
+
Values can be converted using the [Temperatures](#temperatures) converter.
|
|
877
|
+
|
|
878
|
+
#### Services
|
|
879
|
+
- [thermostat](#thermostat)
|
|
880
|
+
|
|
881
|
+
#### Configuration
|
|
882
|
+
|
|
883
|
+
```json
|
|
884
|
+
{
|
|
885
|
+
"topics": {
|
|
886
|
+
"coolingThreshold": {
|
|
887
|
+
"get": "<read_topic>",
|
|
888
|
+
"set": "<read_topic>",
|
|
889
|
+
"converter"?: "fahrenheit"
|
|
890
|
+
}
|
|
891
|
+
}
|
|
892
|
+
}
|
|
893
|
+
```
|
|
894
|
+
|
|
895
|
+
### <code style="color: green">currentFanState</code>
|
|
896
|
+
|
|
897
|
+
> [!NOTE]
|
|
898
|
+
> When used as part of a `fan` service, this can be shorten to `currentState`
|
|
899
|
+
|
|
900
|
+
Describes the current state of the fan. Expects the following numeric values:
|
|
901
|
+
- `0` - indicating "inactive" state
|
|
902
|
+
- `1` - indicating "idle" state
|
|
903
|
+
- `2` - indicating "blowing air" state
|
|
904
|
+
|
|
905
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
906
|
+
|
|
907
|
+
#### Services
|
|
908
|
+
- [fan](#fan)
|
|
909
|
+
|
|
910
|
+
#### Configuration
|
|
911
|
+
|
|
912
|
+
```json
|
|
913
|
+
{
|
|
914
|
+
"topics": {
|
|
915
|
+
"currentFanState": {
|
|
916
|
+
"get": "<read_topic>",
|
|
917
|
+
"converter"?: {
|
|
918
|
+
"inactive"?: "'inactive' state value",
|
|
919
|
+
"idle"?: "'idle' state value",
|
|
920
|
+
"blowingAir"?: "'blowing air' state value"
|
|
921
|
+
}
|
|
922
|
+
}
|
|
923
|
+
}
|
|
924
|
+
}
|
|
925
|
+
```
|
|
926
|
+
|
|
927
|
+
### <code style="color: green">currentHeatingCoolingState</code>
|
|
928
|
+
|
|
929
|
+
> [!NOTE]
|
|
930
|
+
> When used as part of a `thermostat` service, this can be shorten to `currentState`
|
|
931
|
+
|
|
932
|
+
Describes the current mode of a thermostat. Expects the following numeric values:
|
|
933
|
+
- `0` - indicating "off" state
|
|
934
|
+
- `1` - indicating "heat" state
|
|
935
|
+
- `2` - indicating "cool" state
|
|
936
|
+
|
|
937
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
938
|
+
|
|
939
|
+
#### Services
|
|
940
|
+
- [thermostat](#thermostat)
|
|
941
|
+
|
|
942
|
+
#### Configuration
|
|
943
|
+
|
|
944
|
+
```json
|
|
945
|
+
{
|
|
946
|
+
"topics": {
|
|
947
|
+
"currentHeatingCoolingState": {
|
|
948
|
+
"get": "<read_topic>",
|
|
949
|
+
"converter"?: {
|
|
950
|
+
"off"?: "'off' state value",
|
|
951
|
+
"heat"?: "'heat' state value",
|
|
952
|
+
"cool"?: "'cool' state value"
|
|
953
|
+
}
|
|
954
|
+
}
|
|
955
|
+
}
|
|
956
|
+
}
|
|
957
|
+
```
|
|
958
|
+
|
|
959
|
+
### <code style="color: green">currentHorizontalTiltAngle</code>
|
|
960
|
+
|
|
961
|
+
Describes the current angle of the horizontal slats of the device. A numeric value in arc degrees, ranging
|
|
962
|
+
between `-90` - `90`.
|
|
963
|
+
|
|
964
|
+
#### Services
|
|
965
|
+
- [window-covering](#window-convering)
|
|
966
|
+
|
|
967
|
+
#### Configuration
|
|
968
|
+
|
|
969
|
+
```json
|
|
970
|
+
{
|
|
971
|
+
"topics": {
|
|
972
|
+
"currentHorizontalTiltAngle": {
|
|
973
|
+
"get": "<read_topic>"
|
|
974
|
+
}
|
|
975
|
+
}
|
|
976
|
+
}
|
|
977
|
+
```
|
|
978
|
+
|
|
979
|
+
### <code style="color: green">currentHumidifierDehumidifierState</code>
|
|
980
|
+
|
|
981
|
+
> [!NOTE]
|
|
982
|
+
> When used as part of a `humidifier-dehumidifier` service, this can be shorten to `currentState`
|
|
983
|
+
|
|
984
|
+
Describes the current state of a humidifier or/and a dehumidifier. Expecting the following numeric values:
|
|
985
|
+
- `0` - indicating `inactive` state
|
|
986
|
+
- `1` - indicating `idle` state
|
|
987
|
+
- `2` - indicating `humidifying` state
|
|
988
|
+
- `3` - indicating `dehumidifying` state
|
|
989
|
+
|
|
990
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
991
|
+
|
|
992
|
+
#### Services
|
|
993
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
994
|
+
|
|
995
|
+
#### Configuration
|
|
996
|
+
|
|
997
|
+
```json
|
|
998
|
+
{
|
|
999
|
+
"topics": {
|
|
1000
|
+
"currentHumidifierDehumidifierState": {
|
|
1001
|
+
"get": "<read_topic>",
|
|
1002
|
+
"converter"?: {
|
|
1003
|
+
"inactive"?: "'inactive' state value",
|
|
1004
|
+
"idle"?: "'idle' state value",
|
|
1005
|
+
"humidifying"?: "'humidifying' state value",
|
|
1006
|
+
"dehumidifying"?: "'dehumidifying' state value"
|
|
1007
|
+
}
|
|
1008
|
+
}
|
|
1009
|
+
}
|
|
1010
|
+
}
|
|
1011
|
+
```
|
|
1012
|
+
|
|
1013
|
+
|
|
1014
|
+
### <code style="color: green">currentPosition</code>
|
|
1015
|
+
|
|
1016
|
+
Describes the current position of accessories as a percentage value. `0` typically indicates "fully closed" while `100`
|
|
1017
|
+
indicates "fully open". Some services (e.g. `window-covering` let you reverse this).
|
|
1018
|
+
Other values can be converted using the [Percentages](#percentages-) converter.
|
|
1019
|
+
|
|
1020
|
+
#### Services
|
|
1021
|
+
- [window](#window)
|
|
1022
|
+
- [door](#door)
|
|
1023
|
+
- [window-covering](#window-covering)
|
|
1024
|
+
|
|
1025
|
+
#### Configuration
|
|
1026
|
+
|
|
1027
|
+
```json
|
|
1028
|
+
{
|
|
1029
|
+
"topics": {
|
|
1030
|
+
"currentPosition": {
|
|
1031
|
+
"get": "<read_topic>",
|
|
1032
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
1033
|
+
}
|
|
1034
|
+
}
|
|
1035
|
+
}
|
|
1036
|
+
```
|
|
1037
|
+
|
|
1038
|
+
|
|
1039
|
+
### <code style="color: green">currentRelativeHumidity</code>
|
|
1040
|
+
|
|
1041
|
+
Describes the current relative humidity of the device's environment. By default, expecting a numeric value
|
|
1042
|
+
between `0` and `100` representing a percentage.
|
|
1043
|
+
Other values can be converted using the [Percentages](#percentages-) converter.
|
|
1044
|
+
|
|
1045
|
+
#### Services
|
|
1046
|
+
- [humidity-sensor](#humidity-sensor)
|
|
1047
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
1048
|
+
|
|
1049
|
+
#### Configuration
|
|
1050
|
+
|
|
1051
|
+
```json
|
|
1052
|
+
{
|
|
1053
|
+
"topics": {
|
|
1054
|
+
"currentRelativeHumidity": {
|
|
1055
|
+
"get": "<read_topic>",
|
|
1056
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
1057
|
+
}
|
|
1058
|
+
}
|
|
1059
|
+
}
|
|
1060
|
+
```
|
|
1061
|
+
|
|
1062
|
+
|
|
1063
|
+
### <code style="color: green">currentTemperature</code>
|
|
1064
|
+
|
|
1065
|
+
Describes the current temperature of the environment in Celsius
|
|
1066
|
+
Other values can be converted using the [Temperatures](#temperatures) converter.
|
|
1067
|
+
|
|
1068
|
+
By default, values range between `10.0` and `38.0` with a minimum step of `0.1`. This can be adjusted in
|
|
1069
|
+
the configuration (as shown below).
|
|
1070
|
+
|
|
1071
|
+
#### Services
|
|
1072
|
+
- [thermostat](#thermostat)
|
|
1073
|
+
- [temperature-sensor](#temperature-sensor)
|
|
1074
|
+
|
|
1075
|
+
#### Configuration
|
|
1076
|
+
|
|
1077
|
+
```json
|
|
1078
|
+
{
|
|
1079
|
+
"topics": {
|
|
1080
|
+
"currentTemperature": {
|
|
1081
|
+
"get": "<read_topic>",
|
|
1082
|
+
"converter"?: "fahrenheit",
|
|
1083
|
+
"minValue"?: <number>, // in celsius (regardless of the converter), defaut: 10.0
|
|
1084
|
+
"maxValue"?: <number>, // in celsius (regardless of the converter), defaut: 38.0
|
|
1085
|
+
"minStep"?: <number> // in celsius (regardless of the converter), defaut: 0.1
|
|
1086
|
+
}
|
|
1087
|
+
}
|
|
1088
|
+
}
|
|
1089
|
+
```
|
|
1090
|
+
|
|
1091
|
+
### <code style="color: green">currentVerticalTiltAngle</code>
|
|
1092
|
+
|
|
1093
|
+
Describes the current angle of the vertical slats of the device. Expecting a numeric value representing arc degrees
|
|
1094
|
+
between `-90` and `90`.
|
|
1095
|
+
|
|
1096
|
+
#### Services
|
|
1097
|
+
- [window-covering](#window-convering)
|
|
1098
|
+
|
|
1099
|
+
#### Configuration
|
|
1100
|
+
|
|
1101
|
+
```json
|
|
1102
|
+
{
|
|
1103
|
+
"topics": {
|
|
1104
|
+
"currentVerticalTiltAngle": {
|
|
1105
|
+
"get": "<read_topic>"
|
|
1106
|
+
}
|
|
1107
|
+
}
|
|
1108
|
+
}
|
|
1109
|
+
```
|
|
1110
|
+
|
|
1111
|
+
### <code style="color: green">faultMessage</code>
|
|
1112
|
+
|
|
1113
|
+
A non-standard homekit characteristic indicating a fault message in case the device if faulty.
|
|
1114
|
+
|
|
1115
|
+
> [!NOTE]
|
|
1116
|
+
> As a non-standard characteristic, this will no show up in the Home app, though other apps that support this
|
|
1117
|
+
> custom characteristic will show it (e.g. [Eve](https://www.evehome.com/en/eve-app))
|
|
1118
|
+
|
|
1119
|
+
#### Services
|
|
1120
|
+
|
|
1121
|
+
This characteristic is optional and can be configured on all service types.
|
|
1122
|
+
|
|
1123
|
+
#### Configuration
|
|
1124
|
+
|
|
1125
|
+
```json
|
|
1126
|
+
{
|
|
1127
|
+
"topics": {
|
|
1128
|
+
"faultMessage": {
|
|
1129
|
+
"get": "<read_topic>"
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
}
|
|
1133
|
+
```
|
|
1134
|
+
|
|
1135
|
+
### <code style="color: green">heatingThreshold</code>
|
|
1136
|
+
|
|
1137
|
+
Describes the heating threshold in Celsius for accessories that support heating and cooling.
|
|
1138
|
+
If the thermostat operates in an "auto" mode and the current temperature goes below this
|
|
1139
|
+
threshold the thermostat will start heating.
|
|
1140
|
+
Values can be converted using the [Temperatures](#temperatures) converter.
|
|
1141
|
+
|
|
1142
|
+
#### Services
|
|
1143
|
+
- [thermostat](#thermostat)
|
|
1144
|
+
|
|
1145
|
+
#### Configuration
|
|
1146
|
+
|
|
1147
|
+
```json
|
|
1148
|
+
{
|
|
1149
|
+
"topics": {
|
|
1150
|
+
"heatingThreshold": {
|
|
1151
|
+
"get": "<read_topic>",
|
|
1152
|
+
"set": "<read_topic>",
|
|
1153
|
+
"converter"?: "fahrenheit"
|
|
1154
|
+
}
|
|
1155
|
+
}
|
|
1156
|
+
}
|
|
1157
|
+
```
|
|
1158
|
+
|
|
1159
|
+
|
|
1160
|
+
### <code style="color: green">holdPosition</code>
|
|
1161
|
+
|
|
1162
|
+
Used to signal a device that it should stop it current operations in its current position (typically used for
|
|
1163
|
+
window-covering). This characteristic doesn't hold a value. To signal a "hold" it sets a value in the configured
|
|
1164
|
+
`set` topic. By default, it sets the value to `1`, though this can be changed in the configuration (as shown below).
|
|
1165
|
+
|
|
1166
|
+
#### Services
|
|
1167
|
+
- [window-covering](#window-covering)
|
|
1168
|
+
|
|
1169
|
+
#### Configuration
|
|
1170
|
+
|
|
1171
|
+
```json
|
|
1172
|
+
{
|
|
1173
|
+
"topics": {
|
|
1174
|
+
"holdPosition": {
|
|
1175
|
+
"set": "<write_topic>",
|
|
1176
|
+
"value"?: "any value that the device will understand as a 'hold' command"
|
|
1177
|
+
}
|
|
1178
|
+
}
|
|
1179
|
+
}
|
|
1180
|
+
```
|
|
1181
|
+
|
|
1182
|
+
### <code style="color: green">hue</code>
|
|
1183
|
+
|
|
1184
|
+
Describes hue or color. A hue is typically measured as an arc degree in a [Hue Wheel](). Expects, a numeric value
|
|
1185
|
+
between `0` and `360`.
|
|
1186
|
+
Percentage values (e.g. 34% of 360) are also supported and be configured using the [Hue Converter](#hue)
|
|
1187
|
+
|
|
1188
|
+
#### Services
|
|
1189
|
+
- [lightbulb](#lightbulb)
|
|
1190
|
+
|
|
1191
|
+
#### Configuration
|
|
1192
|
+
|
|
1193
|
+
```json
|
|
1194
|
+
{
|
|
1195
|
+
"topics": {
|
|
1196
|
+
"hue": {
|
|
1197
|
+
"get": "<read_topic>",
|
|
1198
|
+
"set": "<write_topic>",
|
|
1199
|
+
"converter"?: "percent-integer" | "percent-decimal"
|
|
1200
|
+
}
|
|
1201
|
+
}
|
|
1202
|
+
}
|
|
1203
|
+
```
|
|
1204
|
+
|
|
1205
|
+
### <code style="color: green">leakDetected</code>
|
|
1206
|
+
|
|
1207
|
+
Indicates if a sensor detected a leak (e.g. water leak, gas leak). By default, will look for `0` (indicating "not detected")
|
|
1208
|
+
or `1` (indicating "detected").
|
|
1209
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1210
|
+
|
|
1211
|
+
#### Services
|
|
1212
|
+
- [leak-sensor](#leak-sensor)
|
|
1213
|
+
|
|
1214
|
+
#### Configuration
|
|
1215
|
+
|
|
1216
|
+
```json
|
|
1217
|
+
{
|
|
1218
|
+
"topics": {
|
|
1219
|
+
"leakDetected": {
|
|
1220
|
+
"get": "<read_topic>",
|
|
1221
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
1222
|
+
}
|
|
1223
|
+
}
|
|
1224
|
+
}
|
|
1225
|
+
```
|
|
1226
|
+
|
|
1227
|
+
|
|
1228
|
+
### <code style="color: green">lockCurrentState</code>
|
|
1229
|
+
|
|
1230
|
+
> [!NOTE]
|
|
1231
|
+
> When used as part of a `lock` service, this can be shorten to `currentState`
|
|
1232
|
+
|
|
1233
|
+
Describes the current state of a lock. Expecting the following numeric values:
|
|
1234
|
+
- `0` - indicating "unsecured" state
|
|
1235
|
+
- `1` - indicating "secured" state
|
|
1236
|
+
- `2` - indicating "jammed" state
|
|
1237
|
+
- `3` - indicating "unknown" state
|
|
1238
|
+
|
|
1239
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
1240
|
+
|
|
1241
|
+
#### Services
|
|
1242
|
+
- [lock](#lock)
|
|
1243
|
+
- [garage-door](#garage-door)
|
|
1244
|
+
|
|
1245
|
+
#### Configuration
|
|
1246
|
+
|
|
1247
|
+
```json
|
|
1248
|
+
{
|
|
1249
|
+
"topics": {
|
|
1250
|
+
"lockCurrentState": {
|
|
1251
|
+
"get": "<read_topic>",
|
|
1252
|
+
"converter"?: {
|
|
1253
|
+
"unsecured"?: "'unsecured' state value",
|
|
1254
|
+
"secured"?: "'secured' state value",
|
|
1255
|
+
"jammed"?: "'jammed' state value",
|
|
1256
|
+
"unknown"?: "'unknown' state value"
|
|
1257
|
+
}
|
|
1258
|
+
}
|
|
1259
|
+
}
|
|
1260
|
+
}
|
|
1261
|
+
```
|
|
1262
|
+
|
|
1263
|
+
|
|
1264
|
+
### <code style="color: green">lockPhysicalControls</code>
|
|
1265
|
+
|
|
1266
|
+
Describes a way to lock a set of physical controls on an accessory (eg. child lock). By default, will look for `0`
|
|
1267
|
+
(indicating "not detected") or `1` (indicating "detected").
|
|
1268
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1269
|
+
|
|
1270
|
+
#### Services
|
|
1271
|
+
- [fan](#fan)
|
|
1272
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
1273
|
+
|
|
1274
|
+
#### Configuration
|
|
1275
|
+
|
|
1276
|
+
```json
|
|
1277
|
+
{
|
|
1278
|
+
"topics": {
|
|
1279
|
+
"lockPhysicalControls": {
|
|
1280
|
+
"get": "<read_topic>",
|
|
1281
|
+
"set": "<write_topic>",
|
|
1282
|
+
"converter"?: "boolean" | { "": "<value indicating 'locked'>", "off": "value indicating 'not-locked'" }
|
|
1283
|
+
}
|
|
1284
|
+
}
|
|
1285
|
+
}
|
|
1286
|
+
```
|
|
1287
|
+
|
|
1288
|
+
### <code style="color: green">lockTargetState</code>
|
|
1289
|
+
|
|
1290
|
+
> [!NOTE]
|
|
1291
|
+
> When used as part of a [`lock-mechansim`](#lock) service, this can be shorten to `targetState`
|
|
1292
|
+
|
|
1293
|
+
Describes the current state of a lock. Expecting the following numeric values:
|
|
1294
|
+
- `0` - indicating "unsecured" state
|
|
1295
|
+
- `1` - indicating "secured" state
|
|
1296
|
+
|
|
1297
|
+
Other values can be converted using a converter (as shown below).
|
|
1298
|
+
|
|
1299
|
+
#### Services
|
|
1300
|
+
- [lock](#lock)
|
|
1301
|
+
- [garage-door](#garage-door)
|
|
1302
|
+
|
|
1303
|
+
#### Configuration
|
|
1304
|
+
|
|
1305
|
+
```json
|
|
1306
|
+
{
|
|
1307
|
+
"topics": {
|
|
1308
|
+
"lockTargetState": {
|
|
1309
|
+
"get": "<read_topic>",
|
|
1310
|
+
"get": "<write_topic>",
|
|
1311
|
+
"converter"?: "boolean" | { "secured": "<value indicating 'secured'>", "unsecured": "value indicating 'unsecured'" } // a boolean 'true' indicates 'secured'
|
|
1312
|
+
}
|
|
1313
|
+
}
|
|
1314
|
+
}
|
|
1315
|
+
```
|
|
1316
|
+
|
|
1317
|
+
### <code style="color: green">motionDetected</code>
|
|
1318
|
+
|
|
1319
|
+
Indicates if a sensor detected motion. By default, will look for `true` (indicating "detected")
|
|
1320
|
+
or `false` (indicating "not-detected").
|
|
1321
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1322
|
+
|
|
1323
|
+
#### Services
|
|
1324
|
+
- [motion-sensor](#motion-sensor)
|
|
1325
|
+
|
|
1326
|
+
#### Configuration
|
|
1327
|
+
|
|
1328
|
+
```json
|
|
1329
|
+
{
|
|
1330
|
+
"topics": {
|
|
1331
|
+
"motionDetected": {
|
|
1332
|
+
"get": "<read_topic>",
|
|
1333
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
1334
|
+
}
|
|
1335
|
+
}
|
|
1336
|
+
}
|
|
1337
|
+
```
|
|
1338
|
+
|
|
1339
|
+
### <code style="color: green">mute</code>
|
|
1340
|
+
|
|
1341
|
+
Allows the control of audio input or output accessory. By default, will look for `true` (indicating "muted")
|
|
1342
|
+
or `false` (indicating "not-muted").
|
|
1343
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1344
|
+
|
|
1345
|
+
#### Services
|
|
1346
|
+
- [speaker](#speaker)
|
|
1347
|
+
- [doorbell](#doorbell)
|
|
1348
|
+
|
|
1349
|
+
#### Configuration
|
|
1350
|
+
|
|
1351
|
+
```json
|
|
1352
|
+
{
|
|
1353
|
+
"topics": {
|
|
1354
|
+
"motionDetected": {
|
|
1355
|
+
"get": "<read_topic>",
|
|
1356
|
+
"set": "<write_topic>",
|
|
1357
|
+
"converter"?: "boolean" | { "on": "<value indicating 'muted'>", "off": "value indicating 'not-muted'" }
|
|
1358
|
+
}
|
|
1359
|
+
}
|
|
1360
|
+
}
|
|
1361
|
+
```
|
|
1362
|
+
|
|
1363
|
+
### <code style="color: green">no2Density</code>
|
|
1364
|
+
|
|
1365
|
+
Indicates the current Nitrogen Dioxide density. A numeric value in $micrograms/m^3$ units.
|
|
1366
|
+
|
|
1367
|
+
#### Services
|
|
1368
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
1369
|
+
|
|
1370
|
+
#### Configuration
|
|
1371
|
+
|
|
1372
|
+
```json
|
|
1373
|
+
{
|
|
1374
|
+
"topics": {
|
|
1375
|
+
"no2Density": {
|
|
1376
|
+
"get": "<read_topic>"
|
|
1377
|
+
}
|
|
1378
|
+
}
|
|
1379
|
+
}
|
|
1380
|
+
```
|
|
1381
|
+
|
|
1382
|
+
|
|
1383
|
+
### <code style="color: green">obstructionDetected</code>
|
|
1384
|
+
|
|
1385
|
+
Describes the current state of an obstruction sensor. By default, will look for `true` (indicating "detected")
|
|
1386
|
+
or `false` (indicating "not detected").
|
|
1387
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1388
|
+
|
|
1389
|
+
#### Services
|
|
1390
|
+
- [door](#door)
|
|
1391
|
+
- [window](#window)
|
|
1392
|
+
- [garage-door](#garage-door)
|
|
1393
|
+
- [window-covering](#window-covering)
|
|
1394
|
+
|
|
1395
|
+
#### Configuration
|
|
1396
|
+
|
|
1397
|
+
```json
|
|
1398
|
+
{
|
|
1399
|
+
"topics": {
|
|
1400
|
+
"obstructionDetected": {
|
|
1401
|
+
"get": "<read_topic>",
|
|
1402
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
1403
|
+
}
|
|
1404
|
+
}
|
|
1405
|
+
}
|
|
1406
|
+
```
|
|
1407
|
+
|
|
1408
|
+
|
|
1409
|
+
### <code style="color: green">occupancyDetected</code>
|
|
1410
|
+
|
|
1411
|
+
Indicates if occupancy was detected (e.g. a person present). By default, will look for `1` (indicating "detected")
|
|
1412
|
+
or `0` (indicating "not detected").
|
|
1413
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1414
|
+
|
|
1415
|
+
#### Services
|
|
1416
|
+
- [occupancy-sensor](#occupancy-sensor)
|
|
1417
|
+
|
|
1418
|
+
#### Configuration
|
|
1419
|
+
|
|
1420
|
+
```json
|
|
1421
|
+
{
|
|
1422
|
+
"topics": {
|
|
1423
|
+
"occupancyDetected": {
|
|
1424
|
+
"get": "<read_topic>",
|
|
1425
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
1426
|
+
}
|
|
1427
|
+
}
|
|
1428
|
+
}
|
|
1429
|
+
```
|
|
1430
|
+
|
|
1431
|
+
|
|
1432
|
+
### <code style="color: green">on</code>
|
|
1433
|
+
|
|
1434
|
+
Represents the states for “on” and “off”. By default, will look for `true` (indicating "on")
|
|
1435
|
+
or `false` (indicating "off").
|
|
1436
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1437
|
+
|
|
1438
|
+
#### Services
|
|
1439
|
+
- [lightbulb](#lightbulb)
|
|
1440
|
+
- [outlet](#outlet)
|
|
1441
|
+
- [switch](#switch)
|
|
1442
|
+
|
|
1443
|
+
#### Configuration
|
|
1444
|
+
|
|
1445
|
+
```json
|
|
1446
|
+
{
|
|
1447
|
+
"topics": {
|
|
1448
|
+
"on": {
|
|
1449
|
+
"get": "<read_topic>",
|
|
1450
|
+
"set": "<write_topic>",
|
|
1451
|
+
"converter"?: "boolean" | { "on": "<value indicating 'on'>", "off": "value indicating 'off'" }
|
|
1452
|
+
}
|
|
1453
|
+
}
|
|
1454
|
+
}
|
|
1455
|
+
```
|
|
1456
|
+
|
|
1457
|
+
|
|
1458
|
+
|
|
1459
|
+
### <code style="color: green">outletInUse</code>
|
|
1460
|
+
|
|
1461
|
+
describes if the power outlet has an appliance physically plugged in. By default, will look for `true` (indicating "in-use")
|
|
1462
|
+
or `false` (indicating "not-in-use").
|
|
1463
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1464
|
+
|
|
1465
|
+
#### Services
|
|
1466
|
+
- [outlet](#outlet)
|
|
1467
|
+
|
|
1468
|
+
#### Configuration
|
|
1469
|
+
|
|
1470
|
+
```json
|
|
1471
|
+
{
|
|
1472
|
+
"topics": {
|
|
1473
|
+
"outletInUse": {
|
|
1474
|
+
"get": "<read_topic>",
|
|
1475
|
+
"converter"?: "boolean" | { "on": "<value indicating 'in-use'>", "off": "value indicating 'not-in-use'" }
|
|
1476
|
+
}
|
|
1477
|
+
}
|
|
1478
|
+
}
|
|
1479
|
+
```
|
|
1480
|
+
|
|
1481
|
+
### <code style="color: green">ozoneDensity</code>
|
|
1482
|
+
|
|
1483
|
+
Indicates the current ozone density. A numeric value in $micrograms/m^3$ units.
|
|
1484
|
+
|
|
1485
|
+
#### Services
|
|
1486
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
1487
|
+
|
|
1488
|
+
#### Configuration
|
|
1489
|
+
|
|
1490
|
+
```json
|
|
1491
|
+
{
|
|
1492
|
+
"topics": {
|
|
1493
|
+
"ozoneDensity": {
|
|
1494
|
+
"get": "<read_topic>"
|
|
1495
|
+
}
|
|
1496
|
+
}
|
|
1497
|
+
}
|
|
1498
|
+
```
|
|
1499
|
+
|
|
1500
|
+
|
|
1501
|
+
### <code style="color: green">pm10Density</code>
|
|
1502
|
+
|
|
1503
|
+
Indicates the current PM10 micrometer particulate density. A numeric value in $micrograms/m^3$ units.
|
|
1504
|
+
|
|
1505
|
+
#### Services
|
|
1506
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
1507
|
+
|
|
1508
|
+
#### Configuration
|
|
1509
|
+
|
|
1510
|
+
```json
|
|
1511
|
+
{
|
|
1512
|
+
"topics": {
|
|
1513
|
+
"pm10Density": {
|
|
1514
|
+
"get": "<read_topic>"
|
|
1515
|
+
}
|
|
1516
|
+
}
|
|
1517
|
+
}
|
|
1518
|
+
```
|
|
1519
|
+
|
|
1520
|
+
### <code style="color: green">pm25Density</code>
|
|
1521
|
+
|
|
1522
|
+
Indicates the current PM2.5 micrometer particulate density. A numeric value in $micrograms/m^3$ units.
|
|
1523
|
+
|
|
1524
|
+
#### Services
|
|
1525
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
1526
|
+
|
|
1527
|
+
#### Configuration
|
|
1528
|
+
|
|
1529
|
+
```json
|
|
1530
|
+
{
|
|
1531
|
+
"topics": {
|
|
1532
|
+
"pm25Density": {
|
|
1533
|
+
"get": "<read_topic>"
|
|
1534
|
+
}
|
|
1535
|
+
}
|
|
1536
|
+
}
|
|
1537
|
+
```
|
|
1538
|
+
|
|
1539
|
+
### <code style="color: green">positionState</code>
|
|
1540
|
+
|
|
1541
|
+
Describes the state of the position of accessories. Expecting the following numeric values:
|
|
1542
|
+
- `0` - indicating "closing" state
|
|
1543
|
+
- `1` - indicating "opening" state
|
|
1544
|
+
- `2` - indicating "stopped" state
|
|
1545
|
+
|
|
1546
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
1547
|
+
|
|
1548
|
+
#### Services
|
|
1549
|
+
- [door](#door)
|
|
1550
|
+
- [window](#window)
|
|
1551
|
+
- [window-covering](#window-covering)
|
|
1552
|
+
|
|
1553
|
+
#### Configuration
|
|
1554
|
+
|
|
1555
|
+
```json
|
|
1556
|
+
{
|
|
1557
|
+
"topics": {
|
|
1558
|
+
"lockCurrentState": {
|
|
1559
|
+
"get": "<read_topic>",
|
|
1560
|
+
"converter"?: {
|
|
1561
|
+
"closing"?: "'closing' state value",
|
|
1562
|
+
"opening"?: "'opening' state value",
|
|
1563
|
+
"stopped"?: "'stopped' state value"
|
|
1564
|
+
}
|
|
1565
|
+
}
|
|
1566
|
+
}
|
|
1567
|
+
}
|
|
1568
|
+
```
|
|
1569
|
+
|
|
1570
|
+
|
|
1571
|
+
### <code style="color: green">pressEvent</code>
|
|
1572
|
+
|
|
1573
|
+
Describes a press event generated by a button. This characteristic doesn't hold a value nor publishes a
|
|
1574
|
+
value to an MQTT topic. All it does is monitor an MQTT topic and based on the value received it triggers
|
|
1575
|
+
the appropriate event. By default, it expects the following numeric values:
|
|
1576
|
+
- `0` - indicating "single-press" event
|
|
1577
|
+
- `1` - indicating "double-press" event
|
|
1578
|
+
- `2` - indicating "long-press" event
|
|
1579
|
+
|
|
1580
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
1581
|
+
|
|
1582
|
+
#### Services
|
|
1583
|
+
- [button](#button)
|
|
1584
|
+
- [doorbell](#doorbell)
|
|
1585
|
+
|
|
1586
|
+
#### Configuration
|
|
1587
|
+
|
|
1588
|
+
```json
|
|
1589
|
+
{
|
|
1590
|
+
"topics": {
|
|
1591
|
+
"pressEvent": {
|
|
1592
|
+
"get": "<read_topic>",
|
|
1593
|
+
"converter"?: {
|
|
1594
|
+
"single"?: "value indicating a 'single' press event",
|
|
1595
|
+
"double"?: "value indicating a 'double' press event",
|
|
1596
|
+
"long"?: "value indicating a 'long' press event"
|
|
1597
|
+
}
|
|
1598
|
+
}
|
|
1599
|
+
}
|
|
1600
|
+
}
|
|
1601
|
+
```
|
|
1602
|
+
|
|
1603
|
+
### <code style="color: green">dehumidifierThreshold</code>
|
|
1604
|
+
|
|
1605
|
+
Describes the relative humidity dehumidifier threshold, representing the maximum relative humidity that must be reached
|
|
1606
|
+
before a dehumidifier is turned on. Expects a numeric value indicating the humidity in percentage between
|
|
1607
|
+
`0` and `100`.
|
|
1608
|
+
|
|
1609
|
+
Other values can be converted using a [Percentages](#percentages-) converter (as shown below).
|
|
1610
|
+
|
|
1611
|
+
#### Services
|
|
1612
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
1613
|
+
|
|
1614
|
+
#### Configuration
|
|
1615
|
+
|
|
1616
|
+
```json
|
|
1617
|
+
{
|
|
1618
|
+
"topics": {
|
|
1619
|
+
"dehumidifierThreshold": {
|
|
1620
|
+
"get": "<read_topic>",
|
|
1621
|
+
"set": "<write_topic>",
|
|
1622
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
1623
|
+
}
|
|
1624
|
+
}
|
|
1625
|
+
}
|
|
1626
|
+
```
|
|
1627
|
+
|
|
1628
|
+
### <code style="color: green">humidifierThreshold</code>
|
|
1629
|
+
|
|
1630
|
+
Describes the relative humidity humidifier threshold, representing the minimum relative humidity that must be reached
|
|
1631
|
+
before a humidifier is turned on. Expects a numeric value indicating the humidity in percentage between
|
|
1632
|
+
`0` and `100`.
|
|
1633
|
+
|
|
1634
|
+
Other values can be converted using a [Percentages](#percentages-) converter (as shown below).
|
|
1635
|
+
|
|
1636
|
+
#### Services
|
|
1637
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
1638
|
+
|
|
1639
|
+
#### Configuration
|
|
1640
|
+
|
|
1641
|
+
```json
|
|
1642
|
+
{
|
|
1643
|
+
"topics": {
|
|
1644
|
+
"humidifierThreshold": {
|
|
1645
|
+
"get": "<read_topic>",
|
|
1646
|
+
"set": "<write_topic>",
|
|
1647
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
1648
|
+
}
|
|
1649
|
+
}
|
|
1650
|
+
}
|
|
1651
|
+
```
|
|
1652
|
+
|
|
1653
|
+
|
|
1654
|
+
### <code style="color: green">rotationDirection</code>
|
|
1655
|
+
|
|
1656
|
+
describes the direction of rotation of a fan. Expects the following numeric values:
|
|
1657
|
+
- `0` - indicates `clockwise` direction
|
|
1658
|
+
- `1` - indicates `counter-clockwise` direction
|
|
1659
|
+
|
|
1660
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
1661
|
+
|
|
1662
|
+
#### Services
|
|
1663
|
+
- [fan](#fan)
|
|
1664
|
+
|
|
1665
|
+
#### Configuration
|
|
1666
|
+
|
|
1667
|
+
```json
|
|
1668
|
+
{
|
|
1669
|
+
"topics": {
|
|
1670
|
+
"rotationDirection": {
|
|
1671
|
+
"get": "<read_topic>",
|
|
1672
|
+
"set": "<write_topic>",
|
|
1673
|
+
"converter"?: { "clockwise": "value representing 'clockwise'", "counter-clockwise": "value representing 'counter-clockwise'" }
|
|
1674
|
+
}
|
|
1675
|
+
}
|
|
1676
|
+
}
|
|
1677
|
+
```
|
|
1678
|
+
|
|
1679
|
+
|
|
1680
|
+
### <code style="color: green">rotationSpeed</code>
|
|
1681
|
+
|
|
1682
|
+
Describes the rotation speed of a fan. A numeric value representing the speed as a percentage between
|
|
1683
|
+
`0` and `100`, where `0` indicates no speed and `100` indicates maximum speed.
|
|
1684
|
+
|
|
1685
|
+
Other values are supported using the following converters:
|
|
1686
|
+
- `decimal` - expects a values representing the speed as a percentage value between `0` and `1` (e.g. `0.36` indicates `36%`)
|
|
1687
|
+
- `{ "min": <number>, "max": <number> }` - expects a value between the `min` and `max` value, from which it deduce the speed percentage.
|
|
1688
|
+
- `<number>` - A converter holding a number indicates the number of supported speed levels, expecting a number between `0` and the configured number.
|
|
1689
|
+
For example, `converter: 5` indicates there are 6 speed levels to look for - `0`, `1`, `2`, `3`, `4`, `5`.
|
|
1690
|
+
- `string[]` - A converter holding an array of values, each representing a level. The speed level of each value is the index
|
|
1691
|
+
of that value in the array - the first value will always represent "no speed". For example, `converter: [ "off", "low", "medium", "high" ]` will expect all to
|
|
1692
|
+
receive any of these values. If, for example, it receives a `low` value, then it knows this value represents
|
|
1693
|
+
`33%` speed level, as it's the first out of 3 possible speed levels (excl. the first one which is "no-speed").
|
|
1694
|
+
|
|
1695
|
+
#### Services
|
|
1696
|
+
- [fan](#fan)
|
|
1697
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
1698
|
+
|
|
1699
|
+
#### Configuration
|
|
1700
|
+
|
|
1701
|
+
```json
|
|
1702
|
+
{
|
|
1703
|
+
"topics": {
|
|
1704
|
+
"rotationDirection": {
|
|
1705
|
+
"get": "<read_topic>",
|
|
1706
|
+
"set": "<write_topic>",
|
|
1707
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> } | <number> | string[]
|
|
1708
|
+
}
|
|
1709
|
+
}
|
|
1710
|
+
}
|
|
1711
|
+
```
|
|
1712
|
+
|
|
1713
|
+
|
|
1714
|
+
### <code style="color: green">saturation</code>
|
|
1715
|
+
|
|
1716
|
+
Describes color saturation. A numeric value indicating a percentage.
|
|
1717
|
+
|
|
1718
|
+
Values can be converted using the [Percentages](#percentages-) converter.
|
|
1719
|
+
|
|
1720
|
+
#### Services
|
|
1721
|
+
- [lightbulb](#lightbulb)
|
|
1722
|
+
|
|
1723
|
+
#### Configuration
|
|
1724
|
+
|
|
1725
|
+
```json
|
|
1726
|
+
{
|
|
1727
|
+
"topics": {
|
|
1728
|
+
"saturation": {
|
|
1729
|
+
"get": "<read_topic>",
|
|
1730
|
+
"set": "<write_topic>",
|
|
1731
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
1732
|
+
}
|
|
1733
|
+
}
|
|
1734
|
+
}
|
|
1735
|
+
```
|
|
1736
|
+
|
|
1737
|
+
### <code style="color: green">alarmType</code>
|
|
1738
|
+
|
|
1739
|
+
describes the type of alarm triggered by a security system. The only alarm type that is currently supported
|
|
1740
|
+
by homekit is an "unknown" type. For this reason, by default, these are the values it expects:
|
|
1741
|
+
- `0` - indicating the alarm is cleared
|
|
1742
|
+
- any other value - indicating the generic "unknown" type.
|
|
1743
|
+
|
|
1744
|
+
It is possible to configure a different values to indicate the `cleared` state (as shown below)
|
|
1745
|
+
|
|
1746
|
+
#### Services
|
|
1747
|
+
- [security-system](#security-system)
|
|
1748
|
+
|
|
1749
|
+
#### Configuration
|
|
1750
|
+
|
|
1751
|
+
```json
|
|
1752
|
+
{
|
|
1753
|
+
"topics": {
|
|
1754
|
+
"alarmType": {
|
|
1755
|
+
"get": "<read_topic>",
|
|
1756
|
+
"converter"?: { "cleared": "value representing a 'cleared` state"}
|
|
1757
|
+
}
|
|
1758
|
+
}
|
|
1759
|
+
}
|
|
1760
|
+
```
|
|
1761
|
+
|
|
1762
|
+
|
|
1763
|
+
### <code style="color: green">securitySystemCurrentState</code>
|
|
1764
|
+
|
|
1765
|
+
> [!NOTE]
|
|
1766
|
+
> When used as part of a `security-system` service, this can be shorten to `currentState`
|
|
1767
|
+
|
|
1768
|
+
Describes the state of a security system. Expecting the following numeric values:
|
|
1769
|
+
- `0` - "stay" state
|
|
1770
|
+
- `1` - "away" state
|
|
1771
|
+
- `2` - "night" state
|
|
1772
|
+
- `3` - "disarmed" state
|
|
1773
|
+
- `4` - "triggered" state
|
|
1774
|
+
|
|
1775
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
1776
|
+
|
|
1777
|
+
#### Services
|
|
1778
|
+
- [security-system](#security-system)
|
|
1779
|
+
|
|
1780
|
+
#### Configuration
|
|
1781
|
+
|
|
1782
|
+
```json
|
|
1783
|
+
{
|
|
1784
|
+
"topics": {
|
|
1785
|
+
"securitySystemCurrentState": {
|
|
1786
|
+
"get": "<read_topic>",
|
|
1787
|
+
"converter"?: {
|
|
1788
|
+
"stay"?: "'stay' state value",
|
|
1789
|
+
"away"?: "'away' state value",
|
|
1790
|
+
"night"?: "'night' state value",
|
|
1791
|
+
"disarmed"?: "'disarmed' state value",
|
|
1792
|
+
"triggered"?: "'triggered' state value",
|
|
1793
|
+
}
|
|
1794
|
+
}
|
|
1795
|
+
}
|
|
1796
|
+
}
|
|
1797
|
+
```
|
|
1798
|
+
|
|
1799
|
+
### <code style="color: green">securitySystemTargetState</code>
|
|
1800
|
+
|
|
1801
|
+
> [!NOTE]
|
|
1802
|
+
> When used as part of a `security-system` service, this can be shorten to `targetState`
|
|
1803
|
+
|
|
1804
|
+
Describes the target state of the security system. Expecting the following numeric values:
|
|
1805
|
+
- `0` - "stay" state
|
|
1806
|
+
- `1` - "away" state
|
|
1807
|
+
- `2` - "night" state
|
|
1808
|
+
- `3` - "disarm" state
|
|
1809
|
+
|
|
1810
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
1811
|
+
|
|
1812
|
+
It is also possible to limit the supported values using the `validValues` settings.
|
|
1813
|
+
|
|
1814
|
+
#### Services
|
|
1815
|
+
- [security-system](#security-system)
|
|
1816
|
+
|
|
1817
|
+
#### Configuration
|
|
1818
|
+
|
|
1819
|
+
```json
|
|
1820
|
+
{
|
|
1821
|
+
"topics": {
|
|
1822
|
+
"securitySystemTargetState": {
|
|
1823
|
+
"get": "<read_topic>",
|
|
1824
|
+
"set": "<write_topic>",
|
|
1825
|
+
"converter"?: {
|
|
1826
|
+
"stay"?: "'stay' state value",
|
|
1827
|
+
"away"?: "'away' state value",
|
|
1828
|
+
"night"?: "'night' state value",
|
|
1829
|
+
"disarm"?: "'disarm' state value",
|
|
1830
|
+
},
|
|
1831
|
+
"validValues"?: string[] // e.g. [ "stay", "away", "disarm" ] to not show the 'night' option.
|
|
1832
|
+
}
|
|
1833
|
+
}
|
|
1834
|
+
}
|
|
1835
|
+
```
|
|
1836
|
+
|
|
1837
|
+
### <code style="color: green">smokeDetected</code>
|
|
1838
|
+
|
|
1839
|
+
Indicates if a sensor detects abnormal levels of smoke. By default, will look for `0` (indicating "not detected")
|
|
1840
|
+
or `1` (indicating "detected").
|
|
1841
|
+
Values can be converted using the [Booleans](#booleans) converter.
|
|
1842
|
+
|
|
1843
|
+
#### Services
|
|
1844
|
+
- [smoke-sensor](#smoke-sensor)
|
|
1845
|
+
|
|
1846
|
+
#### Configuration
|
|
1847
|
+
|
|
1848
|
+
```json
|
|
1849
|
+
{
|
|
1850
|
+
"topics": {
|
|
1851
|
+
"smokeDetected": {
|
|
1852
|
+
"get": "<read_topic>",
|
|
1853
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
1854
|
+
}
|
|
1855
|
+
}
|
|
1856
|
+
}
|
|
1857
|
+
```
|
|
1858
|
+
|
|
1859
|
+
|
|
1860
|
+
### <code style="color: green">so2Density</code>
|
|
1861
|
+
|
|
1862
|
+
Indicates the current Sulphur Dioxide density. A numeric value in $micrograms/m^3$ units.
|
|
1863
|
+
|
|
1864
|
+
#### Services
|
|
1865
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
1866
|
+
|
|
1867
|
+
#### Configuration
|
|
1868
|
+
|
|
1869
|
+
```json
|
|
1870
|
+
{
|
|
1871
|
+
"topics": {
|
|
1872
|
+
"so2Density": {
|
|
1873
|
+
"get": "<read_topic>"
|
|
1874
|
+
}
|
|
1875
|
+
}
|
|
1876
|
+
}
|
|
1877
|
+
```
|
|
1878
|
+
|
|
1879
|
+
|
|
1880
|
+
### <code style="color: green">statusFault</code>
|
|
1881
|
+
|
|
1882
|
+
Indicates the device is faulty. Expecting a `1` indicating a "general fault" and `0` indicating there's no fault.
|
|
1883
|
+
Other values can be converted using the [Booleans](#booleans) converter.
|
|
1884
|
+
|
|
1885
|
+
#### Services
|
|
1886
|
+
This characteristic is optional on all services.
|
|
1887
|
+
|
|
1888
|
+
#### Configuration
|
|
1889
|
+
|
|
1890
|
+
```json
|
|
1891
|
+
{
|
|
1892
|
+
"topics": {
|
|
1893
|
+
"statusFault": {
|
|
1894
|
+
"get": "<read_topic>",
|
|
1895
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
1896
|
+
}
|
|
1897
|
+
}
|
|
1898
|
+
}
|
|
1899
|
+
```
|
|
1900
|
+
|
|
1901
|
+
|
|
1902
|
+
### <code style="color: green">statusLowBattery</code>
|
|
1903
|
+
|
|
1904
|
+
Describes an accessory which has been tampered with. By default, will look for `0` indicating battery
|
|
1905
|
+
level is not low, and `1` indicating "low-battery" status.
|
|
1906
|
+
Other values can be converted using the [Booleans](#booleans) converter.
|
|
1907
|
+
|
|
1908
|
+
#### Services
|
|
1909
|
+
This characteristic is optional on all sensor services.
|
|
1910
|
+
|
|
1911
|
+
#### Configuration
|
|
1912
|
+
|
|
1913
|
+
```json
|
|
1914
|
+
{
|
|
1915
|
+
"topics": {
|
|
1916
|
+
"statusLowBattery": {
|
|
1917
|
+
"get": "<read_topic>",
|
|
1918
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
1919
|
+
}
|
|
1920
|
+
}
|
|
1921
|
+
}
|
|
1922
|
+
```
|
|
1923
|
+
|
|
1924
|
+
|
|
1925
|
+
### <code style="color: green">statusTampered</code>
|
|
1926
|
+
|
|
1927
|
+
Indicates if a battery-ran device is running low on battery. By default, will look for `0` indicating battery
|
|
1928
|
+
level is not low, and `1` indicating "low-battery" status.
|
|
1929
|
+
Other values can be converted using the [Booleans](#booleans) converter.
|
|
1930
|
+
|
|
1931
|
+
#### Services
|
|
1932
|
+
This characteristic is optional on all sensor services.
|
|
1933
|
+
|
|
1934
|
+
#### Configuration
|
|
1935
|
+
|
|
1936
|
+
```json
|
|
1937
|
+
{
|
|
1938
|
+
"topics": {
|
|
1939
|
+
"statusTampered": {
|
|
1940
|
+
"get": "<read_topic>",
|
|
1941
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
1942
|
+
}
|
|
1943
|
+
}
|
|
1944
|
+
}
|
|
1945
|
+
```
|
|
1946
|
+
|
|
1947
|
+
|
|
1948
|
+
### <code style="color: green">swingMode</code>
|
|
1949
|
+
|
|
1950
|
+
Indicates if swing mode is enabled. By default, will look for `0` indicating swing "disabled" mode, and `1`
|
|
1951
|
+
indicating swing "enabled" mode.
|
|
1952
|
+
Other values can be converted using the [Booleans](#booleans) converter.
|
|
1953
|
+
|
|
1954
|
+
#### Services
|
|
1955
|
+
- [fan](#fan)
|
|
1956
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
1957
|
+
|
|
1958
|
+
#### Configuration
|
|
1959
|
+
|
|
1960
|
+
```json
|
|
1961
|
+
{
|
|
1962
|
+
"topics": {
|
|
1963
|
+
"swingMode": {
|
|
1964
|
+
"get": "<read_topic>",
|
|
1965
|
+
"set": "<write_topic>",
|
|
1966
|
+
"converter"?: "boolean" | { "on": "'enabled' mode value", "off": "'disabled' mode value"}
|
|
1967
|
+
}
|
|
1968
|
+
}
|
|
1969
|
+
}
|
|
1970
|
+
```
|
|
1971
|
+
|
|
1972
|
+
|
|
1973
|
+
### <code style="color: green">targetFanState</code>
|
|
1974
|
+
|
|
1975
|
+
> [!NOTE]
|
|
1976
|
+
> When used as part of a `fan` service, this can be shorten to `targetState`
|
|
1977
|
+
|
|
1978
|
+
Describes the target state of the fan. Expecting the following numeric values:
|
|
1979
|
+
- `0` - indicates a "manual" state
|
|
1980
|
+
- `1` - indicates an "auto" state
|
|
1981
|
+
|
|
1982
|
+
Other values can be converted using the value-map converter (as show below).
|
|
1983
|
+
|
|
1984
|
+
#### Services
|
|
1985
|
+
- [fan](#fan)
|
|
1986
|
+
|
|
1987
|
+
#### Configuration
|
|
1988
|
+
|
|
1989
|
+
```json
|
|
1990
|
+
{
|
|
1991
|
+
"topics": {
|
|
1992
|
+
"targetFanState": {
|
|
1993
|
+
"get": "<read_topic>",
|
|
1994
|
+
"set": "<write_topic>",
|
|
1995
|
+
"converter"?: { "auto": "'auto' state value", "manual": "'manual' state value"}
|
|
1996
|
+
}
|
|
1997
|
+
}
|
|
1998
|
+
}
|
|
1999
|
+
```
|
|
2000
|
+
|
|
2001
|
+
### <code style="color: green">targetHeatingCoolingState</code>
|
|
2002
|
+
|
|
2003
|
+
> [!NOTE]
|
|
2004
|
+
> When used as part of a `thermostat` service, this can be shorten to `targetState`
|
|
2005
|
+
|
|
2006
|
+
Describes the target mode of a thermostat. Expects the following numeric values:
|
|
2007
|
+
- `0` - indicating "off" state
|
|
2008
|
+
- `1` - indicating "heat" state
|
|
2009
|
+
- `2` - indicating "cool" state
|
|
2010
|
+
- `3` - indicating "auto" state
|
|
2011
|
+
|
|
2012
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
2013
|
+
|
|
2014
|
+
It is also possible to limit the possible values using the `validValues` setting.
|
|
2015
|
+
|
|
2016
|
+
#### Services
|
|
2017
|
+
- [thermostat](#thermostat)
|
|
2018
|
+
|
|
2019
|
+
#### Configuration
|
|
2020
|
+
|
|
2021
|
+
```json
|
|
2022
|
+
{
|
|
2023
|
+
"topics": {
|
|
2024
|
+
"targetHeatingCoolingState": {
|
|
2025
|
+
"get": "<read_topic>",
|
|
2026
|
+
"set": "<write_topic>",
|
|
2027
|
+
"converter"?: {
|
|
2028
|
+
"off"?: "'off' state value",
|
|
2029
|
+
"heat"?: "'heat' state value",
|
|
2030
|
+
"cool"?: "'cool' state value",
|
|
2031
|
+
"auto"?: "'auto' state value",
|
|
2032
|
+
},
|
|
2033
|
+
"validValues": string[] // e.g. [ "off", "auto" ] to only provide the user to stop the operation of the device
|
|
2034
|
+
}
|
|
2035
|
+
}
|
|
2036
|
+
}
|
|
2037
|
+
```
|
|
2038
|
+
|
|
2039
|
+
### <code style="color: green">targetHorizontalTiltAngle</code>
|
|
2040
|
+
|
|
2041
|
+
Describes the target angle of the horizontal slats of the device. A numeric value in arc degrees, ranging
|
|
2042
|
+
between `-90` - `90`.
|
|
2043
|
+
|
|
2044
|
+
#### Services
|
|
2045
|
+
- [window-covering](#window-convering)
|
|
2046
|
+
|
|
2047
|
+
#### Configuration
|
|
2048
|
+
|
|
2049
|
+
```json
|
|
2050
|
+
{
|
|
2051
|
+
"topics": {
|
|
2052
|
+
"targetHorizontalTiltAngle": {
|
|
2053
|
+
"get": "<read_topic>",
|
|
2054
|
+
"set": "<write_topic>"
|
|
2055
|
+
}
|
|
2056
|
+
}
|
|
2057
|
+
}
|
|
2058
|
+
```
|
|
2059
|
+
|
|
2060
|
+
### <code style="color: green">targetHumidifierDehumidifierState</code>
|
|
2061
|
+
|
|
2062
|
+
> [!NOTE]
|
|
2063
|
+
> When used as part of a `humidifier-dehumidifier` service, this can be shorten to `targetState`
|
|
2064
|
+
|
|
2065
|
+
Describes the target state of a humidifier or/and a dehumidifier. Expecting the following numeric values:
|
|
2066
|
+
- `0` - indicating `humidifierDehumidifier` state - only applicable to devices that are both humidifiers and dehumidifiers,
|
|
2067
|
+
this indicates that the device should always keep the humidity at bay, by both humidifying when humidity is low and
|
|
2068
|
+
dehumidifying when humidity is high (both low and high humidity levels are determined by the
|
|
2069
|
+
[humidifierThreshold](#code-stylecolor-greenhumidifierthresholdcode) and
|
|
2070
|
+
[dehumidifierThreshold](#code-stylecolor-greendehumidifierthresholdcode) characteristics.
|
|
2071
|
+
|
|
2072
|
+
- `1` - indicating `humidifier` state - only applicable to devices that are humidifiers. Indicating that the device should
|
|
2073
|
+
humidify if the humidity level is too low (reaches the [humidifierThreshold](#code-stylecolor-greenhumidifierthresholdcode)).
|
|
2074
|
+
|
|
2075
|
+
- `2` - indicating `dehumidifier` state - only applicable to devices that are dehumidifiers. Indicating that the device should
|
|
2076
|
+
dehumidify if the humidity level is too hight (reaches the [dehumidifierThreshold](#code-stylecolor-greendehumidifierthresholdcode)).
|
|
2077
|
+
|
|
2078
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
2079
|
+
|
|
2080
|
+
#### Services
|
|
2081
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
2082
|
+
|
|
2083
|
+
#### Configuration
|
|
2084
|
+
|
|
2085
|
+
```json
|
|
2086
|
+
{
|
|
2087
|
+
"topics": {
|
|
2088
|
+
"targetHumidifierDehumidifierState": {
|
|
2089
|
+
"get": "<read_topic>",
|
|
2090
|
+
"set": "<write_topic>",
|
|
2091
|
+
"converter"?: {
|
|
2092
|
+
"humidifierDehumidifier"?: "'humidifierDehumidifier' state value",
|
|
2093
|
+
"humidifier"?: "'humidifier' state value",
|
|
2094
|
+
"dehumidifier"?: "'dehumidifier' state value"
|
|
2095
|
+
}
|
|
2096
|
+
}
|
|
2097
|
+
}
|
|
2098
|
+
}
|
|
2099
|
+
```
|
|
2100
|
+
|
|
2101
|
+
### <code style="color: green">targetPosition</code>
|
|
2102
|
+
|
|
2103
|
+
Describes the target position of accessories as a percentage value. `0` typically indicates "fully closed" while `100`
|
|
2104
|
+
indicates "fully open". Some services (e.g. `window-covering` let you reverse this).
|
|
2105
|
+
Other values can be converted using the [Percentages](#percentages-) converter.
|
|
2106
|
+
|
|
2107
|
+
#### Services
|
|
2108
|
+
- [window](#window)
|
|
2109
|
+
- [door](#door)
|
|
2110
|
+
- [window-covering](#window-covering)
|
|
2111
|
+
|
|
2112
|
+
#### Configuration
|
|
2113
|
+
|
|
2114
|
+
```json
|
|
2115
|
+
{
|
|
2116
|
+
"topics": {
|
|
2117
|
+
"targetPosition": {
|
|
2118
|
+
"get": "<read_topic>",
|
|
2119
|
+
"set": "<write_topic>",
|
|
2120
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2121
|
+
}
|
|
2122
|
+
}
|
|
2123
|
+
}
|
|
2124
|
+
```
|
|
2125
|
+
|
|
2126
|
+
### <code style="color: green">targetRelativeHumidity</code>
|
|
2127
|
+
|
|
2128
|
+
Describes the target relative humidity that the device should actively attempt to reach. By default, expecting a numeric
|
|
2129
|
+
value between `0` and `100` representing a percentage.
|
|
2130
|
+
Other values can be converted using the [Percentages](#percentages-) converter.
|
|
2131
|
+
|
|
2132
|
+
#### Services
|
|
2133
|
+
- [thermostat](#thermostat)
|
|
2134
|
+
|
|
2135
|
+
#### Configuration
|
|
2136
|
+
|
|
2137
|
+
```json
|
|
2138
|
+
{
|
|
2139
|
+
"topics": {
|
|
2140
|
+
"targetRelativeHumidity": {
|
|
2141
|
+
"get": "<read_topic>",
|
|
2142
|
+
"set": "<write_topic>",
|
|
2143
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2144
|
+
}
|
|
2145
|
+
}
|
|
2146
|
+
}
|
|
2147
|
+
```
|
|
2148
|
+
|
|
2149
|
+
### <code style="color: green">targetTemperature</code>
|
|
2150
|
+
|
|
2151
|
+
Describes the target temperature of the environment in Celsius.
|
|
2152
|
+
Other values can be converted using the [Temperatures](#temperatures) converter.
|
|
2153
|
+
|
|
2154
|
+
By default, values range between `10.0` and `38.0` with a minimum step of `0.1`. This can be adjusted in
|
|
2155
|
+
the configuration (as shown below).
|
|
2156
|
+
|
|
2157
|
+
#### Services
|
|
2158
|
+
- [thermostat](#thermostat)
|
|
2159
|
+
- [temperature-sensor](#temperature-sensor)
|
|
2160
|
+
|
|
2161
|
+
#### Configuration
|
|
2162
|
+
|
|
2163
|
+
```json
|
|
2164
|
+
{
|
|
2165
|
+
"topics": {
|
|
2166
|
+
"currentTemperature": {
|
|
2167
|
+
"get": "<read_topic>",
|
|
2168
|
+
"set": "<write_topic>",
|
|
2169
|
+
"converter"?: "fahrenheit",
|
|
2170
|
+
"minValue"?: <number>, // in celsius (regardless of the converter), defaut: 10.0
|
|
2171
|
+
"maxValue"?: <number>, // in celsius (regardless of the converter), defaut: 38.0
|
|
2172
|
+
"minStep"?: <number> // in celsius (regardless of the converter), defaut: 0.1
|
|
2173
|
+
}
|
|
2174
|
+
}
|
|
2175
|
+
}
|
|
2176
|
+
```
|
|
2177
|
+
|
|
2178
|
+
### <code style="color: green">targetVerticalTiltAngle</code>
|
|
2179
|
+
|
|
2180
|
+
Describes the target angle of the vertical slats of the device. Expecting a numeric value representing arc degrees
|
|
2181
|
+
between `-90` and `90`.
|
|
2182
|
+
|
|
2183
|
+
#### Services
|
|
2184
|
+
- [window-covering](#window-convering)
|
|
2185
|
+
|
|
2186
|
+
#### Configuration
|
|
2187
|
+
|
|
2188
|
+
```json
|
|
2189
|
+
{
|
|
2190
|
+
"topics": {
|
|
2191
|
+
"targetVerticalTiltAngle": {
|
|
2192
|
+
"get": "<read_topic>",
|
|
2193
|
+
"set": "<write_topic>"
|
|
2194
|
+
}
|
|
2195
|
+
}
|
|
2196
|
+
}
|
|
2197
|
+
```
|
|
2198
|
+
|
|
2199
|
+
### <code style="color: green">temperatureDisplayUnits</code>
|
|
2200
|
+
|
|
2201
|
+
Describes units of temperature used for presentation purposes. Expecting the following numeric values:
|
|
2202
|
+
- `0` - indicating `celsius`
|
|
2203
|
+
- `1` - indicating `fahrentheit`
|
|
2204
|
+
|
|
2205
|
+
Other values can be converted using a value-map converter (as shown below).
|
|
2206
|
+
|
|
2207
|
+
#### Services
|
|
2208
|
+
- [thermostat](#thermostat)
|
|
2209
|
+
|
|
2210
|
+
#### Configuration
|
|
2211
|
+
|
|
2212
|
+
```json
|
|
2213
|
+
{
|
|
2214
|
+
"topics": {
|
|
2215
|
+
"temperatureDisplayUnits": {
|
|
2216
|
+
"get": "<read_topic>",
|
|
2217
|
+
"set": "<write_topic>",
|
|
2218
|
+
"converter"?: { "celsius": "value indicating 'celsius'", "fahrenheit": "value indicating 'fahrenheit'" }
|
|
2219
|
+
}
|
|
2220
|
+
}
|
|
2221
|
+
}
|
|
2222
|
+
```
|
|
2223
|
+
|
|
2224
|
+
### <code style="color: green">vocDensity</code>
|
|
2225
|
+
|
|
2226
|
+
Indicates the current volatile organic compound density. A numeric value in $micrograms/m^3$ units.
|
|
2227
|
+
|
|
2228
|
+
#### Services
|
|
2229
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
2230
|
+
|
|
2231
|
+
#### Configuration
|
|
2232
|
+
|
|
2233
|
+
```json
|
|
2234
|
+
{
|
|
2235
|
+
"topics": {
|
|
2236
|
+
"vocDensity": {
|
|
2237
|
+
"get": "<read_topic>"
|
|
2238
|
+
}
|
|
2239
|
+
}
|
|
2240
|
+
}
|
|
2241
|
+
```
|
|
2242
|
+
|
|
2243
|
+
|
|
2244
|
+
### <code style="color: green">volume</code>
|
|
2245
|
+
|
|
2246
|
+
Enables controlling the input or output volume of an audio device. By default, expecting a numeric value
|
|
2247
|
+
between `0` and `100` representing a percentage.
|
|
2248
|
+
Other values can be converted using the [Percentages](#percentages-) converter.
|
|
2249
|
+
|
|
2250
|
+
#### Services
|
|
2251
|
+
- [speaker](#speaker)
|
|
2252
|
+
- [doorbell](#doorbell)
|
|
2253
|
+
|
|
2254
|
+
#### Configuration
|
|
2255
|
+
|
|
2256
|
+
```json
|
|
2257
|
+
{
|
|
2258
|
+
"topics": {
|
|
2259
|
+
"volume": {
|
|
2260
|
+
"get": "<read_topic>",
|
|
2261
|
+
"set": "<write_topic>",
|
|
2262
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2263
|
+
}
|
|
2264
|
+
}
|
|
2265
|
+
}
|
|
2266
|
+
```
|
|
2267
|
+
|
|
2268
|
+
### <code style="color: green">waterLevel</code>
|
|
2269
|
+
|
|
2270
|
+
Indicating the current water level of the device. By default, expecting a numeric value between `0` and `100`
|
|
2271
|
+
representing a percentage.
|
|
2272
|
+
Other values can be converted using the [Percentages](#percentages-) converter.
|
|
2273
|
+
|
|
2274
|
+
#### Services
|
|
2275
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
2276
|
+
|
|
2277
|
+
#### Configuration
|
|
2278
|
+
|
|
2279
|
+
```json
|
|
2280
|
+
{
|
|
2281
|
+
"topics": {
|
|
2282
|
+
"waterLevel": {
|
|
2283
|
+
"get": "<read_topic>",
|
|
2284
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2285
|
+
}
|
|
2286
|
+
}
|
|
2287
|
+
}
|
|
2288
|
+
```
|
|
2289
|
+
|
|
2290
|
+
## Services Reference
|
|
2291
|
+
- [air-quality-sensor](#air-quality-sensor)
|
|
2292
|
+
- [battery](#battery)
|
|
2293
|
+
- [button](#button)
|
|
2294
|
+
- [co2-sensor](#co2-sensor)
|
|
2295
|
+
- [contact-sensor](#contact-sensor)
|
|
2296
|
+
- [co-sensor](#co-sensor)
|
|
2297
|
+
- [door](#door)
|
|
2298
|
+
- [doorbell](#doorbell)
|
|
2299
|
+
- [fan](#fan)
|
|
2300
|
+
- [humidifier-dehumidifier](#humidifier-dehumidifier)
|
|
2301
|
+
- [humidity-sensor](#humidity-sensor)
|
|
2302
|
+
- [leak-sensor](#leak-sensor)
|
|
2303
|
+
- [lightbulb](#lightbulb)
|
|
2304
|
+
- [light-sensor](#light-sensor)
|
|
2305
|
+
- [lock](#lock)
|
|
2306
|
+
- [microphone](#microphone)
|
|
2307
|
+
- [motion-sensor](#motion-sensor)
|
|
2308
|
+
- [occupancy-sensor](#occupancy-sensor)
|
|
2309
|
+
- [outlet](#outlet)
|
|
2310
|
+
- [security-system](#security-system)
|
|
2311
|
+
- [smoke-sensor](#smoke-sensor)
|
|
2312
|
+
- [speaker](#speaker)
|
|
2313
|
+
- [switch](#switch)
|
|
2314
|
+
- [temperature-sensor](#temperature-sensor)
|
|
2315
|
+
- [thermostat](#thermostat)
|
|
2316
|
+
- [window](#window)
|
|
2317
|
+
- [window-covering](#window-covering)
|
|
2318
|
+
|
|
2319
|
+
|
|
2320
|
+
### air-quality-sensor
|
|
2321
|
+
|
|
2322
|
+
Characteristics:
|
|
2323
|
+
- [airQuality](#code-stylecolor-greenairqualitycode) (required)
|
|
2324
|
+
- [airQuality](#code-stylecolor-greenairqualitycode) (optional)
|
|
2325
|
+
- [ozoneDensity](#code-stylecolor-greenozonedensitycode) (optional)
|
|
2326
|
+
- [no2Density](#code-stylecolor-greenno2densitycode) (optional)
|
|
2327
|
+
- [so2Density](#code-stylecolor-greenso2Densitycode) (optional)
|
|
2328
|
+
- [pm25Density](#code-stylecolor-greenpm25Densitycode) (optional)
|
|
2329
|
+
- [pm10Density](#code-stylecolor-greenpm10Densitycode) (optional)
|
|
2330
|
+
- [vocDensity](#code-stylecolor-greenvocDensitycode) (optional)
|
|
2331
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2332
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2333
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
2334
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
2335
|
+
|
|
2336
|
+
```json
|
|
2337
|
+
{
|
|
2338
|
+
"name": "<custom name>",
|
|
2339
|
+
"type": "air-quality-sensor",
|
|
2340
|
+
"topics": {
|
|
2341
|
+
"airQuality": { //required
|
|
2342
|
+
"get": "<topic>",
|
|
2343
|
+
"converter"?: { "unknown": string, "excellent": stirng, "good": string, "fair": string, "inferior": stirng, "port": string }
|
|
2344
|
+
},
|
|
2345
|
+
"ozoneDensity"?: { // optional
|
|
2346
|
+
"get": "<topic>"
|
|
2347
|
+
},
|
|
2348
|
+
"no2Density"?: { // optional
|
|
2349
|
+
"get": "<topic>"
|
|
2350
|
+
},
|
|
2351
|
+
"so2Density"?: { // optional
|
|
2352
|
+
"get": "<topic>"
|
|
2353
|
+
},
|
|
2354
|
+
"pm25Density"?: { // optional
|
|
2355
|
+
"get": "<topic>"
|
|
2356
|
+
},
|
|
2357
|
+
"pm10Density"?: { // optional
|
|
2358
|
+
"get": "<topic>"
|
|
2359
|
+
},
|
|
2360
|
+
"vocDensity"?: { // optional
|
|
2361
|
+
"get": "<topic>"
|
|
2362
|
+
},
|
|
2363
|
+
"statusFault"?: { // optional
|
|
2364
|
+
"get": "<read_topic>",
|
|
2365
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2366
|
+
},
|
|
2367
|
+
"faultMessage"?: { // optional
|
|
2368
|
+
"get": "<topic>"
|
|
2369
|
+
},
|
|
2370
|
+
"statusLowBattery"?: { // optional
|
|
2371
|
+
"get": "<read_topic>",
|
|
2372
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
2373
|
+
},
|
|
2374
|
+
"statusTampered"?: { // optional
|
|
2375
|
+
"get": "<read_topic>",
|
|
2376
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
2377
|
+
}
|
|
2378
|
+
}
|
|
2379
|
+
}
|
|
2380
|
+
```
|
|
2381
|
+
|
|
2382
|
+
### battery
|
|
2383
|
+
|
|
2384
|
+
Characteristics:
|
|
2385
|
+
- [batteryLevel](#code-stylecolor-greenbatteryLevelcode) (required)
|
|
2386
|
+
- [chargingState](#code-stylecolor-greenchargingStatecode) (optional)
|
|
2387
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2388
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2389
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
2390
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
2391
|
+
|
|
2392
|
+
```json
|
|
2393
|
+
{
|
|
2394
|
+
"name": "<custom name>",
|
|
2395
|
+
"type": "battery",
|
|
2396
|
+
"topics": {
|
|
2397
|
+
"batteryLevel": { //required
|
|
2398
|
+
"get": "<topic>",
|
|
2399
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2400
|
+
},
|
|
2401
|
+
"chargingState"?: { // optional
|
|
2402
|
+
"get": "<read_topic>",
|
|
2403
|
+
"converter"?: "boolean" | { "on": "'charging' value", "off": "'not-charging' value" }
|
|
2404
|
+
},
|
|
2405
|
+
"statusFault"?: { // optional
|
|
2406
|
+
"get": "<read_topic>",
|
|
2407
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2408
|
+
},
|
|
2409
|
+
"faultMessage"?: { // optional
|
|
2410
|
+
"get": "<topic>"
|
|
2411
|
+
},
|
|
2412
|
+
"statusLowBattery"?: { // optional
|
|
2413
|
+
"get": "<read_topic>",
|
|
2414
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
2415
|
+
},
|
|
2416
|
+
"statusTampered"?: { // optional
|
|
2417
|
+
"get": "<read_topic>",
|
|
2418
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
2419
|
+
}
|
|
2420
|
+
}
|
|
2421
|
+
}
|
|
2422
|
+
```
|
|
2423
|
+
|
|
2424
|
+
### button
|
|
2425
|
+
|
|
2426
|
+
Characteristics:
|
|
2427
|
+
- [pressEvent](#code-stylecolor-greenpressEventcode) (required)
|
|
2428
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2429
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2430
|
+
|
|
2431
|
+
```json
|
|
2432
|
+
{
|
|
2433
|
+
"name": "<custom name>",
|
|
2434
|
+
"type": "button",
|
|
2435
|
+
"topics": {
|
|
2436
|
+
"pressEvent": { //required
|
|
2437
|
+
"get": "<read_topic>",
|
|
2438
|
+
"converter"?: {
|
|
2439
|
+
"single"?: "value indicating a 'single' press event",
|
|
2440
|
+
"double"?: "value indicating a 'double' press event",
|
|
2441
|
+
"long"?: "value indicating a 'long' press event"
|
|
2442
|
+
}
|
|
2443
|
+
},
|
|
2444
|
+
"statusFault"?: { // optional
|
|
2445
|
+
"get": "<read_topic>",
|
|
2446
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2447
|
+
},
|
|
2448
|
+
"faultMessage"?: { // optional
|
|
2449
|
+
"get": "<topic>"
|
|
2450
|
+
}
|
|
2451
|
+
}
|
|
2452
|
+
}
|
|
2453
|
+
```
|
|
2454
|
+
|
|
2455
|
+
### co2-sensor
|
|
2456
|
+
|
|
2457
|
+
Characteristics:
|
|
2458
|
+
- [co2Detected](#code-stylecolor-greenco2Detectedcode) (required)
|
|
2459
|
+
- [co2Level](#code-stylecolor-greenco2Levelcode) (optional)
|
|
2460
|
+
- [co2PeakLevel](#code-stylecolor-greenco2PeakLevelcode) (optional)
|
|
2461
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2462
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2463
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
2464
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
2465
|
+
|
|
2466
|
+
```json
|
|
2467
|
+
{
|
|
2468
|
+
"name": "<custom name>",
|
|
2469
|
+
"type": "co2-sensor",
|
|
2470
|
+
"topics": {
|
|
2471
|
+
"co2Detected": { //required
|
|
2472
|
+
"get": "<read_topic>",
|
|
2473
|
+
"converter"?: "boolean" | { "on": "'detected' value", "off": "'not-detected' value" }
|
|
2474
|
+
},
|
|
2475
|
+
"co2Level"?: { // optional
|
|
2476
|
+
"get": "<read_topic>"
|
|
2477
|
+
},
|
|
2478
|
+
"co2PeakLevel"?: { // optional
|
|
2479
|
+
"get": "<read_topic>",
|
|
2480
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2481
|
+
},
|
|
2482
|
+
"statusFault"?: { // optional
|
|
2483
|
+
"get": "<read_topic>",
|
|
2484
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2485
|
+
},
|
|
2486
|
+
"faultMessage"?: { // optional
|
|
2487
|
+
"get": "<topic>"
|
|
2488
|
+
},
|
|
2489
|
+
"statusLowBattery"?: { // optional
|
|
2490
|
+
"get": "<read_topic>",
|
|
2491
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
2492
|
+
},
|
|
2493
|
+
"statusTampered"?: { // optional
|
|
2494
|
+
"get": "<read_topic>",
|
|
2495
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
2496
|
+
}
|
|
2497
|
+
}
|
|
2498
|
+
}
|
|
2499
|
+
```
|
|
2500
|
+
|
|
2501
|
+
### contact-sensor
|
|
2502
|
+
|
|
2503
|
+
Characteristics:
|
|
2504
|
+
- [contactSensorState](#code-stylecolor-greencontactSensorStatecode) (required)
|
|
2505
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2506
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2507
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
2508
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
2509
|
+
|
|
2510
|
+
```json
|
|
2511
|
+
{
|
|
2512
|
+
"name": "<custom name>",
|
|
2513
|
+
"type": "contact-sensor",
|
|
2514
|
+
"topics": {
|
|
2515
|
+
"contactSensorState": { //required
|
|
2516
|
+
"get": "<read_topic>",
|
|
2517
|
+
"converter"?: "boolean" | { "on": "'contact' value", "off": "'no-contact' value" }
|
|
2518
|
+
},
|
|
2519
|
+
"statusFault"?: { // optional
|
|
2520
|
+
"get": "<read_topic>",
|
|
2521
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2522
|
+
},
|
|
2523
|
+
"faultMessage"?: { // optional
|
|
2524
|
+
"get": "<topic>"
|
|
2525
|
+
},
|
|
2526
|
+
"statusLowBattery"?: { // optional
|
|
2527
|
+
"get": "<read_topic>",
|
|
2528
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
2529
|
+
},
|
|
2530
|
+
"statusTampered"?: { // optional
|
|
2531
|
+
"get": "<read_topic>",
|
|
2532
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
2533
|
+
}
|
|
2534
|
+
}
|
|
2535
|
+
}
|
|
2536
|
+
```
|
|
2537
|
+
|
|
2538
|
+
### co-sensor
|
|
2539
|
+
|
|
2540
|
+
Characteristics:
|
|
2541
|
+
- [coDetected](#code-stylecolor-greencoDetectedcode) (required)
|
|
2542
|
+
- [coLevel](#code-stylecolor-greencoLevelcode) (optional)
|
|
2543
|
+
- [coPeakLevel](#code-stylecolor-greencoPeakLevelcode) (optional)
|
|
2544
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2545
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2546
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
2547
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
2548
|
+
|
|
2549
|
+
```json
|
|
2550
|
+
{
|
|
2551
|
+
"name": "<custom name>",
|
|
2552
|
+
"type": "co-sensor",
|
|
2553
|
+
"topics": {
|
|
2554
|
+
"coDetected": { //required
|
|
2555
|
+
"get": "<read_topic>",
|
|
2556
|
+
"converter"?: "boolean" | { "on": "'detected' value", "off": "'not-detected' value" }
|
|
2557
|
+
},
|
|
2558
|
+
"coLevel"?: { // optional
|
|
2559
|
+
"get": "<read_topic>"
|
|
2560
|
+
},
|
|
2561
|
+
"coPeakLevel"?: { // optional
|
|
2562
|
+
"get": "<read_topic>",
|
|
2563
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2564
|
+
},
|
|
2565
|
+
"statusFault"?: { // optional
|
|
2566
|
+
"get": "<read_topic>",
|
|
2567
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2568
|
+
},
|
|
2569
|
+
"faultMessage"?: { // optional
|
|
2570
|
+
"get": "<topic>"
|
|
2571
|
+
},
|
|
2572
|
+
"statusLowBattery"?: { // optional
|
|
2573
|
+
"get": "<read_topic>",
|
|
2574
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
2575
|
+
},
|
|
2576
|
+
"statusTampered"?: { // optional
|
|
2577
|
+
"get": "<read_topic>",
|
|
2578
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
2579
|
+
}
|
|
2580
|
+
}
|
|
2581
|
+
}
|
|
2582
|
+
```
|
|
2583
|
+
|
|
2584
|
+
### door
|
|
2585
|
+
|
|
2586
|
+
Characteristics:
|
|
2587
|
+
- [currentPosition](#code-stylecolor-greencurrentPositioncode) (required)
|
|
2588
|
+
- [targetPosition](#code-stylecolor-greentargetPositioncode) (required)
|
|
2589
|
+
- [positionState](#code-stylecolor-greenpositionStatecode) (required)
|
|
2590
|
+
- [holdPosition](#code-stylecolor-greenholdPositioncode) (optional)
|
|
2591
|
+
- [obstructionDetected](#code-stylecolor-greenobstructionDetectedcode) (optional)
|
|
2592
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2593
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2594
|
+
|
|
2595
|
+
```json
|
|
2596
|
+
{
|
|
2597
|
+
"name": "<custom name>",
|
|
2598
|
+
"type": "door",
|
|
2599
|
+
"topics": {
|
|
2600
|
+
"currentPosition": { //required
|
|
2601
|
+
"get": "<read_topic>",
|
|
2602
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2603
|
+
},
|
|
2604
|
+
"targetPosition": { // required
|
|
2605
|
+
"get": "<read_topic>",
|
|
2606
|
+
"set": "<write_topic>",
|
|
2607
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2608
|
+
},
|
|
2609
|
+
"positionState": { // required
|
|
2610
|
+
"get": "<read_topic>",
|
|
2611
|
+
"converter"?: {
|
|
2612
|
+
"closing"?: "'closing' state value",
|
|
2613
|
+
"opening"?: "'opening' state value",
|
|
2614
|
+
"stopped"?: "'stopped' state value"
|
|
2615
|
+
}
|
|
2616
|
+
},
|
|
2617
|
+
"holdPosition"?: { // optional
|
|
2618
|
+
"set": "<write_topic>",
|
|
2619
|
+
"value"?: "any value that the device will understand as a 'hold' command"
|
|
2620
|
+
},
|
|
2621
|
+
"obstructionDetected"?: { // optional
|
|
2622
|
+
"get": "<read_topic>",
|
|
2623
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
2624
|
+
},
|
|
2625
|
+
"statusFault"?: { // optional
|
|
2626
|
+
"get": "<read_topic>",
|
|
2627
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2628
|
+
},
|
|
2629
|
+
"faultMessage"?: { // optional
|
|
2630
|
+
"get": "<topic>"
|
|
2631
|
+
}
|
|
2632
|
+
}
|
|
2633
|
+
}
|
|
2634
|
+
```
|
|
2635
|
+
|
|
2636
|
+
### doorbell
|
|
2637
|
+
|
|
2638
|
+
Characteristics:
|
|
2639
|
+
- [pressEvent](#code-stylecolor-greenpressEventcode) (required)
|
|
2640
|
+
- [volume](#code-stylecolor-greenvolumecode) (optional)
|
|
2641
|
+
- [brightness](#code-stylecolor-greenbrightnesscode) (optional)
|
|
2642
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2643
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2644
|
+
|
|
2645
|
+
```json
|
|
2646
|
+
{
|
|
2647
|
+
"name": "<custom name>",
|
|
2648
|
+
"type": "doorbell",
|
|
2649
|
+
"topics": {
|
|
2650
|
+
"pressEvent": { //required
|
|
2651
|
+
"get": "<read_topic>",
|
|
2652
|
+
"converter"?: {
|
|
2653
|
+
"single"?: "value indicating a 'single' press event",
|
|
2654
|
+
"double"?: "value indicating a 'double' press event",
|
|
2655
|
+
"long"?: "value indicating a 'long' press event"
|
|
2656
|
+
}
|
|
2657
|
+
},
|
|
2658
|
+
"volume"?: { // optional
|
|
2659
|
+
"get": "<read_topic>",
|
|
2660
|
+
"set": "<write_topic>",
|
|
2661
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2662
|
+
},
|
|
2663
|
+
"brightness"?: { // optional
|
|
2664
|
+
"get": "<read_topic>",
|
|
2665
|
+
"get": "<write_topic>",
|
|
2666
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2667
|
+
},
|
|
2668
|
+
"statusFault"?: { // optional
|
|
2669
|
+
"get": "<read_topic>",
|
|
2670
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2671
|
+
},
|
|
2672
|
+
"faultMessage"?: { // optional
|
|
2673
|
+
"get": "<topic>"
|
|
2674
|
+
}
|
|
2675
|
+
}
|
|
2676
|
+
}
|
|
2677
|
+
```
|
|
2678
|
+
|
|
2679
|
+
### fan
|
|
2680
|
+
|
|
2681
|
+
Characteristics:
|
|
2682
|
+
- [active](#code-stylecolor-greenactivecode) (required)
|
|
2683
|
+
- [currentState](#code-stylecolor-greencurrentFanStatecode) (required) (can also be `currentFanState`)
|
|
2684
|
+
- [targetState](#code-stylecolor-greentargetFanStatecode) (required) (can also be `targetFanState`)
|
|
2685
|
+
- [rotationDirection](#code-stylecolor-greenrotationDirectioncode) (optional)
|
|
2686
|
+
- [rotationSpeed](#code-stylecolor-greenrotationSpeedcode) (optional)
|
|
2687
|
+
- [swingMode](#code-stylecolor-greenswingModecode) (optional)
|
|
2688
|
+
- [lockPhysicalControls](#code-stylecolor-greenlockPhysicalControlscode) (optional)
|
|
2689
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2690
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2691
|
+
|
|
2692
|
+
```json
|
|
2693
|
+
{
|
|
2694
|
+
"name": "<custom name>",
|
|
2695
|
+
"type": "fan",
|
|
2696
|
+
"topics": {
|
|
2697
|
+
"active": { //required
|
|
2698
|
+
"get": "<read_topic>",
|
|
2699
|
+
"set": "<write_topic>",
|
|
2700
|
+
"converter"?: "boolean" | { "min": <number>, "max": <number> }
|
|
2701
|
+
},
|
|
2702
|
+
"currentState": { // required
|
|
2703
|
+
"get": "<read_topic>",
|
|
2704
|
+
"converter"?: {
|
|
2705
|
+
"inactive"?: "'inactive' state value",
|
|
2706
|
+
"idle"?: "'idle' state value",
|
|
2707
|
+
"blowingAir"?: "'blowing air' state value"
|
|
2708
|
+
}
|
|
2709
|
+
},
|
|
2710
|
+
"targetState": { // required
|
|
2711
|
+
"get": "<read_topic>",
|
|
2712
|
+
"set": "<write_topic>",
|
|
2713
|
+
"converter"?: { "auto": "'auto' state value", "manual": "'manual' state value"}
|
|
2714
|
+
},
|
|
2715
|
+
"rotationDirection"?: { // optional
|
|
2716
|
+
"get": "<read_topic>",
|
|
2717
|
+
"set": "<write_topic>",
|
|
2718
|
+
"converter"?: { "clockwise": "value representing 'clockwise'", "counter-clockwise": "value representing 'counter-clockwise'" }
|
|
2719
|
+
},
|
|
2720
|
+
"rotationSpeed"?: { // optional
|
|
2721
|
+
"get": "<read_topic>",
|
|
2722
|
+
"set": "<write_topic>",
|
|
2723
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> } | <number> | string[]
|
|
2724
|
+
},
|
|
2725
|
+
"swingMode"?: { // optional
|
|
2726
|
+
"get": "<read_topic>",
|
|
2727
|
+
"set": "<write_topic>",
|
|
2728
|
+
"converter"?: "boolean" | { "on": "'enabled' mode value", "off": "'disabled' mode value"}
|
|
2729
|
+
},
|
|
2730
|
+
"lockPhysicalControls"?: {// optional
|
|
2731
|
+
"get": "<read_topic>",
|
|
2732
|
+
"set": "<write_topic>",
|
|
2733
|
+
"converter"?: "boolean" | { "on": "<value indicating 'locked'>", "off": "value indicating 'not-locked'" }
|
|
2734
|
+
},
|
|
2735
|
+
"statusFault"?: { // optional
|
|
2736
|
+
"get": "<read_topic>",
|
|
2737
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2738
|
+
},
|
|
2739
|
+
"faultMessage"?: { // optional
|
|
2740
|
+
"get": "<topic>"
|
|
2741
|
+
}
|
|
2742
|
+
}
|
|
2743
|
+
}
|
|
2744
|
+
```
|
|
2745
|
+
|
|
2746
|
+
### humidifier-dehumidifier
|
|
2747
|
+
|
|
2748
|
+
Characteristics:
|
|
2749
|
+
- [currentState](#code-stylecolor-greencurrentHumidifierDehumidifierStatecode) (required) (can also be `currentHumidifierDehumidifierState`)
|
|
2750
|
+
- [targetState](#code-stylecolor-greentargetHumidifierDehumidifierStatecode) (required) (can also be `targetHumidifierDehumidifierState`)
|
|
2751
|
+
- [humidifierThreshold](#code-stylecolor-greenhumidifierThresholdcode) (optional)
|
|
2752
|
+
- [dehumidifierThreshold](#code-stylecolor-greendehumidifierThresholdcode) (optional)
|
|
2753
|
+
- [rotationSpeed](#code-stylecolor-greenrotationSpeedcode) (optional)
|
|
2754
|
+
- [swingMode](#code-stylecolor-greenswingModecode) (optional)
|
|
2755
|
+
- [waterLevel](#code-stylecolor-greenwaterLevelcode) (optional)
|
|
2756
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2757
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2758
|
+
|
|
2759
|
+
```json
|
|
2760
|
+
{
|
|
2761
|
+
"name": "<custom name>",
|
|
2762
|
+
"type": "humidifier-dehumidifier",
|
|
2763
|
+
"topics": {
|
|
2764
|
+
"currentState": { // required
|
|
2765
|
+
"get": "<read_topic>",
|
|
2766
|
+
"converter"?: {
|
|
2767
|
+
"inactive"?: "'inactive' state value",
|
|
2768
|
+
"idle"?: "'idle' state value",
|
|
2769
|
+
"humidifying"?: "'humidifying' state value",
|
|
2770
|
+
"dehumidifying"?: "'dehumidifying' state value"
|
|
2771
|
+
}
|
|
2772
|
+
},
|
|
2773
|
+
"targetState": { // required
|
|
2774
|
+
"get": "<read_topic>",
|
|
2775
|
+
"set": "<write_topic>",
|
|
2776
|
+
"converter"?: {
|
|
2777
|
+
"humidifierDehumidifier"?: "'humidifierDehumidifier' state value",
|
|
2778
|
+
"humidifier"?: "'humidifier' state value",
|
|
2779
|
+
"dehumidifier"?: "'dehumidifier' state value"
|
|
2780
|
+
}
|
|
2781
|
+
},
|
|
2782
|
+
"humidifierThreshold"?: { // optional
|
|
2783
|
+
"get": "<read_topic>",
|
|
2784
|
+
"set": "<write_topic>",
|
|
2785
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2786
|
+
},
|
|
2787
|
+
"dehumidifierThreshold"?: { // optional
|
|
2788
|
+
"get": "<read_topic>",
|
|
2789
|
+
"set": "<write_topic>",
|
|
2790
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2791
|
+
},
|
|
2792
|
+
"rotationSpeed"?: { // optional
|
|
2793
|
+
"get": "<read_topic>",
|
|
2794
|
+
"set": "<write_topic>",
|
|
2795
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> } | <number> | string[]
|
|
2796
|
+
},
|
|
2797
|
+
"swingMode"?: { // optional
|
|
2798
|
+
"get": "<read_topic>",
|
|
2799
|
+
"set": "<write_topic>",
|
|
2800
|
+
"converter"?: "boolean" | { "on": "'enabled' mode value", "off": "'disabled' mode value"}
|
|
2801
|
+
},
|
|
2802
|
+
"waterLevel": { // optional
|
|
2803
|
+
"get": "<read_topic>",
|
|
2804
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2805
|
+
}
|
|
2806
|
+
"statusFault"?: { // optional
|
|
2807
|
+
"get": "<read_topic>",
|
|
2808
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2809
|
+
},
|
|
2810
|
+
"faultMessage"?: { // optional
|
|
2811
|
+
"get": "<topic>"
|
|
2812
|
+
}
|
|
2813
|
+
}
|
|
2814
|
+
}
|
|
2815
|
+
```
|
|
2816
|
+
|
|
2817
|
+
|
|
2818
|
+
### humidity-sensor
|
|
2819
|
+
|
|
2820
|
+
Characteristics:
|
|
2821
|
+
- [currentRelativeHumidity](#code-stylecolor-greencurrentRelativeHumiditycode) (required)
|
|
2822
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2823
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2824
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
2825
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
2826
|
+
|
|
2827
|
+
|
|
2828
|
+
```json
|
|
2829
|
+
{
|
|
2830
|
+
"name": "<custom name>",
|
|
2831
|
+
"type": "humidity-sensor",
|
|
2832
|
+
"topics": {
|
|
2833
|
+
"currentRelativeHumidity": { // required
|
|
2834
|
+
"get": "<read_topic>",
|
|
2835
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2836
|
+
},
|
|
2837
|
+
"statusFault"?: { // optional
|
|
2838
|
+
"get": "<read_topic>",
|
|
2839
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2840
|
+
},
|
|
2841
|
+
"faultMessage"?: { // optional
|
|
2842
|
+
"get": "<topic>"
|
|
2843
|
+
},
|
|
2844
|
+
"statusLowBattery"?: { // optional
|
|
2845
|
+
"get": "<read_topic>",
|
|
2846
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
2847
|
+
},
|
|
2848
|
+
"statusTampered"?: { // optional
|
|
2849
|
+
"get": "<read_topic>",
|
|
2850
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
2851
|
+
}
|
|
2852
|
+
}
|
|
2853
|
+
}
|
|
2854
|
+
```
|
|
2855
|
+
|
|
2856
|
+
### leak-sensor
|
|
2857
|
+
|
|
2858
|
+
Characteristics:
|
|
2859
|
+
- [leakDetected](#code-stylecolor-greenleakDetectedcode) (required)
|
|
2860
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2861
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2862
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
2863
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
2864
|
+
|
|
2865
|
+
|
|
2866
|
+
```json
|
|
2867
|
+
{
|
|
2868
|
+
"name": "<custom name>",
|
|
2869
|
+
"type": "leak-sensor",
|
|
2870
|
+
"topics": {
|
|
2871
|
+
"leakDetected": { // required
|
|
2872
|
+
"get": "<read_topic>",
|
|
2873
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
2874
|
+
},
|
|
2875
|
+
"statusFault"?: { // optional
|
|
2876
|
+
"get": "<read_topic>",
|
|
2877
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2878
|
+
},
|
|
2879
|
+
"faultMessage"?: { // optional
|
|
2880
|
+
"get": "<topic>"
|
|
2881
|
+
},
|
|
2882
|
+
"statusLowBattery"?: { // optional
|
|
2883
|
+
"get": "<read_topic>",
|
|
2884
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
2885
|
+
},
|
|
2886
|
+
"statusTampered"?: { // optional
|
|
2887
|
+
"get": "<read_topic>",
|
|
2888
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
2889
|
+
}
|
|
2890
|
+
}
|
|
2891
|
+
}
|
|
2892
|
+
```
|
|
2893
|
+
|
|
2894
|
+
### lightbulb
|
|
2895
|
+
|
|
2896
|
+
Characteristics:
|
|
2897
|
+
- [on](#code-stylecolor-greenoncode) (required)
|
|
2898
|
+
- [brightness](#code-stylecolor-greenbrightnesscode) (optional)
|
|
2899
|
+
- [saturation](#code-stylecolor-greensaturationcode) (optional)
|
|
2900
|
+
- [hue](#code-stylecolor-greenhuecode) (optional)
|
|
2901
|
+
- [colorTemperature](#code-stylecolor-greencolorTemperaturecode) (optional)
|
|
2902
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2903
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2904
|
+
|
|
2905
|
+
```json
|
|
2906
|
+
{
|
|
2907
|
+
"name": "<custom name>",
|
|
2908
|
+
"type": "lightbulb",
|
|
2909
|
+
"topics": {
|
|
2910
|
+
"on": { // required
|
|
2911
|
+
"get": "<read_topic>",
|
|
2912
|
+
"set": "<write_topic>",
|
|
2913
|
+
"converter"?: "boolean" | { "on": "<value indicating 'on'>", "off": "value indicating 'off'" }
|
|
2914
|
+
},
|
|
2915
|
+
"brightness": { // optional
|
|
2916
|
+
"get": "<read_topic>",
|
|
2917
|
+
"get": "<write_topic>",
|
|
2918
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2919
|
+
},
|
|
2920
|
+
"saturation": { // optional
|
|
2921
|
+
"get": "<read_topic>",
|
|
2922
|
+
"set": "<write_topic>",
|
|
2923
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
2924
|
+
},
|
|
2925
|
+
"hue": { // optional
|
|
2926
|
+
"get": "<read_topic>",
|
|
2927
|
+
"set": "<write_topic>",
|
|
2928
|
+
"converter"?: "percent-integer" | "percent-decimal"
|
|
2929
|
+
},
|
|
2930
|
+
"colorTemperature": { // optional
|
|
2931
|
+
"get": "<read_topic>",
|
|
2932
|
+
"set": "<read_topic>",
|
|
2933
|
+
"converter"?: "kelvin"
|
|
2934
|
+
},
|
|
2935
|
+
"statusFault"?: { // optional
|
|
2936
|
+
"get": "<read_topic>",
|
|
2937
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2938
|
+
},
|
|
2939
|
+
"faultMessage"?: { // optional
|
|
2940
|
+
"get": "<topic>"
|
|
2941
|
+
}
|
|
2942
|
+
}
|
|
2943
|
+
}
|
|
2944
|
+
```
|
|
2945
|
+
|
|
2946
|
+
### light-sensor
|
|
2947
|
+
|
|
2948
|
+
Characteristics:
|
|
2949
|
+
- [ambientLightLevel](#code-stylecolor-greenambientLightLevelcode) (required)
|
|
2950
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2951
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2952
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
2953
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
2954
|
+
|
|
2955
|
+
|
|
2956
|
+
```json
|
|
2957
|
+
{
|
|
2958
|
+
"name": "<custom name>",
|
|
2959
|
+
"type": "light-sensor",
|
|
2960
|
+
"topics": {
|
|
2961
|
+
"ambientLightLevel": { // required
|
|
2962
|
+
"get": "<read_topic>",
|
|
2963
|
+
"converter"?: log-scale-lux"
|
|
2964
|
+
},
|
|
2965
|
+
"statusFault"?: { // optional
|
|
2966
|
+
"get": "<read_topic>",
|
|
2967
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
2968
|
+
},
|
|
2969
|
+
"faultMessage"?: { // optional
|
|
2970
|
+
"get": "<topic>"
|
|
2971
|
+
},
|
|
2972
|
+
"statusLowBattery"?: { // optional
|
|
2973
|
+
"get": "<read_topic>",
|
|
2974
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
2975
|
+
},
|
|
2976
|
+
"statusTampered"?: { // optional
|
|
2977
|
+
"get": "<read_topic>",
|
|
2978
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
2979
|
+
}
|
|
2980
|
+
}
|
|
2981
|
+
}
|
|
2982
|
+
```
|
|
2983
|
+
|
|
2984
|
+
### lock
|
|
2985
|
+
|
|
2986
|
+
Characteristics:
|
|
2987
|
+
- [currentState](#code-stylecolor-greenlockCurrentStatecode) (required) (can also be `lockCurrentState`)
|
|
2988
|
+
- [targetState](#code-stylecolor-greenlockTargetStatecode) (optional) (can also be `lockTargetState`)
|
|
2989
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
2990
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
2991
|
+
|
|
2992
|
+
```json
|
|
2993
|
+
{
|
|
2994
|
+
"name": "<custom name>",
|
|
2995
|
+
"type": "lock",
|
|
2996
|
+
"topics": {
|
|
2997
|
+
"currentState": { // required
|
|
2998
|
+
"get": "<read_topic>",
|
|
2999
|
+
"converter"?: {
|
|
3000
|
+
"unsecured"?: "'unsecured' state value",
|
|
3001
|
+
"secured"?: "'secured' state value",
|
|
3002
|
+
"jammed"?: "'jammed' state value",
|
|
3003
|
+
"unknown"?: "'unknown' state value"
|
|
3004
|
+
}
|
|
3005
|
+
},
|
|
3006
|
+
"targetState": { // required
|
|
3007
|
+
"get": "<read_topic>",
|
|
3008
|
+
"set": "<write_topic>",
|
|
3009
|
+
"converter"?: "boolean" | { "secured": "<value indicating 'secured'>", "unsecured": "value indicating 'unsecured'" }
|
|
3010
|
+
},
|
|
3011
|
+
"statusFault"?: { // optional
|
|
3012
|
+
"get": "<read_topic>",
|
|
3013
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3014
|
+
},
|
|
3015
|
+
"faultMessage"?: { // optional
|
|
3016
|
+
"get": "<topic>"
|
|
3017
|
+
}
|
|
3018
|
+
}
|
|
3019
|
+
}
|
|
3020
|
+
```
|
|
3021
|
+
|
|
3022
|
+
### microphone
|
|
3023
|
+
|
|
3024
|
+
Characteristics:
|
|
3025
|
+
- [mute](#code-stylecolor-greenmutecode) (required)
|
|
3026
|
+
- [volume](#code-stylecolor-greenvolumecode) (optional)
|
|
3027
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3028
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3029
|
+
|
|
3030
|
+
```json
|
|
3031
|
+
{
|
|
3032
|
+
"name": "<custom name>",
|
|
3033
|
+
"type": "microphone",
|
|
3034
|
+
"topics": {
|
|
3035
|
+
"mute": { // required
|
|
3036
|
+
"get": "<read_topic>",
|
|
3037
|
+
"set": "<write_topic>",
|
|
3038
|
+
"converter"?: "boolean" | { "on": "<value indicating 'muted'>", "off": "value indicating 'not-muted'" }
|
|
3039
|
+
},
|
|
3040
|
+
"volume": { // required
|
|
3041
|
+
"get": "<read_topic>",
|
|
3042
|
+
"set": "<write_topic>",
|
|
3043
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
3044
|
+
},
|
|
3045
|
+
"statusFault"?: { // optional
|
|
3046
|
+
"get": "<read_topic>",
|
|
3047
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3048
|
+
},
|
|
3049
|
+
"faultMessage"?: { // optional
|
|
3050
|
+
"get": "<topic>"
|
|
3051
|
+
}
|
|
3052
|
+
}
|
|
3053
|
+
}
|
|
3054
|
+
```
|
|
3055
|
+
|
|
3056
|
+
### motion-sensor
|
|
3057
|
+
|
|
3058
|
+
Characteristics:
|
|
3059
|
+
- [motionDetected](#code-stylecolor-greenmotionDetectedcode) (required)
|
|
3060
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3061
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3062
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
3063
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
3064
|
+
|
|
3065
|
+
|
|
3066
|
+
```json
|
|
3067
|
+
{
|
|
3068
|
+
"name": "<custom name>",
|
|
3069
|
+
"type": "motion-sensor",
|
|
3070
|
+
"topics": {
|
|
3071
|
+
"motionDetected": { // required
|
|
3072
|
+
"get": "<read_topic>",
|
|
3073
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
3074
|
+
},
|
|
3075
|
+
"statusFault"?: { // optional
|
|
3076
|
+
"get": "<read_topic>",
|
|
3077
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3078
|
+
},
|
|
3079
|
+
"faultMessage"?: { // optional
|
|
3080
|
+
"get": "<topic>"
|
|
3081
|
+
},
|
|
3082
|
+
"statusLowBattery"?: { // optional
|
|
3083
|
+
"get": "<read_topic>",
|
|
3084
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
3085
|
+
},
|
|
3086
|
+
"statusTampered"?: { // optional
|
|
3087
|
+
"get": "<read_topic>",
|
|
3088
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
3089
|
+
}
|
|
3090
|
+
}
|
|
3091
|
+
}
|
|
3092
|
+
```
|
|
3093
|
+
|
|
3094
|
+
### occupancy-sensor
|
|
3095
|
+
|
|
3096
|
+
Characteristics:
|
|
3097
|
+
- [occupancyDetected](#code-stylecolor-greenoccupancyDetectedcode) (required)
|
|
3098
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3099
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3100
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
3101
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
3102
|
+
|
|
3103
|
+
|
|
3104
|
+
```json
|
|
3105
|
+
{
|
|
3106
|
+
"name": "<custom name>",
|
|
3107
|
+
"type": "occupancy-sensor",
|
|
3108
|
+
"topics": {
|
|
3109
|
+
"occupancyDetected": { // required
|
|
3110
|
+
"get": "<read_topic>",
|
|
3111
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
3112
|
+
},
|
|
3113
|
+
"statusFault"?: { // optional
|
|
3114
|
+
"get": "<read_topic>",
|
|
3115
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3116
|
+
},
|
|
3117
|
+
"faultMessage"?: { // optional
|
|
3118
|
+
"get": "<topic>"
|
|
3119
|
+
},
|
|
3120
|
+
"statusLowBattery"?: { // optional
|
|
3121
|
+
"get": "<read_topic>",
|
|
3122
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
3123
|
+
},
|
|
3124
|
+
"statusTampered"?: { // optional
|
|
3125
|
+
"get": "<read_topic>",
|
|
3126
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
3127
|
+
}
|
|
3128
|
+
}
|
|
3129
|
+
}
|
|
3130
|
+
```
|
|
3131
|
+
|
|
3132
|
+
### outlet
|
|
3133
|
+
|
|
3134
|
+
Characteristics:
|
|
3135
|
+
- [on](#code-stylecolor-greenoncode) (required)
|
|
3136
|
+
- [outletInUse](#code-stylecolor-greenoutletInUsecode) (optional)
|
|
3137
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3138
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3139
|
+
|
|
3140
|
+
```json
|
|
3141
|
+
{
|
|
3142
|
+
"name": "<custom name>",
|
|
3143
|
+
"type": "outlet",
|
|
3144
|
+
"topics": {
|
|
3145
|
+
"on": { // required
|
|
3146
|
+
"get": "<read_topic>",
|
|
3147
|
+
"set": "<write_topic>",
|
|
3148
|
+
"converter"?: "boolean" | { "on": "<value indicating 'on'>", "off": "value indicating 'off'" }
|
|
3149
|
+
},
|
|
3150
|
+
"outletInUse": { // optional
|
|
3151
|
+
"get": "<read_topic>",
|
|
3152
|
+
"converter"?: "boolean" | { "on": "<value indicating 'in-use'>", "off": "value indicating 'not-in-use'" }
|
|
3153
|
+
},
|
|
3154
|
+
"statusFault"?: { // optional
|
|
3155
|
+
"get": "<read_topic>",
|
|
3156
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3157
|
+
},
|
|
3158
|
+
"faultMessage"?: { // optional
|
|
3159
|
+
"get": "<topic>"
|
|
3160
|
+
}
|
|
3161
|
+
}
|
|
3162
|
+
}
|
|
3163
|
+
```
|
|
3164
|
+
|
|
3165
|
+
### security-system
|
|
3166
|
+
|
|
3167
|
+
Characteristics:
|
|
3168
|
+
- [currentState](#code-stylecolor-greensecuritySystemCurrentStatecode) (required) (can also be `securitySystemCurrentState`)
|
|
3169
|
+
- [targetState](#code-stylecolor-greensecuritySystemTargetStatecode) (required) (can also be `securitySystemTargetState`)
|
|
3170
|
+
- [alarmType](#code-stylecolor-greenalarmTypecode) (optional)
|
|
3171
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
3172
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3173
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3174
|
+
|
|
3175
|
+
```json
|
|
3176
|
+
{
|
|
3177
|
+
"name": "<custom name>",
|
|
3178
|
+
"type": "security-system",
|
|
3179
|
+
"topics": {
|
|
3180
|
+
"currentState": { // required
|
|
3181
|
+
"get": "<read_topic>",
|
|
3182
|
+
"converter"?: {
|
|
3183
|
+
"stay"?: "'stay' state value",
|
|
3184
|
+
"away"?: "'away' state value",
|
|
3185
|
+
"night"?: "'night' state value",
|
|
3186
|
+
"disarmed"?: "'disarmed' state value",
|
|
3187
|
+
"triggered"?: "'triggered' state value",
|
|
3188
|
+
}
|
|
3189
|
+
},
|
|
3190
|
+
"targetState": { // required
|
|
3191
|
+
"get": "<read_topic>",
|
|
3192
|
+
"set": "<write_topic>",
|
|
3193
|
+
"converter"?: {
|
|
3194
|
+
"stay"?: "'stay' state value",
|
|
3195
|
+
"away"?: "'away' state value",
|
|
3196
|
+
"night"?: "'night' state value",
|
|
3197
|
+
"disarm"?: "'disarm' state value",
|
|
3198
|
+
},
|
|
3199
|
+
"validValues"?: string[] // e.g. [ "stay", "away", "disarm" ] to not show the 'night' option.
|
|
3200
|
+
},
|
|
3201
|
+
"alarmType": { // optional
|
|
3202
|
+
"get": "<read_topic>",
|
|
3203
|
+
"converter"?: { "cleared": "value representing a 'cleared` state"}
|
|
3204
|
+
},
|
|
3205
|
+
"statusTampered": { // optional
|
|
3206
|
+
"get": "<read_topic>",
|
|
3207
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
3208
|
+
}
|
|
3209
|
+
"statusFault"?: { // optional
|
|
3210
|
+
"get": "<read_topic>",
|
|
3211
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3212
|
+
},
|
|
3213
|
+
"faultMessage"?: { // optional
|
|
3214
|
+
"get": "<topic>"
|
|
3215
|
+
}
|
|
3216
|
+
}
|
|
3217
|
+
}
|
|
3218
|
+
```
|
|
3219
|
+
|
|
3220
|
+
### smoke-sensor
|
|
3221
|
+
|
|
3222
|
+
Characteristics:
|
|
3223
|
+
- [smokeDetected](#code-stylecolor-greensmokeDetectedcode) (required)
|
|
3224
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3225
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3226
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
3227
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
3228
|
+
|
|
3229
|
+
|
|
3230
|
+
```json
|
|
3231
|
+
{
|
|
3232
|
+
"name": "<custom name>",
|
|
3233
|
+
"type": "smoke-sensor",
|
|
3234
|
+
"topics": {
|
|
3235
|
+
"smokeDetected": { // required
|
|
3236
|
+
"get": "<read_topic>",
|
|
3237
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
3238
|
+
},
|
|
3239
|
+
"statusFault"?: { // optional
|
|
3240
|
+
"get": "<read_topic>",
|
|
3241
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3242
|
+
},
|
|
3243
|
+
"faultMessage"?: { // optional
|
|
3244
|
+
"get": "<topic>"
|
|
3245
|
+
},
|
|
3246
|
+
"statusLowBattery"?: { // optional
|
|
3247
|
+
"get": "<read_topic>",
|
|
3248
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
3249
|
+
},
|
|
3250
|
+
"statusTampered"?: { // optional
|
|
3251
|
+
"get": "<read_topic>",
|
|
3252
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
3253
|
+
}
|
|
3254
|
+
}
|
|
3255
|
+
}
|
|
3256
|
+
```
|
|
3257
|
+
|
|
3258
|
+
### speaker
|
|
3259
|
+
|
|
3260
|
+
Characteristics:
|
|
3261
|
+
- [mute](#code-stylecolor-greenmutecode) (required)
|
|
3262
|
+
- [volume](#code-stylecolor-greenvolumecode) (optional)
|
|
3263
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3264
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3265
|
+
|
|
3266
|
+
```json
|
|
3267
|
+
{
|
|
3268
|
+
"name": "<custom name>",
|
|
3269
|
+
"type": "speaker",
|
|
3270
|
+
"topics": {
|
|
3271
|
+
"mute": { // required
|
|
3272
|
+
"get": "<read_topic>",
|
|
3273
|
+
"set": "<write_topic>",
|
|
3274
|
+
"converter"?: "boolean" | { "on": "<value indicating 'muted'>", "off": "value indicating 'not-muted'" }
|
|
3275
|
+
},
|
|
3276
|
+
"volume": { // required
|
|
3277
|
+
"get": "<read_topic>",
|
|
3278
|
+
"set": "<write_topic>",
|
|
3279
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
3280
|
+
},
|
|
3281
|
+
"statusFault"?: { // optional
|
|
3282
|
+
"get": "<read_topic>",
|
|
3283
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3284
|
+
},
|
|
3285
|
+
"faultMessage"?: { // optional
|
|
3286
|
+
"get": "<topic>"
|
|
3287
|
+
}
|
|
3288
|
+
}
|
|
3289
|
+
}
|
|
3290
|
+
```
|
|
3291
|
+
|
|
3292
|
+
### switch
|
|
3293
|
+
|
|
3294
|
+
Characteristics:
|
|
3295
|
+
- [on](#code-stylecolor-greenoncode) (required)
|
|
3296
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3297
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3298
|
+
|
|
3299
|
+
```json
|
|
3300
|
+
{
|
|
3301
|
+
"name": "<custom name>",
|
|
3302
|
+
"type": "outlet",
|
|
3303
|
+
"topics": {
|
|
3304
|
+
"on": { // required
|
|
3305
|
+
"get": "<read_topic>",
|
|
3306
|
+
"set": "<write_topic>",
|
|
3307
|
+
"converter"?: "boolean" | { "on": "<value indicating 'on'>", "off": "value indicating 'off'" }
|
|
3308
|
+
},
|
|
3309
|
+
"statusFault"?: { // optional
|
|
3310
|
+
"get": "<read_topic>",
|
|
3311
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3312
|
+
},
|
|
3313
|
+
"faultMessage"?: { // optional
|
|
3314
|
+
"get": "<topic>"
|
|
3315
|
+
}
|
|
3316
|
+
}
|
|
3317
|
+
}
|
|
3318
|
+
```
|
|
3319
|
+
|
|
3320
|
+
### temperature-sensor
|
|
3321
|
+
|
|
3322
|
+
Characteristics:
|
|
3323
|
+
- [currentTemperature](#code-stylecolor-greencurrentTemperaturecode) (required)
|
|
3324
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3325
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3326
|
+
- [statusLowBattery](#code-stylecolor-greenstatusLowBatterycode) (optional)
|
|
3327
|
+
- [statusTampered](#code-stylecolor-greenstatusTamperedcode) (optional)
|
|
3328
|
+
|
|
3329
|
+
|
|
3330
|
+
```json
|
|
3331
|
+
{
|
|
3332
|
+
"name": "<custom name>",
|
|
3333
|
+
"type": "smoke-sensor",
|
|
3334
|
+
"topics": {
|
|
3335
|
+
"currentTemperature": { // required
|
|
3336
|
+
"get": "<read_topic>",
|
|
3337
|
+
"converter"?: "fahrenheit",
|
|
3338
|
+
"minValue"?: <number>, // in celsius (regardless of the converter), defaut: 10.0
|
|
3339
|
+
"maxValue"?: <number>, // in celsius (regardless of the converter), defaut: 38.0
|
|
3340
|
+
"minStep"?: <number> // in celsius (regardless of the converter), defaut: 0.1
|
|
3341
|
+
},
|
|
3342
|
+
"statusFault"?: { // optional
|
|
3343
|
+
"get": "<read_topic>",
|
|
3344
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3345
|
+
},
|
|
3346
|
+
"faultMessage"?: { // optional
|
|
3347
|
+
"get": "<topic>"
|
|
3348
|
+
},
|
|
3349
|
+
"statusLowBattery"?: { // optional
|
|
3350
|
+
"get": "<read_topic>",
|
|
3351
|
+
"converter"?: "boolean" | { "on": "'low' status value", "off": "'not-low' status value"}
|
|
3352
|
+
},
|
|
3353
|
+
"statusTampered"?: { // optional
|
|
3354
|
+
"get": "<read_topic>",
|
|
3355
|
+
"converter"?: "boolean" | { "on": "'tampered' status value", "off": "'not-tampered' status value"}
|
|
3356
|
+
}
|
|
3357
|
+
}
|
|
3358
|
+
}
|
|
3359
|
+
```
|
|
3360
|
+
|
|
3361
|
+
### thermostat
|
|
3362
|
+
|
|
3363
|
+
Characteristics:
|
|
3364
|
+
- [currentTemperature](#code-stylecolor-greencurrentTemperaturecode) (required)
|
|
3365
|
+
- [targetTemperature](#code-stylecolor-greentargetTemperaturecode) (required)
|
|
3366
|
+
- [currentState](#code-stylecolor-greencurrentHeatingCoolingStatecode) (optional) (can also be `currentHeatingCoolingState`)
|
|
3367
|
+
- [targetState](#code-stylecolor-greentargetHeatingCoolingStatecode) (optional) (can also be `targetHeatingCoolingState`)
|
|
3368
|
+
- [temperatureDisplayUnits](#code-stylecolor-greentemperatureDisplayUnitscode) (optional)
|
|
3369
|
+
- [coolingThreshold](#code-stylecolor-greencoolingThresholdcode) (optional)
|
|
3370
|
+
- [heatingThreshold](#code-stylecolor-greenheatingThresholdcode) (optional)
|
|
3371
|
+
- [currentRelativeHumidity](#code-stylecolor-greencurrentRelativeHumiditycode) (optional)
|
|
3372
|
+
- [targetRelativeHumidity](#code-stylecolor-greentargetRelativeHumiditycode) (optional)
|
|
3373
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3374
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3375
|
+
|
|
3376
|
+
Additional Settings:
|
|
3377
|
+
|
|
3378
|
+
- `hvacType` (optional) - only used when `currentHeatingCoolingState` is not set. Can have one of the following values:
|
|
3379
|
+
- `heat-cool`: depending on the current and target temp. `heat`/`cool`/`off` will be set as the current state
|
|
3380
|
+
- `heat-only`: depending on the current and target temp. `heat`/`off` will be set as the current state
|
|
3381
|
+
- `cool-only`: depending on the current and target temp. `cool`/`off` will be set as the current state
|
|
3382
|
+
|
|
3383
|
+
|
|
3384
|
+
- `stateThreshold` (optional) - Only used when `currentHeatingCoolingState` is not set. A numeric values that determines
|
|
3385
|
+
when the current state will change (based on the current and target temperatures). e.g.
|
|
3386
|
+
- if `target > current + threshold` the state will either be `heat` or `off` (depending on the `hvacType`)
|
|
3387
|
+
- if `target < current - threshold` the state will either be `cool` or `off` (depending on the `hvacType`)
|
|
3388
|
+
- otherwise, the state will be `off`
|
|
3389
|
+
|
|
3390
|
+
|
|
3391
|
+
```json
|
|
3392
|
+
{
|
|
3393
|
+
"name": "<custom name>",
|
|
3394
|
+
"type": "thermostat",
|
|
3395
|
+
"hvacType"?: "heat-cool" | "heat-only" | "cool-only",
|
|
3396
|
+
"stateThreshold"?: <number>,
|
|
3397
|
+
"topics": {
|
|
3398
|
+
"currentTemperature": { // required
|
|
3399
|
+
"get": "<read_topic>",
|
|
3400
|
+
"converter"?: "fahrenheit",
|
|
3401
|
+
"minValue"?: <number>, // in celsius (regardless of the converter), defaut: 10.0
|
|
3402
|
+
"maxValue"?: <number>, // in celsius (regardless of the converter), defaut: 38.0
|
|
3403
|
+
"minStep"?: <number> // in celsius (regardless of the converter), defaut: 0.1
|
|
3404
|
+
},
|
|
3405
|
+
"targetTemperature": { // required
|
|
3406
|
+
"get": "<read_topic>",
|
|
3407
|
+
"set": "<write_topic>",
|
|
3408
|
+
"converter"?: "fahrenheit",
|
|
3409
|
+
"minValue"?: <number>, // in celsius (regardless of the converter), defaut: 10.0
|
|
3410
|
+
"maxValue"?: <number>, // in celsius (regardless of the converter), defaut: 38.0
|
|
3411
|
+
"minStep"?: <number> // in celsius (regardless of the converter), defaut: 0.1
|
|
3412
|
+
},
|
|
3413
|
+
"currentState": { // optional
|
|
3414
|
+
"get": "<read_topic>",
|
|
3415
|
+
"converter"?: {
|
|
3416
|
+
"off"?: "'off' state value",
|
|
3417
|
+
"heat"?: "'heat' state value",
|
|
3418
|
+
"cool"?: "'cool' state value"
|
|
3419
|
+
}
|
|
3420
|
+
},
|
|
3421
|
+
"targetState": {
|
|
3422
|
+
"get": "<read_topic>",
|
|
3423
|
+
"set": "<write_topic>",
|
|
3424
|
+
"converter"?: {
|
|
3425
|
+
"off"?: "'off' state value",
|
|
3426
|
+
"heat"?: "'heat' state value",
|
|
3427
|
+
"cool"?: "'cool' state value",
|
|
3428
|
+
"auto"?: "'auto' state value",
|
|
3429
|
+
},
|
|
3430
|
+
"validValues": string[] // e.g. [ "off", "auto" ] to only provide the user to stop the operation of the device
|
|
3431
|
+
},
|
|
3432
|
+
"temperatureDisplayUnits": { // optional
|
|
3433
|
+
"get": "<read_topic>",
|
|
3434
|
+
"set": "<write_topic>",
|
|
3435
|
+
"converter"?: { "celsius": "value indicating 'celsius'", "fahrenheit": "value indicating 'fahrenheit'" }
|
|
3436
|
+
},
|
|
3437
|
+
"coolingThreshold": { // optional
|
|
3438
|
+
"get": "<read_topic>",
|
|
3439
|
+
"set": "<read_topic>",
|
|
3440
|
+
"converter"?: "fahrenheit"
|
|
3441
|
+
},
|
|
3442
|
+
"heatingThreshold": { // optional
|
|
3443
|
+
"get": "<read_topic>",
|
|
3444
|
+
"set": "<read_topic>",
|
|
3445
|
+
"converter"?: "fahrenheit"
|
|
3446
|
+
},
|
|
3447
|
+
"currentRelativeHumidity": { // optional
|
|
3448
|
+
"get": "<read_topic>",
|
|
3449
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
3450
|
+
},
|
|
3451
|
+
"targetRelativeHumidity": { // optional
|
|
3452
|
+
"get": "<read_topic>",
|
|
3453
|
+
"set": "<write_topic>",
|
|
3454
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
3455
|
+
},
|
|
3456
|
+
"statusFault"?: { // optional
|
|
3457
|
+
"get": "<read_topic>",
|
|
3458
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3459
|
+
},
|
|
3460
|
+
"faultMessage"?: { // optional
|
|
3461
|
+
"get": "<topic>"
|
|
3462
|
+
}
|
|
3463
|
+
}
|
|
3464
|
+
}
|
|
3465
|
+
```
|
|
3466
|
+
|
|
3467
|
+
### window
|
|
3468
|
+
|
|
3469
|
+
Characteristics:
|
|
3470
|
+
- [currentPosition](#code-stylecolor-greencurrentPositioncode) (required)
|
|
3471
|
+
- [targetPosition](#code-stylecolor-greentargetPositioncode) (required)
|
|
3472
|
+
- [positionState](#code-stylecolor-greenpositionStatecode) (required)
|
|
3473
|
+
- [holdPosition](#code-stylecolor-greenholdPositioncode) (optional)
|
|
3474
|
+
- [obstructionDetected](#code-stylecolor-greenobstructionDetectedcode) (optional)
|
|
3475
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3476
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3477
|
+
|
|
3478
|
+
```json
|
|
3479
|
+
{
|
|
3480
|
+
"name": "<custom name>",
|
|
3481
|
+
"type": "window",
|
|
3482
|
+
"topics": {
|
|
3483
|
+
"currentPosition": { //required
|
|
3484
|
+
"get": "<read_topic>",
|
|
3485
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
3486
|
+
},
|
|
3487
|
+
"targetPosition": { // required
|
|
3488
|
+
"get": "<read_topic>",
|
|
3489
|
+
"set": "<write_topic>",
|
|
3490
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
3491
|
+
},
|
|
3492
|
+
"positionState": { // required
|
|
3493
|
+
"get": "<read_topic>",
|
|
3494
|
+
"converter"?: {
|
|
3495
|
+
"closing"?: "'closing' state value",
|
|
3496
|
+
"opening"?: "'opening' state value",
|
|
3497
|
+
"stopped"?: "'stopped' state value"
|
|
3498
|
+
}
|
|
3499
|
+
},
|
|
3500
|
+
"holdPosition"?: { // optional
|
|
3501
|
+
"set": "<write_topic>",
|
|
3502
|
+
"value"?: "any value that the device will understand as a 'hold' command"
|
|
3503
|
+
},
|
|
3504
|
+
"obstructionDetected"?: { // optional
|
|
3505
|
+
"get": "<read_topic>",
|
|
3506
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
3507
|
+
},
|
|
3508
|
+
"statusFault"?: { // optional
|
|
3509
|
+
"get": "<read_topic>",
|
|
3510
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3511
|
+
},
|
|
3512
|
+
"faultMessage"?: { // optional
|
|
3513
|
+
"get": "<topic>"
|
|
3514
|
+
}
|
|
3515
|
+
}
|
|
3516
|
+
}
|
|
3517
|
+
```
|
|
3518
|
+
|
|
3519
|
+
### window-covering
|
|
3520
|
+
|
|
3521
|
+
Characteristics:
|
|
3522
|
+
- [currentPosition](#code-stylecolor-greencurrentPositioncode) (required)
|
|
3523
|
+
- [targetPosition](#code-stylecolor-greentargetPositioncode) (required)
|
|
3524
|
+
- [positionState](#code-stylecolor-greenpositionStatecode) (optional)
|
|
3525
|
+
- [holdPosition](#code-stylecolor-greenholdPositioncode) (optional)
|
|
3526
|
+
- [obstructionDetected](#code-stylecolor-greenobstructionDetectedcode) (optional)
|
|
3527
|
+
- [currentHorizontalTiltAngle](#code-stylecolor-greencurrentHorizontalTiltAnglecode) (optional)
|
|
3528
|
+
- [targetHorizontalTiltAngle](#code-stylecolor-greentargetHorizontalTiltAnglecode) (optional)
|
|
3529
|
+
- [currentVerticalTiltAngle](#code-stylecolor-greencurrentVerticalTiltAnglecode) (optional)
|
|
3530
|
+
- [targetVerticalTiltAngle](#code-stylecolor-greentargetVerticalTiltAnglecode) (optional)
|
|
3531
|
+
- [statusFault](#code-stylecolor-greenstatusFaultcode) (optional)
|
|
3532
|
+
- [faultMessage](#code-stylecolor-greenfaultMessagecode) (optional)
|
|
3533
|
+
|
|
3534
|
+
```json
|
|
3535
|
+
{
|
|
3536
|
+
"name": "<custom name>",
|
|
3537
|
+
"type": "window-covering",
|
|
3538
|
+
"topics": {
|
|
3539
|
+
"currentPosition": { //required
|
|
3540
|
+
"get": "<read_topic>",
|
|
3541
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
3542
|
+
},
|
|
3543
|
+
"targetPosition": { // required
|
|
3544
|
+
"get": "<read_topic>",
|
|
3545
|
+
"set": "<write_topic>",
|
|
3546
|
+
"converter"?: "decimal" | { "min": <number>, "max": <number> }
|
|
3547
|
+
},
|
|
3548
|
+
"positionState?": { // optional
|
|
3549
|
+
"get": "<read_topic>",
|
|
3550
|
+
"converter"?: {
|
|
3551
|
+
"closing"?: "'closing' state value",
|
|
3552
|
+
"opening"?: "'opening' state value",
|
|
3553
|
+
"stopped"?: "'stopped' state value"
|
|
3554
|
+
}
|
|
3555
|
+
},
|
|
3556
|
+
"holdPosition"?: { // optional
|
|
3557
|
+
"set": "<write_topic>",
|
|
3558
|
+
"value"?: "any value that the device will understand as a 'hold' command"
|
|
3559
|
+
},
|
|
3560
|
+
"obstructionDetected"?: { // optional
|
|
3561
|
+
"get": "<read_topic>",
|
|
3562
|
+
"converter"?: "boolean" | { "on": "<value indicating 'detected'>", "off": "value indicating 'not-detected'" }
|
|
3563
|
+
},
|
|
3564
|
+
"currentHorizontalTiltAngle"?: { // optional
|
|
3565
|
+
"get": "<read_topic>"
|
|
3566
|
+
},
|
|
3567
|
+
"targetHorizontalTiltAngle"?: {
|
|
3568
|
+
"get": "<read_topic>",
|
|
3569
|
+
"set": "<write_topic>"
|
|
3570
|
+
},
|
|
3571
|
+
"currentVerticalTiltAngle"?: { // optional
|
|
3572
|
+
"get": "<read_topic>"
|
|
3573
|
+
},
|
|
3574
|
+
"targetVerticalTiltAngle"?: { // optional
|
|
3575
|
+
"get": "<read_topic>",
|
|
3576
|
+
"set": "<write_topic>"
|
|
3577
|
+
}
|
|
3578
|
+
"statusFault"?: { // optional
|
|
3579
|
+
"get": "<read_topic>",
|
|
3580
|
+
"converter"?: "boolean" | { "on": "'fault' value", "off": "'no fault' value"}
|
|
3581
|
+
},
|
|
3582
|
+
"faultMessage"?: { // optional
|
|
3583
|
+
"get": "<topic>"
|
|
3584
|
+
}
|
|
3585
|
+
}
|
|
3586
|
+
}
|
|
3587
|
+
```
|