@zwave-js/cc 15.0.0-beta.0 → 15.0.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/cc/AlarmSensorCC.d.ts +79 -161
- package/build/cjs/cc/AlarmSensorCC.js +12 -50
- package/build/cjs/cc/AlarmSensorCC.js.map +2 -2
- package/build/cjs/cc/AssociationCC.d.ts +63 -199
- package/build/cjs/cc/AssociationCC.js +9 -22
- package/build/cjs/cc/AssociationCC.js.map +2 -2
- package/build/cjs/cc/AssociationGroupInfoCC.d.ts +66 -166
- package/build/cjs/cc/AssociationGroupInfoCC.js +11 -22
- package/build/cjs/cc/AssociationGroupInfoCC.js.map +2 -2
- package/build/cjs/cc/BarrierOperatorCC.d.ts +86 -294
- package/build/cjs/cc/BarrierOperatorCC.js +12 -44
- package/build/cjs/cc/BarrierOperatorCC.js.map +2 -2
- package/build/cjs/cc/BasicCC.d.ts +85 -331
- package/build/cjs/cc/BasicCC.js +15 -46
- package/build/cjs/cc/BasicCC.js.map +2 -2
- package/build/cjs/cc/BatteryCC.d.ts +237 -835
- package/build/cjs/cc/BatteryCC.js +7 -84
- package/build/cjs/cc/BatteryCC.js.map +2 -2
- package/build/cjs/cc/BinarySensorCC.d.ts +34 -99
- package/build/cjs/cc/BinarySensorCC.js +9 -29
- package/build/cjs/cc/BinarySensorCC.js.map +2 -2
- package/build/cjs/cc/BinarySwitchCC.d.ts +45 -197
- package/build/cjs/cc/BinarySwitchCC.js +6 -22
- package/build/cjs/cc/BinarySwitchCC.js.map +2 -2
- package/build/cjs/cc/CentralSceneCC.d.ts +77 -296
- package/build/cjs/cc/CentralSceneCC.js +7 -30
- package/build/cjs/cc/CentralSceneCC.js.map +2 -2
- package/build/cjs/cc/ClimateControlScheduleCC.d.ts +45 -160
- package/build/cjs/cc/ClimateControlScheduleCC.js +5 -24
- package/build/cjs/cc/ClimateControlScheduleCC.js.map +2 -2
- package/build/cjs/cc/ColorSwitchCC.d.ts +130 -457
- package/build/cjs/cc/ColorSwitchCC.js +23 -75
- package/build/cjs/cc/ColorSwitchCC.js.map +2 -2
- package/build/cjs/cc/ConfigurationCC.d.ts +32 -100
- package/build/cjs/cc/ConfigurationCC.js +11 -31
- package/build/cjs/cc/ConfigurationCC.js.map +2 -2
- package/build/cjs/cc/DoorLockCC.d.ts +512 -1823
- package/build/cjs/cc/DoorLockCC.js +51 -156
- package/build/cjs/cc/DoorLockCC.js.map +2 -2
- package/build/cjs/cc/DoorLockLoggingCC.d.ts +11 -63
- package/build/cjs/cc/DoorLockLoggingCC.js +4 -8
- package/build/cjs/cc/DoorLockLoggingCC.js.map +2 -2
- package/build/cjs/cc/EnergyProductionCC.d.ts +14 -29
- package/build/cjs/cc/EnergyProductionCC.js +5 -17
- package/build/cjs/cc/EnergyProductionCC.js.map +2 -2
- package/build/cjs/cc/EntryControlCC.d.ts +73 -324
- package/build/cjs/cc/EntryControlCC.js +9 -36
- package/build/cjs/cc/EntryControlCC.js.map +2 -2
- package/build/cjs/cc/FirmwareUpdateMetaDataCC.d.ts +78 -390
- package/build/cjs/cc/FirmwareUpdateMetaDataCC.js +5 -26
- package/build/cjs/cc/FirmwareUpdateMetaDataCC.js.map +2 -2
- package/build/cjs/cc/HumidityControlModeCC.d.ts +31 -131
- package/build/cjs/cc/HumidityControlModeCC.js +6 -15
- package/build/cjs/cc/HumidityControlModeCC.js.map +2 -2
- package/build/cjs/cc/HumidityControlOperatingStateCC.d.ts +17 -65
- package/build/cjs/cc/HumidityControlOperatingStateCC.js +4 -12
- package/build/cjs/cc/HumidityControlOperatingStateCC.js.map +2 -2
- package/build/cjs/cc/HumidityControlSetpointCC.d.ts +51 -128
- package/build/cjs/cc/HumidityControlSetpointCC.js +10 -28
- package/build/cjs/cc/HumidityControlSetpointCC.js.map +2 -2
- package/build/cjs/cc/IndicatorCC.d.ts +123 -365
- package/build/cjs/cc/IndicatorCC.js +15 -61
- package/build/cjs/cc/IndicatorCC.js.map +2 -2
- package/build/cjs/cc/IrrigationCC.d.ts +826 -2317
- package/build/cjs/cc/IrrigationCC.js +29 -233
- package/build/cjs/cc/IrrigationCC.js.map +2 -2
- package/build/cjs/cc/LanguageCC.d.ts +31 -133
- package/build/cjs/cc/LanguageCC.js +4 -15
- package/build/cjs/cc/LanguageCC.js.map +2 -2
- package/build/cjs/cc/LockCC.d.ts +14 -64
- package/build/cjs/cc/LockCC.js +4 -12
- package/build/cjs/cc/LockCC.js.map +2 -2
- package/build/cjs/cc/ManufacturerProprietaryCC.js.map +2 -2
- package/build/cjs/cc/ManufacturerSpecificCC.d.ts +77 -239
- package/build/cjs/cc/ManufacturerSpecificCC.js +5 -26
- package/build/cjs/cc/ManufacturerSpecificCC.js.map +2 -2
- package/build/cjs/cc/MeterCC.d.ts +119 -393
- package/build/cjs/cc/MeterCC.js +25 -69
- package/build/cjs/cc/MeterCC.js.map +2 -2
- package/build/cjs/cc/MultiChannelAssociationCC.d.ts +66 -166
- package/build/cjs/cc/MultiChannelAssociationCC.js +10 -23
- package/build/cjs/cc/MultiChannelAssociationCC.js.map +2 -2
- package/build/cjs/cc/MultiChannelCC.d.ts +119 -499
- package/build/cjs/cc/MultiChannelCC.js +18 -46
- package/build/cjs/cc/MultiChannelCC.js.map +2 -2
- package/build/cjs/cc/MultilevelSensorCC.d.ts +46 -130
- package/build/cjs/cc/MultilevelSensorCC.js +12 -33
- package/build/cjs/cc/MultilevelSensorCC.js.map +2 -2
- package/build/cjs/cc/MultilevelSwitchCC.d.ts +160 -525
- package/build/cjs/cc/MultilevelSwitchCC.js +13 -107
- package/build/cjs/cc/MultilevelSwitchCC.js.map +2 -2
- package/build/cjs/cc/NodeNamingCC.d.ts +33 -135
- package/build/cjs/cc/NodeNamingCC.js +5 -16
- package/build/cjs/cc/NodeNamingCC.js.map +2 -2
- package/build/cjs/cc/NotificationCC.d.ts +262 -702
- package/build/cjs/cc/NotificationCC.js +29 -112
- package/build/cjs/cc/NotificationCC.js.map +2 -2
- package/build/cjs/cc/ProtectionCC.d.ts +118 -524
- package/build/cjs/cc/ProtectionCC.js +15 -50
- package/build/cjs/cc/ProtectionCC.js.map +2 -2
- package/build/cjs/cc/SceneActivationCC.d.ts +33 -132
- package/build/cjs/cc/SceneActivationCC.js +4 -17
- package/build/cjs/cc/SceneActivationCC.js.map +2 -2
- package/build/cjs/cc/SceneActuatorConfigurationCC.d.ts +34 -61
- package/build/cjs/cc/SceneActuatorConfigurationCC.js +9 -21
- package/build/cjs/cc/SceneActuatorConfigurationCC.js.map +2 -2
- package/build/cjs/cc/SceneControllerConfigurationCC.d.ts +34 -61
- package/build/cjs/cc/SceneControllerConfigurationCC.js +10 -22
- package/build/cjs/cc/SceneControllerConfigurationCC.js.map +2 -2
- package/build/cjs/cc/ScheduleEntryLockCC.d.ts +95 -299
- package/build/cjs/cc/ScheduleEntryLockCC.js +13 -30
- package/build/cjs/cc/ScheduleEntryLockCC.js.map +2 -2
- package/build/cjs/cc/SoundSwitchCC.d.ts +72 -261
- package/build/cjs/cc/SoundSwitchCC.js +11 -43
- package/build/cjs/cc/SoundSwitchCC.js.map +2 -2
- package/build/cjs/cc/SupervisionCC.d.ts +17 -33
- package/build/cjs/cc/SupervisionCC.js +4 -9
- package/build/cjs/cc/SupervisionCC.js.map +2 -2
- package/build/cjs/cc/ThermostatFanModeCC.d.ts +44 -195
- package/build/cjs/cc/ThermostatFanModeCC.js +8 -21
- package/build/cjs/cc/ThermostatFanModeCC.js.map +2 -2
- package/build/cjs/cc/ThermostatFanStateCC.d.ts +17 -65
- package/build/cjs/cc/ThermostatFanStateCC.js +4 -12
- package/build/cjs/cc/ThermostatFanStateCC.js.map +2 -2
- package/build/cjs/cc/ThermostatModeCC.d.ts +44 -195
- package/build/cjs/cc/ThermostatModeCC.js +8 -21
- package/build/cjs/cc/ThermostatModeCC.js.map +2 -2
- package/build/cjs/cc/ThermostatOperatingStateCC.d.ts +17 -65
- package/build/cjs/cc/ThermostatOperatingStateCC.js +4 -12
- package/build/cjs/cc/ThermostatOperatingStateCC.js.map +2 -2
- package/build/cjs/cc/ThermostatSetpointCC.d.ts +49 -129
- package/build/cjs/cc/ThermostatSetpointCC.js +10 -25
- package/build/cjs/cc/ThermostatSetpointCC.js.map +2 -2
- package/build/cjs/cc/TimeParametersCC.d.ts +12 -63
- package/build/cjs/cc/TimeParametersCC.js +4 -11
- package/build/cjs/cc/TimeParametersCC.js.map +2 -2
- package/build/cjs/cc/UserCodeCC.d.ts +311 -1066
- package/build/cjs/cc/UserCodeCC.js +33 -98
- package/build/cjs/cc/UserCodeCC.js.map +2 -2
- package/build/cjs/cc/VersionCC.d.ts +289 -1003
- package/build/cjs/cc/VersionCC.js +7 -98
- package/build/cjs/cc/VersionCC.js.map +2 -2
- package/build/cjs/cc/WakeUpCC.d.ts +49 -201
- package/build/cjs/cc/WakeUpCC.js +6 -26
- package/build/cjs/cc/WakeUpCC.js.map +2 -2
- package/build/cjs/cc/WindowCoveringCC.d.ts +126 -220
- package/build/cjs/cc/WindowCoveringCC.js +16 -128
- package/build/cjs/cc/WindowCoveringCC.js.map +2 -2
- package/build/cjs/cc/ZWavePlusCC.d.ts +69 -329
- package/build/cjs/cc/ZWavePlusCC.js +4 -25
- package/build/cjs/cc/ZWavePlusCC.js.map +2 -2
- package/build/cjs/cc/_CCValues.generated.d.ts +15814 -0
- package/build/cjs/cc/_CCValues.generated.js +8723 -0
- package/build/cjs/cc/_CCValues.generated.js.map +7 -0
- package/build/cjs/lib/CCValueUtils.d.ts +14 -0
- package/build/cjs/lib/CCValueUtils.js +93 -0
- package/build/cjs/lib/CCValueUtils.js.map +7 -0
- package/build/cjs/lib/Values.d.ts +6 -105
- package/build/cjs/lib/Values.js +13 -107
- package/build/cjs/lib/Values.js.map +3 -3
- package/build/esm/cc/AlarmSensorCC.d.ts +79 -161
- package/build/esm/cc/AlarmSensorCC.d.ts.map +1 -1
- package/build/esm/cc/AlarmSensorCC.js +2 -39
- package/build/esm/cc/AlarmSensorCC.js.map +1 -1
- package/build/esm/cc/AssociationCC.d.ts +63 -199
- package/build/esm/cc/AssociationCC.d.ts.map +1 -1
- package/build/esm/cc/AssociationCC.js +2 -14
- package/build/esm/cc/AssociationCC.js.map +1 -1
- package/build/esm/cc/AssociationGroupInfoCC.d.ts +66 -166
- package/build/esm/cc/AssociationGroupInfoCC.d.ts.map +1 -1
- package/build/esm/cc/AssociationGroupInfoCC.js +2 -13
- package/build/esm/cc/AssociationGroupInfoCC.js.map +1 -1
- package/build/esm/cc/BarrierOperatorCC.d.ts +86 -294
- package/build/esm/cc/BarrierOperatorCC.d.ts.map +1 -1
- package/build/esm/cc/BarrierOperatorCC.js +2 -34
- package/build/esm/cc/BarrierOperatorCC.js.map +1 -1
- package/build/esm/cc/BasicCC.d.ts +85 -331
- package/build/esm/cc/BasicCC.d.ts.map +1 -1
- package/build/esm/cc/BasicCC.js +2 -32
- package/build/esm/cc/BasicCC.js.map +1 -1
- package/build/esm/cc/BatteryCC.d.ts +237 -835
- package/build/esm/cc/BatteryCC.d.ts.map +1 -1
- package/build/esm/cc/BatteryCC.js +2 -78
- package/build/esm/cc/BatteryCC.js.map +1 -1
- package/build/esm/cc/BinarySensorCC.d.ts +34 -99
- package/build/esm/cc/BinarySensorCC.d.ts.map +1 -1
- package/build/esm/cc/BinarySensorCC.js +2 -16
- package/build/esm/cc/BinarySensorCC.js.map +1 -1
- package/build/esm/cc/BinarySwitchCC.d.ts +45 -197
- package/build/esm/cc/BinarySwitchCC.d.ts.map +1 -1
- package/build/esm/cc/BinarySwitchCC.js +2 -17
- package/build/esm/cc/BinarySwitchCC.js.map +1 -1
- package/build/esm/cc/CentralSceneCC.d.ts +77 -296
- package/build/esm/cc/CentralSceneCC.d.ts.map +1 -1
- package/build/esm/cc/CentralSceneCC.js +2 -26
- package/build/esm/cc/CentralSceneCC.js.map +1 -1
- package/build/esm/cc/ClimateControlScheduleCC.d.ts +45 -160
- package/build/esm/cc/ClimateControlScheduleCC.d.ts.map +1 -1
- package/build/esm/cc/ClimateControlScheduleCC.js +2 -23
- package/build/esm/cc/ClimateControlScheduleCC.js.map +1 -1
- package/build/esm/cc/ColorSwitchCC.d.ts +130 -457
- package/build/esm/cc/ColorSwitchCC.d.ts.map +1 -1
- package/build/esm/cc/ColorSwitchCC.js +2 -52
- package/build/esm/cc/ColorSwitchCC.js.map +1 -1
- package/build/esm/cc/ConfigurationCC.d.ts +32 -100
- package/build/esm/cc/ConfigurationCC.d.ts.map +1 -1
- package/build/esm/cc/ConfigurationCC.js +2 -15
- package/build/esm/cc/ConfigurationCC.js.map +1 -1
- package/build/esm/cc/DoorLockCC.d.ts +512 -1823
- package/build/esm/cc/DoorLockCC.d.ts.map +1 -1
- package/build/esm/cc/DoorLockCC.js +9 -127
- package/build/esm/cc/DoorLockCC.js.map +1 -1
- package/build/esm/cc/DoorLockLoggingCC.d.ts +11 -63
- package/build/esm/cc/DoorLockLoggingCC.d.ts.map +1 -1
- package/build/esm/cc/DoorLockLoggingCC.js +2 -5
- package/build/esm/cc/DoorLockLoggingCC.js.map +1 -1
- package/build/esm/cc/EnergyProductionCC.d.ts +14 -29
- package/build/esm/cc/EnergyProductionCC.d.ts.map +1 -1
- package/build/esm/cc/EnergyProductionCC.js +2 -13
- package/build/esm/cc/EnergyProductionCC.js.map +1 -1
- package/build/esm/cc/EntryControlCC.d.ts +73 -324
- package/build/esm/cc/EntryControlCC.d.ts.map +1 -1
- package/build/esm/cc/EntryControlCC.js +2 -28
- package/build/esm/cc/EntryControlCC.js.map +1 -1
- package/build/esm/cc/FirmwareUpdateMetaDataCC.d.ts +78 -390
- package/build/esm/cc/FirmwareUpdateMetaDataCC.d.ts.map +1 -1
- package/build/esm/cc/FirmwareUpdateMetaDataCC.js +2 -23
- package/build/esm/cc/FirmwareUpdateMetaDataCC.js.map +1 -1
- package/build/esm/cc/HumidityControlModeCC.d.ts +31 -131
- package/build/esm/cc/HumidityControlModeCC.d.ts.map +1 -1
- package/build/esm/cc/HumidityControlModeCC.js +2 -10
- package/build/esm/cc/HumidityControlModeCC.js.map +1 -1
- package/build/esm/cc/HumidityControlOperatingStateCC.d.ts +17 -65
- package/build/esm/cc/HumidityControlOperatingStateCC.d.ts.map +1 -1
- package/build/esm/cc/HumidityControlOperatingStateCC.js +2 -9
- package/build/esm/cc/HumidityControlOperatingStateCC.js.map +1 -1
- package/build/esm/cc/HumidityControlSetpointCC.d.ts +51 -128
- package/build/esm/cc/HumidityControlSetpointCC.d.ts.map +1 -1
- package/build/esm/cc/HumidityControlSetpointCC.js +2 -19
- package/build/esm/cc/HumidityControlSetpointCC.js.map +1 -1
- package/build/esm/cc/IndicatorCC.d.ts +123 -365
- package/build/esm/cc/IndicatorCC.d.ts.map +1 -1
- package/build/esm/cc/IndicatorCC.js +2 -43
- package/build/esm/cc/IndicatorCC.js.map +1 -1
- package/build/esm/cc/IrrigationCC.d.ts +826 -2317
- package/build/esm/cc/IrrigationCC.d.ts.map +1 -1
- package/build/esm/cc/IrrigationCC.js +3 -222
- package/build/esm/cc/IrrigationCC.js.map +1 -1
- package/build/esm/cc/LanguageCC.d.ts +31 -133
- package/build/esm/cc/LanguageCC.d.ts.map +1 -1
- package/build/esm/cc/LanguageCC.js +2 -12
- package/build/esm/cc/LanguageCC.js.map +1 -1
- package/build/esm/cc/LockCC.d.ts +14 -64
- package/build/esm/cc/LockCC.d.ts.map +1 -1
- package/build/esm/cc/LockCC.js +2 -9
- package/build/esm/cc/LockCC.js.map +1 -1
- package/build/esm/cc/ManufacturerProprietaryCC.d.ts.map +1 -1
- package/build/esm/cc/ManufacturerProprietaryCC.js +0 -1
- package/build/esm/cc/ManufacturerProprietaryCC.js.map +1 -1
- package/build/esm/cc/ManufacturerSpecificCC.d.ts +77 -239
- package/build/esm/cc/ManufacturerSpecificCC.d.ts.map +1 -1
- package/build/esm/cc/ManufacturerSpecificCC.js +2 -24
- package/build/esm/cc/ManufacturerSpecificCC.js.map +1 -1
- package/build/esm/cc/MeterCC.d.ts +119 -393
- package/build/esm/cc/MeterCC.d.ts.map +1 -1
- package/build/esm/cc/MeterCC.js +3 -49
- package/build/esm/cc/MeterCC.js.map +1 -1
- package/build/esm/cc/MultiChannelAssociationCC.d.ts +66 -166
- package/build/esm/cc/MultiChannelAssociationCC.d.ts.map +1 -1
- package/build/esm/cc/MultiChannelAssociationCC.js +2 -14
- package/build/esm/cc/MultiChannelAssociationCC.js.map +1 -1
- package/build/esm/cc/MultiChannelCC.d.ts +119 -499
- package/build/esm/cc/MultiChannelCC.d.ts.map +1 -1
- package/build/esm/cc/MultiChannelCC.js +2 -30
- package/build/esm/cc/MultiChannelCC.js.map +1 -1
- package/build/esm/cc/MultilevelSensorCC.d.ts +46 -130
- package/build/esm/cc/MultilevelSensorCC.d.ts.map +1 -1
- package/build/esm/cc/MultilevelSensorCC.js +2 -22
- package/build/esm/cc/MultilevelSensorCC.js.map +1 -1
- package/build/esm/cc/MultilevelSwitchCC.d.ts +160 -525
- package/build/esm/cc/MultilevelSwitchCC.d.ts.map +1 -1
- package/build/esm/cc/MultilevelSwitchCC.js +5 -101
- package/build/esm/cc/MultilevelSwitchCC.js.map +1 -1
- package/build/esm/cc/NodeNamingCC.d.ts +33 -135
- package/build/esm/cc/NodeNamingCC.d.ts.map +1 -1
- package/build/esm/cc/NodeNamingCC.js +2 -12
- package/build/esm/cc/NodeNamingCC.js.map +1 -1
- package/build/esm/cc/NotificationCC.d.ts +262 -702
- package/build/esm/cc/NotificationCC.d.ts.map +1 -1
- package/build/esm/cc/NotificationCC.js +3 -85
- package/build/esm/cc/NotificationCC.js.map +1 -1
- package/build/esm/cc/ProtectionCC.d.ts +118 -524
- package/build/esm/cc/ProtectionCC.d.ts.map +1 -1
- package/build/esm/cc/ProtectionCC.js +2 -36
- package/build/esm/cc/ProtectionCC.js.map +1 -1
- package/build/esm/cc/SceneActivationCC.d.ts +33 -132
- package/build/esm/cc/SceneActivationCC.d.ts.map +1 -1
- package/build/esm/cc/SceneActivationCC.js +2 -14
- package/build/esm/cc/SceneActivationCC.js.map +1 -1
- package/build/esm/cc/SceneActuatorConfigurationCC.d.ts +34 -61
- package/build/esm/cc/SceneActuatorConfigurationCC.d.ts.map +1 -1
- package/build/esm/cc/SceneActuatorConfigurationCC.js +2 -14
- package/build/esm/cc/SceneActuatorConfigurationCC.js.map +1 -1
- package/build/esm/cc/SceneControllerConfigurationCC.d.ts +34 -61
- package/build/esm/cc/SceneControllerConfigurationCC.d.ts.map +1 -1
- package/build/esm/cc/SceneControllerConfigurationCC.js +2 -14
- package/build/esm/cc/SceneControllerConfigurationCC.js.map +1 -1
- package/build/esm/cc/ScheduleEntryLockCC.d.ts +95 -299
- package/build/esm/cc/ScheduleEntryLockCC.d.ts.map +1 -1
- package/build/esm/cc/ScheduleEntryLockCC.js +2 -17
- package/build/esm/cc/ScheduleEntryLockCC.js.map +1 -1
- package/build/esm/cc/SoundSwitchCC.d.ts +72 -261
- package/build/esm/cc/SoundSwitchCC.d.ts.map +1 -1
- package/build/esm/cc/SoundSwitchCC.js +2 -33
- package/build/esm/cc/SoundSwitchCC.js.map +1 -1
- package/build/esm/cc/SupervisionCC.d.ts +17 -33
- package/build/esm/cc/SupervisionCC.d.ts.map +1 -1
- package/build/esm/cc/SupervisionCC.js +2 -7
- package/build/esm/cc/SupervisionCC.js.map +1 -1
- package/build/esm/cc/ThermostatFanModeCC.d.ts +44 -195
- package/build/esm/cc/ThermostatFanModeCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatFanModeCC.js +2 -14
- package/build/esm/cc/ThermostatFanModeCC.js.map +1 -1
- package/build/esm/cc/ThermostatFanStateCC.d.ts +17 -65
- package/build/esm/cc/ThermostatFanStateCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatFanStateCC.js +2 -9
- package/build/esm/cc/ThermostatFanStateCC.js.map +1 -1
- package/build/esm/cc/ThermostatModeCC.d.ts +44 -195
- package/build/esm/cc/ThermostatModeCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatModeCC.js +2 -14
- package/build/esm/cc/ThermostatModeCC.js.map +1 -1
- package/build/esm/cc/ThermostatOperatingStateCC.d.ts +17 -65
- package/build/esm/cc/ThermostatOperatingStateCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatOperatingStateCC.js +2 -9
- package/build/esm/cc/ThermostatOperatingStateCC.js.map +1 -1
- package/build/esm/cc/ThermostatSetpointCC.d.ts +49 -129
- package/build/esm/cc/ThermostatSetpointCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatSetpointCC.js +2 -16
- package/build/esm/cc/ThermostatSetpointCC.js.map +1 -1
- package/build/esm/cc/TimeParametersCC.d.ts +12 -63
- package/build/esm/cc/TimeParametersCC.d.ts.map +1 -1
- package/build/esm/cc/TimeParametersCC.js +2 -8
- package/build/esm/cc/TimeParametersCC.js.map +1 -1
- package/build/esm/cc/UserCodeCC.d.ts +311 -1066
- package/build/esm/cc/UserCodeCC.d.ts.map +1 -1
- package/build/esm/cc/UserCodeCC.js +2 -60
- package/build/esm/cc/UserCodeCC.js.map +1 -1
- package/build/esm/cc/VersionCC.d.ts +289 -1003
- package/build/esm/cc/VersionCC.d.ts.map +1 -1
- package/build/esm/cc/VersionCC.js +2 -92
- package/build/esm/cc/VersionCC.js.map +1 -1
- package/build/esm/cc/WakeUpCC.d.ts +49 -201
- package/build/esm/cc/WakeUpCC.d.ts.map +1 -1
- package/build/esm/cc/WakeUpCC.js +2 -21
- package/build/esm/cc/WakeUpCC.js.map +1 -1
- package/build/esm/cc/WindowCoveringCC.d.ts +126 -220
- package/build/esm/cc/WindowCoveringCC.d.ts.map +1 -1
- package/build/esm/cc/WindowCoveringCC.js +3 -103
- package/build/esm/cc/WindowCoveringCC.js.map +1 -1
- package/build/esm/cc/ZWavePlusCC.d.ts +69 -329
- package/build/esm/cc/ZWavePlusCC.d.ts.map +1 -1
- package/build/esm/cc/ZWavePlusCC.js +2 -25
- package/build/esm/cc/ZWavePlusCC.js.map +1 -1
- package/build/esm/cc/_CCValues.generated.d.ts +15814 -0
- package/build/esm/cc/_CCValues.generated.d.ts.map +1 -0
- package/build/esm/cc/_CCValues.generated.js +9187 -0
- package/build/esm/cc/_CCValues.generated.js.map +1 -0
- package/build/esm/lib/CCValueUtils.d.ts +14 -0
- package/build/esm/lib/CCValueUtils.d.ts.map +1 -0
- package/build/esm/lib/CCValueUtils.js +62 -0
- package/build/esm/lib/CCValueUtils.js.map +1 -0
- package/build/esm/lib/Values.d.ts +6 -105
- package/build/esm/lib/Values.d.ts.map +1 -1
- package/build/esm/lib/Values.js +7 -104
- package/build/esm/lib/Values.js.map +1 -1
- package/package.json +9 -7
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/cc/SceneControllerConfigurationCC.ts"],
|
|
4
|
-
"sourcesContent": ["import { type CCEncodingContext, type CCParsingContext } from \"@zwave-js/cc\";\nimport { type GetDeviceConfig } from \"@zwave-js/config\";\nimport {\n\tCommandClasses,\n\tDuration,\n\ttype EndpointId,\n\ttype GetValueDB,\n\ttype MaybeNotKnown,\n\ttype MessageOrCCLogEntry,\n\tMessagePriority,\n\ttype SupervisionResult,\n\tValueMetadata,\n\ttype WithAddress,\n\tZWaveError,\n\tZWaveErrorCodes,\n\tgetCCName,\n\tvalidatePayload,\n} from \"@zwave-js/core/safe\";\nimport { Bytes } from \"@zwave-js/shared/safe\";\nimport { pick } from \"@zwave-js/shared/safe\";\nimport { validateArgs } from \"@zwave-js/transformers\";\nimport {\n\tCCAPI,\n\tPOLL_VALUE,\n\ttype PollValueImplementation,\n\tSET_VALUE,\n\ttype SetValueImplementation,\n\tthrowMissingPropertyKey,\n\tthrowUnsupportedProperty,\n\tthrowUnsupportedPropertyKey,\n\tthrowWrongValueType,\n} from \"../lib/API.js\";\nimport {\n\ttype CCRaw,\n\tCommandClass,\n\ttype InterviewContext,\n\ttype PersistValuesContext,\n\ttype RefreshValuesContext,\n} from \"../lib/CommandClass.js\";\nimport {\n\tAPI,\n\tCCCommand,\n\tccValues,\n\tcommandClass,\n\texpectedCCResponse,\n\timplementedVersion,\n\tuseSupervision,\n} from \"../lib/CommandClassDecorators.js\";\nimport { V } from \"../lib/Values.js\";\nimport { SceneControllerConfigurationCommand } from \"../lib/_Types.js\";\nimport { AssociationCC } from \"./AssociationCC.js\";\n\nexport const SceneControllerConfigurationCCValues = Object.freeze({\n\t...V.defineDynamicCCValues(\n\t\tCommandClasses[\"Scene Controller Configuration\"],\n\t\t{\n\t\t\t...V.dynamicPropertyAndKeyWithName(\n\t\t\t\t\"sceneId\",\n\t\t\t\t\"sceneId\",\n\t\t\t\t(groupId: number) => groupId,\n\t\t\t\t({ property, propertyKey }) =>\n\t\t\t\t\tproperty === \"sceneId\" && typeof propertyKey === \"number\",\n\t\t\t\t(groupId: number) => ({\n\t\t\t\t\t...ValueMetadata.UInt8,\n\t\t\t\t\tlabel: `Associated Scene ID (${groupId})`,\n\t\t\t\t\tvalueChangeOptions: [\"transitionDuration\"],\n\t\t\t\t} as const),\n\t\t\t),\n\n\t\t\t...V.dynamicPropertyAndKeyWithName(\n\t\t\t\t\"dimmingDuration\",\n\t\t\t\t\"dimmingDuration\",\n\t\t\t\t(groupId: number) => groupId,\n\t\t\t\t({ property, propertyKey }) =>\n\t\t\t\t\tproperty === \"dimmingDuration\"\n\t\t\t\t\t&& typeof propertyKey === \"number\",\n\t\t\t\t(groupId: number) => ({\n\t\t\t\t\t...ValueMetadata.Duration,\n\t\t\t\t\tlabel: `Dimming duration (${groupId})`,\n\t\t\t\t} as const),\n\t\t\t),\n\t\t},\n\t),\n});\n\n@API(CommandClasses[\"Scene Controller Configuration\"])\nexport class SceneControllerConfigurationCCAPI extends CCAPI {\n\tpublic supportsCommand(\n\t\tcmd: SceneControllerConfigurationCommand,\n\t): MaybeNotKnown<boolean> {\n\t\tswitch (cmd) {\n\t\t\tcase SceneControllerConfigurationCommand.Get:\n\t\t\t\treturn this.isSinglecast();\n\t\t\tcase SceneControllerConfigurationCommand.Set:\n\t\t\t\treturn true; // This is mandatory\n\t\t}\n\t\treturn super.supportsCommand(cmd);\n\t}\n\n\tprotected override get [SET_VALUE](): SetValueImplementation {\n\t\treturn async function(\n\t\t\tthis: SceneControllerConfigurationCCAPI,\n\t\t\t{ property, propertyKey },\n\t\t\tvalue,\n\t\t\toptions,\n\t\t) {\n\t\t\tif (propertyKey == undefined) {\n\t\t\t\tthrowMissingPropertyKey(this.ccId, property);\n\t\t\t} else if (typeof propertyKey !== \"number\") {\n\t\t\t\tthrowUnsupportedPropertyKey(this.ccId, property, propertyKey);\n\t\t\t}\n\t\t\tif (property === \"sceneId\") {\n\t\t\t\tif (typeof value !== \"number\") {\n\t\t\t\t\tthrowWrongValueType(\n\t\t\t\t\t\tthis.ccId,\n\t\t\t\t\t\tproperty,\n\t\t\t\t\t\t\"number\",\n\t\t\t\t\t\ttypeof value,\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tif (value === 0) {\n\t\t\t\t\t// Disable Group ID / Scene ID\n\t\t\t\t\treturn this.disable(propertyKey);\n\t\t\t\t} else {\n\t\t\t\t\t// We need to set the dimming duration along with the scene ID\n\t\t\t\t\t// Dimming duration is chosen with the following precedence:\n\t\t\t\t\t// 1. options.transitionDuration\n\t\t\t\t\t// 2. current stored value\n\t\t\t\t\t// 3. default value\n\t\t\t\t\tconst dimmingDuration =\n\t\t\t\t\t\tDuration.from(options?.transitionDuration)\n\t\t\t\t\t\t\t?? this.tryGetValueDB()?.getValue<Duration>(\n\t\t\t\t\t\t\t\tSceneControllerConfigurationCCValues\n\t\t\t\t\t\t\t\t\t.dimmingDuration(\n\t\t\t\t\t\t\t\t\t\tpropertyKey,\n\t\t\t\t\t\t\t\t\t).endpoint(this.endpoint.index),\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t?? Duration.default();\n\t\t\t\t\treturn this.set(propertyKey, value, dimmingDuration);\n\t\t\t\t}\n\t\t\t} else if (property === \"dimmingDuration\") {\n\t\t\t\tif (typeof value !== \"string\" && !Duration.isDuration(value)) {\n\t\t\t\t\tthrowWrongValueType(\n\t\t\t\t\t\tthis.ccId,\n\t\t\t\t\t\tproperty,\n\t\t\t\t\t\t\"duration\",\n\t\t\t\t\t\ttypeof value,\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tconst dimmingDuration = Duration.from(value);\n\t\t\t\tif (dimmingDuration == undefined) {\n\t\t\t\t\tthrow new ZWaveError(\n\t\t\t\t\t\t`${\n\t\t\t\t\t\t\tgetCCName(\n\t\t\t\t\t\t\t\tthis.ccId,\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t}: \"${property}\" could not be set. ${\n\t\t\t\t\t\t\tJSON.stringify(\n\t\t\t\t\t\t\t\tvalue,\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t} is not a valid duration.`,\n\t\t\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tconst valueDB = this.tryGetValueDB();\n\t\t\t\tconst sceneId = valueDB?.getValue<number>(\n\t\t\t\t\tSceneControllerConfigurationCCValues.sceneId(\n\t\t\t\t\t\tpropertyKey,\n\t\t\t\t\t).endpoint(this.endpoint.index),\n\t\t\t\t);\n\t\t\t\tif (sceneId == undefined || sceneId === 0) {\n\t\t\t\t\tif (valueDB) {\n\t\t\t\t\t\t// Can't actually send dimmingDuration without valid sceneId\n\t\t\t\t\t\t// So we save it in the valueDB without sending it to the node\n\t\t\t\t\t\tconst dimmingDurationValueId =\n\t\t\t\t\t\t\tSceneControllerConfigurationCCValues\n\t\t\t\t\t\t\t\t.dimmingDuration(\n\t\t\t\t\t\t\t\t\tpropertyKey,\n\t\t\t\t\t\t\t\t).endpoint(this.endpoint.index);\n\t\t\t\t\t\tvalueDB.setValue(\n\t\t\t\t\t\t\tdimmingDurationValueId,\n\t\t\t\t\t\t\tdimmingDuration,\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\treturn this.set(propertyKey, sceneId, dimmingDuration);\n\t\t\t} else {\n\t\t\t\tthrowUnsupportedProperty(this.ccId, property);\n\t\t\t}\n\t\t};\n\t}\n\n\tprotected get [POLL_VALUE](): PollValueImplementation {\n\t\treturn async function(\n\t\t\tthis: SceneControllerConfigurationCCAPI,\n\t\t\t{ property, propertyKey },\n\t\t) {\n\t\t\tswitch (property) {\n\t\t\t\tcase \"sceneId\":\n\t\t\t\tcase \"dimmingDuration\": {\n\t\t\t\t\tif (propertyKey == undefined) {\n\t\t\t\t\t\tthrowMissingPropertyKey(this.ccId, property);\n\t\t\t\t\t} else if (typeof propertyKey !== \"number\") {\n\t\t\t\t\t\tthrowUnsupportedPropertyKey(\n\t\t\t\t\t\t\tthis.ccId,\n\t\t\t\t\t\t\tproperty,\n\t\t\t\t\t\t\tpropertyKey,\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\treturn (await this.get(propertyKey))?.[property];\n\t\t\t\t}\n\t\t\t\tdefault:\n\t\t\t\t\tthrowUnsupportedProperty(this.ccId, property);\n\t\t\t}\n\t\t};\n\t}\n\n\t@validateArgs()\n\tpublic async disable(\n\t\tgroupId: number,\n\t): Promise<SupervisionResult | undefined> {\n\t\tthis.assertSupportsCommand(\n\t\t\tSceneControllerConfigurationCommand,\n\t\t\tSceneControllerConfigurationCommand.Set,\n\t\t);\n\n\t\treturn this.set(groupId, 0, new Duration(0, \"seconds\"));\n\t}\n\n\t@validateArgs()\n\tpublic async set(\n\t\tgroupId: number,\n\t\tsceneId: number,\n\t\tdimmingDuration?: Duration | string,\n\t): Promise<SupervisionResult | undefined> {\n\t\tthis.assertSupportsCommand(\n\t\t\tSceneControllerConfigurationCommand,\n\t\t\tSceneControllerConfigurationCommand.Set,\n\t\t);\n\n\t\tif (!this.endpoint.virtual) {\n\t\t\tconst groupCount = SceneControllerConfigurationCC\n\t\t\t\t.getGroupCountCached(\n\t\t\t\t\tthis.host,\n\t\t\t\t\tthis.endpoint,\n\t\t\t\t);\n\n\t\t\t// The client SHOULD NOT specify group 1 (the life-line group).\n\t\t\t// We don't block it here, because the specs don't forbid it,\n\t\t\t// and it may be needed for some devices.\n\t\t\tif (groupId < 1 || groupId > groupCount) {\n\t\t\t\tthrow new ZWaveError(\n\t\t\t\t\t`${this.constructor.name}: The group ID must be between 1 and the number of supported groups ${groupCount}.`,\n\t\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t\t);\n\t\t\t}\n\t\t} else if (groupId < 1) {\n\t\t\tthrow new ZWaveError(\n\t\t\t\t`The group ID must be greater than 0.`,\n\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t);\n\t\t}\n\n\t\tconst cc = new SceneControllerConfigurationCCSet({\n\t\t\tnodeId: this.endpoint.nodeId,\n\t\t\tendpointIndex: this.endpoint.index,\n\t\t\tgroupId,\n\t\t\tsceneId,\n\t\t\tdimmingDuration,\n\t\t});\n\n\t\treturn this.host.sendCommand(cc, this.commandOptions);\n\t}\n\n\tpublic async getLastActivated(): Promise<\n\t\tMaybeNotKnown<\n\t\t\tPick<\n\t\t\t\tSceneControllerConfigurationCCReport,\n\t\t\t\t\"groupId\" | \"sceneId\" | \"dimmingDuration\"\n\t\t\t>\n\t\t>\n\t> {\n\t\tthis.assertSupportsCommand(\n\t\t\tSceneControllerConfigurationCommand,\n\t\t\tSceneControllerConfigurationCommand.Get,\n\t\t);\n\n\t\tconst cc = new SceneControllerConfigurationCCGet({\n\t\t\tnodeId: this.endpoint.nodeId,\n\t\t\tendpointIndex: this.endpoint.index,\n\t\t\tgroupId: 0,\n\t\t});\n\t\tconst response = await this.host.sendCommand<\n\t\t\tSceneControllerConfigurationCCReport\n\t\t>(\n\t\t\tcc,\n\t\t\tthis.commandOptions,\n\t\t);\n\n\t\t// Return value includes \"groupId\", because\n\t\t// the returned report will include the actual groupId of the\n\t\t// last activated groupId / sceneId\n\t\tif (response) {\n\t\t\treturn pick(response, [\"groupId\", \"sceneId\", \"dimmingDuration\"]);\n\t\t}\n\t}\n\n\t@validateArgs()\n\tpublic async get(\n\t\tgroupId: number,\n\t): Promise<\n\t\tMaybeNotKnown<\n\t\t\tPick<\n\t\t\t\tSceneControllerConfigurationCCReport,\n\t\t\t\t\"sceneId\" | \"dimmingDuration\"\n\t\t\t>\n\t\t>\n\t> {\n\t\tthis.assertSupportsCommand(\n\t\t\tSceneControllerConfigurationCommand,\n\t\t\tSceneControllerConfigurationCommand.Get,\n\t\t);\n\n\t\tif (groupId === 0) {\n\t\t\tthrow new ZWaveError(\n\t\t\t\t`Invalid group ID 0. To get the last activated group / scene, use getLastActivated() instead.`,\n\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t);\n\t\t} else if (groupId < 0) {\n\t\t\tthrow new ZWaveError(\n\t\t\t\t`The group ID must be greater than 0.`,\n\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t);\n\t\t}\n\n\t\tconst cc = new SceneControllerConfigurationCCGet({\n\t\t\tnodeId: this.endpoint.nodeId,\n\t\t\tendpointIndex: this.endpoint.index,\n\t\t\tgroupId,\n\t\t});\n\t\tconst response = await this.host.sendCommand<\n\t\t\tSceneControllerConfigurationCCReport\n\t\t>(\n\t\t\tcc,\n\t\t\tthis.commandOptions,\n\t\t);\n\n\t\t// Since groupId is not allowed to be 0, only Reports with\n\t\t// groupId equal to the requested groupId will be accepted,\n\t\t// so we can omit groupId from the return.\n\t\tif (response) {\n\t\t\treturn pick(response, [\"sceneId\", \"dimmingDuration\"]);\n\t\t}\n\t}\n}\n\n@commandClass(CommandClasses[\"Scene Controller Configuration\"])\n@implementedVersion(1)\n@ccValues(SceneControllerConfigurationCCValues)\nexport class SceneControllerConfigurationCC extends CommandClass {\n\tdeclare ccCommand: SceneControllerConfigurationCommand;\n\n\tpublic determineRequiredCCInterviews(): readonly CommandClasses[] {\n\t\t// AssociationCC is required and MUST be interviewed\n\t\t// before SceneControllerConfigurationCC to supply groupCount\n\t\treturn [\n\t\t\t...super.determineRequiredCCInterviews(),\n\t\t\tCommandClasses.Association,\n\t\t];\n\t}\n\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tpublic async interview(\n\t\tctx: InterviewContext,\n\t): Promise<void> {\n\t\tconst node = this.getNode(ctx)!;\n\t\tconst endpoint = this.getEndpoint(ctx)!;\n\n\t\tctx.logNode(node.id, {\n\t\t\tendpoint: this.endpointIndex,\n\t\t\tmessage: `Interviewing ${this.ccName}...`,\n\t\t\tdirection: \"none\",\n\t\t});\n\n\t\tconst groupCount = SceneControllerConfigurationCC.getGroupCountCached(\n\t\t\tctx,\n\t\t\tendpoint,\n\t\t);\n\t\tif (groupCount === 0) {\n\t\t\tctx.logNode(node.id, {\n\t\t\t\tendpoint: this.endpointIndex,\n\t\t\t\tmessage:\n\t\t\t\t\t`skipping Scene Controller Configuration interview because Association group count is unknown`,\n\t\t\t\tdirection: \"none\",\n\t\t\t\tlevel: \"warn\",\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\n\t\t// Create metadata for each scene, but don't query their actual configuration\n\t\t// since some devices only support setting scenes\n\t\tfor (let groupId = 1; groupId <= groupCount; groupId++) {\n\t\t\tconst sceneIdValue = SceneControllerConfigurationCCValues.sceneId(\n\t\t\t\tgroupId,\n\t\t\t);\n\t\t\tthis.ensureMetadata(ctx, sceneIdValue);\n\n\t\t\tconst dimmingDurationValue = SceneControllerConfigurationCCValues\n\t\t\t\t.dimmingDuration(groupId);\n\t\t\tthis.ensureMetadata(ctx, dimmingDurationValue);\n\t\t}\n\n\t\t// Remember that the interview is complete\n\t\tthis.setInterviewComplete(ctx, true);\n\t}\n\n\tpublic async refreshValues(\n\t\tctx: RefreshValuesContext,\n\t): Promise<void> {\n\t\tconst node = this.getNode(ctx)!;\n\t\tconst endpoint = this.getEndpoint(ctx)!;\n\t\tconst api = CCAPI.create(\n\t\t\tCommandClasses[\"Scene Controller Configuration\"],\n\t\t\tctx,\n\t\t\tendpoint,\n\t\t).withOptions({\n\t\t\tpriority: MessagePriority.NodeQuery,\n\t\t});\n\n\t\tconst groupCount = SceneControllerConfigurationCC.getGroupCountCached(\n\t\t\tctx,\n\t\t\tendpoint,\n\t\t);\n\n\t\tctx.logNode(node.id, {\n\t\t\tmessage: \"querying all scene controller configurations...\",\n\t\t\tdirection: \"outbound\",\n\t\t});\n\t\tfor (let groupId = 1; groupId <= groupCount; groupId++) {\n\t\t\tctx.logNode(node.id, {\n\t\t\t\tendpoint: this.endpointIndex,\n\t\t\t\tmessage:\n\t\t\t\t\t`querying scene configuration for group #${groupId}...`,\n\t\t\t\tdirection: \"outbound\",\n\t\t\t});\n\t\t\tconst group = await api.get(groupId);\n\t\t\tif (group != undefined) {\n\t\t\t\tconst logMessage =\n\t\t\t\t\t`received scene configuration for group #${groupId}:\nscene ID: ${group.sceneId}\ndimming duration: ${group.dimmingDuration.toString()}`;\n\t\t\t\tctx.logNode(node.id, {\n\t\t\t\t\tendpoint: this.endpointIndex,\n\t\t\t\t\tmessage: logMessage,\n\t\t\t\t\tdirection: \"inbound\",\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Returns the number of association groups reported by the node.\n\t * This only works AFTER the node has been interviewed by this CC\n\t * or the AssociationCC.\n\t */\n\tpublic static getGroupCountCached(\n\t\tctx: GetValueDB & GetDeviceConfig,\n\t\tendpoint: EndpointId,\n\t): number {\n\t\treturn ctx.getDeviceConfig?.(endpoint.nodeId)?.compat\n\t\t\t?.forceSceneControllerGroupCount\n\t\t\t?? AssociationCC.getGroupCountCached(ctx, endpoint)\n\t\t\t?? 0;\n\t}\n}\n\n// @publicAPI\nexport interface SceneControllerConfigurationCCSetOptions {\n\tgroupId: number;\n\tsceneId: number;\n\tdimmingDuration?: Duration | string;\n}\n\n@CCCommand(SceneControllerConfigurationCommand.Set)\n@useSupervision()\nexport class SceneControllerConfigurationCCSet\n\textends SceneControllerConfigurationCC\n{\n\tpublic constructor(\n\t\toptions: WithAddress<SceneControllerConfigurationCCSetOptions>,\n\t) {\n\t\tsuper(options);\n\t\tthis.groupId = options.groupId;\n\t\tthis.sceneId = options.sceneId;\n\t\t// if dimmingDuration was missing, use default duration.\n\t\tthis.dimmingDuration = Duration.from(options.dimmingDuration)\n\t\t\t?? Duration.default();\n\t}\n\n\tpublic static from(\n\t\t_raw: CCRaw,\n\t\t_ctx: CCParsingContext,\n\t): SceneControllerConfigurationCCSet {\n\t\t// TODO: Deserialize payload\n\t\tthrow new ZWaveError(\n\t\t\t`${this.name}: deserialization not implemented`,\n\t\t\tZWaveErrorCodes.Deserialization_NotImplemented,\n\t\t);\n\n\t\t// return new SceneControllerConfigurationCCSet({\n\t\t// \tnodeId: ctx.sourceNodeId,\n\t\t// });\n\t}\n\n\tpublic groupId: number;\n\tpublic sceneId: number;\n\tpublic dimmingDuration: Duration;\n\n\tpublic serialize(ctx: CCEncodingContext): Promise<Bytes> {\n\t\tthis.payload = Bytes.from([\n\t\t\tthis.groupId,\n\t\t\tthis.sceneId,\n\t\t\tthis.dimmingDuration.serializeSet(),\n\t\t]);\n\t\treturn super.serialize(ctx);\n\t}\n\n\tpublic toLogEntry(ctx?: GetValueDB): MessageOrCCLogEntry {\n\t\treturn {\n\t\t\t...super.toLogEntry(ctx),\n\t\t\tmessage: {\n\t\t\t\t\"group id\": this.groupId,\n\t\t\t\t\"scene id\": this.sceneId,\n\t\t\t\t\"dimming duration\": this.dimmingDuration.toString(),\n\t\t\t},\n\t\t};\n\t}\n}\n\n// @publicAPI\nexport interface SceneControllerConfigurationCCReportOptions {\n\tgroupId: number;\n\tsceneId: number;\n\tdimmingDuration: Duration;\n}\n\n@CCCommand(SceneControllerConfigurationCommand.Report)\nexport class SceneControllerConfigurationCCReport\n\textends SceneControllerConfigurationCC\n{\n\tpublic constructor(\n\t\toptions: WithAddress<SceneControllerConfigurationCCReportOptions>,\n\t) {\n\t\tsuper(options);\n\n\t\t// TODO: Check implementation:\n\t\tthis.groupId = options.groupId;\n\t\tthis.sceneId = options.sceneId;\n\t\tthis.dimmingDuration = options.dimmingDuration;\n\t}\n\n\tpublic static from(\n\t\traw: CCRaw,\n\t\tctx: CCParsingContext,\n\t): SceneControllerConfigurationCCReport {\n\t\tvalidatePayload(raw.payload.length >= 3);\n\t\tconst groupId = raw.payload[0];\n\t\tconst sceneId = raw.payload[1];\n\t\tconst dimmingDuration: Duration = Duration.parseReport(raw.payload[2])\n\t\t\t?? Duration.unknown();\n\n\t\treturn new this({\n\t\t\tnodeId: ctx.sourceNodeId,\n\t\t\tgroupId,\n\t\t\tsceneId,\n\t\t\tdimmingDuration,\n\t\t});\n\t}\n\n\tpublic readonly groupId: number;\n\tpublic readonly sceneId: number;\n\tpublic readonly dimmingDuration: Duration;\n\n\tpublic persistValues(ctx: PersistValuesContext): boolean {\n\t\tif (!super.persistValues(ctx)) return false;\n\n\t\t// If groupId = 0, values are meaningless\n\t\tif (this.groupId === 0) return false;\n\n\t\tconst sceneIdValue = SceneControllerConfigurationCCValues.sceneId(\n\t\t\tthis.groupId,\n\t\t);\n\t\tthis.ensureMetadata(ctx, sceneIdValue);\n\t\tconst dimmingDurationValue = SceneControllerConfigurationCCValues\n\t\t\t.dimmingDuration(this.groupId);\n\t\tthis.ensureMetadata(ctx, dimmingDurationValue);\n\n\t\tthis.setValue(ctx, sceneIdValue, this.sceneId);\n\t\tthis.setValue(ctx, dimmingDurationValue, this.dimmingDuration);\n\n\t\treturn true;\n\t}\n\n\tpublic toLogEntry(ctx?: GetValueDB): MessageOrCCLogEntry {\n\t\treturn {\n\t\t\t...super.toLogEntry(ctx),\n\t\t\tmessage: {\n\t\t\t\t\"group id\": this.groupId,\n\t\t\t\t\"scene id\": this.sceneId,\n\t\t\t\t\"dimming duration\": this.dimmingDuration.toString(),\n\t\t\t},\n\t\t};\n\t}\n}\n\nfunction testResponseForSceneControllerConfigurationGet(\n\tsent: SceneControllerConfigurationCCGet,\n\treceived: SceneControllerConfigurationCCReport,\n) {\n\t// We expect a Scene Controller Configuration Report that matches\n\t// the requested groupId, unless groupId 0 was requested\n\treturn sent.groupId === 0 || received.groupId === sent.groupId;\n}\n\n// @publicAPI\nexport interface SceneControllerConfigurationCCGetOptions {\n\tgroupId: number;\n}\n\n@CCCommand(SceneControllerConfigurationCommand.Get)\n@expectedCCResponse(\n\tSceneControllerConfigurationCCReport,\n\ttestResponseForSceneControllerConfigurationGet,\n)\nexport class SceneControllerConfigurationCCGet\n\textends SceneControllerConfigurationCC\n{\n\tpublic constructor(\n\t\toptions: WithAddress<SceneControllerConfigurationCCGetOptions>,\n\t) {\n\t\tsuper(options);\n\t\tthis.groupId = options.groupId;\n\t}\n\n\tpublic static from(\n\t\t_raw: CCRaw,\n\t\t_ctx: CCParsingContext,\n\t): SceneControllerConfigurationCCGet {\n\t\t// TODO: Deserialize payload\n\t\tthrow new ZWaveError(\n\t\t\t`${this.name}: deserialization not implemented`,\n\t\t\tZWaveErrorCodes.Deserialization_NotImplemented,\n\t\t);\n\n\t\t// return new SceneControllerConfigurationCCGet({\n\t\t// \tnodeId: ctx.sourceNodeId,\n\t\t// });\n\t}\n\n\tpublic groupId: number;\n\n\tpublic serialize(ctx: CCEncodingContext): Promise<Bytes> {\n\t\tthis.payload = Bytes.from([this.groupId]);\n\t\treturn super.serialize(ctx);\n\t}\n\n\tpublic toLogEntry(ctx?: GetValueDB): MessageOrCCLogEntry {\n\t\treturn {\n\t\t\t...super.toLogEntry(ctx),\n\t\t\tmessage: { \"group id\": this.groupId },\n\t\t};\n\t}\n}\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,kBAeO;AACP,IAAAA,eAAsB;AACtB,IAAAA,eAAqB;AAErB,iBAUO;AACP,0BAMO;AACP,oCAQO;AACP,oBAAkB;AAClB,mBAAoD;AACpD,2BAA8B
|
|
4
|
+
"sourcesContent": ["import { type CCEncodingContext, type CCParsingContext } from \"@zwave-js/cc\";\nimport { type GetDeviceConfig } from \"@zwave-js/config\";\nimport {\n\tCommandClasses,\n\tDuration,\n\ttype EndpointId,\n\ttype GetValueDB,\n\ttype MaybeNotKnown,\n\ttype MessageOrCCLogEntry,\n\tMessagePriority,\n\ttype SupervisionResult,\n\tValueMetadata,\n\ttype WithAddress,\n\tZWaveError,\n\tZWaveErrorCodes,\n\tgetCCName,\n\tvalidatePayload,\n} from \"@zwave-js/core/safe\";\nimport { Bytes } from \"@zwave-js/shared/safe\";\nimport { pick } from \"@zwave-js/shared/safe\";\nimport { validateArgs } from \"@zwave-js/transformers\";\nimport {\n\tCCAPI,\n\tPOLL_VALUE,\n\ttype PollValueImplementation,\n\tSET_VALUE,\n\ttype SetValueImplementation,\n\tthrowMissingPropertyKey,\n\tthrowUnsupportedProperty,\n\tthrowUnsupportedPropertyKey,\n\tthrowWrongValueType,\n} from \"../lib/API.js\";\nimport {\n\ttype CCRaw,\n\tCommandClass,\n\ttype InterviewContext,\n\ttype PersistValuesContext,\n\ttype RefreshValuesContext,\n} from \"../lib/CommandClass.js\";\nimport {\n\tAPI,\n\tCCCommand,\n\tccValues,\n\tcommandClass,\n\texpectedCCResponse,\n\timplementedVersion,\n\tuseSupervision,\n} from \"../lib/CommandClassDecorators.js\";\nimport { V } from \"../lib/Values.js\";\nimport { SceneControllerConfigurationCommand } from \"../lib/_Types.js\";\nimport { AssociationCC } from \"./AssociationCC.js\";\n\nexport const SceneControllerConfigurationCCValues = V.defineCCValues(\n\tCommandClasses[\"Scene Controller Configuration\"],\n\t{\n\t\t...V.dynamicPropertyAndKeyWithName(\n\t\t\t\"sceneId\",\n\t\t\t\"sceneId\",\n\t\t\t(groupId: number) => groupId,\n\t\t\t({ property, propertyKey }) =>\n\t\t\t\tproperty === \"sceneId\" && typeof propertyKey === \"number\",\n\t\t\t(groupId: number) => ({\n\t\t\t\t...ValueMetadata.UInt8,\n\t\t\t\tlabel: `Associated Scene ID (${groupId})`,\n\t\t\t\tvalueChangeOptions: [\"transitionDuration\"],\n\t\t\t} as const),\n\t\t),\n\t\t...V.dynamicPropertyAndKeyWithName(\n\t\t\t\"dimmingDuration\",\n\t\t\t\"dimmingDuration\",\n\t\t\t(groupId: number) => groupId,\n\t\t\t({ property, propertyKey }) =>\n\t\t\t\tproperty === \"dimmingDuration\"\n\t\t\t\t&& typeof propertyKey === \"number\",\n\t\t\t(groupId: number) => ({\n\t\t\t\t...ValueMetadata.Duration,\n\t\t\t\tlabel: `Dimming duration (${groupId})`,\n\t\t\t} as const),\n\t\t),\n\t},\n);\n\n@API(CommandClasses[\"Scene Controller Configuration\"])\nexport class SceneControllerConfigurationCCAPI extends CCAPI {\n\tpublic supportsCommand(\n\t\tcmd: SceneControllerConfigurationCommand,\n\t): MaybeNotKnown<boolean> {\n\t\tswitch (cmd) {\n\t\t\tcase SceneControllerConfigurationCommand.Get:\n\t\t\t\treturn this.isSinglecast();\n\t\t\tcase SceneControllerConfigurationCommand.Set:\n\t\t\t\treturn true; // This is mandatory\n\t\t}\n\t\treturn super.supportsCommand(cmd);\n\t}\n\n\tprotected override get [SET_VALUE](): SetValueImplementation {\n\t\treturn async function(\n\t\t\tthis: SceneControllerConfigurationCCAPI,\n\t\t\t{ property, propertyKey },\n\t\t\tvalue,\n\t\t\toptions,\n\t\t) {\n\t\t\tif (propertyKey == undefined) {\n\t\t\t\tthrowMissingPropertyKey(this.ccId, property);\n\t\t\t} else if (typeof propertyKey !== \"number\") {\n\t\t\t\tthrowUnsupportedPropertyKey(this.ccId, property, propertyKey);\n\t\t\t}\n\t\t\tif (property === \"sceneId\") {\n\t\t\t\tif (typeof value !== \"number\") {\n\t\t\t\t\tthrowWrongValueType(\n\t\t\t\t\t\tthis.ccId,\n\t\t\t\t\t\tproperty,\n\t\t\t\t\t\t\"number\",\n\t\t\t\t\t\ttypeof value,\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tif (value === 0) {\n\t\t\t\t\t// Disable Group ID / Scene ID\n\t\t\t\t\treturn this.disable(propertyKey);\n\t\t\t\t} else {\n\t\t\t\t\t// We need to set the dimming duration along with the scene ID\n\t\t\t\t\t// Dimming duration is chosen with the following precedence:\n\t\t\t\t\t// 1. options.transitionDuration\n\t\t\t\t\t// 2. current stored value\n\t\t\t\t\t// 3. default value\n\t\t\t\t\tconst dimmingDuration =\n\t\t\t\t\t\tDuration.from(options?.transitionDuration)\n\t\t\t\t\t\t\t?? this.tryGetValueDB()?.getValue<Duration>(\n\t\t\t\t\t\t\t\tSceneControllerConfigurationCCValues\n\t\t\t\t\t\t\t\t\t.dimmingDuration(\n\t\t\t\t\t\t\t\t\t\tpropertyKey,\n\t\t\t\t\t\t\t\t\t).endpoint(this.endpoint.index),\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t?? Duration.default();\n\t\t\t\t\treturn this.set(propertyKey, value, dimmingDuration);\n\t\t\t\t}\n\t\t\t} else if (property === \"dimmingDuration\") {\n\t\t\t\tif (typeof value !== \"string\" && !Duration.isDuration(value)) {\n\t\t\t\t\tthrowWrongValueType(\n\t\t\t\t\t\tthis.ccId,\n\t\t\t\t\t\tproperty,\n\t\t\t\t\t\t\"duration\",\n\t\t\t\t\t\ttypeof value,\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tconst dimmingDuration = Duration.from(value);\n\t\t\t\tif (dimmingDuration == undefined) {\n\t\t\t\t\tthrow new ZWaveError(\n\t\t\t\t\t\t`${\n\t\t\t\t\t\t\tgetCCName(\n\t\t\t\t\t\t\t\tthis.ccId,\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t}: \"${property}\" could not be set. ${\n\t\t\t\t\t\t\tJSON.stringify(\n\t\t\t\t\t\t\t\tvalue,\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t} is not a valid duration.`,\n\t\t\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\tconst valueDB = this.tryGetValueDB();\n\t\t\t\tconst sceneId = valueDB?.getValue<number>(\n\t\t\t\t\tSceneControllerConfigurationCCValues.sceneId(\n\t\t\t\t\t\tpropertyKey,\n\t\t\t\t\t).endpoint(this.endpoint.index),\n\t\t\t\t);\n\t\t\t\tif (sceneId == undefined || sceneId === 0) {\n\t\t\t\t\tif (valueDB) {\n\t\t\t\t\t\t// Can't actually send dimmingDuration without valid sceneId\n\t\t\t\t\t\t// So we save it in the valueDB without sending it to the node\n\t\t\t\t\t\tconst dimmingDurationValueId =\n\t\t\t\t\t\t\tSceneControllerConfigurationCCValues\n\t\t\t\t\t\t\t\t.dimmingDuration(\n\t\t\t\t\t\t\t\t\tpropertyKey,\n\t\t\t\t\t\t\t\t).endpoint(this.endpoint.index);\n\t\t\t\t\t\tvalueDB.setValue(\n\t\t\t\t\t\t\tdimmingDurationValueId,\n\t\t\t\t\t\t\tdimmingDuration,\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\treturn this.set(propertyKey, sceneId, dimmingDuration);\n\t\t\t} else {\n\t\t\t\tthrowUnsupportedProperty(this.ccId, property);\n\t\t\t}\n\t\t};\n\t}\n\n\tprotected get [POLL_VALUE](): PollValueImplementation {\n\t\treturn async function(\n\t\t\tthis: SceneControllerConfigurationCCAPI,\n\t\t\t{ property, propertyKey },\n\t\t) {\n\t\t\tswitch (property) {\n\t\t\t\tcase \"sceneId\":\n\t\t\t\tcase \"dimmingDuration\": {\n\t\t\t\t\tif (propertyKey == undefined) {\n\t\t\t\t\t\tthrowMissingPropertyKey(this.ccId, property);\n\t\t\t\t\t} else if (typeof propertyKey !== \"number\") {\n\t\t\t\t\t\tthrowUnsupportedPropertyKey(\n\t\t\t\t\t\t\tthis.ccId,\n\t\t\t\t\t\t\tproperty,\n\t\t\t\t\t\t\tpropertyKey,\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\treturn (await this.get(propertyKey))?.[property];\n\t\t\t\t}\n\t\t\t\tdefault:\n\t\t\t\t\tthrowUnsupportedProperty(this.ccId, property);\n\t\t\t}\n\t\t};\n\t}\n\n\t@validateArgs()\n\tpublic async disable(\n\t\tgroupId: number,\n\t): Promise<SupervisionResult | undefined> {\n\t\tthis.assertSupportsCommand(\n\t\t\tSceneControllerConfigurationCommand,\n\t\t\tSceneControllerConfigurationCommand.Set,\n\t\t);\n\n\t\treturn this.set(groupId, 0, new Duration(0, \"seconds\"));\n\t}\n\n\t@validateArgs()\n\tpublic async set(\n\t\tgroupId: number,\n\t\tsceneId: number,\n\t\tdimmingDuration?: Duration | string,\n\t): Promise<SupervisionResult | undefined> {\n\t\tthis.assertSupportsCommand(\n\t\t\tSceneControllerConfigurationCommand,\n\t\t\tSceneControllerConfigurationCommand.Set,\n\t\t);\n\n\t\tif (!this.endpoint.virtual) {\n\t\t\tconst groupCount = SceneControllerConfigurationCC\n\t\t\t\t.getGroupCountCached(\n\t\t\t\t\tthis.host,\n\t\t\t\t\tthis.endpoint,\n\t\t\t\t);\n\n\t\t\t// The client SHOULD NOT specify group 1 (the life-line group).\n\t\t\t// We don't block it here, because the specs don't forbid it,\n\t\t\t// and it may be needed for some devices.\n\t\t\tif (groupId < 1 || groupId > groupCount) {\n\t\t\t\tthrow new ZWaveError(\n\t\t\t\t\t`${this.constructor.name}: The group ID must be between 1 and the number of supported groups ${groupCount}.`,\n\t\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t\t);\n\t\t\t}\n\t\t} else if (groupId < 1) {\n\t\t\tthrow new ZWaveError(\n\t\t\t\t`The group ID must be greater than 0.`,\n\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t);\n\t\t}\n\n\t\tconst cc = new SceneControllerConfigurationCCSet({\n\t\t\tnodeId: this.endpoint.nodeId,\n\t\t\tendpointIndex: this.endpoint.index,\n\t\t\tgroupId,\n\t\t\tsceneId,\n\t\t\tdimmingDuration,\n\t\t});\n\n\t\treturn this.host.sendCommand(cc, this.commandOptions);\n\t}\n\n\tpublic async getLastActivated(): Promise<\n\t\tMaybeNotKnown<\n\t\t\tPick<\n\t\t\t\tSceneControllerConfigurationCCReport,\n\t\t\t\t\"groupId\" | \"sceneId\" | \"dimmingDuration\"\n\t\t\t>\n\t\t>\n\t> {\n\t\tthis.assertSupportsCommand(\n\t\t\tSceneControllerConfigurationCommand,\n\t\t\tSceneControllerConfigurationCommand.Get,\n\t\t);\n\n\t\tconst cc = new SceneControllerConfigurationCCGet({\n\t\t\tnodeId: this.endpoint.nodeId,\n\t\t\tendpointIndex: this.endpoint.index,\n\t\t\tgroupId: 0,\n\t\t});\n\t\tconst response = await this.host.sendCommand<\n\t\t\tSceneControllerConfigurationCCReport\n\t\t>(\n\t\t\tcc,\n\t\t\tthis.commandOptions,\n\t\t);\n\n\t\t// Return value includes \"groupId\", because\n\t\t// the returned report will include the actual groupId of the\n\t\t// last activated groupId / sceneId\n\t\tif (response) {\n\t\t\treturn pick(response, [\"groupId\", \"sceneId\", \"dimmingDuration\"]);\n\t\t}\n\t}\n\n\t@validateArgs()\n\tpublic async get(\n\t\tgroupId: number,\n\t): Promise<\n\t\tMaybeNotKnown<\n\t\t\tPick<\n\t\t\t\tSceneControllerConfigurationCCReport,\n\t\t\t\t\"sceneId\" | \"dimmingDuration\"\n\t\t\t>\n\t\t>\n\t> {\n\t\tthis.assertSupportsCommand(\n\t\t\tSceneControllerConfigurationCommand,\n\t\t\tSceneControllerConfigurationCommand.Get,\n\t\t);\n\n\t\tif (groupId === 0) {\n\t\t\tthrow new ZWaveError(\n\t\t\t\t`Invalid group ID 0. To get the last activated group / scene, use getLastActivated() instead.`,\n\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t);\n\t\t} else if (groupId < 0) {\n\t\t\tthrow new ZWaveError(\n\t\t\t\t`The group ID must be greater than 0.`,\n\t\t\t\tZWaveErrorCodes.Argument_Invalid,\n\t\t\t);\n\t\t}\n\n\t\tconst cc = new SceneControllerConfigurationCCGet({\n\t\t\tnodeId: this.endpoint.nodeId,\n\t\t\tendpointIndex: this.endpoint.index,\n\t\t\tgroupId,\n\t\t});\n\t\tconst response = await this.host.sendCommand<\n\t\t\tSceneControllerConfigurationCCReport\n\t\t>(\n\t\t\tcc,\n\t\t\tthis.commandOptions,\n\t\t);\n\n\t\t// Since groupId is not allowed to be 0, only Reports with\n\t\t// groupId equal to the requested groupId will be accepted,\n\t\t// so we can omit groupId from the return.\n\t\tif (response) {\n\t\t\treturn pick(response, [\"sceneId\", \"dimmingDuration\"]);\n\t\t}\n\t}\n}\n\n@commandClass(CommandClasses[\"Scene Controller Configuration\"])\n@implementedVersion(1)\n@ccValues(SceneControllerConfigurationCCValues)\nexport class SceneControllerConfigurationCC extends CommandClass {\n\tdeclare ccCommand: SceneControllerConfigurationCommand;\n\n\tpublic determineRequiredCCInterviews(): readonly CommandClasses[] {\n\t\t// AssociationCC is required and MUST be interviewed\n\t\t// before SceneControllerConfigurationCC to supply groupCount\n\t\treturn [\n\t\t\t...super.determineRequiredCCInterviews(),\n\t\t\tCommandClasses.Association,\n\t\t];\n\t}\n\n\t// eslint-disable-next-line @typescript-eslint/require-await\n\tpublic async interview(\n\t\tctx: InterviewContext,\n\t): Promise<void> {\n\t\tconst node = this.getNode(ctx)!;\n\t\tconst endpoint = this.getEndpoint(ctx)!;\n\n\t\tctx.logNode(node.id, {\n\t\t\tendpoint: this.endpointIndex,\n\t\t\tmessage: `Interviewing ${this.ccName}...`,\n\t\t\tdirection: \"none\",\n\t\t});\n\n\t\tconst groupCount = SceneControllerConfigurationCC.getGroupCountCached(\n\t\t\tctx,\n\t\t\tendpoint,\n\t\t);\n\t\tif (groupCount === 0) {\n\t\t\tctx.logNode(node.id, {\n\t\t\t\tendpoint: this.endpointIndex,\n\t\t\t\tmessage:\n\t\t\t\t\t`skipping Scene Controller Configuration interview because Association group count is unknown`,\n\t\t\t\tdirection: \"none\",\n\t\t\t\tlevel: \"warn\",\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\n\t\t// Create metadata for each scene, but don't query their actual configuration\n\t\t// since some devices only support setting scenes\n\t\tfor (let groupId = 1; groupId <= groupCount; groupId++) {\n\t\t\tconst sceneIdValue = SceneControllerConfigurationCCValues.sceneId(\n\t\t\t\tgroupId,\n\t\t\t);\n\t\t\tthis.ensureMetadata(ctx, sceneIdValue);\n\n\t\t\tconst dimmingDurationValue = SceneControllerConfigurationCCValues\n\t\t\t\t.dimmingDuration(groupId);\n\t\t\tthis.ensureMetadata(ctx, dimmingDurationValue);\n\t\t}\n\n\t\t// Remember that the interview is complete\n\t\tthis.setInterviewComplete(ctx, true);\n\t}\n\n\tpublic async refreshValues(\n\t\tctx: RefreshValuesContext,\n\t): Promise<void> {\n\t\tconst node = this.getNode(ctx)!;\n\t\tconst endpoint = this.getEndpoint(ctx)!;\n\t\tconst api = CCAPI.create(\n\t\t\tCommandClasses[\"Scene Controller Configuration\"],\n\t\t\tctx,\n\t\t\tendpoint,\n\t\t).withOptions({\n\t\t\tpriority: MessagePriority.NodeQuery,\n\t\t});\n\n\t\tconst groupCount = SceneControllerConfigurationCC.getGroupCountCached(\n\t\t\tctx,\n\t\t\tendpoint,\n\t\t);\n\n\t\tctx.logNode(node.id, {\n\t\t\tmessage: \"querying all scene controller configurations...\",\n\t\t\tdirection: \"outbound\",\n\t\t});\n\t\tfor (let groupId = 1; groupId <= groupCount; groupId++) {\n\t\t\tctx.logNode(node.id, {\n\t\t\t\tendpoint: this.endpointIndex,\n\t\t\t\tmessage:\n\t\t\t\t\t`querying scene configuration for group #${groupId}...`,\n\t\t\t\tdirection: \"outbound\",\n\t\t\t});\n\t\t\tconst group = await api.get(groupId);\n\t\t\tif (group != undefined) {\n\t\t\t\tconst logMessage =\n\t\t\t\t\t`received scene configuration for group #${groupId}:\nscene ID: ${group.sceneId}\ndimming duration: ${group.dimmingDuration.toString()}`;\n\t\t\t\tctx.logNode(node.id, {\n\t\t\t\t\tendpoint: this.endpointIndex,\n\t\t\t\t\tmessage: logMessage,\n\t\t\t\t\tdirection: \"inbound\",\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Returns the number of association groups reported by the node.\n\t * This only works AFTER the node has been interviewed by this CC\n\t * or the AssociationCC.\n\t */\n\tpublic static getGroupCountCached(\n\t\tctx: GetValueDB & GetDeviceConfig,\n\t\tendpoint: EndpointId,\n\t): number {\n\t\treturn ctx.getDeviceConfig?.(endpoint.nodeId)?.compat\n\t\t\t?.forceSceneControllerGroupCount\n\t\t\t?? AssociationCC.getGroupCountCached(ctx, endpoint)\n\t\t\t?? 0;\n\t}\n}\n\n// @publicAPI\nexport interface SceneControllerConfigurationCCSetOptions {\n\tgroupId: number;\n\tsceneId: number;\n\tdimmingDuration?: Duration | string;\n}\n\n@CCCommand(SceneControllerConfigurationCommand.Set)\n@useSupervision()\nexport class SceneControllerConfigurationCCSet\n\textends SceneControllerConfigurationCC\n{\n\tpublic constructor(\n\t\toptions: WithAddress<SceneControllerConfigurationCCSetOptions>,\n\t) {\n\t\tsuper(options);\n\t\tthis.groupId = options.groupId;\n\t\tthis.sceneId = options.sceneId;\n\t\t// if dimmingDuration was missing, use default duration.\n\t\tthis.dimmingDuration = Duration.from(options.dimmingDuration)\n\t\t\t?? Duration.default();\n\t}\n\n\tpublic static from(\n\t\t_raw: CCRaw,\n\t\t_ctx: CCParsingContext,\n\t): SceneControllerConfigurationCCSet {\n\t\t// TODO: Deserialize payload\n\t\tthrow new ZWaveError(\n\t\t\t`${this.name}: deserialization not implemented`,\n\t\t\tZWaveErrorCodes.Deserialization_NotImplemented,\n\t\t);\n\n\t\t// return new SceneControllerConfigurationCCSet({\n\t\t// \tnodeId: ctx.sourceNodeId,\n\t\t// });\n\t}\n\n\tpublic groupId: number;\n\tpublic sceneId: number;\n\tpublic dimmingDuration: Duration;\n\n\tpublic serialize(ctx: CCEncodingContext): Promise<Bytes> {\n\t\tthis.payload = Bytes.from([\n\t\t\tthis.groupId,\n\t\t\tthis.sceneId,\n\t\t\tthis.dimmingDuration.serializeSet(),\n\t\t]);\n\t\treturn super.serialize(ctx);\n\t}\n\n\tpublic toLogEntry(ctx?: GetValueDB): MessageOrCCLogEntry {\n\t\treturn {\n\t\t\t...super.toLogEntry(ctx),\n\t\t\tmessage: {\n\t\t\t\t\"group id\": this.groupId,\n\t\t\t\t\"scene id\": this.sceneId,\n\t\t\t\t\"dimming duration\": this.dimmingDuration.toString(),\n\t\t\t},\n\t\t};\n\t}\n}\n\n// @publicAPI\nexport interface SceneControllerConfigurationCCReportOptions {\n\tgroupId: number;\n\tsceneId: number;\n\tdimmingDuration: Duration;\n}\n\n@CCCommand(SceneControllerConfigurationCommand.Report)\nexport class SceneControllerConfigurationCCReport\n\textends SceneControllerConfigurationCC\n{\n\tpublic constructor(\n\t\toptions: WithAddress<SceneControllerConfigurationCCReportOptions>,\n\t) {\n\t\tsuper(options);\n\n\t\t// TODO: Check implementation:\n\t\tthis.groupId = options.groupId;\n\t\tthis.sceneId = options.sceneId;\n\t\tthis.dimmingDuration = options.dimmingDuration;\n\t}\n\n\tpublic static from(\n\t\traw: CCRaw,\n\t\tctx: CCParsingContext,\n\t): SceneControllerConfigurationCCReport {\n\t\tvalidatePayload(raw.payload.length >= 3);\n\t\tconst groupId = raw.payload[0];\n\t\tconst sceneId = raw.payload[1];\n\t\tconst dimmingDuration: Duration = Duration.parseReport(raw.payload[2])\n\t\t\t?? Duration.unknown();\n\n\t\treturn new this({\n\t\t\tnodeId: ctx.sourceNodeId,\n\t\t\tgroupId,\n\t\t\tsceneId,\n\t\t\tdimmingDuration,\n\t\t});\n\t}\n\n\tpublic readonly groupId: number;\n\tpublic readonly sceneId: number;\n\tpublic readonly dimmingDuration: Duration;\n\n\tpublic persistValues(ctx: PersistValuesContext): boolean {\n\t\tif (!super.persistValues(ctx)) return false;\n\n\t\t// If groupId = 0, values are meaningless\n\t\tif (this.groupId === 0) return false;\n\n\t\tconst sceneIdValue = SceneControllerConfigurationCCValues.sceneId(\n\t\t\tthis.groupId,\n\t\t);\n\t\tthis.ensureMetadata(ctx, sceneIdValue);\n\t\tconst dimmingDurationValue = SceneControllerConfigurationCCValues\n\t\t\t.dimmingDuration(this.groupId);\n\t\tthis.ensureMetadata(ctx, dimmingDurationValue);\n\n\t\tthis.setValue(ctx, sceneIdValue, this.sceneId);\n\t\tthis.setValue(ctx, dimmingDurationValue, this.dimmingDuration);\n\n\t\treturn true;\n\t}\n\n\tpublic toLogEntry(ctx?: GetValueDB): MessageOrCCLogEntry {\n\t\treturn {\n\t\t\t...super.toLogEntry(ctx),\n\t\t\tmessage: {\n\t\t\t\t\"group id\": this.groupId,\n\t\t\t\t\"scene id\": this.sceneId,\n\t\t\t\t\"dimming duration\": this.dimmingDuration.toString(),\n\t\t\t},\n\t\t};\n\t}\n}\n\nfunction testResponseForSceneControllerConfigurationGet(\n\tsent: SceneControllerConfigurationCCGet,\n\treceived: SceneControllerConfigurationCCReport,\n) {\n\t// We expect a Scene Controller Configuration Report that matches\n\t// the requested groupId, unless groupId 0 was requested\n\treturn sent.groupId === 0 || received.groupId === sent.groupId;\n}\n\n// @publicAPI\nexport interface SceneControllerConfigurationCCGetOptions {\n\tgroupId: number;\n}\n\n@CCCommand(SceneControllerConfigurationCommand.Get)\n@expectedCCResponse(\n\tSceneControllerConfigurationCCReport,\n\ttestResponseForSceneControllerConfigurationGet,\n)\nexport class SceneControllerConfigurationCCGet\n\textends SceneControllerConfigurationCC\n{\n\tpublic constructor(\n\t\toptions: WithAddress<SceneControllerConfigurationCCGetOptions>,\n\t) {\n\t\tsuper(options);\n\t\tthis.groupId = options.groupId;\n\t}\n\n\tpublic static from(\n\t\t_raw: CCRaw,\n\t\t_ctx: CCParsingContext,\n\t): SceneControllerConfigurationCCGet {\n\t\t// TODO: Deserialize payload\n\t\tthrow new ZWaveError(\n\t\t\t`${this.name}: deserialization not implemented`,\n\t\t\tZWaveErrorCodes.Deserialization_NotImplemented,\n\t\t);\n\n\t\t// return new SceneControllerConfigurationCCGet({\n\t\t// \tnodeId: ctx.sourceNodeId,\n\t\t// });\n\t}\n\n\tpublic groupId: number;\n\n\tpublic serialize(ctx: CCEncodingContext): Promise<Bytes> {\n\t\tthis.payload = Bytes.from([this.groupId]);\n\t\treturn super.serialize(ctx);\n\t}\n\n\tpublic toLogEntry(ctx?: GetValueDB): MessageOrCCLogEntry {\n\t\treturn {\n\t\t\t...super.toLogEntry(ctx),\n\t\t\tmessage: { \"group id\": this.groupId },\n\t\t};\n\t}\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,kBAeO;AACP,IAAAA,eAAsB;AACtB,IAAAA,eAAqB;AAErB,iBAUO;AACP,0BAMO;AACP,oCAQO;AACP,oBAAkB;AAClB,mBAAoD;AACpD,2BAA8B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAiCjB,qCAAiC,MAAA;8BAD7C,mCAAI,2BAAe,gCAAgC,CAAC,CAAC;;;;oBACC;;;;;yDAAA,YAAK;WAAA;;;;;;;;6BAwI1D,uDAAA,CAAc;yBAYd,mDAAA,CAAc;yBA8Ed,mDAAA,CAAc;AAzFf,mBAAA,MAAA,MAAA,qBAAA,EAAA,MAAA,UAAA,MAAA,WAAA,QAAA,OAAA,SAAA,OAAA,QAAA,EAAA,KAAA,gCAAA,aAAA,KAAA,QAAA,KAAA,gCAAA,IAAa,SAAb,OAAoB,GAAA,UAAA,UAAA,GAAA,MAAA,0BAAA;AAYpB,mBAAA,MAAA,MAAA,iBAAA,EAAA,MAAA,UAAA,MAAA,OAAA,QAAA,OAAA,SAAA,OAAA,QAAA,EAAA,KAAA,gCAAA,SAAA,KAAA,QAAA,KAAA,gCAAA,IAAa,KAAb,OAAgB,GAAA,UAAA,UAAA,GAAA,MAAA,0BAAA;AA8EhB,mBAAA,MAAA,MAAA,iBAAA,EAAA,MAAA,UAAA,MAAA,OAAA,QAAA,OAAA,SAAA,OAAA,QAAA,EAAA,KAAA,gCAAA,SAAA,KAAA,QAAA,KAAA,gCAAA,IAAa,KAAb,OAAgB,GAAA,UAAA,UAAA,GAAA,MAAA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,KAAK;AACxD;AAPS;IAmBI,qCAAiC,MAAA;8BAL7C,yCAAU,iDAAoC,GAAG,OACjD,kDACA,sCACA,8CAA8C,CAC9C;;;;oBAEQ;yDAAA,YAA8B;WAAA;;;;;;;;AADvC,mBAAA,MAAA,mBAAA,EAAA,OAAA,WAAA,GAAA,kBAAA,EAAA,MAAA,SAAA,MAAA,WAAA,MAAA,UAAA,UAAA,GAAA,MAAA,uBAAA;;;AAAa,wBAAA,YAAA,uBAAA;;IAGZ,YACC,SAA8D;AAE9D,YAAM,OAAO;AACb,WAAK,UAAU,QAAQ;IACxB;IAEO,OAAO,KACb,MACA,MAAsB;AAGtB,YAAM,IAAI,uBACT,GAAG,KAAK,IAAI,qCACZ,4BAAgB,8BAA8B;IAMhD;IAEO;IAEA,UAAU,KAAsB;AACtC,WAAK,UAAU,mBAAM,KAAK,CAAC,KAAK,OAAO,CAAC;AACxC,aAAO,MAAM,UAAU,GAAG;IAC3B;IAEO,WAAW,KAAgB;AACjC,aAAO;QACN,GAAG,MAAM,WAAW,GAAG;QACvB,SAAS,EAAE,YAAY,KAAK,QAAO;;IAErC;;;;",
|
|
6
6
|
"names": ["import_safe", "SceneControllerConfigurationCC"]
|
|
7
7
|
}
|
|
@@ -6,368 +6,164 @@ import { CCAPI } from "../lib/API.js";
|
|
|
6
6
|
import { type CCRaw, CommandClass, type InterviewContext, type PersistValuesContext } from "../lib/CommandClass.js";
|
|
7
7
|
import { ScheduleEntryLockCommand, type ScheduleEntryLockDailyRepeatingSchedule, ScheduleEntryLockScheduleKind, ScheduleEntryLockSetAction, type ScheduleEntryLockSlotId, type ScheduleEntryLockWeekDaySchedule, ScheduleEntryLockWeekday, type ScheduleEntryLockYearDaySchedule, type Timezone } from "../lib/_Types.js";
|
|
8
8
|
export declare const ScheduleEntryLockCCValues: Readonly<{
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
readonly
|
|
12
|
-
readonly
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
readonly type: "any";
|
|
16
|
-
readonly readable: true;
|
|
17
|
-
readonly writeable: true;
|
|
18
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>) extends infer T ? { [K in keyof T as [undefined] extends [(import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
19
|
-
readonly type: "any";
|
|
20
|
-
readonly readable: true;
|
|
21
|
-
readonly writeable: true;
|
|
22
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
23
|
-
readonly type: "any";
|
|
24
|
-
readonly readable: true;
|
|
25
|
-
readonly writeable: true;
|
|
26
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]] ? never : K]: (import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
27
|
-
readonly type: "any";
|
|
28
|
-
readonly readable: true;
|
|
29
|
-
readonly writeable: true;
|
|
30
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
31
|
-
readonly type: "any";
|
|
32
|
-
readonly readable: true;
|
|
33
|
-
readonly writeable: true;
|
|
34
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]; } : never>;
|
|
35
|
-
readonly id: ValueIDBase;
|
|
36
|
-
readonly endpoint: (endpoint?: number | undefined) => {
|
|
9
|
+
numWeekDaySlots: {
|
|
10
|
+
id: {
|
|
11
|
+
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
12
|
+
readonly property: "numWeekDaySlots";
|
|
13
|
+
};
|
|
14
|
+
endpoint: (endpoint?: number) => {
|
|
37
15
|
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
38
16
|
readonly endpoint: number;
|
|
39
|
-
readonly property: "
|
|
40
|
-
readonly propertyKey: number;
|
|
17
|
+
readonly property: "numWeekDaySlots";
|
|
41
18
|
};
|
|
42
|
-
}) & {
|
|
43
19
|
is: (valueId: import("@zwave-js/core").ValueID) => boolean;
|
|
44
|
-
readonly
|
|
45
|
-
readonly stateful: true;
|
|
46
|
-
readonly secret: false;
|
|
47
|
-
readonly minVersion: 1;
|
|
48
|
-
readonly supportsEndpoints: true;
|
|
49
|
-
readonly autoCreate: true;
|
|
50
|
-
readonly internal: true;
|
|
51
|
-
};
|
|
52
|
-
};
|
|
53
|
-
scheduleKind: ((userId: number) => {
|
|
54
|
-
readonly meta: Readonly<(import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
55
|
-
readonly type: "any";
|
|
56
|
-
readonly readable: true;
|
|
57
|
-
readonly writeable: true;
|
|
58
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
59
|
-
readonly type: "any";
|
|
60
|
-
readonly readable: true;
|
|
61
|
-
readonly writeable: true;
|
|
62
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>) extends infer T ? { [K in keyof T as [undefined] extends [(import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
63
|
-
readonly type: "any";
|
|
64
|
-
readonly readable: true;
|
|
65
|
-
readonly writeable: true;
|
|
66
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
67
|
-
readonly type: "any";
|
|
68
|
-
readonly readable: true;
|
|
69
|
-
readonly writeable: true;
|
|
70
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]] ? never : K]: (import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
71
|
-
readonly type: "any";
|
|
72
|
-
readonly readable: true;
|
|
73
|
-
readonly writeable: true;
|
|
74
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
20
|
+
readonly meta: Readonly<{
|
|
75
21
|
readonly type: "any";
|
|
76
22
|
readonly readable: true;
|
|
77
23
|
readonly writeable: true;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
82
|
-
readonly endpoint: number;
|
|
83
|
-
readonly property: "scheduleKind";
|
|
84
|
-
readonly propertyKey: number;
|
|
85
|
-
};
|
|
86
|
-
}) & {
|
|
87
|
-
is: (valueId: import("@zwave-js/core").ValueID) => boolean;
|
|
88
|
-
readonly options: {
|
|
89
|
-
readonly stateful: true;
|
|
90
|
-
readonly secret: false;
|
|
24
|
+
}>;
|
|
25
|
+
options: {
|
|
26
|
+
readonly internal: true;
|
|
91
27
|
readonly minVersion: 1;
|
|
28
|
+
readonly secret: false;
|
|
29
|
+
readonly stateful: true;
|
|
92
30
|
readonly supportsEndpoints: true;
|
|
93
31
|
readonly autoCreate: true;
|
|
94
|
-
readonly internal: true;
|
|
95
32
|
};
|
|
96
33
|
};
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
readonly
|
|
100
|
-
readonly
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
readonly type: "any";
|
|
104
|
-
readonly readable: true;
|
|
105
|
-
readonly writeable: true;
|
|
106
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>) extends infer T ? { [K in keyof T as [undefined] extends [(import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
107
|
-
readonly type: "any";
|
|
108
|
-
readonly readable: true;
|
|
109
|
-
readonly writeable: true;
|
|
110
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
111
|
-
readonly type: "any";
|
|
112
|
-
readonly readable: true;
|
|
113
|
-
readonly writeable: true;
|
|
114
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]] ? never : K]: (import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
115
|
-
readonly type: "any";
|
|
116
|
-
readonly readable: true;
|
|
117
|
-
readonly writeable: true;
|
|
118
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
119
|
-
readonly type: "any";
|
|
120
|
-
readonly readable: true;
|
|
121
|
-
readonly writeable: true;
|
|
122
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]; } : never>;
|
|
123
|
-
readonly id: ValueIDBase;
|
|
124
|
-
readonly endpoint: (endpoint?: number | undefined) => {
|
|
34
|
+
numYearDaySlots: {
|
|
35
|
+
id: {
|
|
36
|
+
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
37
|
+
readonly property: "numYearDaySlots";
|
|
38
|
+
};
|
|
39
|
+
endpoint: (endpoint?: number) => {
|
|
125
40
|
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
126
41
|
readonly endpoint: number;
|
|
127
|
-
readonly property: "
|
|
128
|
-
readonly propertyKey: number;
|
|
42
|
+
readonly property: "numYearDaySlots";
|
|
129
43
|
};
|
|
130
|
-
}) & {
|
|
131
44
|
is: (valueId: import("@zwave-js/core").ValueID) => boolean;
|
|
132
|
-
readonly
|
|
133
|
-
readonly
|
|
134
|
-
readonly
|
|
45
|
+
readonly meta: Readonly<{
|
|
46
|
+
readonly type: "any";
|
|
47
|
+
readonly readable: true;
|
|
48
|
+
readonly writeable: true;
|
|
49
|
+
}>;
|
|
50
|
+
options: {
|
|
51
|
+
readonly internal: true;
|
|
135
52
|
readonly minVersion: 1;
|
|
53
|
+
readonly secret: false;
|
|
54
|
+
readonly stateful: true;
|
|
136
55
|
readonly supportsEndpoints: true;
|
|
137
56
|
readonly autoCreate: true;
|
|
138
|
-
readonly internal: true;
|
|
139
57
|
};
|
|
140
58
|
};
|
|
141
59
|
numDailyRepeatingSlots: {
|
|
142
|
-
|
|
143
|
-
|
|
60
|
+
id: {
|
|
61
|
+
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
62
|
+
readonly property: "numDailyRepeatingSlots";
|
|
63
|
+
};
|
|
64
|
+
endpoint: (endpoint?: number) => {
|
|
144
65
|
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
145
66
|
readonly endpoint: number;
|
|
146
67
|
readonly property: "numDailyRepeatingSlots";
|
|
147
68
|
};
|
|
148
|
-
|
|
149
|
-
readonly meta: Readonly<
|
|
150
|
-
readonly type: "any";
|
|
151
|
-
readonly readable: true;
|
|
152
|
-
readonly writeable: true;
|
|
153
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
154
|
-
readonly type: "any";
|
|
155
|
-
readonly readable: true;
|
|
156
|
-
readonly writeable: true;
|
|
157
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>) extends infer T ? { [K in keyof T as [undefined] extends [(import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
158
|
-
readonly type: "any";
|
|
159
|
-
readonly readable: true;
|
|
160
|
-
readonly writeable: true;
|
|
161
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
162
|
-
readonly type: "any";
|
|
163
|
-
readonly readable: true;
|
|
164
|
-
readonly writeable: true;
|
|
165
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]] ? never : K]: (import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
166
|
-
readonly type: "any";
|
|
167
|
-
readonly readable: true;
|
|
168
|
-
readonly writeable: true;
|
|
169
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
69
|
+
is: (valueId: import("@zwave-js/core").ValueID) => boolean;
|
|
70
|
+
readonly meta: Readonly<{
|
|
170
71
|
readonly type: "any";
|
|
171
72
|
readonly readable: true;
|
|
172
73
|
readonly writeable: true;
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
readonly internal:
|
|
176
|
-
readonly minVersion: 1;
|
|
177
|
-
readonly secret: false;
|
|
178
|
-
readonly stateful: true;
|
|
179
|
-
readonly supportsEndpoints: true;
|
|
180
|
-
readonly autoCreate: true;
|
|
181
|
-
} : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<{
|
|
182
|
-
readonly internal: false;
|
|
183
|
-
readonly minVersion: 1;
|
|
184
|
-
readonly secret: false;
|
|
185
|
-
readonly stateful: true;
|
|
186
|
-
readonly supportsEndpoints: true;
|
|
187
|
-
readonly autoCreate: true;
|
|
188
|
-
}, ("stateful" | "secret" | "internal" | "minVersion" | "supportsEndpoints" | "autoCreate") & keyof NonNullable<TBlueprint["options"]>> & TBlueprint["options"]>) extends infer T ? { [K in keyof T as [undefined] extends [(import("@zwave-js/cc").CCValueOptions extends NonNullable<TBlueprint["options"]> ? {
|
|
189
|
-
readonly internal: false;
|
|
190
|
-
readonly minVersion: 1;
|
|
191
|
-
readonly secret: false;
|
|
192
|
-
readonly stateful: true;
|
|
193
|
-
readonly supportsEndpoints: true;
|
|
194
|
-
readonly autoCreate: true;
|
|
195
|
-
} : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<{
|
|
196
|
-
readonly internal: false;
|
|
197
|
-
readonly minVersion: 1;
|
|
198
|
-
readonly secret: false;
|
|
199
|
-
readonly stateful: true;
|
|
200
|
-
readonly supportsEndpoints: true;
|
|
201
|
-
readonly autoCreate: true;
|
|
202
|
-
}, ("stateful" | "secret" | "internal" | "minVersion" | "supportsEndpoints" | "autoCreate") & keyof NonNullable<TBlueprint["options"]>> & TBlueprint["options"]>)[K]] ? never : K]: (import("@zwave-js/cc").CCValueOptions extends NonNullable<TBlueprint["options"]> ? {
|
|
203
|
-
readonly internal: false;
|
|
204
|
-
readonly minVersion: 1;
|
|
205
|
-
readonly secret: false;
|
|
206
|
-
readonly stateful: true;
|
|
207
|
-
readonly supportsEndpoints: true;
|
|
208
|
-
readonly autoCreate: true;
|
|
209
|
-
} : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<{
|
|
210
|
-
readonly internal: false;
|
|
74
|
+
}>;
|
|
75
|
+
options: {
|
|
76
|
+
readonly internal: true;
|
|
211
77
|
readonly minVersion: 1;
|
|
212
78
|
readonly secret: false;
|
|
213
79
|
readonly stateful: true;
|
|
214
80
|
readonly supportsEndpoints: true;
|
|
215
81
|
readonly autoCreate: true;
|
|
216
|
-
}
|
|
82
|
+
};
|
|
217
83
|
};
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
84
|
+
userEnabled: ((userId: number) => {
|
|
85
|
+
id: {
|
|
86
|
+
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
87
|
+
readonly property: "userEnabled";
|
|
88
|
+
readonly propertyKey: number;
|
|
89
|
+
};
|
|
90
|
+
endpoint: (endpoint?: number) => {
|
|
221
91
|
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
222
92
|
readonly endpoint: number;
|
|
223
|
-
readonly property: "
|
|
93
|
+
readonly property: "userEnabled";
|
|
94
|
+
readonly propertyKey: number;
|
|
224
95
|
};
|
|
225
|
-
readonly
|
|
226
|
-
readonly meta: Readonly<(import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
227
|
-
readonly type: "any";
|
|
228
|
-
readonly readable: true;
|
|
229
|
-
readonly writeable: true;
|
|
230
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
231
|
-
readonly type: "any";
|
|
232
|
-
readonly readable: true;
|
|
233
|
-
readonly writeable: true;
|
|
234
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>) extends infer T ? { [K in keyof T as [undefined] extends [(import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
235
|
-
readonly type: "any";
|
|
236
|
-
readonly readable: true;
|
|
237
|
-
readonly writeable: true;
|
|
238
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
239
|
-
readonly type: "any";
|
|
240
|
-
readonly readable: true;
|
|
241
|
-
readonly writeable: true;
|
|
242
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]] ? never : K]: (import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
96
|
+
readonly meta: Readonly<{
|
|
243
97
|
readonly type: "any";
|
|
244
98
|
readonly readable: true;
|
|
245
99
|
readonly writeable: true;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
readonly options: Readonly<(import("@zwave-js/cc").CCValueOptions extends NonNullable<TBlueprint["options"]> ? {
|
|
252
|
-
readonly internal: false;
|
|
253
|
-
readonly minVersion: 1;
|
|
254
|
-
readonly secret: false;
|
|
255
|
-
readonly stateful: true;
|
|
256
|
-
readonly supportsEndpoints: true;
|
|
257
|
-
readonly autoCreate: true;
|
|
258
|
-
} : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<{
|
|
259
|
-
readonly internal: false;
|
|
260
|
-
readonly minVersion: 1;
|
|
261
|
-
readonly secret: false;
|
|
262
|
-
readonly stateful: true;
|
|
263
|
-
readonly supportsEndpoints: true;
|
|
264
|
-
readonly autoCreate: true;
|
|
265
|
-
}, ("stateful" | "secret" | "internal" | "minVersion" | "supportsEndpoints" | "autoCreate") & keyof NonNullable<TBlueprint["options"]>> & TBlueprint["options"]>) extends infer T ? { [K in keyof T as [undefined] extends [(import("@zwave-js/cc").CCValueOptions extends NonNullable<TBlueprint["options"]> ? {
|
|
266
|
-
readonly internal: false;
|
|
267
|
-
readonly minVersion: 1;
|
|
268
|
-
readonly secret: false;
|
|
269
|
-
readonly stateful: true;
|
|
270
|
-
readonly supportsEndpoints: true;
|
|
271
|
-
readonly autoCreate: true;
|
|
272
|
-
} : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<{
|
|
273
|
-
readonly internal: false;
|
|
274
|
-
readonly minVersion: 1;
|
|
275
|
-
readonly secret: false;
|
|
276
|
-
readonly stateful: true;
|
|
277
|
-
readonly supportsEndpoints: true;
|
|
278
|
-
readonly autoCreate: true;
|
|
279
|
-
}, ("stateful" | "secret" | "internal" | "minVersion" | "supportsEndpoints" | "autoCreate") & keyof NonNullable<TBlueprint["options"]>> & TBlueprint["options"]>)[K]] ? never : K]: (import("@zwave-js/cc").CCValueOptions extends NonNullable<TBlueprint["options"]> ? {
|
|
280
|
-
readonly internal: false;
|
|
281
|
-
readonly minVersion: 1;
|
|
282
|
-
readonly secret: false;
|
|
283
|
-
readonly stateful: true;
|
|
284
|
-
readonly supportsEndpoints: true;
|
|
285
|
-
readonly autoCreate: true;
|
|
286
|
-
} : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<{
|
|
287
|
-
readonly internal: false;
|
|
100
|
+
}>;
|
|
101
|
+
}) & {
|
|
102
|
+
is: (valueId: import("@zwave-js/core").ValueID) => boolean;
|
|
103
|
+
options: {
|
|
104
|
+
readonly internal: true;
|
|
288
105
|
readonly minVersion: 1;
|
|
289
106
|
readonly secret: false;
|
|
290
107
|
readonly stateful: true;
|
|
291
108
|
readonly supportsEndpoints: true;
|
|
292
109
|
readonly autoCreate: true;
|
|
293
|
-
}
|
|
110
|
+
};
|
|
294
111
|
};
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
112
|
+
scheduleKind: ((userId: number) => {
|
|
113
|
+
id: {
|
|
114
|
+
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
115
|
+
readonly property: "scheduleKind";
|
|
116
|
+
readonly propertyKey: number;
|
|
117
|
+
};
|
|
118
|
+
endpoint: (endpoint?: number) => {
|
|
298
119
|
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
299
120
|
readonly endpoint: number;
|
|
300
|
-
readonly property: "
|
|
121
|
+
readonly property: "scheduleKind";
|
|
122
|
+
readonly propertyKey: number;
|
|
301
123
|
};
|
|
302
|
-
readonly
|
|
303
|
-
readonly meta: Readonly<(import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
124
|
+
readonly meta: Readonly<{
|
|
304
125
|
readonly type: "any";
|
|
305
126
|
readonly readable: true;
|
|
306
127
|
readonly writeable: true;
|
|
307
|
-
}
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
readonly type: "any";
|
|
313
|
-
readonly readable: true;
|
|
314
|
-
readonly writeable: true;
|
|
315
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
316
|
-
readonly type: "any";
|
|
317
|
-
readonly readable: true;
|
|
318
|
-
readonly writeable: true;
|
|
319
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]] ? never : K]: (import("@zwave-js/core").ValueMetadata extends NonNullable<TBlueprint["meta"]> ? Readonly<{
|
|
320
|
-
readonly type: "any";
|
|
321
|
-
readonly readable: true;
|
|
322
|
-
readonly writeable: true;
|
|
323
|
-
}> : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<Readonly<{
|
|
324
|
-
readonly type: "any";
|
|
325
|
-
readonly readable: true;
|
|
326
|
-
readonly writeable: true;
|
|
327
|
-
}>, ("type" | "readable" | "writeable") & keyof NonNullable<TBlueprint["meta"]>> & TBlueprint["meta"]>)[K]; } : never>;
|
|
328
|
-
readonly options: Readonly<(import("@zwave-js/cc").CCValueOptions extends NonNullable<TBlueprint["options"]> ? {
|
|
329
|
-
readonly internal: false;
|
|
330
|
-
readonly minVersion: 1;
|
|
331
|
-
readonly secret: false;
|
|
332
|
-
readonly stateful: true;
|
|
333
|
-
readonly supportsEndpoints: true;
|
|
334
|
-
readonly autoCreate: true;
|
|
335
|
-
} : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<{
|
|
336
|
-
readonly internal: false;
|
|
337
|
-
readonly minVersion: 1;
|
|
338
|
-
readonly secret: false;
|
|
339
|
-
readonly stateful: true;
|
|
340
|
-
readonly supportsEndpoints: true;
|
|
341
|
-
readonly autoCreate: true;
|
|
342
|
-
}, ("stateful" | "secret" | "internal" | "minVersion" | "supportsEndpoints" | "autoCreate") & keyof NonNullable<TBlueprint["options"]>> & TBlueprint["options"]>) extends infer T ? { [K in keyof T as [undefined] extends [(import("@zwave-js/cc").CCValueOptions extends NonNullable<TBlueprint["options"]> ? {
|
|
343
|
-
readonly internal: false;
|
|
344
|
-
readonly minVersion: 1;
|
|
345
|
-
readonly secret: false;
|
|
346
|
-
readonly stateful: true;
|
|
347
|
-
readonly supportsEndpoints: true;
|
|
348
|
-
readonly autoCreate: true;
|
|
349
|
-
} : import("alcalzone-shared/types").Simplify<import("alcalzone-shared/types").Omit<{
|
|
350
|
-
readonly internal: false;
|
|
351
|
-
readonly minVersion: 1;
|
|
352
|
-
readonly secret: false;
|
|
353
|
-
readonly stateful: true;
|
|
354
|
-
readonly supportsEndpoints: true;
|
|
355
|
-
readonly autoCreate: true;
|
|
356
|
-
}, ("stateful" | "secret" | "internal" | "minVersion" | "supportsEndpoints" | "autoCreate") & keyof NonNullable<TBlueprint["options"]>> & TBlueprint["options"]>)[K]] ? never : K]: (import("@zwave-js/cc").CCValueOptions extends NonNullable<TBlueprint["options"]> ? {
|
|
357
|
-
readonly internal: false;
|
|
128
|
+
}>;
|
|
129
|
+
}) & {
|
|
130
|
+
is: (valueId: import("@zwave-js/core").ValueID) => boolean;
|
|
131
|
+
options: {
|
|
132
|
+
readonly internal: true;
|
|
358
133
|
readonly minVersion: 1;
|
|
359
134
|
readonly secret: false;
|
|
360
135
|
readonly stateful: true;
|
|
361
136
|
readonly supportsEndpoints: true;
|
|
362
137
|
readonly autoCreate: true;
|
|
363
|
-
}
|
|
364
|
-
|
|
138
|
+
};
|
|
139
|
+
};
|
|
140
|
+
schedule: ((scheduleKind: ScheduleEntryLockScheduleKind, userId: number, slotId: number) => {
|
|
141
|
+
id: {
|
|
142
|
+
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
143
|
+
readonly property: "schedule";
|
|
144
|
+
readonly propertyKey: number;
|
|
145
|
+
};
|
|
146
|
+
endpoint: (endpoint?: number) => {
|
|
147
|
+
readonly commandClass: (typeof CommandClasses)["Schedule Entry Lock"];
|
|
148
|
+
readonly endpoint: number;
|
|
149
|
+
readonly property: "schedule";
|
|
150
|
+
readonly propertyKey: number;
|
|
151
|
+
};
|
|
152
|
+
readonly meta: Readonly<{
|
|
153
|
+
readonly type: "any";
|
|
154
|
+
readonly readable: true;
|
|
155
|
+
readonly writeable: true;
|
|
156
|
+
}>;
|
|
157
|
+
}) & {
|
|
158
|
+
is: (valueId: import("@zwave-js/core").ValueID) => boolean;
|
|
159
|
+
options: {
|
|
160
|
+
readonly internal: true;
|
|
365
161
|
readonly minVersion: 1;
|
|
366
162
|
readonly secret: false;
|
|
367
163
|
readonly stateful: true;
|
|
368
164
|
readonly supportsEndpoints: true;
|
|
369
165
|
readonly autoCreate: true;
|
|
370
|
-
}
|
|
166
|
+
};
|
|
371
167
|
};
|
|
372
168
|
}>;
|
|
373
169
|
export declare class ScheduleEntryLockCCAPI extends CCAPI {
|