@zwave-js/cc 14.0.0-beta.1 → 14.0.0-beta.4
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/build/cjs/cc/AlarmSensorCC.d.ts +194 -0
- package/build/cjs/cc/AlarmSensorCC.js +395 -0
- package/build/cjs/cc/AlarmSensorCC.js.map +7 -0
- package/build/cjs/cc/AssociationCC.d.ts +253 -0
- package/build/cjs/cc/AssociationCC.js +711 -0
- package/build/cjs/cc/AssociationCC.js.map +7 -0
- package/build/cjs/cc/AssociationGroupInfoCC.d.ts +230 -0
- package/build/cjs/cc/AssociationGroupInfoCC.js +746 -0
- package/build/cjs/cc/AssociationGroupInfoCC.js.map +7 -0
- package/build/cjs/cc/BarrierOperatorCC.d.ts +243 -0
- package/build/cjs/cc/BarrierOperatorCC.js +582 -0
- package/build/cjs/cc/BarrierOperatorCC.js.map +7 -0
- package/build/cjs/cc/BasicCC.d.ts +191 -0
- package/build/cjs/cc/BasicCC.js +384 -0
- package/build/cjs/cc/BasicCC.js.map +7 -0
- package/build/cjs/cc/BatteryCC.d.ts +406 -0
- package/build/cjs/cc/BatteryCC.js +508 -0
- package/build/cjs/cc/BatteryCC.js.map +7 -0
- package/build/cjs/cc/BinarySensorCC.d.ts +122 -0
- package/build/cjs/cc/BinarySensorCC.js +431 -0
- package/build/cjs/cc/BinarySensorCC.js.map +7 -0
- package/build/cjs/cc/BinarySwitchCC.d.ts +139 -0
- package/build/cjs/cc/BinarySwitchCC.js +378 -0
- package/build/cjs/cc/BinarySwitchCC.js.map +7 -0
- package/build/cjs/cc/CRC16CC.d.ts +29 -0
- package/build/cjs/cc/CRC16CC.js +133 -0
- package/build/cjs/cc/CRC16CC.js.map +7 -0
- package/build/cjs/cc/CentralSceneCC.d.ts +210 -0
- package/build/cjs/cc/CentralSceneCC.js +449 -0
- package/build/cjs/cc/CentralSceneCC.js.map +7 -0
- package/build/cjs/cc/ClimateControlScheduleCC.d.ts +177 -0
- package/build/cjs/cc/ClimateControlScheduleCC.js +480 -0
- package/build/cjs/cc/ClimateControlScheduleCC.js.map +7 -0
- package/build/cjs/cc/ClockCC.d.ts +47 -0
- package/build/cjs/cc/ClockCC.js +226 -0
- package/build/cjs/cc/ClockCC.js.map +7 -0
- package/build/cjs/cc/ColorSwitchCC.d.ts +339 -0
- package/build/cjs/cc/ColorSwitchCC.js +1117 -0
- package/build/cjs/cc/ColorSwitchCC.js.map +7 -0
- package/build/cjs/cc/ConfigurationCC.d.ts +396 -0
- package/build/cjs/cc/ConfigurationCC.js +2230 -0
- package/build/cjs/cc/ConfigurationCC.js.map +7 -0
- package/build/cjs/cc/DeviceResetLocallyCC.d.ts +17 -0
- package/build/cjs/cc/DeviceResetLocallyCC.js +92 -0
- package/build/cjs/cc/DeviceResetLocallyCC.js.map +7 -0
- package/build/cjs/cc/DoorLockCC.d.ts +837 -0
- package/build/cjs/cc/DoorLockCC.js +1239 -0
- package/build/cjs/cc/DoorLockCC.js.map +7 -0
- package/build/cjs/cc/DoorLockLoggingCC.d.ts +77 -0
- package/build/cjs/cc/DoorLockLoggingCC.js +343 -0
- package/build/cjs/cc/DoorLockLoggingCC.js.map +7 -0
- package/build/cjs/cc/EnergyProductionCC.d.ts +77 -0
- package/build/cjs/cc/EnergyProductionCC.js +240 -0
- package/build/cjs/cc/EnergyProductionCC.js.map +7 -0
- package/build/cjs/cc/EntryControlCC.d.ts +231 -0
- package/build/cjs/cc/EntryControlCC.js +593 -0
- package/build/cjs/cc/EntryControlCC.js.map +7 -0
- package/build/cjs/cc/FirmwareUpdateMetaDataCC.d.ts +359 -0
- package/build/cjs/cc/FirmwareUpdateMetaDataCC.js +1122 -0
- package/build/cjs/cc/FirmwareUpdateMetaDataCC.js.map +7 -0
- package/build/cjs/cc/HailCC.d.ts +6 -0
- package/build/cjs/cc/HailCC.js +45 -0
- package/build/cjs/cc/HailCC.js.map +7 -0
- package/build/cjs/cc/HumidityControlModeCC.d.ts +111 -0
- package/build/cjs/cc/HumidityControlModeCC.js +323 -0
- package/build/cjs/cc/HumidityControlModeCC.js.map +7 -0
- package/build/cjs/cc/HumidityControlOperatingStateCC.d.ts +60 -0
- package/build/cjs/cc/HumidityControlOperatingStateCC.js +164 -0
- package/build/cjs/cc/HumidityControlOperatingStateCC.js.map +7 -0
- package/build/cjs/cc/HumidityControlSetpointCC.d.ts +209 -0
- package/build/cjs/cc/HumidityControlSetpointCC.js +634 -0
- package/build/cjs/cc/HumidityControlSetpointCC.js.map +7 -0
- package/build/cjs/cc/InclusionControllerCC.d.ts +42 -0
- package/build/cjs/cc/InclusionControllerCC.js +160 -0
- package/build/cjs/cc/InclusionControllerCC.js.map +7 -0
- package/build/cjs/cc/IndicatorCC.d.ts +338 -0
- package/build/cjs/cc/IndicatorCC.js +1234 -0
- package/build/cjs/cc/IndicatorCC.js.map +7 -0
- package/build/cjs/cc/IrrigationCC.d.ts +1496 -0
- package/build/cjs/cc/IrrigationCC.js +1978 -0
- package/build/cjs/cc/IrrigationCC.js.map +7 -0
- package/build/cjs/cc/LanguageCC.d.ts +101 -0
- package/build/cjs/cc/LanguageCC.js +267 -0
- package/build/cjs/cc/LanguageCC.js.map +7 -0
- package/build/cjs/cc/LockCC.d.ts +73 -0
- package/build/cjs/cc/LockCC.js +222 -0
- package/build/cjs/cc/LockCC.js.map +7 -0
- package/build/cjs/cc/ManufacturerProprietaryCC.d.ts +32 -0
- package/build/cjs/cc/ManufacturerProprietaryCC.js +209 -0
- package/build/cjs/cc/ManufacturerProprietaryCC.js.map +7 -0
- package/build/cjs/cc/ManufacturerSpecificCC.d.ts +171 -0
- package/build/cjs/cc/ManufacturerSpecificCC.js +334 -0
- package/build/cjs/cc/ManufacturerSpecificCC.js.map +7 -0
- package/build/cjs/cc/MeterCC.d.ts +318 -0
- package/build/cjs/cc/MeterCC.js +1235 -0
- package/build/cjs/cc/MeterCC.js.map +7 -0
- package/build/cjs/cc/MultiChannelAssociationCC.d.ts +241 -0
- package/build/cjs/cc/MultiChannelAssociationCC.js +956 -0
- package/build/cjs/cc/MultiChannelAssociationCC.js.map +7 -0
- package/build/cjs/cc/MultiChannelCC.d.ts +394 -0
- package/build/cjs/cc/MultiChannelCC.js +1050 -0
- package/build/cjs/cc/MultiChannelCC.js.map +7 -0
- package/build/cjs/cc/MultiCommandCC.d.ts +27 -0
- package/build/cjs/cc/MultiCommandCC.js +159 -0
- package/build/cjs/cc/MultiCommandCC.js.map +7 -0
- package/build/cjs/cc/MultilevelSensorCC.d.ts +185 -0
- package/build/cjs/cc/MultilevelSensorCC.js +716 -0
- package/build/cjs/cc/MultilevelSensorCC.js.map +7 -0
- package/build/cjs/cc/MultilevelSwitchCC.d.ts +357 -0
- package/build/cjs/cc/MultilevelSwitchCC.js +780 -0
- package/build/cjs/cc/MultilevelSwitchCC.js.map +7 -0
- package/build/cjs/cc/NoOperationCC.d.ts +9 -0
- package/build/cjs/cc/NoOperationCC.js +64 -0
- package/build/cjs/cc/NoOperationCC.js.map +7 -0
- package/build/cjs/cc/NodeNamingCC.d.ts +118 -0
- package/build/cjs/cc/NodeNamingCC.js +364 -0
- package/build/cjs/cc/NodeNamingCC.js.map +7 -0
- package/build/cjs/cc/NotificationCC.d.ts +479 -0
- package/build/cjs/cc/NotificationCC.js +1245 -0
- package/build/cjs/cc/NotificationCC.js.map +7 -0
- package/build/cjs/cc/PowerlevelCC.d.ts +82 -0
- package/build/cjs/cc/PowerlevelCC.js +510 -0
- package/build/cjs/cc/PowerlevelCC.js.map +7 -0
- package/build/cjs/cc/ProtectionCC.d.ts +325 -0
- package/build/cjs/cc/ProtectionCC.js +667 -0
- package/build/cjs/cc/ProtectionCC.js.map +7 -0
- package/build/cjs/cc/SceneActivationCC.d.ts +89 -0
- package/build/cjs/cc/SceneActivationCC.js +193 -0
- package/build/cjs/cc/SceneActivationCC.js.map +7 -0
- package/build/cjs/cc/SceneActuatorConfigurationCC.d.ts +120 -0
- package/build/cjs/cc/SceneActuatorConfigurationCC.js +370 -0
- package/build/cjs/cc/SceneActuatorConfigurationCC.js.map +7 -0
- package/build/cjs/cc/SceneControllerConfigurationCC.d.ts +129 -0
- package/build/cjs/cc/SceneControllerConfigurationCC.js +423 -0
- package/build/cjs/cc/SceneControllerConfigurationCC.js.map +7 -0
- package/build/cjs/cc/ScheduleEntryLockCC.d.ts +434 -0
- package/build/cjs/cc/ScheduleEntryLockCC.js +1763 -0
- package/build/cjs/cc/ScheduleEntryLockCC.js.map +7 -0
- package/build/cjs/cc/Security2CC.d.ts +251 -0
- package/build/cjs/cc/Security2CC.js +1589 -0
- package/build/cjs/cc/Security2CC.js.map +7 -0
- package/build/cjs/cc/SecurityCC.d.ts +128 -0
- package/build/cjs/cc/SecurityCC.js +757 -0
- package/build/cjs/cc/SecurityCC.js.map +7 -0
- package/build/cjs/cc/SoundSwitchCC.d.ts +232 -0
- package/build/cjs/cc/SoundSwitchCC.js +661 -0
- package/build/cjs/cc/SoundSwitchCC.js.map +7 -0
- package/build/cjs/cc/SupervisionCC.d.ts +104 -0
- package/build/cjs/cc/SupervisionCC.js +308 -0
- package/build/cjs/cc/SupervisionCC.js.map +7 -0
- package/build/cjs/cc/ThermostatFanModeCC.d.ts +141 -0
- package/build/cjs/cc/ThermostatFanModeCC.js +372 -0
- package/build/cjs/cc/ThermostatFanModeCC.js.map +7 -0
- package/build/cjs/cc/ThermostatFanStateCC.d.ts +60 -0
- package/build/cjs/cc/ThermostatFanStateCC.js +166 -0
- package/build/cjs/cc/ThermostatFanStateCC.js.map +7 -0
- package/build/cjs/cc/ThermostatModeCC.d.ts +150 -0
- package/build/cjs/cc/ThermostatModeCC.js +436 -0
- package/build/cjs/cc/ThermostatModeCC.js.map +7 -0
- package/build/cjs/cc/ThermostatOperatingStateCC.d.ts +61 -0
- package/build/cjs/cc/ThermostatOperatingStateCC.js +162 -0
- package/build/cjs/cc/ThermostatOperatingStateCC.js.map +7 -0
- package/build/cjs/cc/ThermostatSetbackCC.d.ts +46 -0
- package/build/cjs/cc/ThermostatSetbackCC.js +262 -0
- package/build/cjs/cc/ThermostatSetbackCC.js.map +7 -0
- package/build/cjs/cc/ThermostatSetpointCC.d.ts +197 -0
- package/build/cjs/cc/ThermostatSetpointCC.js +638 -0
- package/build/cjs/cc/ThermostatSetpointCC.js.map +7 -0
- package/build/cjs/cc/TimeCC.d.ts +88 -0
- package/build/cjs/cc/TimeCC.js +473 -0
- package/build/cjs/cc/TimeCC.js.map +7 -0
- package/build/cjs/cc/TimeParametersCC.d.ts +72 -0
- package/build/cjs/cc/TimeParametersCC.js +313 -0
- package/build/cjs/cc/TimeParametersCC.js.map +7 -0
- package/build/cjs/cc/TransportServiceCC.d.ts +107 -0
- package/build/cjs/cc/TransportServiceCC.js +404 -0
- package/build/cjs/cc/TransportServiceCC.js.map +7 -0
- package/build/cjs/cc/UserCodeCC.d.ts +683 -0
- package/build/cjs/cc/UserCodeCC.js +1620 -0
- package/build/cjs/cc/UserCodeCC.js.map +7 -0
- package/build/cjs/cc/VersionCC.d.ts +469 -0
- package/build/cjs/cc/VersionCC.js +828 -0
- package/build/cjs/cc/VersionCC.js.map +7 -0
- package/build/cjs/cc/WakeUpCC.d.ts +150 -0
- package/build/cjs/cc/WakeUpCC.js +456 -0
- package/build/cjs/cc/WakeUpCC.js.map +7 -0
- package/build/cjs/cc/WindowCoveringCC.d.ts +315 -0
- package/build/cjs/cc/WindowCoveringCC.js +776 -0
- package/build/cjs/cc/WindowCoveringCC.js.map +7 -0
- package/build/cjs/cc/ZWaveLongRangeCC.d.ts +4 -0
- package/build/cjs/cc/ZWaveLongRangeCC.js +43 -0
- package/build/cjs/cc/ZWaveLongRangeCC.js.map +7 -0
- package/build/cjs/cc/ZWavePlusCC.d.ts +163 -0
- package/build/cjs/cc/ZWavePlusCC.js +288 -0
- package/build/cjs/cc/ZWavePlusCC.js.map +7 -0
- package/build/cjs/cc/ZWaveProtocolCC.d.ts +344 -0
- package/build/cjs/cc/ZWaveProtocolCC.js +1071 -0
- package/build/cjs/cc/ZWaveProtocolCC.js.map +7 -0
- package/build/cjs/cc/index.d.ts +132 -0
- package/build/cjs/cc/index.js +1180 -0
- package/build/cjs/cc/index.js.map +7 -0
- package/build/cjs/cc/manufacturerProprietary/Decorators.d.ts +64 -0
- package/build/cjs/cc/manufacturerProprietary/Decorators.js +76 -0
- package/build/cjs/cc/manufacturerProprietary/Decorators.js.map +7 -0
- package/build/cjs/cc/manufacturerProprietary/FibaroCC.d.ts +79 -0
- package/build/cjs/cc/manufacturerProprietary/FibaroCC.js +412 -0
- package/build/cjs/cc/manufacturerProprietary/FibaroCC.js.map +7 -0
- package/build/cjs/index.d.ts +15 -0
- package/build/cjs/index.js +77 -0
- package/build/cjs/index.js.map +7 -0
- package/build/cjs/index_safe.d.ts +3 -0
- package/build/cjs/index_safe.js +25 -0
- package/build/cjs/index_safe.js.map +7 -0
- package/build/cjs/lib/API.d.ts +271 -0
- package/build/cjs/lib/API.js +413 -0
- package/build/cjs/lib/API.js.map +7 -0
- package/build/cjs/lib/CommandClass.d.ts +234 -0
- package/build/cjs/lib/CommandClass.js +692 -0
- package/build/cjs/lib/CommandClass.js.map +7 -0
- package/build/cjs/lib/CommandClassDecorators.d.ts +112 -0
- package/build/cjs/lib/CommandClassDecorators.js +182 -0
- package/build/cjs/lib/CommandClassDecorators.js.map +7 -0
- package/build/cjs/lib/EncapsulatingCommandClass.d.ts +22 -0
- package/build/cjs/lib/EncapsulatingCommandClass.js +71 -0
- package/build/cjs/lib/EncapsulatingCommandClass.js.map +7 -0
- package/build/cjs/lib/ICommandClassContainer.js +17 -0
- package/build/cjs/lib/ICommandClassContainer.js.map +7 -0
- package/build/cjs/lib/NotificationEventPayload.d.ts +10 -0
- package/build/cjs/lib/NotificationEventPayload.js +31 -0
- package/build/cjs/lib/NotificationEventPayload.js.map +7 -0
- package/build/cjs/lib/Security2/Extension.js +333 -0
- package/build/cjs/lib/Security2/Extension.js.map +7 -0
- package/build/cjs/lib/Security2/shared.js +69 -0
- package/build/cjs/lib/Security2/shared.js.map +7 -0
- package/build/cjs/lib/SetValueResult.js +65 -0
- package/build/cjs/lib/SetValueResult.js.map +7 -0
- package/build/cjs/lib/Values.d.ts +223 -0
- package/build/cjs/lib/Values.js +191 -0
- package/build/cjs/lib/Values.js.map +7 -0
- package/build/cjs/lib/_Types.js +1676 -0
- package/build/cjs/lib/_Types.js.map +7 -0
- package/build/cjs/lib/serializers.d.ts +34 -0
- package/build/cjs/lib/serializers.js +110 -0
- package/build/cjs/lib/serializers.js.map +7 -0
- package/build/cjs/lib/utils.d.ts +17 -0
- package/build/cjs/lib/utils.js +678 -0
- package/build/cjs/lib/utils.js.map +7 -0
- package/build/cjs/package.json +3 -0
- package/build/esm/cc/AlarmSensorCC.d.ts +194 -0
- package/build/esm/cc/AlarmSensorCC.d.ts.map +1 -0
- package/build/esm/cc/AlarmSensorCC.js +392 -0
- package/build/esm/cc/AlarmSensorCC.js.map +1 -0
- package/build/esm/cc/AssociationCC.d.ts +253 -0
- package/build/esm/cc/AssociationCC.d.ts.map +1 -0
- package/build/esm/cc/AssociationCC.js +706 -0
- package/build/esm/cc/AssociationCC.js.map +1 -0
- package/build/esm/cc/AssociationGroupInfoCC.d.ts +230 -0
- package/build/esm/cc/AssociationGroupInfoCC.d.ts.map +1 -0
- package/build/esm/cc/AssociationGroupInfoCC.js +769 -0
- package/build/esm/cc/AssociationGroupInfoCC.js.map +1 -0
- package/build/esm/cc/BarrierOperatorCC.d.ts +243 -0
- package/build/esm/cc/BarrierOperatorCC.d.ts.map +1 -0
- package/build/esm/cc/BarrierOperatorCC.js +610 -0
- package/build/esm/cc/BarrierOperatorCC.js.map +1 -0
- package/build/esm/cc/BasicCC.d.ts +191 -0
- package/build/esm/cc/BasicCC.d.ts.map +1 -0
- package/build/esm/cc/BasicCC.js +390 -0
- package/build/esm/cc/BasicCC.js.map +1 -0
- package/build/esm/cc/BatteryCC.d.ts +406 -0
- package/build/esm/cc/BatteryCC.d.ts.map +1 -0
- package/build/esm/cc/BatteryCC.js +513 -0
- package/build/esm/cc/BatteryCC.js.map +1 -0
- package/build/esm/cc/BinarySensorCC.d.ts +122 -0
- package/build/esm/cc/BinarySensorCC.d.ts.map +1 -0
- package/build/esm/cc/BinarySensorCC.js +417 -0
- package/build/esm/cc/BinarySensorCC.js.map +1 -0
- package/build/esm/cc/BinarySwitchCC.d.ts +139 -0
- package/build/esm/cc/BinarySwitchCC.d.ts.map +1 -0
- package/build/esm/cc/BinarySwitchCC.js +362 -0
- package/build/esm/cc/BinarySwitchCC.js.map +1 -0
- package/build/esm/cc/CRC16CC.d.ts +29 -0
- package/build/esm/cc/CRC16CC.d.ts.map +1 -0
- package/build/esm/cc/CRC16CC.js +123 -0
- package/build/esm/cc/CRC16CC.js.map +1 -0
- package/build/esm/cc/CentralSceneCC.d.ts +210 -0
- package/build/esm/cc/CentralSceneCC.d.ts.map +1 -0
- package/build/esm/cc/CentralSceneCC.js +427 -0
- package/build/esm/cc/CentralSceneCC.js.map +1 -0
- package/build/esm/cc/ClimateControlScheduleCC.d.ts +177 -0
- package/build/esm/cc/ClimateControlScheduleCC.d.ts.map +1 -0
- package/build/esm/cc/ClimateControlScheduleCC.js +466 -0
- package/build/esm/cc/ClimateControlScheduleCC.js.map +1 -0
- package/build/esm/cc/ClockCC.d.ts +47 -0
- package/build/esm/cc/ClockCC.d.ts.map +1 -0
- package/build/esm/cc/ClockCC.js +205 -0
- package/build/esm/cc/ClockCC.js.map +1 -0
- package/build/esm/cc/ColorSwitchCC.d.ts +339 -0
- package/build/esm/cc/ColorSwitchCC.d.ts.map +1 -0
- package/build/esm/cc/ColorSwitchCC.js +1149 -0
- package/build/esm/cc/ColorSwitchCC.js.map +1 -0
- package/build/esm/cc/ConfigurationCC.d.ts +396 -0
- package/build/esm/cc/ConfigurationCC.d.ts.map +1 -0
- package/build/esm/cc/ConfigurationCC.js +2454 -0
- package/build/esm/cc/ConfigurationCC.js.map +1 -0
- package/build/esm/cc/DeviceResetLocallyCC.d.ts +17 -0
- package/build/esm/cc/DeviceResetLocallyCC.d.ts.map +1 -0
- package/build/esm/cc/DeviceResetLocallyCC.js +73 -0
- package/build/esm/cc/DeviceResetLocallyCC.js.map +1 -0
- package/build/esm/cc/DoorLockCC.d.ts +837 -0
- package/build/esm/cc/DoorLockCC.d.ts.map +1 -0
- package/build/esm/cc/DoorLockCC.js +1270 -0
- package/build/esm/cc/DoorLockCC.js.map +1 -0
- package/build/esm/cc/DoorLockLoggingCC.d.ts +77 -0
- package/build/esm/cc/DoorLockLoggingCC.d.ts.map +1 -0
- package/build/esm/cc/DoorLockLoggingCC.js +316 -0
- package/build/esm/cc/DoorLockLoggingCC.js.map +1 -0
- package/build/esm/cc/EnergyProductionCC.d.ts +77 -0
- package/build/esm/cc/EnergyProductionCC.d.ts.map +1 -0
- package/build/esm/cc/EnergyProductionCC.js +213 -0
- package/build/esm/cc/EnergyProductionCC.js.map +1 -0
- package/build/esm/cc/EntryControlCC.d.ts +231 -0
- package/build/esm/cc/EntryControlCC.d.ts.map +1 -0
- package/build/esm/cc/EntryControlCC.js +581 -0
- package/build/esm/cc/EntryControlCC.js.map +1 -0
- package/build/esm/cc/FirmwareUpdateMetaDataCC.d.ts +359 -0
- package/build/esm/cc/FirmwareUpdateMetaDataCC.d.ts.map +1 -0
- package/build/esm/cc/FirmwareUpdateMetaDataCC.js +1142 -0
- package/build/esm/cc/FirmwareUpdateMetaDataCC.js.map +1 -0
- package/build/esm/cc/HailCC.d.ts +6 -0
- package/build/esm/cc/HailCC.d.ts.map +1 -0
- package/build/esm/cc/HailCC.js +21 -0
- package/build/esm/cc/HailCC.js.map +1 -0
- package/build/esm/cc/HumidityControlModeCC.d.ts +111 -0
- package/build/esm/cc/HumidityControlModeCC.d.ts.map +1 -0
- package/build/esm/cc/HumidityControlModeCC.js +305 -0
- package/build/esm/cc/HumidityControlModeCC.js.map +1 -0
- package/build/esm/cc/HumidityControlOperatingStateCC.d.ts +60 -0
- package/build/esm/cc/HumidityControlOperatingStateCC.d.ts.map +1 -0
- package/build/esm/cc/HumidityControlOperatingStateCC.js +137 -0
- package/build/esm/cc/HumidityControlOperatingStateCC.js.map +1 -0
- package/build/esm/cc/HumidityControlSetpointCC.d.ts +209 -0
- package/build/esm/cc/HumidityControlSetpointCC.d.ts.map +1 -0
- package/build/esm/cc/HumidityControlSetpointCC.js +645 -0
- package/build/esm/cc/HumidityControlSetpointCC.js.map +1 -0
- package/build/esm/cc/InclusionControllerCC.d.ts +42 -0
- package/build/esm/cc/InclusionControllerCC.d.ts.map +1 -0
- package/build/esm/cc/InclusionControllerCC.js +133 -0
- package/build/esm/cc/InclusionControllerCC.js.map +1 -0
- package/build/esm/cc/IndicatorCC.d.ts +338 -0
- package/build/esm/cc/IndicatorCC.d.ts.map +1 -0
- package/build/esm/cc/IndicatorCC.js +1317 -0
- package/build/esm/cc/IndicatorCC.js.map +1 -0
- package/build/esm/cc/IrrigationCC.d.ts +1496 -0
- package/build/esm/cc/IrrigationCC.d.ts.map +1 -0
- package/build/esm/cc/IrrigationCC.js +2038 -0
- package/build/esm/cc/IrrigationCC.js.map +1 -0
- package/build/esm/cc/LanguageCC.d.ts +101 -0
- package/build/esm/cc/LanguageCC.d.ts.map +1 -0
- package/build/esm/cc/LanguageCC.js +243 -0
- package/build/esm/cc/LanguageCC.js.map +1 -0
- package/build/esm/cc/LockCC.d.ts +73 -0
- package/build/esm/cc/LockCC.d.ts.map +1 -0
- package/build/esm/cc/LockCC.js +197 -0
- package/build/esm/cc/LockCC.js.map +1 -0
- package/build/esm/cc/ManufacturerProprietaryCC.d.ts +32 -0
- package/build/esm/cc/ManufacturerProprietaryCC.d.ts.map +1 -0
- package/build/esm/cc/ManufacturerProprietaryCC.js +201 -0
- package/build/esm/cc/ManufacturerProprietaryCC.js.map +1 -0
- package/build/esm/cc/ManufacturerSpecificCC.d.ts +171 -0
- package/build/esm/cc/ManufacturerSpecificCC.d.ts.map +1 -0
- package/build/esm/cc/ManufacturerSpecificCC.js +315 -0
- package/build/esm/cc/ManufacturerSpecificCC.js.map +1 -0
- package/build/esm/cc/MeterCC.d.ts +318 -0
- package/build/esm/cc/MeterCC.d.ts.map +1 -0
- package/build/esm/cc/MeterCC.js +1308 -0
- package/build/esm/cc/MeterCC.js.map +1 -0
- package/build/esm/cc/MultiChannelAssociationCC.d.ts +241 -0
- package/build/esm/cc/MultiChannelAssociationCC.d.ts.map +1 -0
- package/build/esm/cc/MultiChannelAssociationCC.js +981 -0
- package/build/esm/cc/MultiChannelAssociationCC.js.map +1 -0
- package/build/esm/cc/MultiChannelCC.d.ts +394 -0
- package/build/esm/cc/MultiChannelCC.d.ts.map +1 -0
- package/build/esm/cc/MultiChannelCC.js +1127 -0
- package/build/esm/cc/MultiChannelCC.js.map +1 -0
- package/build/esm/cc/MultiCommandCC.d.ts +27 -0
- package/build/esm/cc/MultiCommandCC.d.ts.map +1 -0
- package/build/esm/cc/MultiCommandCC.js +142 -0
- package/build/esm/cc/MultiCommandCC.js.map +1 -0
- package/build/esm/cc/MultilevelSensorCC.d.ts +185 -0
- package/build/esm/cc/MultilevelSensorCC.d.ts.map +1 -0
- package/build/esm/cc/MultilevelSensorCC.js +753 -0
- package/build/esm/cc/MultilevelSensorCC.js.map +1 -0
- package/build/esm/cc/MultilevelSwitchCC.d.ts +357 -0
- package/build/esm/cc/MultilevelSwitchCC.d.ts.map +1 -0
- package/build/esm/cc/MultilevelSwitchCC.js +810 -0
- package/build/esm/cc/MultilevelSwitchCC.js.map +1 -0
- package/build/esm/cc/NoOperationCC.d.ts +9 -0
- package/build/esm/cc/NoOperationCC.d.ts.map +1 -0
- package/build/esm/cc/NoOperationCC.js +39 -0
- package/build/esm/cc/NoOperationCC.js.map +1 -0
- package/build/esm/cc/NodeNamingCC.d.ts +118 -0
- package/build/esm/cc/NodeNamingCC.d.ts.map +1 -0
- package/build/esm/cc/NodeNamingCC.js +345 -0
- package/build/esm/cc/NodeNamingCC.js.map +1 -0
- package/build/esm/cc/NotificationCC.d.ts +479 -0
- package/build/esm/cc/NotificationCC.d.ts.map +1 -0
- package/build/esm/cc/NotificationCC.js +1350 -0
- package/build/esm/cc/NotificationCC.js.map +1 -0
- package/build/esm/cc/PowerlevelCC.d.ts +82 -0
- package/build/esm/cc/PowerlevelCC.d.ts.map +1 -0
- package/build/esm/cc/PowerlevelCC.js +485 -0
- package/build/esm/cc/PowerlevelCC.js.map +1 -0
- package/build/esm/cc/ProtectionCC.d.ts +325 -0
- package/build/esm/cc/ProtectionCC.d.ts.map +1 -0
- package/build/esm/cc/ProtectionCC.js +669 -0
- package/build/esm/cc/ProtectionCC.js.map +1 -0
- package/build/esm/cc/SceneActivationCC.d.ts +89 -0
- package/build/esm/cc/SceneActivationCC.d.ts.map +1 -0
- package/build/esm/cc/SceneActivationCC.js +166 -0
- package/build/esm/cc/SceneActivationCC.js.map +1 -0
- package/build/esm/cc/SceneActuatorConfigurationCC.d.ts +120 -0
- package/build/esm/cc/SceneActuatorConfigurationCC.d.ts.map +1 -0
- package/build/esm/cc/SceneActuatorConfigurationCC.js +374 -0
- package/build/esm/cc/SceneActuatorConfigurationCC.js.map +1 -0
- package/build/esm/cc/SceneControllerConfigurationCC.d.ts +129 -0
- package/build/esm/cc/SceneControllerConfigurationCC.d.ts.map +1 -0
- package/build/esm/cc/SceneControllerConfigurationCC.js +446 -0
- package/build/esm/cc/SceneControllerConfigurationCC.js.map +1 -0
- package/build/esm/cc/ScheduleEntryLockCC.d.ts +434 -0
- package/build/esm/cc/ScheduleEntryLockCC.d.ts.map +1 -0
- package/build/esm/cc/ScheduleEntryLockCC.js +1826 -0
- package/build/esm/cc/ScheduleEntryLockCC.js.map +1 -0
- package/build/esm/cc/Security2CC.d.ts +251 -0
- package/build/esm/cc/Security2CC.d.ts.map +1 -0
- package/build/esm/cc/Security2CC.js +1814 -0
- package/build/esm/cc/Security2CC.js.map +1 -0
- package/build/esm/cc/SecurityCC.d.ts +128 -0
- package/build/esm/cc/SecurityCC.d.ts.map +1 -0
- package/build/esm/cc/SecurityCC.js +800 -0
- package/build/esm/cc/SecurityCC.js.map +1 -0
- package/build/esm/cc/SoundSwitchCC.d.ts +232 -0
- package/build/esm/cc/SoundSwitchCC.d.ts.map +1 -0
- package/build/esm/cc/SoundSwitchCC.js +633 -0
- package/build/esm/cc/SoundSwitchCC.js.map +1 -0
- package/build/esm/cc/SupervisionCC.d.ts +104 -0
- package/build/esm/cc/SupervisionCC.d.ts.map +1 -0
- package/build/esm/cc/SupervisionCC.js +319 -0
- package/build/esm/cc/SupervisionCC.js.map +1 -0
- package/build/esm/cc/ThermostatFanModeCC.d.ts +141 -0
- package/build/esm/cc/ThermostatFanModeCC.d.ts.map +1 -0
- package/build/esm/cc/ThermostatFanModeCC.js +359 -0
- package/build/esm/cc/ThermostatFanModeCC.js.map +1 -0
- package/build/esm/cc/ThermostatFanStateCC.d.ts +60 -0
- package/build/esm/cc/ThermostatFanStateCC.d.ts.map +1 -0
- package/build/esm/cc/ThermostatFanStateCC.js +139 -0
- package/build/esm/cc/ThermostatFanStateCC.js.map +1 -0
- package/build/esm/cc/ThermostatModeCC.d.ts +150 -0
- package/build/esm/cc/ThermostatModeCC.d.ts.map +1 -0
- package/build/esm/cc/ThermostatModeCC.js +426 -0
- package/build/esm/cc/ThermostatModeCC.js.map +1 -0
- package/build/esm/cc/ThermostatOperatingStateCC.d.ts +61 -0
- package/build/esm/cc/ThermostatOperatingStateCC.d.ts.map +1 -0
- package/build/esm/cc/ThermostatOperatingStateCC.js +135 -0
- package/build/esm/cc/ThermostatOperatingStateCC.js.map +1 -0
- package/build/esm/cc/ThermostatSetbackCC.d.ts +46 -0
- package/build/esm/cc/ThermostatSetbackCC.d.ts.map +1 -0
- package/build/esm/cc/ThermostatSetbackCC.js +244 -0
- package/build/esm/cc/ThermostatSetbackCC.js.map +1 -0
- package/build/esm/cc/ThermostatSetpointCC.d.ts +197 -0
- package/build/esm/cc/ThermostatSetpointCC.d.ts.map +1 -0
- package/build/esm/cc/ThermostatSetpointCC.js +655 -0
- package/build/esm/cc/ThermostatSetpointCC.js.map +1 -0
- package/build/esm/cc/TimeCC.d.ts +88 -0
- package/build/esm/cc/TimeCC.d.ts.map +1 -0
- package/build/esm/cc/TimeCC.js +451 -0
- package/build/esm/cc/TimeCC.js.map +1 -0
- package/build/esm/cc/TimeParametersCC.d.ts +72 -0
- package/build/esm/cc/TimeParametersCC.d.ts.map +1 -0
- package/build/esm/cc/TimeParametersCC.js +300 -0
- package/build/esm/cc/TimeParametersCC.js.map +1 -0
- package/build/esm/cc/TransportServiceCC.d.ts +107 -0
- package/build/esm/cc/TransportServiceCC.d.ts.map +1 -0
- package/build/esm/cc/TransportServiceCC.js +422 -0
- package/build/esm/cc/TransportServiceCC.js.map +1 -0
- package/build/esm/cc/UserCodeCC.d.ts +683 -0
- package/build/esm/cc/UserCodeCC.d.ts.map +1 -0
- package/build/esm/cc/UserCodeCC.js +1695 -0
- package/build/esm/cc/UserCodeCC.js.map +1 -0
- package/build/esm/cc/VersionCC.d.ts +469 -0
- package/build/esm/cc/VersionCC.d.ts.map +1 -0
- package/build/esm/cc/VersionCC.js +862 -0
- package/build/esm/cc/VersionCC.js.map +1 -0
- package/build/esm/cc/WakeUpCC.d.ts +150 -0
- package/build/esm/cc/WakeUpCC.d.ts.map +1 -0
- package/build/esm/cc/WakeUpCC.js +438 -0
- package/build/esm/cc/WakeUpCC.js.map +1 -0
- package/build/esm/cc/WindowCoveringCC.d.ts +315 -0
- package/build/esm/cc/WindowCoveringCC.d.ts.map +1 -0
- package/build/esm/cc/WindowCoveringCC.js +780 -0
- package/build/esm/cc/WindowCoveringCC.js.map +1 -0
- package/build/esm/cc/ZWaveLongRangeCC.d.ts +4 -0
- package/build/esm/cc/ZWaveLongRangeCC.d.ts.map +1 -0
- package/build/esm/cc/ZWaveLongRangeCC.js +17 -0
- package/build/esm/cc/ZWaveLongRangeCC.js.map +1 -0
- package/build/esm/cc/ZWavePlusCC.d.ts +163 -0
- package/build/esm/cc/ZWavePlusCC.d.ts.map +1 -0
- package/build/esm/cc/ZWavePlusCC.js +267 -0
- package/build/esm/cc/ZWavePlusCC.js.map +1 -0
- package/build/esm/cc/ZWaveProtocolCC.d.ts +344 -0
- package/build/esm/cc/ZWaveProtocolCC.d.ts.map +1 -0
- package/build/esm/cc/ZWaveProtocolCC.js +1030 -0
- package/build/esm/cc/ZWaveProtocolCC.js.map +1 -0
- package/build/esm/cc/index.d.ts +132 -0
- package/build/esm/cc/index.d.ts.map +1 -0
- package/build/esm/cc/index.js +71 -0
- package/build/esm/cc/index.js.map +1 -0
- package/build/esm/cc/manufacturerProprietary/Decorators.d.ts +64 -0
- package/build/esm/cc/manufacturerProprietary/Decorators.d.ts.map +1 -0
- package/build/esm/cc/manufacturerProprietary/Decorators.js +79 -0
- package/build/esm/cc/manufacturerProprietary/Decorators.js.map +1 -0
- package/build/esm/cc/manufacturerProprietary/FibaroCC.d.ts +79 -0
- package/build/esm/cc/manufacturerProprietary/FibaroCC.d.ts.map +1 -0
- package/build/esm/cc/manufacturerProprietary/FibaroCC.js +385 -0
- package/build/esm/cc/manufacturerProprietary/FibaroCC.js.map +1 -0
- package/build/esm/index.d.ts +15 -0
- package/build/esm/index.d.ts.map +1 -0
- package/build/esm/index.js +14 -0
- package/build/esm/index.js.map +1 -0
- package/build/esm/index_safe.d.ts +3 -0
- package/build/esm/index_safe.d.ts.map +1 -0
- package/build/esm/index_safe.js +4 -0
- package/build/esm/index_safe.js.map +1 -0
- package/build/esm/lib/API.d.ts +271 -0
- package/build/esm/lib/API.d.ts.map +1 -0
- package/build/esm/lib/API.js +448 -0
- package/build/esm/lib/API.js.map +1 -0
- package/build/esm/lib/CommandClass.d.ts +234 -0
- package/build/esm/lib/CommandClass.d.ts.map +1 -0
- package/build/esm/lib/CommandClass.js +781 -0
- package/build/esm/lib/CommandClass.js.map +1 -0
- package/build/esm/lib/CommandClassDecorators.d.ts +112 -0
- package/build/esm/lib/CommandClassDecorators.d.ts.map +1 -0
- package/build/esm/lib/CommandClassDecorators.js +229 -0
- package/build/esm/lib/CommandClassDecorators.js.map +1 -0
- package/build/esm/lib/EncapsulatingCommandClass.d.ts +22 -0
- package/build/esm/lib/EncapsulatingCommandClass.d.ts.map +1 -0
- package/build/esm/lib/EncapsulatingCommandClass.js +56 -0
- package/build/esm/lib/EncapsulatingCommandClass.js.map +1 -0
- package/build/esm/lib/ICommandClassContainer.d.ts +2 -0
- package/build/esm/lib/ICommandClassContainer.d.ts.map +1 -0
- package/build/esm/lib/ICommandClassContainer.js +2 -0
- package/build/esm/lib/ICommandClassContainer.js.map +1 -0
- package/build/esm/lib/NotificationEventPayload.d.ts +10 -0
- package/build/esm/lib/NotificationEventPayload.d.ts.map +1 -0
- package/build/esm/lib/NotificationEventPayload.js +7 -0
- package/build/esm/lib/NotificationEventPayload.js.map +1 -0
- package/build/esm/lib/Security2/Extension.d.ts +106 -0
- package/build/esm/lib/Security2/Extension.d.ts.map +1 -0
- package/build/esm/lib/Security2/Extension.js +296 -0
- package/build/esm/lib/Security2/Extension.js.map +1 -0
- package/build/esm/lib/Security2/shared.d.ts +37 -0
- package/build/esm/lib/Security2/shared.d.ts.map +1 -0
- package/build/esm/lib/Security2/shared.js +40 -0
- package/build/esm/lib/Security2/shared.js.map +1 -0
- package/build/esm/lib/SetValueResult.d.ts +55 -0
- package/build/esm/lib/SetValueResult.d.ts.map +1 -0
- package/build/esm/lib/SetValueResult.js +53 -0
- package/build/esm/lib/SetValueResult.js.map +1 -0
- package/build/esm/lib/Values.d.ts +223 -0
- package/build/esm/lib/Values.d.ts.map +1 -0
- package/build/esm/lib/Values.js +169 -0
- package/build/esm/lib/Values.js.map +1 -0
- package/build/esm/lib/_Types.d.ts +1461 -0
- package/build/esm/lib/_Types.d.ts.map +1 -0
- package/build/esm/lib/_Types.js +1432 -0
- package/build/esm/lib/_Types.js.map +1 -0
- package/build/esm/lib/serializers.d.ts +34 -0
- package/build/esm/lib/serializers.d.ts.map +1 -0
- package/build/esm/lib/serializers.js +98 -0
- package/build/esm/lib/serializers.js.map +1 -0
- package/build/esm/lib/utils.d.ts +17 -0
- package/build/esm/lib/utils.d.ts.map +1 -0
- package/build/esm/lib/utils.js +847 -0
- package/build/esm/lib/utils.js.map +1 -0
- package/build/esm/package.json +3 -0
- package/package.json +28 -23
- package/build/cc/AlarmSensorCC.d.ts +0 -194
- package/build/cc/AlarmSensorCC.d.ts.map +0 -1
- package/build/cc/AlarmSensorCC.js +0 -395
- package/build/cc/AlarmSensorCC.js.map +0 -1
- package/build/cc/AssociationCC.d.ts +0 -253
- package/build/cc/AssociationCC.d.ts.map +0 -1
- package/build/cc/AssociationCC.js +0 -732
- package/build/cc/AssociationCC.js.map +0 -1
- package/build/cc/AssociationGroupInfoCC.d.ts +0 -230
- package/build/cc/AssociationGroupInfoCC.d.ts.map +0 -1
- package/build/cc/AssociationGroupInfoCC.js +0 -772
- package/build/cc/AssociationGroupInfoCC.js.map +0 -1
- package/build/cc/BarrierOperatorCC.d.ts +0 -243
- package/build/cc/BarrierOperatorCC.d.ts.map +0 -1
- package/build/cc/BarrierOperatorCC.js +0 -613
- package/build/cc/BarrierOperatorCC.js.map +0 -1
- package/build/cc/BasicCC.d.ts +0 -191
- package/build/cc/BasicCC.d.ts.map +0 -1
- package/build/cc/BasicCC.js +0 -393
- package/build/cc/BasicCC.js.map +0 -1
- package/build/cc/BatteryCC.d.ts +0 -406
- package/build/cc/BatteryCC.d.ts.map +0 -1
- package/build/cc/BatteryCC.js +0 -516
- package/build/cc/BatteryCC.js.map +0 -1
- package/build/cc/BinarySensorCC.d.ts +0 -122
- package/build/cc/BinarySensorCC.d.ts.map +0 -1
- package/build/cc/BinarySensorCC.js +0 -420
- package/build/cc/BinarySensorCC.js.map +0 -1
- package/build/cc/BinarySwitchCC.d.ts +0 -139
- package/build/cc/BinarySwitchCC.d.ts.map +0 -1
- package/build/cc/BinarySwitchCC.js +0 -365
- package/build/cc/BinarySwitchCC.js.map +0 -1
- package/build/cc/CRC16CC.d.ts +0 -29
- package/build/cc/CRC16CC.d.ts.map +0 -1
- package/build/cc/CRC16CC.js +0 -126
- package/build/cc/CRC16CC.js.map +0 -1
- package/build/cc/CentralSceneCC.d.ts +0 -210
- package/build/cc/CentralSceneCC.d.ts.map +0 -1
- package/build/cc/CentralSceneCC.js +0 -453
- package/build/cc/CentralSceneCC.js.map +0 -1
- package/build/cc/ClimateControlScheduleCC.d.ts +0 -177
- package/build/cc/ClimateControlScheduleCC.d.ts.map +0 -1
- package/build/cc/ClimateControlScheduleCC.js +0 -469
- package/build/cc/ClimateControlScheduleCC.js.map +0 -1
- package/build/cc/ClockCC.d.ts +0 -47
- package/build/cc/ClockCC.d.ts.map +0 -1
- package/build/cc/ClockCC.js +0 -208
- package/build/cc/ClockCC.js.map +0 -1
- package/build/cc/ColorSwitchCC.d.ts +0 -339
- package/build/cc/ColorSwitchCC.d.ts.map +0 -1
- package/build/cc/ColorSwitchCC.js +0 -1152
- package/build/cc/ColorSwitchCC.js.map +0 -1
- package/build/cc/ConfigurationCC.d.ts +0 -396
- package/build/cc/ConfigurationCC.d.ts.map +0 -1
- package/build/cc/ConfigurationCC.js +0 -2458
- package/build/cc/ConfigurationCC.js.map +0 -1
- package/build/cc/DeviceResetLocallyCC.d.ts +0 -17
- package/build/cc/DeviceResetLocallyCC.d.ts.map +0 -1
- package/build/cc/DeviceResetLocallyCC.js +0 -76
- package/build/cc/DeviceResetLocallyCC.js.map +0 -1
- package/build/cc/DoorLockCC.d.ts +0 -837
- package/build/cc/DoorLockCC.d.ts.map +0 -1
- package/build/cc/DoorLockCC.js +0 -1273
- package/build/cc/DoorLockCC.js.map +0 -1
- package/build/cc/DoorLockLoggingCC.d.ts +0 -77
- package/build/cc/DoorLockLoggingCC.d.ts.map +0 -1
- package/build/cc/DoorLockLoggingCC.js +0 -319
- package/build/cc/DoorLockLoggingCC.js.map +0 -1
- package/build/cc/EnergyProductionCC.d.ts +0 -77
- package/build/cc/EnergyProductionCC.d.ts.map +0 -1
- package/build/cc/EnergyProductionCC.js +0 -216
- package/build/cc/EnergyProductionCC.js.map +0 -1
- package/build/cc/EntryControlCC.d.ts +0 -231
- package/build/cc/EntryControlCC.d.ts.map +0 -1
- package/build/cc/EntryControlCC.js +0 -607
- package/build/cc/EntryControlCC.js.map +0 -1
- package/build/cc/FirmwareUpdateMetaDataCC.d.ts +0 -359
- package/build/cc/FirmwareUpdateMetaDataCC.d.ts.map +0 -1
- package/build/cc/FirmwareUpdateMetaDataCC.js +0 -1145
- package/build/cc/FirmwareUpdateMetaDataCC.js.map +0 -1
- package/build/cc/HailCC.d.ts +0 -6
- package/build/cc/HailCC.d.ts.map +0 -1
- package/build/cc/HailCC.js +0 -24
- package/build/cc/HailCC.js.map +0 -1
- package/build/cc/HumidityControlModeCC.d.ts +0 -111
- package/build/cc/HumidityControlModeCC.d.ts.map +0 -1
- package/build/cc/HumidityControlModeCC.js +0 -308
- package/build/cc/HumidityControlModeCC.js.map +0 -1
- package/build/cc/HumidityControlOperatingStateCC.d.ts +0 -60
- package/build/cc/HumidityControlOperatingStateCC.d.ts.map +0 -1
- package/build/cc/HumidityControlOperatingStateCC.js +0 -140
- package/build/cc/HumidityControlOperatingStateCC.js.map +0 -1
- package/build/cc/HumidityControlSetpointCC.d.ts +0 -209
- package/build/cc/HumidityControlSetpointCC.d.ts.map +0 -1
- package/build/cc/HumidityControlSetpointCC.js +0 -648
- package/build/cc/HumidityControlSetpointCC.js.map +0 -1
- package/build/cc/InclusionControllerCC.d.ts +0 -42
- package/build/cc/InclusionControllerCC.d.ts.map +0 -1
- package/build/cc/InclusionControllerCC.js +0 -136
- package/build/cc/InclusionControllerCC.js.map +0 -1
- package/build/cc/IndicatorCC.d.ts +0 -338
- package/build/cc/IndicatorCC.d.ts.map +0 -1
- package/build/cc/IndicatorCC.js +0 -1320
- package/build/cc/IndicatorCC.js.map +0 -1
- package/build/cc/IrrigationCC.d.ts +0 -1496
- package/build/cc/IrrigationCC.d.ts.map +0 -1
- package/build/cc/IrrigationCC.js +0 -2041
- package/build/cc/IrrigationCC.js.map +0 -1
- package/build/cc/LanguageCC.d.ts +0 -101
- package/build/cc/LanguageCC.d.ts.map +0 -1
- package/build/cc/LanguageCC.js +0 -246
- package/build/cc/LanguageCC.js.map +0 -1
- package/build/cc/LockCC.d.ts +0 -73
- package/build/cc/LockCC.d.ts.map +0 -1
- package/build/cc/LockCC.js +0 -200
- package/build/cc/LockCC.js.map +0 -1
- package/build/cc/ManufacturerProprietaryCC.d.ts +0 -32
- package/build/cc/ManufacturerProprietaryCC.d.ts.map +0 -1
- package/build/cc/ManufacturerProprietaryCC.js +0 -204
- package/build/cc/ManufacturerProprietaryCC.js.map +0 -1
- package/build/cc/ManufacturerSpecificCC.d.ts +0 -171
- package/build/cc/ManufacturerSpecificCC.d.ts.map +0 -1
- package/build/cc/ManufacturerSpecificCC.js +0 -318
- package/build/cc/ManufacturerSpecificCC.js.map +0 -1
- package/build/cc/MeterCC.d.ts +0 -318
- package/build/cc/MeterCC.d.ts.map +0 -1
- package/build/cc/MeterCC.js +0 -1312
- package/build/cc/MeterCC.js.map +0 -1
- package/build/cc/MultiChannelAssociationCC.d.ts +0 -241
- package/build/cc/MultiChannelAssociationCC.d.ts.map +0 -1
- package/build/cc/MultiChannelAssociationCC.js +0 -1007
- package/build/cc/MultiChannelAssociationCC.js.map +0 -1
- package/build/cc/MultiChannelCC.d.ts +0 -394
- package/build/cc/MultiChannelCC.d.ts.map +0 -1
- package/build/cc/MultiChannelCC.js +0 -1130
- package/build/cc/MultiChannelCC.js.map +0 -1
- package/build/cc/MultiCommandCC.d.ts +0 -27
- package/build/cc/MultiCommandCC.d.ts.map +0 -1
- package/build/cc/MultiCommandCC.js +0 -145
- package/build/cc/MultiCommandCC.js.map +0 -1
- package/build/cc/MultilevelSensorCC.d.ts +0 -185
- package/build/cc/MultilevelSensorCC.d.ts.map +0 -1
- package/build/cc/MultilevelSensorCC.js +0 -756
- package/build/cc/MultilevelSensorCC.js.map +0 -1
- package/build/cc/MultilevelSwitchCC.d.ts +0 -357
- package/build/cc/MultilevelSwitchCC.d.ts.map +0 -1
- package/build/cc/MultilevelSwitchCC.js +0 -813
- package/build/cc/MultilevelSwitchCC.js.map +0 -1
- package/build/cc/NoOperationCC.d.ts +0 -9
- package/build/cc/NoOperationCC.d.ts.map +0 -1
- package/build/cc/NoOperationCC.js +0 -42
- package/build/cc/NoOperationCC.js.map +0 -1
- package/build/cc/NodeNamingCC.d.ts +0 -118
- package/build/cc/NodeNamingCC.d.ts.map +0 -1
- package/build/cc/NodeNamingCC.js +0 -348
- package/build/cc/NodeNamingCC.js.map +0 -1
- package/build/cc/NotificationCC.d.ts +0 -479
- package/build/cc/NotificationCC.d.ts.map +0 -1
- package/build/cc/NotificationCC.js +0 -1379
- package/build/cc/NotificationCC.js.map +0 -1
- package/build/cc/PowerlevelCC.d.ts +0 -82
- package/build/cc/PowerlevelCC.d.ts.map +0 -1
- package/build/cc/PowerlevelCC.js +0 -488
- package/build/cc/PowerlevelCC.js.map +0 -1
- package/build/cc/ProtectionCC.d.ts +0 -325
- package/build/cc/ProtectionCC.d.ts.map +0 -1
- package/build/cc/ProtectionCC.js +0 -672
- package/build/cc/ProtectionCC.js.map +0 -1
- package/build/cc/SceneActivationCC.d.ts +0 -89
- package/build/cc/SceneActivationCC.d.ts.map +0 -1
- package/build/cc/SceneActivationCC.js +0 -169
- package/build/cc/SceneActivationCC.js.map +0 -1
- package/build/cc/SceneActuatorConfigurationCC.d.ts +0 -120
- package/build/cc/SceneActuatorConfigurationCC.d.ts.map +0 -1
- package/build/cc/SceneActuatorConfigurationCC.js +0 -377
- package/build/cc/SceneActuatorConfigurationCC.js.map +0 -1
- package/build/cc/SceneControllerConfigurationCC.d.ts +0 -129
- package/build/cc/SceneControllerConfigurationCC.d.ts.map +0 -1
- package/build/cc/SceneControllerConfigurationCC.js +0 -449
- package/build/cc/SceneControllerConfigurationCC.js.map +0 -1
- package/build/cc/ScheduleEntryLockCC.d.ts +0 -434
- package/build/cc/ScheduleEntryLockCC.d.ts.map +0 -1
- package/build/cc/ScheduleEntryLockCC.js +0 -1829
- package/build/cc/ScheduleEntryLockCC.js.map +0 -1
- package/build/cc/Security2CC.d.ts +0 -251
- package/build/cc/Security2CC.d.ts.map +0 -1
- package/build/cc/Security2CC.js +0 -1817
- package/build/cc/Security2CC.js.map +0 -1
- package/build/cc/SecurityCC.d.ts +0 -128
- package/build/cc/SecurityCC.d.ts.map +0 -1
- package/build/cc/SecurityCC.js +0 -803
- package/build/cc/SecurityCC.js.map +0 -1
- package/build/cc/SoundSwitchCC.d.ts +0 -232
- package/build/cc/SoundSwitchCC.d.ts.map +0 -1
- package/build/cc/SoundSwitchCC.js +0 -636
- package/build/cc/SoundSwitchCC.js.map +0 -1
- package/build/cc/SupervisionCC.d.ts +0 -104
- package/build/cc/SupervisionCC.d.ts.map +0 -1
- package/build/cc/SupervisionCC.js +0 -322
- package/build/cc/SupervisionCC.js.map +0 -1
- package/build/cc/ThermostatFanModeCC.d.ts +0 -141
- package/build/cc/ThermostatFanModeCC.d.ts.map +0 -1
- package/build/cc/ThermostatFanModeCC.js +0 -362
- package/build/cc/ThermostatFanModeCC.js.map +0 -1
- package/build/cc/ThermostatFanStateCC.d.ts +0 -60
- package/build/cc/ThermostatFanStateCC.d.ts.map +0 -1
- package/build/cc/ThermostatFanStateCC.js +0 -142
- package/build/cc/ThermostatFanStateCC.js.map +0 -1
- package/build/cc/ThermostatModeCC.d.ts +0 -150
- package/build/cc/ThermostatModeCC.d.ts.map +0 -1
- package/build/cc/ThermostatModeCC.js +0 -429
- package/build/cc/ThermostatModeCC.js.map +0 -1
- package/build/cc/ThermostatOperatingStateCC.d.ts +0 -61
- package/build/cc/ThermostatOperatingStateCC.d.ts.map +0 -1
- package/build/cc/ThermostatOperatingStateCC.js +0 -138
- package/build/cc/ThermostatOperatingStateCC.js.map +0 -1
- package/build/cc/ThermostatSetbackCC.d.ts +0 -46
- package/build/cc/ThermostatSetbackCC.d.ts.map +0 -1
- package/build/cc/ThermostatSetbackCC.js +0 -247
- package/build/cc/ThermostatSetbackCC.js.map +0 -1
- package/build/cc/ThermostatSetpointCC.d.ts +0 -197
- package/build/cc/ThermostatSetpointCC.d.ts.map +0 -1
- package/build/cc/ThermostatSetpointCC.js +0 -658
- package/build/cc/ThermostatSetpointCC.js.map +0 -1
- package/build/cc/TimeCC.d.ts +0 -88
- package/build/cc/TimeCC.d.ts.map +0 -1
- package/build/cc/TimeCC.js +0 -454
- package/build/cc/TimeCC.js.map +0 -1
- package/build/cc/TimeParametersCC.d.ts +0 -72
- package/build/cc/TimeParametersCC.d.ts.map +0 -1
- package/build/cc/TimeParametersCC.js +0 -303
- package/build/cc/TimeParametersCC.js.map +0 -1
- package/build/cc/TransportServiceCC.d.ts +0 -107
- package/build/cc/TransportServiceCC.d.ts.map +0 -1
- package/build/cc/TransportServiceCC.js +0 -426
- package/build/cc/TransportServiceCC.js.map +0 -1
- package/build/cc/UserCodeCC.d.ts +0 -683
- package/build/cc/UserCodeCC.d.ts.map +0 -1
- package/build/cc/UserCodeCC.js +0 -1699
- package/build/cc/UserCodeCC.js.map +0 -1
- package/build/cc/VersionCC.d.ts +0 -469
- package/build/cc/VersionCC.d.ts.map +0 -1
- package/build/cc/VersionCC.js +0 -865
- package/build/cc/VersionCC.js.map +0 -1
- package/build/cc/WakeUpCC.d.ts +0 -150
- package/build/cc/WakeUpCC.d.ts.map +0 -1
- package/build/cc/WakeUpCC.js +0 -441
- package/build/cc/WakeUpCC.js.map +0 -1
- package/build/cc/WindowCoveringCC.d.ts +0 -315
- package/build/cc/WindowCoveringCC.d.ts.map +0 -1
- package/build/cc/WindowCoveringCC.js +0 -783
- package/build/cc/WindowCoveringCC.js.map +0 -1
- package/build/cc/ZWaveLongRangeCC.d.ts +0 -4
- package/build/cc/ZWaveLongRangeCC.d.ts.map +0 -1
- package/build/cc/ZWaveLongRangeCC.js +0 -20
- package/build/cc/ZWaveLongRangeCC.js.map +0 -1
- package/build/cc/ZWavePlusCC.d.ts +0 -163
- package/build/cc/ZWavePlusCC.d.ts.map +0 -1
- package/build/cc/ZWavePlusCC.js +0 -270
- package/build/cc/ZWavePlusCC.js.map +0 -1
- package/build/cc/ZWaveProtocolCC.d.ts +0 -344
- package/build/cc/ZWaveProtocolCC.d.ts.map +0 -1
- package/build/cc/ZWaveProtocolCC.js +0 -1033
- package/build/cc/ZWaveProtocolCC.js.map +0 -1
- package/build/cc/index.d.ts +0 -132
- package/build/cc/index.d.ts.map +0 -1
- package/build/cc/index.js +0 -627
- package/build/cc/index.js.map +0 -1
- package/build/cc/manufacturerProprietary/Decorators.d.ts +0 -64
- package/build/cc/manufacturerProprietary/Decorators.d.ts.map +0 -1
- package/build/cc/manufacturerProprietary/Decorators.js +0 -83
- package/build/cc/manufacturerProprietary/Decorators.js.map +0 -1
- package/build/cc/manufacturerProprietary/FibaroCC.d.ts +0 -79
- package/build/cc/manufacturerProprietary/FibaroCC.d.ts.map +0 -1
- package/build/cc/manufacturerProprietary/FibaroCC.js +0 -392
- package/build/cc/manufacturerProprietary/FibaroCC.js.map +0 -1
- package/build/index.d.ts +0 -15
- package/build/index.d.ts.map +0 -1
- package/build/index.js +0 -52
- package/build/index.js.map +0 -1
- package/build/index_safe.d.ts +0 -3
- package/build/index_safe.d.ts.map +0 -1
- package/build/index_safe.js +0 -20
- package/build/index_safe.js.map +0 -1
- package/build/lib/API.d.ts +0 -271
- package/build/lib/API.d.ts.map +0 -1
- package/build/lib/API.js +0 -458
- package/build/lib/API.js.map +0 -1
- package/build/lib/CommandClass.d.ts +0 -234
- package/build/lib/CommandClass.d.ts.map +0 -1
- package/build/lib/CommandClass.js +0 -788
- package/build/lib/CommandClass.js.map +0 -1
- package/build/lib/CommandClassDecorators.d.ts +0 -112
- package/build/lib/CommandClassDecorators.d.ts.map +0 -1
- package/build/lib/CommandClassDecorators.js +0 -243
- package/build/lib/CommandClassDecorators.js.map +0 -1
- package/build/lib/EncapsulatingCommandClass.d.ts +0 -22
- package/build/lib/EncapsulatingCommandClass.d.ts.map +0 -1
- package/build/lib/EncapsulatingCommandClass.js +0 -61
- package/build/lib/EncapsulatingCommandClass.js.map +0 -1
- package/build/lib/ICommandClassContainer.d.ts.map +0 -1
- package/build/lib/ICommandClassContainer.js +0 -3
- package/build/lib/ICommandClassContainer.js.map +0 -1
- package/build/lib/NotificationEventPayload.d.ts +0 -10
- package/build/lib/NotificationEventPayload.d.ts.map +0 -1
- package/build/lib/NotificationEventPayload.js +0 -10
- package/build/lib/NotificationEventPayload.js.map +0 -1
- package/build/lib/Security2/Extension.d.ts.map +0 -1
- package/build/lib/Security2/Extension.js +0 -303
- package/build/lib/Security2/Extension.js.map +0 -1
- package/build/lib/Security2/shared.d.ts.map +0 -1
- package/build/lib/Security2/shared.js +0 -43
- package/build/lib/Security2/shared.js.map +0 -1
- package/build/lib/SetValueResult.d.ts.map +0 -1
- package/build/lib/SetValueResult.js +0 -60
- package/build/lib/SetValueResult.js.map +0 -1
- package/build/lib/Values.d.ts +0 -223
- package/build/lib/Values.d.ts.map +0 -1
- package/build/lib/Values.js +0 -172
- package/build/lib/Values.js.map +0 -1
- package/build/lib/_Types.d.ts.map +0 -1
- package/build/lib/_Types.js +0 -1443
- package/build/lib/_Types.js.map +0 -1
- package/build/lib/serializers.d.ts +0 -34
- package/build/lib/serializers.d.ts.map +0 -1
- package/build/lib/serializers.js +0 -107
- package/build/lib/serializers.js.map +0 -1
- package/build/lib/utils.d.ts +0 -17
- package/build/lib/utils.d.ts.map +0 -1
- package/build/lib/utils.js +0 -860
- package/build/lib/utils.js.map +0 -1
- /package/build/{lib → cjs/lib}/ICommandClassContainer.d.ts +0 -0
- /package/build/{lib → cjs/lib}/Security2/Extension.d.ts +0 -0
- /package/build/{lib → cjs/lib}/Security2/shared.d.ts +0 -0
- /package/build/{lib → cjs/lib}/SetValueResult.d.ts +0 -0
- /package/build/{lib → cjs/lib}/_Types.d.ts +0 -0
|
@@ -0,0 +1,1317 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var IndicatorCCSet_1, IndicatorCCReport_1, IndicatorCCGet_1, IndicatorCCSupportedReport_1, IndicatorCCSupportedGet_1, IndicatorCCDescriptionReport_1, IndicatorCCDescriptionGet_1;
|
|
8
|
+
function __assertType(argName, typeName, boundHasError) {
|
|
9
|
+
const { ZWaveError, ZWaveErrorCodes } = require("@zwave-js/core");
|
|
10
|
+
if (boundHasError()) {
|
|
11
|
+
throw new ZWaveError(typeName ? `${argName} is not a ${typeName}` : `${argName} has the wrong type`, ZWaveErrorCodes.Argument_Invalid);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
const __assertType__optional_number = $o => {
|
|
15
|
+
function _number($o) {
|
|
16
|
+
return typeof $o !== "number" ? {} : null;
|
|
17
|
+
}
|
|
18
|
+
function optional__number($o) {
|
|
19
|
+
if ($o !== undefined) {
|
|
20
|
+
const error = _number($o);
|
|
21
|
+
if (error)
|
|
22
|
+
return error;
|
|
23
|
+
}
|
|
24
|
+
return null;
|
|
25
|
+
}
|
|
26
|
+
return optional__number($o);
|
|
27
|
+
};
|
|
28
|
+
const __assertType__su__number_sa__5_ea_5_5_5_eu = $o => {
|
|
29
|
+
function _number($o) {
|
|
30
|
+
return typeof $o !== "number" ? {} : null;
|
|
31
|
+
}
|
|
32
|
+
function _false($o) {
|
|
33
|
+
return $o !== false ? {} : null;
|
|
34
|
+
}
|
|
35
|
+
function _true($o) {
|
|
36
|
+
return $o !== true ? {} : null;
|
|
37
|
+
}
|
|
38
|
+
function su__number__7__8_eu($o) {
|
|
39
|
+
const conditions = [_number, _false, _true];
|
|
40
|
+
for (const condition of conditions) {
|
|
41
|
+
const error = condition($o);
|
|
42
|
+
if (!error)
|
|
43
|
+
return null;
|
|
44
|
+
}
|
|
45
|
+
return {};
|
|
46
|
+
}
|
|
47
|
+
function _5($o) {
|
|
48
|
+
if (typeof $o !== "object" || $o === null || Array.isArray($o))
|
|
49
|
+
return {};
|
|
50
|
+
if ("indicatorId" in $o && $o["indicatorId"] !== undefined) {
|
|
51
|
+
const error = _number($o["indicatorId"]);
|
|
52
|
+
if (error)
|
|
53
|
+
return error;
|
|
54
|
+
}
|
|
55
|
+
else
|
|
56
|
+
return {};
|
|
57
|
+
if ("propertyId" in $o && $o["propertyId"] !== undefined) {
|
|
58
|
+
const error = _number($o["propertyId"]);
|
|
59
|
+
if (error)
|
|
60
|
+
return error;
|
|
61
|
+
}
|
|
62
|
+
else
|
|
63
|
+
return {};
|
|
64
|
+
if ("value" in $o && $o["value"] !== undefined) {
|
|
65
|
+
const error = su__number__7__8_eu($o["value"]);
|
|
66
|
+
if (error)
|
|
67
|
+
return error;
|
|
68
|
+
}
|
|
69
|
+
else
|
|
70
|
+
return {};
|
|
71
|
+
return null;
|
|
72
|
+
}
|
|
73
|
+
function sa__5_ea_5($o) {
|
|
74
|
+
if (!Array.isArray($o))
|
|
75
|
+
return {};
|
|
76
|
+
for (let i = 0; i < $o.length; i++) {
|
|
77
|
+
const error = _5($o[i]);
|
|
78
|
+
if (error)
|
|
79
|
+
return error;
|
|
80
|
+
}
|
|
81
|
+
return null;
|
|
82
|
+
}
|
|
83
|
+
function su__number_sa__5_ea_5_5_5_eu($o) {
|
|
84
|
+
const conditions = [_number, sa__5_ea_5];
|
|
85
|
+
for (const condition of conditions) {
|
|
86
|
+
const error = condition($o);
|
|
87
|
+
if (!error)
|
|
88
|
+
return null;
|
|
89
|
+
}
|
|
90
|
+
return {};
|
|
91
|
+
}
|
|
92
|
+
return su__number_sa__5_ea_5_5_5_eu($o);
|
|
93
|
+
};
|
|
94
|
+
const __assertType__IndicatorCCReportOptions = $o => {
|
|
95
|
+
function _number($o) {
|
|
96
|
+
return typeof $o !== "number" ? {} : null;
|
|
97
|
+
}
|
|
98
|
+
function _1($o) {
|
|
99
|
+
if (typeof $o !== "object" || $o === null || Array.isArray($o))
|
|
100
|
+
return {};
|
|
101
|
+
if ("value" in $o && $o["value"] !== undefined) {
|
|
102
|
+
const error = _number($o["value"]);
|
|
103
|
+
if (error)
|
|
104
|
+
return error;
|
|
105
|
+
}
|
|
106
|
+
else
|
|
107
|
+
return {};
|
|
108
|
+
return null;
|
|
109
|
+
}
|
|
110
|
+
function _false($o) {
|
|
111
|
+
return $o !== false ? {} : null;
|
|
112
|
+
}
|
|
113
|
+
function _true($o) {
|
|
114
|
+
return $o !== true ? {} : null;
|
|
115
|
+
}
|
|
116
|
+
function su__number__8__9_eu($o) {
|
|
117
|
+
const conditions = [_number, _false, _true];
|
|
118
|
+
for (const condition of conditions) {
|
|
119
|
+
const error = condition($o);
|
|
120
|
+
if (!error)
|
|
121
|
+
return null;
|
|
122
|
+
}
|
|
123
|
+
return {};
|
|
124
|
+
}
|
|
125
|
+
function _5($o) {
|
|
126
|
+
if (typeof $o !== "object" || $o === null || Array.isArray($o))
|
|
127
|
+
return {};
|
|
128
|
+
if ("indicatorId" in $o && $o["indicatorId"] !== undefined) {
|
|
129
|
+
const error = _number($o["indicatorId"]);
|
|
130
|
+
if (error)
|
|
131
|
+
return error;
|
|
132
|
+
}
|
|
133
|
+
else
|
|
134
|
+
return {};
|
|
135
|
+
if ("propertyId" in $o && $o["propertyId"] !== undefined) {
|
|
136
|
+
const error = _number($o["propertyId"]);
|
|
137
|
+
if (error)
|
|
138
|
+
return error;
|
|
139
|
+
}
|
|
140
|
+
else
|
|
141
|
+
return {};
|
|
142
|
+
if ("value" in $o && $o["value"] !== undefined) {
|
|
143
|
+
const error = su__number__8__9_eu($o["value"]);
|
|
144
|
+
if (error)
|
|
145
|
+
return error;
|
|
146
|
+
}
|
|
147
|
+
else
|
|
148
|
+
return {};
|
|
149
|
+
return null;
|
|
150
|
+
}
|
|
151
|
+
function sa__5_ea_5($o) {
|
|
152
|
+
if (!Array.isArray($o))
|
|
153
|
+
return {};
|
|
154
|
+
for (let i = 0; i < $o.length; i++) {
|
|
155
|
+
const error = _5($o[i]);
|
|
156
|
+
if (error)
|
|
157
|
+
return error;
|
|
158
|
+
}
|
|
159
|
+
return null;
|
|
160
|
+
}
|
|
161
|
+
function _2($o) {
|
|
162
|
+
if (typeof $o !== "object" || $o === null || Array.isArray($o))
|
|
163
|
+
return {};
|
|
164
|
+
if ("values" in $o && $o["values"] !== undefined) {
|
|
165
|
+
const error = sa__5_ea_5($o["values"]);
|
|
166
|
+
if (error)
|
|
167
|
+
return error;
|
|
168
|
+
}
|
|
169
|
+
else
|
|
170
|
+
return {};
|
|
171
|
+
return null;
|
|
172
|
+
}
|
|
173
|
+
function su__1__2_eu($o) {
|
|
174
|
+
const conditions = [_1, _2];
|
|
175
|
+
for (const condition of conditions) {
|
|
176
|
+
const error = condition($o);
|
|
177
|
+
if (!error)
|
|
178
|
+
return null;
|
|
179
|
+
}
|
|
180
|
+
return {};
|
|
181
|
+
}
|
|
182
|
+
return su__1__2_eu($o);
|
|
183
|
+
};
|
|
184
|
+
const __assertType__number = $o => {
|
|
185
|
+
function _number($o) {
|
|
186
|
+
return typeof $o !== "number" ? {} : null;
|
|
187
|
+
}
|
|
188
|
+
return _number($o);
|
|
189
|
+
};
|
|
190
|
+
const __assertType__sa__number_ea_2 = $o => {
|
|
191
|
+
function _number($o) {
|
|
192
|
+
return typeof $o !== "number" ? {} : null;
|
|
193
|
+
}
|
|
194
|
+
function sa__number_ea_2($o) {
|
|
195
|
+
if (!Array.isArray($o))
|
|
196
|
+
return {};
|
|
197
|
+
for (let i = 0; i < $o.length; i++) {
|
|
198
|
+
const error = _number($o[i]);
|
|
199
|
+
if (error)
|
|
200
|
+
return error;
|
|
201
|
+
}
|
|
202
|
+
return null;
|
|
203
|
+
}
|
|
204
|
+
return sa__number_ea_2($o);
|
|
205
|
+
};
|
|
206
|
+
const __assertType__string = $o => {
|
|
207
|
+
function _string($o) {
|
|
208
|
+
return typeof $o !== "string" ? {} : null;
|
|
209
|
+
}
|
|
210
|
+
return _string($o);
|
|
211
|
+
};
|
|
212
|
+
const __assertType__su__undefined__string__3_eu = $o => {
|
|
213
|
+
function _undefined($o) {
|
|
214
|
+
return $o !== undefined ? {} : null;
|
|
215
|
+
}
|
|
216
|
+
function _string($o) {
|
|
217
|
+
return typeof $o !== "string" ? {} : null;
|
|
218
|
+
}
|
|
219
|
+
function _number($o) {
|
|
220
|
+
return typeof $o !== "number" ? {} : null;
|
|
221
|
+
}
|
|
222
|
+
function _3($o) {
|
|
223
|
+
if (typeof $o !== "object" || $o === null || Array.isArray($o))
|
|
224
|
+
return {};
|
|
225
|
+
if ("hours" in $o && $o["hours"] !== undefined) {
|
|
226
|
+
const error = _number($o["hours"]);
|
|
227
|
+
if (error)
|
|
228
|
+
return error;
|
|
229
|
+
}
|
|
230
|
+
if ("minutes" in $o && $o["minutes"] !== undefined) {
|
|
231
|
+
const error = _number($o["minutes"]);
|
|
232
|
+
if (error)
|
|
233
|
+
return error;
|
|
234
|
+
}
|
|
235
|
+
if ("seconds" in $o && $o["seconds"] !== undefined) {
|
|
236
|
+
const error = _number($o["seconds"]);
|
|
237
|
+
if (error)
|
|
238
|
+
return error;
|
|
239
|
+
}
|
|
240
|
+
return null;
|
|
241
|
+
}
|
|
242
|
+
function su__undefined__string__3_eu($o) {
|
|
243
|
+
const conditions = [_undefined, _string, _3];
|
|
244
|
+
for (const condition of conditions) {
|
|
245
|
+
const error = condition($o);
|
|
246
|
+
if (!error)
|
|
247
|
+
return null;
|
|
248
|
+
}
|
|
249
|
+
return {};
|
|
250
|
+
}
|
|
251
|
+
return su__undefined__string__3_eu($o);
|
|
252
|
+
};
|
|
253
|
+
import { CommandClasses, Indicator, MessagePriority, ValueMetadata, ZWaveError, ZWaveErrorCodes, encodeBitMask, getIndicatorProperty, parseBitMask, validatePayload, } from "@zwave-js/core/safe";
|
|
254
|
+
import { Bytes } from "@zwave-js/shared/safe";
|
|
255
|
+
import { num2hex } from "@zwave-js/shared/safe";
|
|
256
|
+
import { clamp, roundTo } from "alcalzone-shared/math/index.js";
|
|
257
|
+
import { isArray } from "alcalzone-shared/typeguards/index.js";
|
|
258
|
+
import { CCAPI, POLL_VALUE, SET_VALUE, throwUnsupportedProperty, throwWrongValueType, } from "../lib/API.js";
|
|
259
|
+
import { CommandClass, } from "../lib/CommandClass.js";
|
|
260
|
+
import { API, CCCommand, ccValues, commandClass, expectedCCResponse, implementedVersion, useSupervision, } from "../lib/CommandClassDecorators.js";
|
|
261
|
+
import { V } from "../lib/Values.js";
|
|
262
|
+
import { IndicatorCommand } from "../lib/_Types.js";
|
|
263
|
+
function isManufacturerDefinedIndicator(indicatorId) {
|
|
264
|
+
return indicatorId >= 0x80 && indicatorId <= 0x9f;
|
|
265
|
+
}
|
|
266
|
+
const timeoutStringRegex = /^(?:(?<hoursStr>\d+)h)?(?:(?<minutesStr>\d+)m)?(?:(?<secondsStr>\d+(?:\.\d+)?)s)?$/i;
|
|
267
|
+
function parseIndicatorTimeoutString(text) {
|
|
268
|
+
if (!text.length)
|
|
269
|
+
return undefined;
|
|
270
|
+
// Try to parse the numeric parts from a timeout
|
|
271
|
+
const match = timeoutStringRegex.exec(text);
|
|
272
|
+
if (!match)
|
|
273
|
+
return undefined;
|
|
274
|
+
const { hoursStr, minutesStr, secondsStr } = match.groups;
|
|
275
|
+
if (!hoursStr && !minutesStr && !secondsStr)
|
|
276
|
+
return undefined;
|
|
277
|
+
const ret = {};
|
|
278
|
+
if (hoursStr) {
|
|
279
|
+
ret.hours = clamp(parseInt(hoursStr, 10), 0, 255);
|
|
280
|
+
}
|
|
281
|
+
if (minutesStr) {
|
|
282
|
+
ret.minutes = clamp(parseInt(minutesStr, 10), 0, 255);
|
|
283
|
+
}
|
|
284
|
+
if (secondsStr) {
|
|
285
|
+
ret.seconds = clamp(roundTo(parseFloat(secondsStr), 2), 0, 59.99);
|
|
286
|
+
}
|
|
287
|
+
return ret;
|
|
288
|
+
}
|
|
289
|
+
function indicatorObjectsToTimeout(values) {
|
|
290
|
+
const timeoutValues = values.filter((v) => [0x0a, 0x06, 0x07, 0x08].includes(v.propertyId));
|
|
291
|
+
if (!timeoutValues.length)
|
|
292
|
+
return undefined;
|
|
293
|
+
const hours = (timeoutValues.find((v) => v.propertyId === 0x0a)?.value
|
|
294
|
+
?? 0);
|
|
295
|
+
const minutes = (timeoutValues.find((v) => v.propertyId === 0x06)?.value
|
|
296
|
+
?? 0);
|
|
297
|
+
const seconds = clamp(timeoutValues.find((v) => v.propertyId === 0x07)
|
|
298
|
+
?.value ?? 0, 0, 59)
|
|
299
|
+
+ clamp(timeoutValues.find((v) => v.propertyId === 0x08)
|
|
300
|
+
?.value ?? 0, 0, 99)
|
|
301
|
+
/ 100;
|
|
302
|
+
return {
|
|
303
|
+
hours,
|
|
304
|
+
minutes,
|
|
305
|
+
seconds,
|
|
306
|
+
};
|
|
307
|
+
}
|
|
308
|
+
export const IndicatorCCValues = Object.freeze({
|
|
309
|
+
...V.defineStaticCCValues(CommandClasses.Indicator, {
|
|
310
|
+
...V.staticProperty("supportedIndicatorIds", undefined, {
|
|
311
|
+
internal: true,
|
|
312
|
+
}),
|
|
313
|
+
...V.staticPropertyWithName("valueV1", "value", {
|
|
314
|
+
...ValueMetadata.UInt8,
|
|
315
|
+
label: "Indicator value",
|
|
316
|
+
ccSpecific: {
|
|
317
|
+
indicatorId: 0,
|
|
318
|
+
},
|
|
319
|
+
}),
|
|
320
|
+
// Convenience values for indicators that are split across multiple properties
|
|
321
|
+
...V.staticProperty("identify", {
|
|
322
|
+
...ValueMetadata.WriteOnlyBoolean,
|
|
323
|
+
label: "Identify",
|
|
324
|
+
states: {
|
|
325
|
+
true: "Identify",
|
|
326
|
+
},
|
|
327
|
+
}, { minVersion: 3 }),
|
|
328
|
+
...V.staticProperty("timeout", {
|
|
329
|
+
...ValueMetadata.String,
|
|
330
|
+
label: "Timeout",
|
|
331
|
+
}, { minVersion: 3 }),
|
|
332
|
+
}),
|
|
333
|
+
...V.defineDynamicCCValues(CommandClasses.Indicator, {
|
|
334
|
+
...V.dynamicPropertyAndKeyWithName("supportedPropertyIDs", "supportedPropertyIDs", (indicatorId) => indicatorId, ({ property, propertyKey }) => property === "supportedPropertyIDs"
|
|
335
|
+
&& typeof propertyKey === "number", undefined, { internal: true }),
|
|
336
|
+
...V.dynamicPropertyAndKeyWithName("valueV2",
|
|
337
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
338
|
+
(indicatorId, propertyId) => indicatorId, (indicatorId, propertyId) => propertyId, ({ property, propertyKey }) => typeof property === "number" && typeof propertyKey === "number",
|
|
339
|
+
// The metadata is highly dependent on the indicator and property
|
|
340
|
+
// so this is just a baseline
|
|
341
|
+
(indicatorId, propertyId) => ({
|
|
342
|
+
...ValueMetadata.Any,
|
|
343
|
+
ccSpecific: {
|
|
344
|
+
indicatorId,
|
|
345
|
+
propertyId,
|
|
346
|
+
},
|
|
347
|
+
}), { minVersion: 2 }),
|
|
348
|
+
...V.dynamicPropertyWithName("indicatorDescription", (indicatorId) => indicatorId, ({ property }) => typeof property === "number", undefined, { internal: true, minVersion: 4 }),
|
|
349
|
+
}),
|
|
350
|
+
});
|
|
351
|
+
/**
|
|
352
|
+
* Looks up the configured metadata for the given indicator and property
|
|
353
|
+
*/
|
|
354
|
+
function getIndicatorMetadata(indicatorId, propertyId, overrideIndicatorLabel) {
|
|
355
|
+
const label = overrideIndicatorLabel
|
|
356
|
+
|| getIndicatorName(indicatorId);
|
|
357
|
+
const prop = getIndicatorProperty(propertyId);
|
|
358
|
+
const baseMetadata = IndicatorCCValues.valueV2(indicatorId, propertyId).meta;
|
|
359
|
+
if (!label && !prop) {
|
|
360
|
+
return {
|
|
361
|
+
...baseMetadata,
|
|
362
|
+
...ValueMetadata.UInt8,
|
|
363
|
+
};
|
|
364
|
+
}
|
|
365
|
+
else if (!prop) {
|
|
366
|
+
return {
|
|
367
|
+
...baseMetadata,
|
|
368
|
+
...ValueMetadata.UInt8,
|
|
369
|
+
label,
|
|
370
|
+
};
|
|
371
|
+
}
|
|
372
|
+
else {
|
|
373
|
+
if (prop.type === "boolean") {
|
|
374
|
+
return {
|
|
375
|
+
...baseMetadata,
|
|
376
|
+
...ValueMetadata.Boolean,
|
|
377
|
+
label: `${label} - ${prop.label}`,
|
|
378
|
+
description: prop.description,
|
|
379
|
+
readable: !prop.readonly,
|
|
380
|
+
};
|
|
381
|
+
}
|
|
382
|
+
else {
|
|
383
|
+
// UInt8
|
|
384
|
+
return {
|
|
385
|
+
...baseMetadata,
|
|
386
|
+
...ValueMetadata.UInt8,
|
|
387
|
+
label: `${label} - ${prop.label}`,
|
|
388
|
+
description: prop.description,
|
|
389
|
+
min: prop.min,
|
|
390
|
+
max: prop.max,
|
|
391
|
+
readable: !prop.readonly,
|
|
392
|
+
};
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
function getIndicatorName(indicatorId) {
|
|
397
|
+
if (indicatorId) {
|
|
398
|
+
return `${num2hex(indicatorId)} (${indicatorId in Indicator ? Indicator[indicatorId] : "Unknown"})`;
|
|
399
|
+
}
|
|
400
|
+
else {
|
|
401
|
+
return "0 (default)";
|
|
402
|
+
}
|
|
403
|
+
}
|
|
404
|
+
const MAX_INDICATOR_OBJECTS = 31;
|
|
405
|
+
let IndicatorCCAPI = class IndicatorCCAPI extends CCAPI {
|
|
406
|
+
supportsCommand(cmd) {
|
|
407
|
+
switch (cmd) {
|
|
408
|
+
case IndicatorCommand.Get:
|
|
409
|
+
case IndicatorCommand.Report:
|
|
410
|
+
return this.isSinglecast();
|
|
411
|
+
case IndicatorCommand.Set:
|
|
412
|
+
return true; // This is mandatory
|
|
413
|
+
case IndicatorCommand.SupportedGet:
|
|
414
|
+
case IndicatorCommand.SupportedReport:
|
|
415
|
+
return this.version >= 2 && this.isSinglecast();
|
|
416
|
+
case IndicatorCommand.DescriptionGet:
|
|
417
|
+
case IndicatorCommand.DescriptionReport:
|
|
418
|
+
return this.version >= 4 && this.isSinglecast();
|
|
419
|
+
}
|
|
420
|
+
return super.supportsCommand(cmd);
|
|
421
|
+
}
|
|
422
|
+
get [SET_VALUE]() {
|
|
423
|
+
return async function ({ property, propertyKey }, value) {
|
|
424
|
+
if (property === "value") {
|
|
425
|
+
// V1 value
|
|
426
|
+
if (typeof value !== "number") {
|
|
427
|
+
throwWrongValueType(this.ccId, property, "number", typeof value);
|
|
428
|
+
}
|
|
429
|
+
return this.set(value);
|
|
430
|
+
}
|
|
431
|
+
else if (typeof property === "number"
|
|
432
|
+
&& typeof propertyKey === "number") {
|
|
433
|
+
const indicatorId = property;
|
|
434
|
+
const propertyId = propertyKey;
|
|
435
|
+
const expectedType = getIndicatorMetadata(indicatorId, propertyId).type;
|
|
436
|
+
// V2+ value
|
|
437
|
+
if (typeof value !== expectedType) {
|
|
438
|
+
throwWrongValueType(this.ccId, property, expectedType, typeof value);
|
|
439
|
+
}
|
|
440
|
+
return this.set([
|
|
441
|
+
{
|
|
442
|
+
indicatorId: property,
|
|
443
|
+
propertyId: propertyKey,
|
|
444
|
+
value: value,
|
|
445
|
+
},
|
|
446
|
+
]);
|
|
447
|
+
}
|
|
448
|
+
else if (property === "identify") {
|
|
449
|
+
if (typeof value !== "boolean") {
|
|
450
|
+
throwWrongValueType(this.ccId, property, "boolean", typeof value);
|
|
451
|
+
}
|
|
452
|
+
return this.identify();
|
|
453
|
+
}
|
|
454
|
+
else {
|
|
455
|
+
throwUnsupportedProperty(this.ccId, property);
|
|
456
|
+
}
|
|
457
|
+
};
|
|
458
|
+
}
|
|
459
|
+
get [POLL_VALUE]() {
|
|
460
|
+
return async function ({ property }) {
|
|
461
|
+
if (property === "value")
|
|
462
|
+
return this.get();
|
|
463
|
+
if (typeof property === "number") {
|
|
464
|
+
return this.get(property);
|
|
465
|
+
}
|
|
466
|
+
throwUnsupportedProperty(this.ccId, property);
|
|
467
|
+
};
|
|
468
|
+
}
|
|
469
|
+
async get(indicatorId) {
|
|
470
|
+
__assertType("indicatorId", "(optional) number", __assertType__optional_number.bind(void 0, indicatorId));
|
|
471
|
+
this.assertSupportsCommand(IndicatorCommand, IndicatorCommand.Get);
|
|
472
|
+
const cc = new IndicatorCCGet({
|
|
473
|
+
nodeId: this.endpoint.nodeId,
|
|
474
|
+
endpointIndex: this.endpoint.index,
|
|
475
|
+
indicatorId,
|
|
476
|
+
});
|
|
477
|
+
const response = await this.host.sendCommand(cc, this.commandOptions);
|
|
478
|
+
if (!response)
|
|
479
|
+
return;
|
|
480
|
+
if (response.values)
|
|
481
|
+
return response.values;
|
|
482
|
+
return response.indicator0Value;
|
|
483
|
+
}
|
|
484
|
+
async set(value) {
|
|
485
|
+
__assertType("value", undefined, __assertType__su__number_sa__5_ea_5_5_5_eu.bind(void 0, value));
|
|
486
|
+
this.assertSupportsCommand(IndicatorCommand, IndicatorCommand.Set);
|
|
487
|
+
if (this.version === 1 && typeof value !== "number") {
|
|
488
|
+
throw new ZWaveError(`Node ${this.endpoint
|
|
489
|
+
.nodeId} only supports IndicatorCC V1 which requires a single value to be set`, ZWaveErrorCodes.Argument_Invalid);
|
|
490
|
+
}
|
|
491
|
+
else if (this.version >= 2
|
|
492
|
+
&& isArray(value)
|
|
493
|
+
&& value.length > MAX_INDICATOR_OBJECTS) {
|
|
494
|
+
throw new ZWaveError(`Only ${MAX_INDICATOR_OBJECTS} indicator values can be set at a time!`, ZWaveErrorCodes.Argument_Invalid);
|
|
495
|
+
}
|
|
496
|
+
const cc = new IndicatorCCSet({
|
|
497
|
+
nodeId: this.endpoint.nodeId,
|
|
498
|
+
endpointIndex: this.endpoint.index,
|
|
499
|
+
...(typeof value === "number" ? { value } : { values: value }),
|
|
500
|
+
});
|
|
501
|
+
return this.host.sendCommand(cc, this.commandOptions);
|
|
502
|
+
}
|
|
503
|
+
async sendReport(options) {
|
|
504
|
+
__assertType("options", "IndicatorCCReportOptions", __assertType__IndicatorCCReportOptions.bind(void 0, options));
|
|
505
|
+
this.assertSupportsCommand(IndicatorCommand, IndicatorCommand.Report);
|
|
506
|
+
const cc = new IndicatorCCReport({
|
|
507
|
+
nodeId: this.endpoint.nodeId,
|
|
508
|
+
endpointIndex: this.endpoint.index,
|
|
509
|
+
...options,
|
|
510
|
+
});
|
|
511
|
+
await this.host.sendCommand(cc, this.commandOptions);
|
|
512
|
+
}
|
|
513
|
+
async getSupported(indicatorId) {
|
|
514
|
+
__assertType("indicatorId", "number", __assertType__number.bind(void 0, indicatorId));
|
|
515
|
+
this.assertSupportsCommand(IndicatorCommand, IndicatorCommand.SupportedGet);
|
|
516
|
+
const cc = new IndicatorCCSupportedGet({
|
|
517
|
+
nodeId: this.endpoint.nodeId,
|
|
518
|
+
endpointIndex: this.endpoint.index,
|
|
519
|
+
indicatorId,
|
|
520
|
+
});
|
|
521
|
+
const response = await this.host.sendCommand(cc, this.commandOptions);
|
|
522
|
+
if (response) {
|
|
523
|
+
return {
|
|
524
|
+
// Include the actual indicator ID if 0x00 was requested
|
|
525
|
+
...(indicatorId === 0x00
|
|
526
|
+
? { indicatorId: response.indicatorId }
|
|
527
|
+
: undefined),
|
|
528
|
+
supportedProperties: response.supportedProperties,
|
|
529
|
+
nextIndicatorId: response.nextIndicatorId,
|
|
530
|
+
};
|
|
531
|
+
}
|
|
532
|
+
}
|
|
533
|
+
async reportSupported(indicatorId, supportedProperties, nextIndicatorId) {
|
|
534
|
+
__assertType("indicatorId", "number", __assertType__number.bind(void 0, indicatorId));
|
|
535
|
+
__assertType("supportedProperties", undefined, __assertType__sa__number_ea_2.bind(void 0, supportedProperties));
|
|
536
|
+
__assertType("nextIndicatorId", "number", __assertType__number.bind(void 0, nextIndicatorId));
|
|
537
|
+
this.assertSupportsCommand(IndicatorCommand, IndicatorCommand.SupportedReport);
|
|
538
|
+
const cc = new IndicatorCCSupportedReport({
|
|
539
|
+
nodeId: this.endpoint.nodeId,
|
|
540
|
+
endpointIndex: this.endpoint.index,
|
|
541
|
+
indicatorId,
|
|
542
|
+
supportedProperties,
|
|
543
|
+
nextIndicatorId,
|
|
544
|
+
});
|
|
545
|
+
await this.host.sendCommand(cc, this.commandOptions);
|
|
546
|
+
}
|
|
547
|
+
async reportDescription(indicatorId, description) {
|
|
548
|
+
__assertType("indicatorId", "number", __assertType__number.bind(void 0, indicatorId));
|
|
549
|
+
__assertType("description", "string", __assertType__string.bind(void 0, description));
|
|
550
|
+
this.assertSupportsCommand(IndicatorCommand, IndicatorCommand.DescriptionReport);
|
|
551
|
+
const cc = new IndicatorCCDescriptionReport({
|
|
552
|
+
nodeId: this.endpoint.nodeId,
|
|
553
|
+
endpointIndex: this.endpoint.index,
|
|
554
|
+
indicatorId,
|
|
555
|
+
description,
|
|
556
|
+
});
|
|
557
|
+
await this.host.sendCommand(cc, this.commandOptions);
|
|
558
|
+
}
|
|
559
|
+
/**
|
|
560
|
+
* Instructs the node to identify itself. Available starting with V3 of this CC.
|
|
561
|
+
*/
|
|
562
|
+
async identify() {
|
|
563
|
+
if (this.version < 3) {
|
|
564
|
+
throw new ZWaveError(`The identify command is only supported in Indicator CC version 3 and above`, ZWaveErrorCodes.CC_NotSupported);
|
|
565
|
+
}
|
|
566
|
+
return this.set([
|
|
567
|
+
{
|
|
568
|
+
indicatorId: 0x50,
|
|
569
|
+
propertyId: 0x03,
|
|
570
|
+
value: 0x08,
|
|
571
|
+
},
|
|
572
|
+
{
|
|
573
|
+
indicatorId: 0x50,
|
|
574
|
+
propertyId: 0x04,
|
|
575
|
+
value: 0x03,
|
|
576
|
+
},
|
|
577
|
+
{
|
|
578
|
+
indicatorId: 0x50,
|
|
579
|
+
propertyId: 0x05,
|
|
580
|
+
value: 0x06,
|
|
581
|
+
},
|
|
582
|
+
]);
|
|
583
|
+
}
|
|
584
|
+
/**
|
|
585
|
+
* Set a timeout for a given indicator ID after which the indicator will be turned off.
|
|
586
|
+
* @param timeout The timeout in one of the supported forms:
|
|
587
|
+
* - a timeout string in the form `12h18m17.59s`. All parts (hours, minutes, seconds, hundredths) are optional, but must be specified in this order. An empty string will be treated like `undefined`.
|
|
588
|
+
* - an object specifying the timeout parts. An empty object will be treated like `undefined`.
|
|
589
|
+
* - `undefined` to disable the timeout.
|
|
590
|
+
*/
|
|
591
|
+
async setTimeout(indicatorId, timeout) {
|
|
592
|
+
__assertType("indicatorId", "number", __assertType__number.bind(void 0, indicatorId));
|
|
593
|
+
__assertType("timeout", undefined, __assertType__su__undefined__string__3_eu.bind(void 0, timeout));
|
|
594
|
+
this.assertPhysicalEndpoint(this.endpoint);
|
|
595
|
+
if (this.version < 3) {
|
|
596
|
+
throw new ZWaveError(`The setTimeout command is only supported in Indicator CC version 3 and above`, ZWaveErrorCodes.CC_NotSupported);
|
|
597
|
+
}
|
|
598
|
+
if (typeof timeout === "string") {
|
|
599
|
+
if (timeout === "") {
|
|
600
|
+
timeout = undefined;
|
|
601
|
+
}
|
|
602
|
+
else {
|
|
603
|
+
const parsed = parseIndicatorTimeoutString(timeout);
|
|
604
|
+
if (!parsed) {
|
|
605
|
+
throw new ZWaveError(`The timeout string "${timeout}" is not valid`, ZWaveErrorCodes.Argument_Invalid);
|
|
606
|
+
}
|
|
607
|
+
timeout = parsed;
|
|
608
|
+
}
|
|
609
|
+
}
|
|
610
|
+
const supportedPropertyIDs = IndicatorCC.getSupportedPropertyIDsCached(this.host, this.endpoint, indicatorId);
|
|
611
|
+
const objects = [];
|
|
612
|
+
if (timeout) {
|
|
613
|
+
const hours = timeout.hours ?? 0;
|
|
614
|
+
const minutes = timeout.minutes ?? 0;
|
|
615
|
+
const seconds = Math.floor(timeout.seconds ?? 0);
|
|
616
|
+
const hundredths = Math.round(((timeout.seconds ?? 0) % 1) * 100);
|
|
617
|
+
if (hours) {
|
|
618
|
+
if (!supportedPropertyIDs?.includes(0x0a)) {
|
|
619
|
+
throw new ZWaveError(`The indicator ${indicatorId} does not support setting the timeout in hours`, ZWaveErrorCodes.Argument_Invalid);
|
|
620
|
+
}
|
|
621
|
+
objects.push({
|
|
622
|
+
indicatorId,
|
|
623
|
+
propertyId: 0x0a,
|
|
624
|
+
value: hours,
|
|
625
|
+
});
|
|
626
|
+
}
|
|
627
|
+
if (minutes) {
|
|
628
|
+
if (!supportedPropertyIDs?.includes(0x06)) {
|
|
629
|
+
throw new ZWaveError(`The indicator ${indicatorId} does not support setting the timeout in minutes`, ZWaveErrorCodes.Argument_Invalid);
|
|
630
|
+
}
|
|
631
|
+
objects.push({
|
|
632
|
+
indicatorId,
|
|
633
|
+
propertyId: 0x06,
|
|
634
|
+
value: minutes,
|
|
635
|
+
});
|
|
636
|
+
}
|
|
637
|
+
if (seconds) {
|
|
638
|
+
if (!supportedPropertyIDs?.includes(0x07)) {
|
|
639
|
+
throw new ZWaveError(`The indicator ${indicatorId} does not support setting the timeout in seconds`, ZWaveErrorCodes.Argument_Invalid);
|
|
640
|
+
}
|
|
641
|
+
objects.push({
|
|
642
|
+
indicatorId,
|
|
643
|
+
propertyId: 0x07,
|
|
644
|
+
value: seconds,
|
|
645
|
+
});
|
|
646
|
+
}
|
|
647
|
+
if (hundredths) {
|
|
648
|
+
if (!supportedPropertyIDs?.includes(0x08)) {
|
|
649
|
+
throw new ZWaveError(`The indicator ${indicatorId} does not support setting the timeout in 1/100 seconds`, ZWaveErrorCodes.Argument_Invalid);
|
|
650
|
+
}
|
|
651
|
+
objects.push({
|
|
652
|
+
indicatorId,
|
|
653
|
+
propertyId: 0x08,
|
|
654
|
+
value: hundredths,
|
|
655
|
+
});
|
|
656
|
+
}
|
|
657
|
+
}
|
|
658
|
+
if (!objects.length) {
|
|
659
|
+
objects.push(...(supportedPropertyIDs ?? []).map((p) => ({
|
|
660
|
+
indicatorId,
|
|
661
|
+
propertyId: p,
|
|
662
|
+
value: 0,
|
|
663
|
+
})));
|
|
664
|
+
}
|
|
665
|
+
return this.set(objects);
|
|
666
|
+
}
|
|
667
|
+
/**
|
|
668
|
+
* Returns the timeout after which the given indicator will be turned off.
|
|
669
|
+
*/
|
|
670
|
+
async getTimeout(indicatorId) {
|
|
671
|
+
__assertType("indicatorId", "number", __assertType__number.bind(void 0, indicatorId));
|
|
672
|
+
const values = await this.get(indicatorId);
|
|
673
|
+
if (!isArray(values))
|
|
674
|
+
return;
|
|
675
|
+
return indicatorObjectsToTimeout(values);
|
|
676
|
+
}
|
|
677
|
+
async getDescription(indicatorId) {
|
|
678
|
+
__assertType("indicatorId", "number", __assertType__number.bind(void 0, indicatorId));
|
|
679
|
+
this.assertSupportsCommand(IndicatorCommand, IndicatorCommand.DescriptionGet);
|
|
680
|
+
const cc = new IndicatorCCDescriptionGet({
|
|
681
|
+
nodeId: this.endpoint.nodeId,
|
|
682
|
+
endpointIndex: this.endpoint.index,
|
|
683
|
+
indicatorId,
|
|
684
|
+
});
|
|
685
|
+
const response = await this.host.sendCommand(cc, this.commandOptions);
|
|
686
|
+
return response?.description;
|
|
687
|
+
}
|
|
688
|
+
};
|
|
689
|
+
IndicatorCCAPI = __decorate([
|
|
690
|
+
API(CommandClasses.Indicator)
|
|
691
|
+
], IndicatorCCAPI);
|
|
692
|
+
export { IndicatorCCAPI };
|
|
693
|
+
let IndicatorCC = class IndicatorCC extends CommandClass {
|
|
694
|
+
async interview(ctx) {
|
|
695
|
+
const node = this.getNode(ctx);
|
|
696
|
+
const endpoint = this.getEndpoint(ctx);
|
|
697
|
+
const api = CCAPI.create(CommandClasses.Indicator, ctx, endpoint).withOptions({
|
|
698
|
+
priority: MessagePriority.NodeQuery,
|
|
699
|
+
});
|
|
700
|
+
ctx.logNode(node.id, {
|
|
701
|
+
endpoint: this.endpointIndex,
|
|
702
|
+
message: `Interviewing ${this.ccName}...`,
|
|
703
|
+
direction: "none",
|
|
704
|
+
});
|
|
705
|
+
if (api.version > 1) {
|
|
706
|
+
ctx.logNode(node.id, {
|
|
707
|
+
endpoint: this.endpointIndex,
|
|
708
|
+
message: "scanning supported indicator IDs...",
|
|
709
|
+
direction: "outbound",
|
|
710
|
+
});
|
|
711
|
+
// Query ID 0 to get the first supported ID
|
|
712
|
+
let curId = 0x00;
|
|
713
|
+
const supportedIndicatorIds = [];
|
|
714
|
+
do {
|
|
715
|
+
const supportedResponse = await api.getSupported(curId);
|
|
716
|
+
if (!supportedResponse) {
|
|
717
|
+
ctx.logNode(node.id, {
|
|
718
|
+
endpoint: this.endpointIndex,
|
|
719
|
+
message: "Time out while scanning supported indicator IDs, skipping interview...",
|
|
720
|
+
level: "warn",
|
|
721
|
+
});
|
|
722
|
+
return;
|
|
723
|
+
}
|
|
724
|
+
supportedIndicatorIds.push(supportedResponse.indicatorId ?? curId);
|
|
725
|
+
curId = supportedResponse.nextIndicatorId;
|
|
726
|
+
} while (curId !== 0x00);
|
|
727
|
+
// The IDs are not stored by the report CCs so store them here once we have all of them
|
|
728
|
+
this.setValue(ctx, IndicatorCCValues.supportedIndicatorIds, supportedIndicatorIds);
|
|
729
|
+
const logMessage = `supported indicator IDs: ${supportedIndicatorIds.join(", ")}`;
|
|
730
|
+
ctx.logNode(node.id, {
|
|
731
|
+
endpoint: this.endpointIndex,
|
|
732
|
+
message: logMessage,
|
|
733
|
+
direction: "inbound",
|
|
734
|
+
});
|
|
735
|
+
if (api.version >= 4) {
|
|
736
|
+
const manufacturerDefinedIndicatorIds = supportedIndicatorIds
|
|
737
|
+
.filter((id) => isManufacturerDefinedIndicator(id));
|
|
738
|
+
if (manufacturerDefinedIndicatorIds.length > 0) {
|
|
739
|
+
ctx.logNode(node.id, {
|
|
740
|
+
endpoint: this.endpointIndex,
|
|
741
|
+
message: "retrieving description for manufacturer-defined indicator IDs...",
|
|
742
|
+
direction: "outbound",
|
|
743
|
+
});
|
|
744
|
+
for (const id of manufacturerDefinedIndicatorIds) {
|
|
745
|
+
await api.getDescription(id);
|
|
746
|
+
}
|
|
747
|
+
}
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
// Query current values
|
|
751
|
+
await this.refreshValues(ctx);
|
|
752
|
+
// Remember that the interview is complete
|
|
753
|
+
this.setInterviewComplete(ctx, true);
|
|
754
|
+
}
|
|
755
|
+
async refreshValues(ctx) {
|
|
756
|
+
const node = this.getNode(ctx);
|
|
757
|
+
const endpoint = this.getEndpoint(ctx);
|
|
758
|
+
const api = CCAPI.create(CommandClasses.Indicator, ctx, endpoint).withOptions({
|
|
759
|
+
priority: MessagePriority.NodeQuery,
|
|
760
|
+
});
|
|
761
|
+
if (api.version === 1) {
|
|
762
|
+
ctx.logNode(node.id, {
|
|
763
|
+
endpoint: this.endpointIndex,
|
|
764
|
+
message: "requesting current indicator value...",
|
|
765
|
+
direction: "outbound",
|
|
766
|
+
});
|
|
767
|
+
await api.get();
|
|
768
|
+
}
|
|
769
|
+
else {
|
|
770
|
+
const supportedIndicatorIds = this.getValue(ctx, IndicatorCCValues.supportedIndicatorIds) ?? [];
|
|
771
|
+
for (const indicatorId of supportedIndicatorIds) {
|
|
772
|
+
ctx.logNode(node.id, {
|
|
773
|
+
endpoint: this.endpointIndex,
|
|
774
|
+
message: `requesting current indicator value (id = ${num2hex(indicatorId)})...`,
|
|
775
|
+
direction: "outbound",
|
|
776
|
+
});
|
|
777
|
+
await api.get(indicatorId);
|
|
778
|
+
}
|
|
779
|
+
}
|
|
780
|
+
}
|
|
781
|
+
translatePropertyKey(ctx, property, propertyKey) {
|
|
782
|
+
if (property === "value") {
|
|
783
|
+
// CC version 1 only has a single value that doesn't need to be translated
|
|
784
|
+
return undefined;
|
|
785
|
+
}
|
|
786
|
+
else if (typeof property === "number"
|
|
787
|
+
&& typeof propertyKey === "number") {
|
|
788
|
+
// The indicator property is our property key
|
|
789
|
+
const prop = getIndicatorProperty(propertyKey);
|
|
790
|
+
if (prop)
|
|
791
|
+
return prop.label;
|
|
792
|
+
}
|
|
793
|
+
return super.translatePropertyKey(ctx, property, propertyKey);
|
|
794
|
+
}
|
|
795
|
+
translateProperty(ctx, property, propertyKey) {
|
|
796
|
+
if (typeof property === "number" && typeof propertyKey === "number") {
|
|
797
|
+
// The indicator corresponds to our property
|
|
798
|
+
if (property in Indicator)
|
|
799
|
+
return Indicator[property];
|
|
800
|
+
}
|
|
801
|
+
return super.translateProperty(ctx, property, propertyKey);
|
|
802
|
+
}
|
|
803
|
+
supportsV2Indicators(ctx) {
|
|
804
|
+
// First test if there are any indicator ids defined
|
|
805
|
+
const supportedIndicatorIds = this.getValue(ctx, IndicatorCCValues.supportedIndicatorIds);
|
|
806
|
+
if (!supportedIndicatorIds?.length)
|
|
807
|
+
return false;
|
|
808
|
+
// Then test if there are any property ids defined
|
|
809
|
+
return supportedIndicatorIds.some((indicatorId) => !!this.getValue(ctx, IndicatorCCValues.supportedPropertyIDs(indicatorId))?.length);
|
|
810
|
+
}
|
|
811
|
+
static getSupportedPropertyIDsCached(ctx, endpoint, indicatorId) {
|
|
812
|
+
return ctx
|
|
813
|
+
.getValueDB(endpoint.nodeId)
|
|
814
|
+
.getValue(IndicatorCCValues.supportedPropertyIDs(indicatorId).endpoint(endpoint.index));
|
|
815
|
+
}
|
|
816
|
+
};
|
|
817
|
+
IndicatorCC = __decorate([
|
|
818
|
+
commandClass(CommandClasses.Indicator),
|
|
819
|
+
implementedVersion(4),
|
|
820
|
+
ccValues(IndicatorCCValues)
|
|
821
|
+
], IndicatorCC);
|
|
822
|
+
export { IndicatorCC };
|
|
823
|
+
let IndicatorCCSet = IndicatorCCSet_1 = class IndicatorCCSet extends IndicatorCC {
|
|
824
|
+
constructor(options) {
|
|
825
|
+
super(options);
|
|
826
|
+
if ("value" in options) {
|
|
827
|
+
this.indicator0Value = options.value;
|
|
828
|
+
}
|
|
829
|
+
else {
|
|
830
|
+
this.values = options.values;
|
|
831
|
+
}
|
|
832
|
+
}
|
|
833
|
+
static from(raw, ctx) {
|
|
834
|
+
validatePayload(raw.payload.length >= 1);
|
|
835
|
+
const objCount = raw.payload.length >= 2
|
|
836
|
+
? raw.payload[1] & 0b11111
|
|
837
|
+
: 0;
|
|
838
|
+
if (objCount === 0) {
|
|
839
|
+
const indicator0Value = raw.payload[0];
|
|
840
|
+
return new IndicatorCCSet_1({
|
|
841
|
+
nodeId: ctx.sourceNodeId,
|
|
842
|
+
value: indicator0Value,
|
|
843
|
+
});
|
|
844
|
+
}
|
|
845
|
+
validatePayload(raw.payload.length >= 2 + 3 * objCount);
|
|
846
|
+
const values = [];
|
|
847
|
+
for (let i = 0; i < objCount; i++) {
|
|
848
|
+
const offset = 2 + 3 * i;
|
|
849
|
+
const value = {
|
|
850
|
+
indicatorId: raw.payload[offset],
|
|
851
|
+
propertyId: raw.payload[offset + 1],
|
|
852
|
+
value: raw.payload[offset + 2],
|
|
853
|
+
};
|
|
854
|
+
values.push(value);
|
|
855
|
+
}
|
|
856
|
+
return new IndicatorCCSet_1({
|
|
857
|
+
nodeId: ctx.sourceNodeId,
|
|
858
|
+
values,
|
|
859
|
+
});
|
|
860
|
+
}
|
|
861
|
+
indicator0Value;
|
|
862
|
+
values;
|
|
863
|
+
serialize(ctx) {
|
|
864
|
+
if (this.values != undefined) {
|
|
865
|
+
// V2+
|
|
866
|
+
this.payload = Bytes.alloc(2 + 3 * this.values.length, 0);
|
|
867
|
+
// Byte 0 is the legacy value
|
|
868
|
+
const objCount = this.values.length & MAX_INDICATOR_OBJECTS;
|
|
869
|
+
this.payload[1] = objCount;
|
|
870
|
+
for (let i = 0; i < objCount; i++) {
|
|
871
|
+
const offset = 2 + 3 * i;
|
|
872
|
+
this.payload[offset] = this.values[i].indicatorId;
|
|
873
|
+
this.payload[offset + 1] = this.values[i].propertyId;
|
|
874
|
+
const value = this.values[i].value;
|
|
875
|
+
this.payload[offset + 2] = value === true
|
|
876
|
+
? 0xff
|
|
877
|
+
: value === false
|
|
878
|
+
? 0x00
|
|
879
|
+
: value;
|
|
880
|
+
}
|
|
881
|
+
}
|
|
882
|
+
else {
|
|
883
|
+
// V1
|
|
884
|
+
this.payload = Bytes.from([this.indicator0Value ?? 0]);
|
|
885
|
+
}
|
|
886
|
+
return super.serialize(ctx);
|
|
887
|
+
}
|
|
888
|
+
toLogEntry(ctx) {
|
|
889
|
+
const message = {};
|
|
890
|
+
if (this.indicator0Value != undefined) {
|
|
891
|
+
message["indicator 0 value"] = this.indicator0Value;
|
|
892
|
+
}
|
|
893
|
+
if (this.values != undefined) {
|
|
894
|
+
message.values = `${this.values
|
|
895
|
+
.map((v) => `
|
|
896
|
+
· indicatorId: ${v.indicatorId}
|
|
897
|
+
propertyId: ${v.propertyId}
|
|
898
|
+
value: ${v.value}`)
|
|
899
|
+
.join("")}`;
|
|
900
|
+
}
|
|
901
|
+
return {
|
|
902
|
+
...super.toLogEntry(ctx),
|
|
903
|
+
message,
|
|
904
|
+
};
|
|
905
|
+
}
|
|
906
|
+
};
|
|
907
|
+
IndicatorCCSet = IndicatorCCSet_1 = __decorate([
|
|
908
|
+
CCCommand(IndicatorCommand.Set),
|
|
909
|
+
useSupervision()
|
|
910
|
+
], IndicatorCCSet);
|
|
911
|
+
export { IndicatorCCSet };
|
|
912
|
+
let IndicatorCCReport = IndicatorCCReport_1 = class IndicatorCCReport extends IndicatorCC {
|
|
913
|
+
constructor(options) {
|
|
914
|
+
super(options);
|
|
915
|
+
if ("value" in options) {
|
|
916
|
+
this.indicator0Value = options.value;
|
|
917
|
+
}
|
|
918
|
+
else if ("values" in options) {
|
|
919
|
+
if (options.values.length > MAX_INDICATOR_OBJECTS) {
|
|
920
|
+
throw new ZWaveError(`Only ${MAX_INDICATOR_OBJECTS} indicator values can be set at a time!`, ZWaveErrorCodes.Argument_Invalid);
|
|
921
|
+
}
|
|
922
|
+
this.values = options.values;
|
|
923
|
+
}
|
|
924
|
+
}
|
|
925
|
+
static from(raw, ctx) {
|
|
926
|
+
validatePayload(raw.payload.length >= 1);
|
|
927
|
+
const objCount = raw.payload.length >= 2
|
|
928
|
+
? raw.payload[1] & 0b11111
|
|
929
|
+
: 0;
|
|
930
|
+
if (objCount === 0) {
|
|
931
|
+
const indicator0Value = raw.payload[0];
|
|
932
|
+
return new IndicatorCCReport_1({
|
|
933
|
+
nodeId: ctx.sourceNodeId,
|
|
934
|
+
value: indicator0Value,
|
|
935
|
+
});
|
|
936
|
+
}
|
|
937
|
+
validatePayload(raw.payload.length >= 2 + 3 * objCount);
|
|
938
|
+
const values = [];
|
|
939
|
+
for (let i = 0; i < objCount; i++) {
|
|
940
|
+
const offset = 2 + 3 * i;
|
|
941
|
+
const value = {
|
|
942
|
+
indicatorId: raw.payload[offset],
|
|
943
|
+
propertyId: raw.payload[offset + 1],
|
|
944
|
+
value: raw.payload[offset + 2],
|
|
945
|
+
};
|
|
946
|
+
values.push(value);
|
|
947
|
+
}
|
|
948
|
+
return new IndicatorCCReport_1({
|
|
949
|
+
nodeId: ctx.sourceNodeId,
|
|
950
|
+
values,
|
|
951
|
+
});
|
|
952
|
+
// TODO: Think if we want this:
|
|
953
|
+
// // If not all Property IDs are included in the command for the actual Indicator ID,
|
|
954
|
+
// // a controlling node MUST assume non-specified Property IDs values to be 0x00.
|
|
955
|
+
// const indicatorId = this.values[0].indicatorId;
|
|
956
|
+
// const supportedIndicatorProperties =
|
|
957
|
+
// valueDB.getValue<number[]>(
|
|
958
|
+
// getSupportedPropertyIDsValueID(
|
|
959
|
+
// this.endpointIndex,
|
|
960
|
+
// indicatorId,
|
|
961
|
+
// ),
|
|
962
|
+
// ) ?? [];
|
|
963
|
+
// // Find out which ones are missing
|
|
964
|
+
// const missingIndicatorProperties = supportedIndicatorProperties.filter(
|
|
965
|
+
// prop =>
|
|
966
|
+
// !this.values!.find(({ propertyId }) => prop === propertyId),
|
|
967
|
+
// );
|
|
968
|
+
// // And assume they are 0 (false)
|
|
969
|
+
// for (const missing of missingIndicatorProperties) {
|
|
970
|
+
// this.setIndicatorValue({
|
|
971
|
+
// indicatorId,
|
|
972
|
+
// propertyId: missing,
|
|
973
|
+
// value: 0,
|
|
974
|
+
// });
|
|
975
|
+
// }
|
|
976
|
+
}
|
|
977
|
+
persistValues(ctx) {
|
|
978
|
+
if (!super.persistValues(ctx))
|
|
979
|
+
return false;
|
|
980
|
+
if (this.indicator0Value != undefined) {
|
|
981
|
+
if (!this.supportsV2Indicators(ctx)) {
|
|
982
|
+
// Publish the value
|
|
983
|
+
const valueV1 = IndicatorCCValues.valueV1;
|
|
984
|
+
this.setMetadata(ctx, valueV1);
|
|
985
|
+
this.setValue(ctx, valueV1, this.indicator0Value);
|
|
986
|
+
}
|
|
987
|
+
else {
|
|
988
|
+
if (this.isSinglecast()) {
|
|
989
|
+
// Don't!
|
|
990
|
+
ctx.logNode(this.nodeId, {
|
|
991
|
+
message: `ignoring V1 indicator report because the node supports V2 indicators`,
|
|
992
|
+
direction: "none",
|
|
993
|
+
endpoint: this.endpointIndex,
|
|
994
|
+
});
|
|
995
|
+
}
|
|
996
|
+
}
|
|
997
|
+
}
|
|
998
|
+
else if (this.values) {
|
|
999
|
+
// Store the simple values first
|
|
1000
|
+
for (const value of this.values) {
|
|
1001
|
+
this.setIndicatorValue(ctx, value);
|
|
1002
|
+
}
|
|
1003
|
+
// Then group values into the convenience properties
|
|
1004
|
+
// ... timeout
|
|
1005
|
+
const timeout = indicatorObjectsToTimeout(this.values);
|
|
1006
|
+
if (timeout) {
|
|
1007
|
+
let timeoutString = "";
|
|
1008
|
+
if (timeout?.hours)
|
|
1009
|
+
timeoutString += `${timeout.hours}h`;
|
|
1010
|
+
if (timeout?.minutes)
|
|
1011
|
+
timeoutString += `${timeout.minutes}m`;
|
|
1012
|
+
if (timeout?.seconds)
|
|
1013
|
+
timeoutString += `${timeout.seconds}s`;
|
|
1014
|
+
this.setValue(ctx, IndicatorCCValues.timeout, timeoutString);
|
|
1015
|
+
}
|
|
1016
|
+
}
|
|
1017
|
+
return true;
|
|
1018
|
+
}
|
|
1019
|
+
indicator0Value;
|
|
1020
|
+
values;
|
|
1021
|
+
setIndicatorValue(ctx, value) {
|
|
1022
|
+
// Manufacturer-defined indicators may need a custom label
|
|
1023
|
+
const overrideIndicatorLabel = isManufacturerDefinedIndicator(value.indicatorId)
|
|
1024
|
+
? this.getValue(ctx, IndicatorCCValues.indicatorDescription(value.indicatorId))
|
|
1025
|
+
: undefined;
|
|
1026
|
+
const metadata = getIndicatorMetadata(value.indicatorId, value.propertyId, overrideIndicatorLabel);
|
|
1027
|
+
// Some values need to be converted
|
|
1028
|
+
if (metadata.type === "boolean") {
|
|
1029
|
+
value.value = !!value.value;
|
|
1030
|
+
}
|
|
1031
|
+
// Publish the value
|
|
1032
|
+
const valueV2 = IndicatorCCValues.valueV2(value.indicatorId, value.propertyId);
|
|
1033
|
+
this.setMetadata(ctx, valueV2, metadata);
|
|
1034
|
+
this.setValue(ctx, valueV2, value.value);
|
|
1035
|
+
}
|
|
1036
|
+
serialize(ctx) {
|
|
1037
|
+
if (this.values != undefined) {
|
|
1038
|
+
// V2+
|
|
1039
|
+
this.payload = Bytes.alloc(2 + 3 * this.values.length, 0);
|
|
1040
|
+
// Byte 0 is the legacy value
|
|
1041
|
+
const objCount = this.values.length & MAX_INDICATOR_OBJECTS;
|
|
1042
|
+
this.payload[1] = objCount;
|
|
1043
|
+
for (let i = 0; i < objCount; i++) {
|
|
1044
|
+
const offset = 2 + 3 * i;
|
|
1045
|
+
this.payload[offset] = this.values[i].indicatorId;
|
|
1046
|
+
this.payload[offset + 1] = this.values[i].propertyId;
|
|
1047
|
+
const value = this.values[i].value;
|
|
1048
|
+
this.payload[offset + 2] = value === true
|
|
1049
|
+
? 0xff
|
|
1050
|
+
: value === false
|
|
1051
|
+
? 0x00
|
|
1052
|
+
: value;
|
|
1053
|
+
}
|
|
1054
|
+
}
|
|
1055
|
+
else {
|
|
1056
|
+
// V1
|
|
1057
|
+
this.payload = Bytes.from([this.indicator0Value ?? 0]);
|
|
1058
|
+
}
|
|
1059
|
+
return super.serialize(ctx);
|
|
1060
|
+
}
|
|
1061
|
+
toLogEntry(ctx) {
|
|
1062
|
+
const message = {};
|
|
1063
|
+
if (this.indicator0Value != undefined) {
|
|
1064
|
+
message["indicator 0 value"] = this.indicator0Value;
|
|
1065
|
+
}
|
|
1066
|
+
if (this.values != undefined) {
|
|
1067
|
+
message.values = `${this.values
|
|
1068
|
+
.map((v) => `
|
|
1069
|
+
· indicatorId: ${v.indicatorId}
|
|
1070
|
+
propertyId: ${v.propertyId}
|
|
1071
|
+
value: ${v.value}`)
|
|
1072
|
+
.join("")}`;
|
|
1073
|
+
}
|
|
1074
|
+
return {
|
|
1075
|
+
...super.toLogEntry(ctx),
|
|
1076
|
+
message,
|
|
1077
|
+
};
|
|
1078
|
+
}
|
|
1079
|
+
};
|
|
1080
|
+
IndicatorCCReport = IndicatorCCReport_1 = __decorate([
|
|
1081
|
+
CCCommand(IndicatorCommand.Report)
|
|
1082
|
+
], IndicatorCCReport);
|
|
1083
|
+
export { IndicatorCCReport };
|
|
1084
|
+
let IndicatorCCGet = IndicatorCCGet_1 = class IndicatorCCGet extends IndicatorCC {
|
|
1085
|
+
constructor(options) {
|
|
1086
|
+
super(options);
|
|
1087
|
+
this.indicatorId = options.indicatorId;
|
|
1088
|
+
}
|
|
1089
|
+
static from(raw, ctx) {
|
|
1090
|
+
let indicatorId;
|
|
1091
|
+
if (raw.payload.length > 0) {
|
|
1092
|
+
indicatorId = raw.payload[0];
|
|
1093
|
+
}
|
|
1094
|
+
return new IndicatorCCGet_1({
|
|
1095
|
+
nodeId: ctx.sourceNodeId,
|
|
1096
|
+
indicatorId,
|
|
1097
|
+
});
|
|
1098
|
+
}
|
|
1099
|
+
indicatorId;
|
|
1100
|
+
serialize(ctx) {
|
|
1101
|
+
if (this.indicatorId != undefined) {
|
|
1102
|
+
this.payload = Bytes.from([this.indicatorId]);
|
|
1103
|
+
}
|
|
1104
|
+
return super.serialize(ctx);
|
|
1105
|
+
}
|
|
1106
|
+
toLogEntry(ctx) {
|
|
1107
|
+
return {
|
|
1108
|
+
...super.toLogEntry(ctx),
|
|
1109
|
+
message: {
|
|
1110
|
+
indicator: getIndicatorName(this.indicatorId),
|
|
1111
|
+
},
|
|
1112
|
+
};
|
|
1113
|
+
}
|
|
1114
|
+
};
|
|
1115
|
+
IndicatorCCGet = IndicatorCCGet_1 = __decorate([
|
|
1116
|
+
CCCommand(IndicatorCommand.Get),
|
|
1117
|
+
expectedCCResponse(IndicatorCCReport)
|
|
1118
|
+
], IndicatorCCGet);
|
|
1119
|
+
export { IndicatorCCGet };
|
|
1120
|
+
let IndicatorCCSupportedReport = IndicatorCCSupportedReport_1 = class IndicatorCCSupportedReport extends IndicatorCC {
|
|
1121
|
+
constructor(options) {
|
|
1122
|
+
super(options);
|
|
1123
|
+
this.indicatorId = options.indicatorId;
|
|
1124
|
+
this.nextIndicatorId = options.nextIndicatorId;
|
|
1125
|
+
this.supportedProperties = options.supportedProperties;
|
|
1126
|
+
}
|
|
1127
|
+
static from(raw, ctx) {
|
|
1128
|
+
validatePayload(raw.payload.length >= 3);
|
|
1129
|
+
const indicatorId = raw.payload[0];
|
|
1130
|
+
const nextIndicatorId = raw.payload[1];
|
|
1131
|
+
const bitMaskLength = raw.payload[2] & 0b11111;
|
|
1132
|
+
let supportedProperties;
|
|
1133
|
+
if (bitMaskLength === 0) {
|
|
1134
|
+
supportedProperties = [];
|
|
1135
|
+
}
|
|
1136
|
+
else {
|
|
1137
|
+
validatePayload(raw.payload.length >= 3 + bitMaskLength);
|
|
1138
|
+
// The bit mask starts at 0, but bit 0 is not used
|
|
1139
|
+
supportedProperties = parseBitMask(raw.payload.subarray(3, 3 + bitMaskLength), 0).filter((v) => v !== 0);
|
|
1140
|
+
}
|
|
1141
|
+
return new IndicatorCCSupportedReport_1({
|
|
1142
|
+
nodeId: ctx.sourceNodeId,
|
|
1143
|
+
indicatorId,
|
|
1144
|
+
nextIndicatorId,
|
|
1145
|
+
supportedProperties,
|
|
1146
|
+
});
|
|
1147
|
+
}
|
|
1148
|
+
persistValues(ctx) {
|
|
1149
|
+
if (!super.persistValues(ctx))
|
|
1150
|
+
return false;
|
|
1151
|
+
if (this.indicatorId !== 0x00) {
|
|
1152
|
+
// Remember which property IDs are supported
|
|
1153
|
+
this.setValue(ctx, IndicatorCCValues.supportedPropertyIDs(this.indicatorId), this.supportedProperties);
|
|
1154
|
+
}
|
|
1155
|
+
return true;
|
|
1156
|
+
}
|
|
1157
|
+
indicatorId;
|
|
1158
|
+
nextIndicatorId;
|
|
1159
|
+
supportedProperties;
|
|
1160
|
+
serialize(ctx) {
|
|
1161
|
+
const bitmask = this.supportedProperties.length > 0
|
|
1162
|
+
? encodeBitMask(this.supportedProperties, undefined, 0)
|
|
1163
|
+
: new Bytes();
|
|
1164
|
+
this.payload = Bytes.concat([
|
|
1165
|
+
Bytes.from([
|
|
1166
|
+
this.indicatorId,
|
|
1167
|
+
this.nextIndicatorId,
|
|
1168
|
+
bitmask.length,
|
|
1169
|
+
]),
|
|
1170
|
+
bitmask,
|
|
1171
|
+
]);
|
|
1172
|
+
return super.serialize(ctx);
|
|
1173
|
+
}
|
|
1174
|
+
toLogEntry(ctx) {
|
|
1175
|
+
return {
|
|
1176
|
+
...super.toLogEntry(ctx),
|
|
1177
|
+
message: {
|
|
1178
|
+
indicator: getIndicatorName(this.indicatorId),
|
|
1179
|
+
"supported properties": `${this.supportedProperties
|
|
1180
|
+
.map((id) => getIndicatorProperty(id)?.label
|
|
1181
|
+
?? `Unknown (${num2hex(id)})`)
|
|
1182
|
+
.join(", ")}`,
|
|
1183
|
+
"next indicator": getIndicatorName(this.nextIndicatorId),
|
|
1184
|
+
},
|
|
1185
|
+
};
|
|
1186
|
+
}
|
|
1187
|
+
};
|
|
1188
|
+
IndicatorCCSupportedReport = IndicatorCCSupportedReport_1 = __decorate([
|
|
1189
|
+
CCCommand(IndicatorCommand.SupportedReport)
|
|
1190
|
+
], IndicatorCCSupportedReport);
|
|
1191
|
+
export { IndicatorCCSupportedReport };
|
|
1192
|
+
function testResponseForIndicatorSupportedGet(sent, received) {
|
|
1193
|
+
return sent.indicatorId === 0 || received.indicatorId === sent.indicatorId;
|
|
1194
|
+
}
|
|
1195
|
+
let IndicatorCCSupportedGet = IndicatorCCSupportedGet_1 = class IndicatorCCSupportedGet extends IndicatorCC {
|
|
1196
|
+
constructor(options) {
|
|
1197
|
+
super(options);
|
|
1198
|
+
this.indicatorId = options.indicatorId;
|
|
1199
|
+
}
|
|
1200
|
+
static from(raw, ctx) {
|
|
1201
|
+
validatePayload(raw.payload.length >= 1);
|
|
1202
|
+
const indicatorId = raw.payload[0];
|
|
1203
|
+
return new IndicatorCCSupportedGet_1({
|
|
1204
|
+
nodeId: ctx.sourceNodeId,
|
|
1205
|
+
indicatorId,
|
|
1206
|
+
});
|
|
1207
|
+
}
|
|
1208
|
+
indicatorId;
|
|
1209
|
+
serialize(ctx) {
|
|
1210
|
+
this.payload = Bytes.from([this.indicatorId]);
|
|
1211
|
+
return super.serialize(ctx);
|
|
1212
|
+
}
|
|
1213
|
+
toLogEntry(ctx) {
|
|
1214
|
+
return {
|
|
1215
|
+
...super.toLogEntry(ctx),
|
|
1216
|
+
message: {
|
|
1217
|
+
indicator: getIndicatorName(this.indicatorId),
|
|
1218
|
+
},
|
|
1219
|
+
};
|
|
1220
|
+
}
|
|
1221
|
+
};
|
|
1222
|
+
IndicatorCCSupportedGet = IndicatorCCSupportedGet_1 = __decorate([
|
|
1223
|
+
CCCommand(IndicatorCommand.SupportedGet),
|
|
1224
|
+
expectedCCResponse(IndicatorCCSupportedReport, testResponseForIndicatorSupportedGet)
|
|
1225
|
+
], IndicatorCCSupportedGet);
|
|
1226
|
+
export { IndicatorCCSupportedGet };
|
|
1227
|
+
let IndicatorCCDescriptionReport = IndicatorCCDescriptionReport_1 = class IndicatorCCDescriptionReport extends IndicatorCC {
|
|
1228
|
+
constructor(options) {
|
|
1229
|
+
super(options);
|
|
1230
|
+
this.indicatorId = options.indicatorId;
|
|
1231
|
+
this.description = options.description;
|
|
1232
|
+
}
|
|
1233
|
+
static from(raw, ctx) {
|
|
1234
|
+
validatePayload(raw.payload.length >= 2);
|
|
1235
|
+
const indicatorId = raw.payload[0];
|
|
1236
|
+
const descrptionLength = raw.payload[1];
|
|
1237
|
+
validatePayload(raw.payload.length >= 2 + descrptionLength);
|
|
1238
|
+
const description = raw.payload
|
|
1239
|
+
.subarray(2, 2 + descrptionLength)
|
|
1240
|
+
.toString("utf8");
|
|
1241
|
+
return new IndicatorCCDescriptionReport_1({
|
|
1242
|
+
nodeId: ctx.sourceNodeId,
|
|
1243
|
+
indicatorId,
|
|
1244
|
+
description,
|
|
1245
|
+
});
|
|
1246
|
+
}
|
|
1247
|
+
indicatorId;
|
|
1248
|
+
description;
|
|
1249
|
+
persistValues(ctx) {
|
|
1250
|
+
if (!super.persistValues(ctx))
|
|
1251
|
+
return false;
|
|
1252
|
+
if (this.description) {
|
|
1253
|
+
this.setValue(ctx, IndicatorCCValues.indicatorDescription(this.indicatorId), this.description);
|
|
1254
|
+
}
|
|
1255
|
+
return true;
|
|
1256
|
+
}
|
|
1257
|
+
serialize(ctx) {
|
|
1258
|
+
const description = Bytes.from(this.description, "utf8");
|
|
1259
|
+
this.payload = Bytes.concat([
|
|
1260
|
+
Bytes.from([this.indicatorId, description.length]),
|
|
1261
|
+
description,
|
|
1262
|
+
]);
|
|
1263
|
+
return super.serialize(ctx);
|
|
1264
|
+
}
|
|
1265
|
+
toLogEntry(ctx) {
|
|
1266
|
+
return {
|
|
1267
|
+
...super.toLogEntry(ctx),
|
|
1268
|
+
message: {
|
|
1269
|
+
"indicator ID": this.indicatorId,
|
|
1270
|
+
description: this.description || "(none)",
|
|
1271
|
+
},
|
|
1272
|
+
};
|
|
1273
|
+
}
|
|
1274
|
+
};
|
|
1275
|
+
IndicatorCCDescriptionReport = IndicatorCCDescriptionReport_1 = __decorate([
|
|
1276
|
+
CCCommand(IndicatorCommand.DescriptionReport)
|
|
1277
|
+
], IndicatorCCDescriptionReport);
|
|
1278
|
+
export { IndicatorCCDescriptionReport };
|
|
1279
|
+
function testResponseForIndicatorDescriptionGet(sent, received) {
|
|
1280
|
+
return received.indicatorId === sent.indicatorId;
|
|
1281
|
+
}
|
|
1282
|
+
let IndicatorCCDescriptionGet = IndicatorCCDescriptionGet_1 = class IndicatorCCDescriptionGet extends IndicatorCC {
|
|
1283
|
+
constructor(options) {
|
|
1284
|
+
super(options);
|
|
1285
|
+
this.indicatorId = options.indicatorId;
|
|
1286
|
+
if (!isManufacturerDefinedIndicator(this.indicatorId)) {
|
|
1287
|
+
throw new ZWaveError("The indicator ID must be between 0x80 and 0x9f", ZWaveErrorCodes.Argument_Invalid);
|
|
1288
|
+
}
|
|
1289
|
+
}
|
|
1290
|
+
static from(raw, ctx) {
|
|
1291
|
+
validatePayload(raw.payload.length >= 1);
|
|
1292
|
+
const indicatorId = raw.payload[0];
|
|
1293
|
+
return new IndicatorCCDescriptionGet_1({
|
|
1294
|
+
nodeId: ctx.sourceNodeId,
|
|
1295
|
+
indicatorId,
|
|
1296
|
+
});
|
|
1297
|
+
}
|
|
1298
|
+
indicatorId;
|
|
1299
|
+
serialize(ctx) {
|
|
1300
|
+
this.payload = Bytes.from([this.indicatorId]);
|
|
1301
|
+
return super.serialize(ctx);
|
|
1302
|
+
}
|
|
1303
|
+
toLogEntry(ctx) {
|
|
1304
|
+
return {
|
|
1305
|
+
...super.toLogEntry(ctx),
|
|
1306
|
+
message: {
|
|
1307
|
+
"indicator ID": this.indicatorId,
|
|
1308
|
+
},
|
|
1309
|
+
};
|
|
1310
|
+
}
|
|
1311
|
+
};
|
|
1312
|
+
IndicatorCCDescriptionGet = IndicatorCCDescriptionGet_1 = __decorate([
|
|
1313
|
+
CCCommand(IndicatorCommand.DescriptionGet),
|
|
1314
|
+
expectedCCResponse(IndicatorCCDescriptionReport, testResponseForIndicatorDescriptionGet)
|
|
1315
|
+
], IndicatorCCDescriptionGet);
|
|
1316
|
+
export { IndicatorCCDescriptionGet };
|
|
1317
|
+
//# sourceMappingURL=IndicatorCC.js.map
|