@zwave-js/cc 14.0.0-beta.4 → 14.0.0
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.js +381 -266
- package/build/cjs/cc/AlarmSensorCC.js.map +3 -3
- package/build/cjs/cc/AssociationCC.js +669 -503
- package/build/cjs/cc/AssociationCC.js.map +3 -3
- package/build/cjs/cc/AssociationGroupInfoCC.js +633 -492
- package/build/cjs/cc/AssociationGroupInfoCC.js.map +3 -3
- package/build/cjs/cc/BarrierOperatorCC.js +595 -429
- package/build/cjs/cc/BarrierOperatorCC.js.map +3 -3
- package/build/cjs/cc/BasicCC.js +354 -260
- package/build/cjs/cc/BasicCC.js.map +3 -3
- package/build/cjs/cc/BatteryCC.js +427 -345
- package/build/cjs/cc/BatteryCC.js.map +3 -3
- package/build/cjs/cc/BinarySensorCC.js +391 -276
- package/build/cjs/cc/BinarySensorCC.js.map +3 -3
- package/build/cjs/cc/BinarySwitchCC.js +347 -253
- package/build/cjs/cc/BinarySwitchCC.js.map +3 -3
- package/build/cjs/cc/CRC16CC.js +160 -85
- package/build/cjs/cc/CRC16CC.js.map +3 -3
- package/build/cjs/cc/CentralSceneCC.js +459 -324
- package/build/cjs/cc/CentralSceneCC.js.map +3 -3
- package/build/cjs/cc/ClimateControlScheduleCC.js +459 -293
- package/build/cjs/cc/ClimateControlScheduleCC.js.map +3 -3
- package/build/cjs/cc/ClockCC.js +254 -150
- package/build/cjs/cc/ClockCC.js.map +3 -3
- package/build/cjs/cc/ColorSwitchCC.js +758 -610
- package/build/cjs/cc/ColorSwitchCC.js.map +3 -3
- package/build/cjs/cc/ConfigurationCC.js +1700 -1453
- package/build/cjs/cc/ConfigurationCC.js.map +3 -3
- package/build/cjs/cc/DeviceResetLocallyCC.js +125 -49
- package/build/cjs/cc/DeviceResetLocallyCC.js.map +3 -3
- package/build/cjs/cc/DoorLockCC.js +904 -777
- package/build/cjs/cc/DoorLockCC.js.map +3 -3
- package/build/cjs/cc/DoorLockLoggingCC.js +321 -206
- package/build/cjs/cc/DoorLockLoggingCC.js.map +3 -3
- package/build/cjs/cc/EnergyProductionCC.js +249 -160
- package/build/cjs/cc/EnergyProductionCC.js.map +3 -3
- package/build/cjs/cc/EntryControlCC.js +619 -458
- package/build/cjs/cc/EntryControlCC.js.map +3 -3
- package/build/cjs/cc/FirmwareUpdateMetaDataCC.js +898 -698
- package/build/cjs/cc/FirmwareUpdateMetaDataCC.js.map +3 -3
- package/build/cjs/cc/HailCC.js +57 -11
- package/build/cjs/cc/HailCC.js.map +2 -2
- package/build/cjs/cc/HumidityControlModeCC.js +359 -233
- package/build/cjs/cc/HumidityControlModeCC.js.map +3 -3
- package/build/cjs/cc/HumidityControlOperatingStateCC.js +189 -103
- package/build/cjs/cc/HumidityControlOperatingStateCC.js.map +3 -3
- package/build/cjs/cc/HumidityControlSetpointCC.js +682 -495
- package/build/cjs/cc/HumidityControlSetpointCC.js.map +3 -3
- package/build/cjs/cc/InclusionControllerCC.js +205 -114
- package/build/cjs/cc/InclusionControllerCC.js.map +3 -3
- package/build/cjs/cc/IndicatorCC.js +897 -736
- package/build/cjs/cc/IndicatorCC.js.map +3 -3
- package/build/cjs/cc/IrrigationCC.js +1651 -1405
- package/build/cjs/cc/IrrigationCC.js.map +3 -3
- package/build/cjs/cc/LanguageCC.js +268 -171
- package/build/cjs/cc/LanguageCC.js.map +3 -3
- package/build/cjs/cc/LockCC.js +254 -154
- package/build/cjs/cc/LockCC.js.map +3 -3
- package/build/cjs/cc/ManufacturerProprietaryCC.js +189 -129
- package/build/cjs/cc/ManufacturerProprietaryCC.js.map +2 -2
- package/build/cjs/cc/ManufacturerSpecificCC.js +319 -213
- package/build/cjs/cc/ManufacturerSpecificCC.js.map +3 -3
- package/build/cjs/cc/MeterCC.js +827 -707
- package/build/cjs/cc/MeterCC.js.map +3 -3
- package/build/cjs/cc/MultiChannelAssociationCC.js +612 -478
- package/build/cjs/cc/MultiChannelAssociationCC.js.map +3 -3
- package/build/cjs/cc/MultiChannelCC.js +1037 -819
- package/build/cjs/cc/MultiChannelCC.js.map +3 -3
- package/build/cjs/cc/MultiCommandCC.js +172 -97
- package/build/cjs/cc/MultiCommandCC.js.map +3 -3
- package/build/cjs/cc/MultilevelSensorCC.js +589 -449
- package/build/cjs/cc/MultilevelSensorCC.js.map +3 -3
- package/build/cjs/cc/MultilevelSwitchCC.js +587 -439
- package/build/cjs/cc/MultilevelSwitchCC.js.map +3 -3
- package/build/cjs/cc/NoOperationCC.js +89 -27
- package/build/cjs/cc/NoOperationCC.js.map +2 -2
- package/build/cjs/cc/NodeNamingCC.js +417 -277
- package/build/cjs/cc/NodeNamingCC.js.map +3 -3
- package/build/cjs/cc/NotificationCC.js +972 -818
- package/build/cjs/cc/NotificationCC.js.map +3 -3
- package/build/cjs/cc/PowerlevelCC.js +450 -303
- package/build/cjs/cc/PowerlevelCC.js.map +3 -3
- package/build/cjs/cc/ProtectionCC.js +686 -494
- package/build/cjs/cc/ProtectionCC.js.map +3 -3
- package/build/cjs/cc/SceneActivationCC.js +165 -97
- package/build/cjs/cc/SceneActivationCC.js.map +3 -3
- package/build/cjs/cc/SceneActuatorConfigurationCC.js +346 -243
- package/build/cjs/cc/SceneActuatorConfigurationCC.js.map +3 -3
- package/build/cjs/cc/SceneControllerConfigurationCC.js +401 -298
- package/build/cjs/cc/SceneControllerConfigurationCC.js.map +3 -3
- package/build/cjs/cc/ScheduleEntryLockCC.js +1552 -1272
- package/build/cjs/cc/ScheduleEntryLockCC.js.map +3 -3
- package/build/cjs/cc/Security2CC.js +1483 -1219
- package/build/cjs/cc/Security2CC.js.map +3 -3
- package/build/cjs/cc/SecurityCC.js +839 -619
- package/build/cjs/cc/SecurityCC.js.map +3 -3
- package/build/cjs/cc/SoundSwitchCC.js +707 -515
- package/build/cjs/cc/SoundSwitchCC.js.map +3 -3
- package/build/cjs/cc/SupervisionCC.js +327 -237
- package/build/cjs/cc/SupervisionCC.js.map +3 -3
- package/build/cjs/cc/ThermostatFanModeCC.js +386 -263
- package/build/cjs/cc/ThermostatFanModeCC.js.map +3 -3
- package/build/cjs/cc/ThermostatFanStateCC.js +192 -106
- package/build/cjs/cc/ThermostatFanStateCC.js.map +3 -3
- package/build/cjs/cc/ThermostatModeCC.js +425 -302
- package/build/cjs/cc/ThermostatModeCC.js.map +3 -3
- package/build/cjs/cc/ThermostatOperatingStateCC.js +188 -102
- package/build/cjs/cc/ThermostatOperatingStateCC.js.map +3 -3
- package/build/cjs/cc/ThermostatSetbackCC.js +277 -173
- package/build/cjs/cc/ThermostatSetbackCC.js.map +3 -3
- package/build/cjs/cc/ThermostatSetpointCC.js +645 -491
- package/build/cjs/cc/ThermostatSetpointCC.js.map +3 -3
- package/build/cjs/cc/TimeCC.js +515 -353
- package/build/cjs/cc/TimeCC.js.map +3 -3
- package/build/cjs/cc/TimeParametersCC.js +302 -202
- package/build/cjs/cc/TimeParametersCC.js.map +3 -3
- package/build/cjs/cc/TransportServiceCC.js +433 -315
- package/build/cjs/cc/TransportServiceCC.js.map +3 -3
- package/build/cjs/cc/UserCodeCC.js +1385 -1102
- package/build/cjs/cc/UserCodeCC.js.map +3 -3
- package/build/cjs/cc/VersionCC.js +696 -562
- package/build/cjs/cc/VersionCC.js.map +3 -3
- package/build/cjs/cc/WakeUpCC.js +499 -346
- package/build/cjs/cc/WakeUpCC.js.map +3 -3
- package/build/cjs/cc/WindowCoveringCC.js +626 -478
- package/build/cjs/cc/WindowCoveringCC.js.map +3 -3
- package/build/cjs/cc/ZWaveLongRangeCC.js +57 -10
- package/build/cjs/cc/ZWaveLongRangeCC.js.map +2 -2
- package/build/cjs/cc/ZWavePlusCC.js +233 -159
- package/build/cjs/cc/ZWavePlusCC.js.map +3 -3
- package/build/cjs/cc/ZWaveProtocolCC.js +1515 -948
- package/build/cjs/cc/ZWaveProtocolCC.js.map +3 -3
- package/build/cjs/cc/manufacturerProprietary/Decorators.d.ts +4 -4
- package/build/cjs/cc/manufacturerProprietary/Decorators.js.map +1 -1
- package/build/cjs/cc/manufacturerProprietary/FibaroCC.js +395 -274
- package/build/cjs/cc/manufacturerProprietary/FibaroCC.js.map +3 -3
- package/build/cjs/lib/CommandClassDecorators.d.ts +11 -15
- package/build/cjs/lib/CommandClassDecorators.js +19 -20
- package/build/cjs/lib/CommandClassDecorators.js.map +2 -2
- package/build/cjs/lib/Security2/Extension.d.ts +1 -1
- package/build/cjs/lib/Security2/Extension.js +217 -126
- package/build/cjs/lib/Security2/Extension.js.map +3 -3
- package/build/esm/cc/AlarmSensorCC.d.ts.map +1 -1
- package/build/esm/cc/AlarmSensorCC.js +389 -291
- package/build/esm/cc/AlarmSensorCC.js.map +1 -1
- package/build/esm/cc/AssociationCC.d.ts.map +1 -1
- package/build/esm/cc/AssociationCC.js +678 -537
- package/build/esm/cc/AssociationCC.js.map +1 -1
- package/build/esm/cc/AssociationGroupInfoCC.d.ts.map +1 -1
- package/build/esm/cc/AssociationGroupInfoCC.js +659 -539
- package/build/esm/cc/AssociationGroupInfoCC.js.map +1 -1
- package/build/esm/cc/BarrierOperatorCC.d.ts.map +1 -1
- package/build/esm/cc/BarrierOperatorCC.js +634 -493
- package/build/esm/cc/BarrierOperatorCC.js.map +1 -1
- package/build/esm/cc/BasicCC.d.ts.map +1 -1
- package/build/esm/cc/BasicCC.js +380 -302
- package/build/esm/cc/BasicCC.js.map +1 -1
- package/build/esm/cc/BatteryCC.d.ts.map +1 -1
- package/build/esm/cc/BatteryCC.js +449 -384
- package/build/esm/cc/BatteryCC.js.map +1 -1
- package/build/esm/cc/BinarySensorCC.d.ts.map +1 -1
- package/build/esm/cc/BinarySensorCC.js +395 -297
- package/build/esm/cc/BinarySensorCC.js.map +1 -1
- package/build/esm/cc/BinarySwitchCC.d.ts.map +1 -1
- package/build/esm/cc/BinarySwitchCC.js +353 -274
- package/build/esm/cc/BinarySwitchCC.js.map +1 -1
- package/build/esm/cc/CRC16CC.js +162 -98
- package/build/esm/cc/CRC16CC.js.map +1 -1
- package/build/esm/cc/CentralSceneCC.d.ts.map +1 -1
- package/build/esm/cc/CentralSceneCC.js +465 -351
- package/build/esm/cc/CentralSceneCC.js.map +1 -1
- package/build/esm/cc/ClimateControlScheduleCC.d.ts.map +1 -1
- package/build/esm/cc/ClimateControlScheduleCC.js +454 -313
- package/build/esm/cc/ClimateControlScheduleCC.js.map +1 -1
- package/build/esm/cc/ClockCC.js +248 -159
- package/build/esm/cc/ClockCC.js.map +1 -1
- package/build/esm/cc/ColorSwitchCC.d.ts.map +1 -1
- package/build/esm/cc/ColorSwitchCC.js +802 -677
- package/build/esm/cc/ColorSwitchCC.js.map +1 -1
- package/build/esm/cc/ConfigurationCC.js +1899 -1687
- package/build/esm/cc/ConfigurationCC.js.map +1 -1
- package/build/esm/cc/DeviceResetLocallyCC.js +124 -59
- package/build/esm/cc/DeviceResetLocallyCC.js.map +1 -1
- package/build/esm/cc/DoorLockCC.d.ts.map +1 -1
- package/build/esm/cc/DoorLockCC.js +951 -849
- package/build/esm/cc/DoorLockCC.js.map +1 -1
- package/build/esm/cc/DoorLockLoggingCC.d.ts.map +1 -1
- package/build/esm/cc/DoorLockLoggingCC.js +316 -218
- package/build/esm/cc/DoorLockLoggingCC.js.map +1 -1
- package/build/esm/cc/EnergyProductionCC.js +240 -164
- package/build/esm/cc/EnergyProductionCC.js.map +1 -1
- package/build/esm/cc/EntryControlCC.d.ts.map +1 -1
- package/build/esm/cc/EntryControlCC.js +629 -493
- package/build/esm/cc/EntryControlCC.js.map +1 -1
- package/build/esm/cc/FirmwareUpdateMetaDataCC.d.ts.map +1 -1
- package/build/esm/cc/FirmwareUpdateMetaDataCC.js +938 -769
- package/build/esm/cc/FirmwareUpdateMetaDataCC.js.map +1 -1
- package/build/esm/cc/HailCC.js +51 -12
- package/build/esm/cc/HailCC.js.map +1 -1
- package/build/esm/cc/HumidityControlModeCC.d.ts.map +1 -1
- package/build/esm/cc/HumidityControlModeCC.js +357 -250
- package/build/esm/cc/HumidityControlModeCC.js.map +1 -1
- package/build/esm/cc/HumidityControlOperatingStateCC.d.ts.map +1 -1
- package/build/esm/cc/HumidityControlOperatingStateCC.js +182 -109
- package/build/esm/cc/HumidityControlOperatingStateCC.js.map +1 -1
- package/build/esm/cc/HumidityControlSetpointCC.d.ts.map +1 -1
- package/build/esm/cc/HumidityControlSetpointCC.js +706 -546
- package/build/esm/cc/HumidityControlSetpointCC.js.map +1 -1
- package/build/esm/cc/InclusionControllerCC.js +197 -119
- package/build/esm/cc/InclusionControllerCC.js.map +1 -1
- package/build/esm/cc/IndicatorCC.js +973 -835
- package/build/esm/cc/IndicatorCC.js.map +1 -1
- package/build/esm/cc/IrrigationCC.d.ts.map +1 -1
- package/build/esm/cc/IrrigationCC.js +1697 -1496
- package/build/esm/cc/IrrigationCC.js.map +1 -1
- package/build/esm/cc/LanguageCC.d.ts.map +1 -1
- package/build/esm/cc/LanguageCC.js +266 -184
- package/build/esm/cc/LanguageCC.js.map +1 -1
- package/build/esm/cc/LockCC.d.ts.map +1 -1
- package/build/esm/cc/LockCC.js +247 -162
- package/build/esm/cc/LockCC.js.map +1 -1
- package/build/esm/cc/ManufacturerProprietaryCC.js +192 -141
- package/build/esm/cc/ManufacturerProprietaryCC.js.map +1 -1
- package/build/esm/cc/ManufacturerSpecificCC.d.ts.map +1 -1
- package/build/esm/cc/ManufacturerSpecificCC.js +312 -223
- package/build/esm/cc/ManufacturerSpecificCC.js.map +1 -1
- package/build/esm/cc/MeterCC.d.ts.map +1 -1
- package/build/esm/cc/MeterCC.js +896 -795
- package/build/esm/cc/MeterCC.js.map +1 -1
- package/build/esm/cc/MultiChannelAssociationCC.d.ts.map +1 -1
- package/build/esm/cc/MultiChannelAssociationCC.js +631 -518
- package/build/esm/cc/MultiChannelAssociationCC.js.map +1 -1
- package/build/esm/cc/MultiChannelCC.d.ts.map +1 -1
- package/build/esm/cc/MultiChannelCC.js +1106 -921
- package/build/esm/cc/MultiChannelCC.js.map +1 -1
- package/build/esm/cc/MultiCommandCC.js +166 -102
- package/build/esm/cc/MultiCommandCC.js.map +1 -1
- package/build/esm/cc/MultilevelSensorCC.d.ts.map +1 -1
- package/build/esm/cc/MultilevelSensorCC.js +616 -497
- package/build/esm/cc/MultilevelSensorCC.js.map +1 -1
- package/build/esm/cc/MultilevelSwitchCC.d.ts.map +1 -1
- package/build/esm/cc/MultilevelSwitchCC.js +621 -496
- package/build/esm/cc/MultilevelSwitchCC.js.map +1 -1
- package/build/esm/cc/NoOperationCC.js +82 -29
- package/build/esm/cc/NoOperationCC.js.map +1 -1
- package/build/esm/cc/NodeNamingCC.d.ts.map +1 -1
- package/build/esm/cc/NodeNamingCC.js +413 -294
- package/build/esm/cc/NodeNamingCC.js.map +1 -1
- package/build/esm/cc/NotificationCC.d.ts.map +1 -1
- package/build/esm/cc/NotificationCC.js +1097 -966
- package/build/esm/cc/NotificationCC.js.map +1 -1
- package/build/esm/cc/PowerlevelCC.js +437 -311
- package/build/esm/cc/PowerlevelCC.js.map +1 -1
- package/build/esm/cc/ProtectionCC.d.ts.map +1 -1
- package/build/esm/cc/ProtectionCC.js +704 -543
- package/build/esm/cc/ProtectionCC.js.map +1 -1
- package/build/esm/cc/SceneActivationCC.d.ts.map +1 -1
- package/build/esm/cc/SceneActivationCC.js +157 -100
- package/build/esm/cc/SceneActivationCC.js.map +1 -1
- package/build/esm/cc/SceneActuatorConfigurationCC.js +357 -269
- package/build/esm/cc/SceneActuatorConfigurationCC.js.map +1 -1
- package/build/esm/cc/SceneControllerConfigurationCC.js +434 -346
- package/build/esm/cc/SceneControllerConfigurationCC.js.map +1 -1
- package/build/esm/cc/ScheduleEntryLockCC.d.ts.map +1 -1
- package/build/esm/cc/ScheduleEntryLockCC.js +1596 -1357
- package/build/esm/cc/ScheduleEntryLockCC.js.map +1 -1
- package/build/esm/cc/Security2CC.js +1633 -1406
- package/build/esm/cc/Security2CC.js.map +1 -1
- package/build/esm/cc/SecurityCC.js +876 -687
- package/build/esm/cc/SecurityCC.js.map +1 -1
- package/build/esm/cc/SoundSwitchCC.d.ts.map +1 -1
- package/build/esm/cc/SoundSwitchCC.js +689 -526
- package/build/esm/cc/SoundSwitchCC.js.map +1 -1
- package/build/esm/cc/SupervisionCC.js +349 -272
- package/build/esm/cc/SupervisionCC.js.map +1 -1
- package/build/esm/cc/ThermostatFanModeCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatFanModeCC.js +388 -284
- package/build/esm/cc/ThermostatFanModeCC.js.map +1 -1
- package/build/esm/cc/ThermostatFanStateCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatFanStateCC.js +184 -111
- package/build/esm/cc/ThermostatFanStateCC.js.map +1 -1
- package/build/esm/cc/ThermostatModeCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatModeCC.js +435 -331
- package/build/esm/cc/ThermostatModeCC.js.map +1 -1
- package/build/esm/cc/ThermostatOperatingStateCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatOperatingStateCC.js +180 -107
- package/build/esm/cc/ThermostatOperatingStateCC.js.map +1 -1
- package/build/esm/cc/ThermostatSetbackCC.js +274 -185
- package/build/esm/cc/ThermostatSetbackCC.js.map +1 -1
- package/build/esm/cc/ThermostatSetpointCC.d.ts.map +1 -1
- package/build/esm/cc/ThermostatSetpointCC.js +674 -543
- package/build/esm/cc/ThermostatSetpointCC.js.map +1 -1
- package/build/esm/cc/TimeCC.js +499 -360
- package/build/esm/cc/TimeCC.js.map +1 -1
- package/build/esm/cc/TimeParametersCC.d.ts.map +1 -1
- package/build/esm/cc/TimeParametersCC.js +296 -211
- package/build/esm/cc/TimeParametersCC.js.map +1 -1
- package/build/esm/cc/TransportServiceCC.js +464 -363
- package/build/esm/cc/TransportServiceCC.js.map +1 -1
- package/build/esm/cc/UserCodeCC.d.ts.map +1 -1
- package/build/esm/cc/UserCodeCC.js +1443 -1205
- package/build/esm/cc/UserCodeCC.js.map +1 -1
- package/build/esm/cc/VersionCC.d.ts.map +1 -1
- package/build/esm/cc/VersionCC.js +744 -635
- package/build/esm/cc/VersionCC.js.map +1 -1
- package/build/esm/cc/WakeUpCC.d.ts.map +1 -1
- package/build/esm/cc/WakeUpCC.js +494 -364
- package/build/esm/cc/WakeUpCC.js.map +1 -1
- package/build/esm/cc/WindowCoveringCC.d.ts.map +1 -1
- package/build/esm/cc/WindowCoveringCC.js +655 -530
- package/build/esm/cc/WindowCoveringCC.js.map +1 -1
- package/build/esm/cc/ZWaveLongRangeCC.js +51 -11
- package/build/esm/cc/ZWaveLongRangeCC.js.map +1 -1
- package/build/esm/cc/ZWavePlusCC.d.ts.map +1 -1
- package/build/esm/cc/ZWavePlusCC.js +223 -162
- package/build/esm/cc/ZWavePlusCC.js.map +1 -1
- package/build/esm/cc/ZWaveProtocolCC.js +1443 -953
- package/build/esm/cc/ZWaveProtocolCC.js.map +1 -1
- package/build/esm/cc/manufacturerProprietary/Decorators.d.ts +4 -4
- package/build/esm/cc/manufacturerProprietary/Decorators.d.ts.map +1 -1
- package/build/esm/cc/manufacturerProprietary/FibaroCC.js +390 -286
- package/build/esm/cc/manufacturerProprietary/FibaroCC.js.map +1 -1
- package/build/esm/lib/CommandClassDecorators.d.ts +11 -15
- package/build/esm/lib/CommandClassDecorators.d.ts.map +1 -1
- package/build/esm/lib/CommandClassDecorators.js +24 -24
- package/build/esm/lib/CommandClassDecorators.js.map +1 -1
- package/build/esm/lib/Security2/Extension.d.ts +1 -1
- package/build/esm/lib/Security2/Extension.d.ts.map +1 -1
- package/build/esm/lib/Security2/Extension.js +207 -123
- package/build/esm/lib/Security2/Extension.js.map +1 -1
- package/package.json +6 -6
|
@@ -38,13 +38,45 @@ var import_CommandClass = require("../lib/CommandClass.js");
|
|
|
38
38
|
var import_CommandClassDecorators = require("../lib/CommandClassDecorators.js");
|
|
39
39
|
var import_Values = require("../lib/Values.js");
|
|
40
40
|
var import_Types = require("../lib/_Types.js");
|
|
41
|
-
var
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
41
|
+
var __esDecorate = function(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
|
|
42
|
+
function accept(f) {
|
|
43
|
+
if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected");
|
|
44
|
+
return f;
|
|
45
|
+
}
|
|
46
|
+
var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value";
|
|
47
|
+
var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null;
|
|
48
|
+
var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});
|
|
49
|
+
var _, done = false;
|
|
50
|
+
for (var i = decorators.length - 1; i >= 0; i--) {
|
|
51
|
+
var context = {};
|
|
52
|
+
for (var p in contextIn) context[p] = p === "access" ? {} : contextIn[p];
|
|
53
|
+
for (var p in contextIn.access) context.access[p] = contextIn.access[p];
|
|
54
|
+
context.addInitializer = function(f) {
|
|
55
|
+
if (done) throw new TypeError("Cannot add initializers after decoration has completed");
|
|
56
|
+
extraInitializers.push(accept(f || null));
|
|
57
|
+
};
|
|
58
|
+
var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);
|
|
59
|
+
if (kind === "accessor") {
|
|
60
|
+
if (result === void 0) continue;
|
|
61
|
+
if (result === null || typeof result !== "object") throw new TypeError("Object expected");
|
|
62
|
+
if (_ = accept(result.get)) descriptor.get = _;
|
|
63
|
+
if (_ = accept(result.set)) descriptor.set = _;
|
|
64
|
+
if (_ = accept(result.init)) initializers.unshift(_);
|
|
65
|
+
} else if (_ = accept(result)) {
|
|
66
|
+
if (kind === "field") initializers.unshift(_);
|
|
67
|
+
else descriptor[key] = _;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
if (target) Object.defineProperty(target, contextIn.name, descriptor);
|
|
71
|
+
done = true;
|
|
72
|
+
};
|
|
73
|
+
var __runInitializers = function(thisArg, initializers, value) {
|
|
74
|
+
var useValue = arguments.length > 2;
|
|
75
|
+
for (var i = 0; i < initializers.length; i++) {
|
|
76
|
+
value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
|
|
77
|
+
}
|
|
78
|
+
return useValue ? value : void 0;
|
|
46
79
|
};
|
|
47
|
-
var WindowCoveringCCSupportedReport_1, WindowCoveringCCReport_1, WindowCoveringCCGet_1, WindowCoveringCCSet_1, WindowCoveringCCStartLevelChange_1, WindowCoveringCCStopLevelChange_1;
|
|
48
80
|
function __assertType(argName, typeName, boundHasError) {
|
|
49
81
|
const { ZWaveError, ZWaveErrorCodes } = require("@zwave-js/core");
|
|
50
82
|
if (boundHasError()) {
|
|
@@ -249,517 +281,633 @@ const WindowCoveringCCValues = Object.freeze({
|
|
|
249
281
|
)
|
|
250
282
|
})
|
|
251
283
|
});
|
|
252
|
-
let WindowCoveringCCAPI =
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
284
|
+
let WindowCoveringCCAPI = (() => {
|
|
285
|
+
let _classDecorators = [(0, import_CommandClassDecorators.API)(import_core.CommandClasses["Window Covering"])];
|
|
286
|
+
let _classDescriptor;
|
|
287
|
+
let _classExtraInitializers = [];
|
|
288
|
+
let _classThis;
|
|
289
|
+
let _classSuper = import_API.CCAPI;
|
|
290
|
+
var WindowCoveringCCAPI2 = class extends _classSuper {
|
|
291
|
+
static {
|
|
292
|
+
_classThis = this;
|
|
293
|
+
}
|
|
294
|
+
static {
|
|
295
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
296
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
297
|
+
WindowCoveringCCAPI2 = _classThis = _classDescriptor.value;
|
|
298
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
299
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
300
|
+
}
|
|
301
|
+
supportsCommand(cmd) {
|
|
302
|
+
switch (cmd) {
|
|
303
|
+
case import_Types.WindowCoveringCommand.Get:
|
|
304
|
+
case import_Types.WindowCoveringCommand.Set:
|
|
305
|
+
case import_Types.WindowCoveringCommand.SupportedGet:
|
|
306
|
+
case import_Types.WindowCoveringCommand.StartLevelChange:
|
|
307
|
+
case import_Types.WindowCoveringCommand.StopLevelChange:
|
|
308
|
+
return true;
|
|
309
|
+
}
|
|
310
|
+
return super.supportsCommand(cmd);
|
|
311
|
+
}
|
|
312
|
+
get [import_API.SET_VALUE]() {
|
|
313
|
+
return async function({ property, propertyKey }, value, options) {
|
|
314
|
+
const valueId = {
|
|
315
|
+
commandClass: this.ccId,
|
|
316
|
+
property,
|
|
317
|
+
propertyKey
|
|
318
|
+
};
|
|
319
|
+
if (WindowCoveringCCValues.targetValue.is(valueId)) {
|
|
320
|
+
if (typeof propertyKey !== "number" || propertyKey % 2 === 0) {
|
|
321
|
+
(0, import_API.throwUnsupportedPropertyKey)(this.ccId, property, propertyKey);
|
|
322
|
+
}
|
|
323
|
+
if (typeof value !== "number") {
|
|
324
|
+
(0, import_API.throwWrongValueType)(this.ccId, property, "number", typeof value);
|
|
325
|
+
}
|
|
326
|
+
const parameter = propertyKey;
|
|
327
|
+
const duration = import_core.Duration.from(options?.transitionDuration);
|
|
328
|
+
return this.set([{ parameter, value }], duration);
|
|
329
|
+
} else if (WindowCoveringCCValues.levelChangeUp.is(valueId) || WindowCoveringCCValues.levelChangeDown.is(valueId)) {
|
|
330
|
+
if (typeof value !== "boolean") {
|
|
331
|
+
(0, import_API.throwWrongValueType)(this.ccId, property, "boolean", typeof value);
|
|
332
|
+
}
|
|
333
|
+
const parameter = propertyKey;
|
|
334
|
+
const direction = WindowCoveringCCValues.levelChangeUp.is(valueId) ? "up" : "down";
|
|
335
|
+
if (value) {
|
|
336
|
+
const duration = import_core.Duration.from(options?.transitionDuration);
|
|
337
|
+
return this.startLevelChange(parameter, direction, duration);
|
|
338
|
+
} else {
|
|
339
|
+
return this.stopLevelChange(parameter);
|
|
340
|
+
}
|
|
341
|
+
} else {
|
|
342
|
+
(0, import_API.throwUnsupportedProperty)(this.ccId, property);
|
|
343
|
+
}
|
|
344
|
+
};
|
|
345
|
+
}
|
|
346
|
+
[import_API.SET_VALUE_HOOKS] = ({ property, propertyKey }, value, options) => {
|
|
266
347
|
const valueId = {
|
|
267
348
|
commandClass: this.ccId,
|
|
268
349
|
property,
|
|
269
350
|
propertyKey
|
|
270
351
|
};
|
|
271
352
|
if (WindowCoveringCCValues.targetValue.is(valueId)) {
|
|
272
|
-
if (typeof propertyKey !== "number"
|
|
273
|
-
|
|
274
|
-
}
|
|
275
|
-
if (typeof value !== "number") {
|
|
276
|
-
(0, import_API.throwWrongValueType)(this.ccId, property, "number", typeof value);
|
|
277
|
-
}
|
|
353
|
+
if (typeof propertyKey !== "number")
|
|
354
|
+
return;
|
|
278
355
|
const parameter = propertyKey;
|
|
279
356
|
const duration = import_core.Duration.from(options?.transitionDuration);
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
}
|
|
298
|
-
[import_API.SET_VALUE_HOOKS] = ({ property, propertyKey }, value, options) => {
|
|
299
|
-
const valueId = {
|
|
300
|
-
commandClass: this.ccId,
|
|
301
|
-
property,
|
|
302
|
-
propertyKey
|
|
303
|
-
};
|
|
304
|
-
if (WindowCoveringCCValues.targetValue.is(valueId)) {
|
|
305
|
-
if (typeof propertyKey !== "number")
|
|
306
|
-
return;
|
|
307
|
-
const parameter = propertyKey;
|
|
308
|
-
const duration = import_core.Duration.from(options?.transitionDuration);
|
|
309
|
-
const currentValueValueId = WindowCoveringCCValues.currentValue(parameter).endpoint(this.endpoint.index);
|
|
310
|
-
return {
|
|
311
|
-
// Window Covering commands may take some time to be executed.
|
|
312
|
-
// Therefore we try to supervise the command execution and delay the
|
|
313
|
-
// optimistic update until the final result is received.
|
|
314
|
-
supervisionDelayedUpdates: true,
|
|
315
|
-
supervisionOnSuccess: async () => {
|
|
316
|
-
if (typeof value === "number" && value >= 0 && value <= 99) {
|
|
317
|
-
this.tryGetValueDB()?.setValue(currentValueValueId, value);
|
|
318
|
-
} else if (value === 255) {
|
|
357
|
+
const currentValueValueId = WindowCoveringCCValues.currentValue(parameter).endpoint(this.endpoint.index);
|
|
358
|
+
return {
|
|
359
|
+
// Window Covering commands may take some time to be executed.
|
|
360
|
+
// Therefore we try to supervise the command execution and delay the
|
|
361
|
+
// optimistic update until the final result is received.
|
|
362
|
+
supervisionDelayedUpdates: true,
|
|
363
|
+
supervisionOnSuccess: async () => {
|
|
364
|
+
if (typeof value === "number" && value >= 0 && value <= 99) {
|
|
365
|
+
this.tryGetValueDB()?.setValue(currentValueValueId, value);
|
|
366
|
+
} else if (value === 255) {
|
|
367
|
+
try {
|
|
368
|
+
await this.get(parameter);
|
|
369
|
+
} catch {
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
},
|
|
373
|
+
supervisionOnFailure: async () => {
|
|
319
374
|
try {
|
|
320
375
|
await this.get(parameter);
|
|
321
376
|
} catch {
|
|
322
377
|
}
|
|
323
|
-
}
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
if (this.isSinglecast()) {
|
|
334
|
-
this.tryGetValueDB()?.setValue(currentValueValueId, value);
|
|
335
|
-
} else if (this.isMulticast()) {
|
|
336
|
-
const affectedNodes = this.endpoint.node.physicalNodes.filter((node) => node.getEndpoint(this.endpoint.index)?.supportsCC(this.ccId));
|
|
337
|
-
for (const node of affectedNodes) {
|
|
338
|
-
this.host.tryGetValueDB(node.id)?.setValue(currentValueValueId, value);
|
|
378
|
+
},
|
|
379
|
+
optimisticallyUpdateRelatedValues: (_supervisedAndSuccessful) => {
|
|
380
|
+
if (typeof value === "number" && value >= 0 && value <= 99) {
|
|
381
|
+
if (this.isSinglecast()) {
|
|
382
|
+
this.tryGetValueDB()?.setValue(currentValueValueId, value);
|
|
383
|
+
} else if (this.isMulticast()) {
|
|
384
|
+
const affectedNodes = this.endpoint.node.physicalNodes.filter((node) => node.getEndpoint(this.endpoint.index)?.supportsCC(this.ccId));
|
|
385
|
+
for (const node of affectedNodes) {
|
|
386
|
+
this.host.tryGetValueDB(node.id)?.setValue(currentValueValueId, value);
|
|
387
|
+
}
|
|
339
388
|
}
|
|
340
389
|
}
|
|
390
|
+
},
|
|
391
|
+
verifyChanges: () => {
|
|
392
|
+
if (this.isSinglecast()) {
|
|
393
|
+
this.schedulePoll(currentValueValueId, value, {
|
|
394
|
+
duration
|
|
395
|
+
});
|
|
396
|
+
} else {
|
|
397
|
+
}
|
|
341
398
|
}
|
|
342
|
-
}
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
399
|
+
};
|
|
400
|
+
}
|
|
401
|
+
};
|
|
402
|
+
get [import_API.POLL_VALUE]() {
|
|
403
|
+
return async function({ property, propertyKey }) {
|
|
404
|
+
switch (property) {
|
|
405
|
+
case "currentValue":
|
|
406
|
+
case "targetValue":
|
|
407
|
+
case "duration":
|
|
408
|
+
if (propertyKey == void 0) {
|
|
409
|
+
(0, import_API.throwMissingPropertyKey)(this.ccId, property);
|
|
410
|
+
} else if (typeof propertyKey !== "number") {
|
|
411
|
+
(0, import_API.throwUnsupportedPropertyKey)(this.ccId, property, propertyKey);
|
|
412
|
+
}
|
|
413
|
+
return (await this.get(propertyKey))?.[property];
|
|
414
|
+
default:
|
|
415
|
+
(0, import_API.throwUnsupportedProperty)(this.ccId, property);
|
|
350
416
|
}
|
|
351
417
|
};
|
|
352
418
|
}
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
419
|
+
async getSupported() {
|
|
420
|
+
this.assertSupportsCommand(import_Types.WindowCoveringCommand, import_Types.WindowCoveringCommand.SupportedGet);
|
|
421
|
+
const cc = new WindowCoveringCCSupportedGet({
|
|
422
|
+
nodeId: this.endpoint.nodeId,
|
|
423
|
+
endpointIndex: this.endpoint.index
|
|
424
|
+
});
|
|
425
|
+
const response = await this.host.sendCommand(cc, this.commandOptions);
|
|
426
|
+
return response?.supportedParameters;
|
|
427
|
+
}
|
|
428
|
+
async get(parameter) {
|
|
429
|
+
__assertType("parameter", "WindowCoveringParameter", __assertType__WindowCoveringParameter.bind(void 0, parameter));
|
|
430
|
+
this.assertSupportsCommand(import_Types.WindowCoveringCommand, import_Types.WindowCoveringCommand.Get);
|
|
431
|
+
const cc = new WindowCoveringCCGet({
|
|
432
|
+
nodeId: this.endpoint.nodeId,
|
|
433
|
+
endpointIndex: this.endpoint.index,
|
|
434
|
+
parameter
|
|
435
|
+
});
|
|
436
|
+
const response = await this.host.sendCommand(cc, this.commandOptions);
|
|
437
|
+
if (response) {
|
|
438
|
+
return (0, import_safe2.pick)(response, ["currentValue", "targetValue", "duration"]);
|
|
368
439
|
}
|
|
369
|
-
};
|
|
370
|
-
}
|
|
371
|
-
async getSupported() {
|
|
372
|
-
this.assertSupportsCommand(import_Types.WindowCoveringCommand, import_Types.WindowCoveringCommand.SupportedGet);
|
|
373
|
-
const cc = new WindowCoveringCCSupportedGet({
|
|
374
|
-
nodeId: this.endpoint.nodeId,
|
|
375
|
-
endpointIndex: this.endpoint.index
|
|
376
|
-
});
|
|
377
|
-
const response = await this.host.sendCommand(cc, this.commandOptions);
|
|
378
|
-
return response?.supportedParameters;
|
|
379
|
-
}
|
|
380
|
-
async get(parameter) {
|
|
381
|
-
__assertType("parameter", "WindowCoveringParameter", __assertType__WindowCoveringParameter.bind(void 0, parameter));
|
|
382
|
-
this.assertSupportsCommand(import_Types.WindowCoveringCommand, import_Types.WindowCoveringCommand.Get);
|
|
383
|
-
const cc = new WindowCoveringCCGet({
|
|
384
|
-
nodeId: this.endpoint.nodeId,
|
|
385
|
-
endpointIndex: this.endpoint.index,
|
|
386
|
-
parameter
|
|
387
|
-
});
|
|
388
|
-
const response = await this.host.sendCommand(cc, this.commandOptions);
|
|
389
|
-
if (response) {
|
|
390
|
-
return (0, import_safe2.pick)(response, ["currentValue", "targetValue", "duration"]);
|
|
391
440
|
}
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
}
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
],
|
|
433
|
-
let
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
441
|
+
async set(targetValues, duration) {
|
|
442
|
+
__assertType("targetValues", void 0, __assertType__sa__2_ea_2.bind(void 0, targetValues));
|
|
443
|
+
__assertType("duration", void 0, __assertType__optional_su__string__2_eu.bind(void 0, duration));
|
|
444
|
+
this.assertSupportsCommand(import_Types.WindowCoveringCommand, import_Types.WindowCoveringCommand.StartLevelChange);
|
|
445
|
+
const cc = new WindowCoveringCCSet({
|
|
446
|
+
nodeId: this.endpoint.nodeId,
|
|
447
|
+
endpointIndex: this.endpoint.index,
|
|
448
|
+
targetValues,
|
|
449
|
+
duration
|
|
450
|
+
});
|
|
451
|
+
return this.host.sendCommand(cc, this.commandOptions);
|
|
452
|
+
}
|
|
453
|
+
async startLevelChange(parameter, direction, duration) {
|
|
454
|
+
__assertType("parameter", "WindowCoveringParameter", __assertType__WindowCoveringParameter.bind(void 0, parameter));
|
|
455
|
+
__assertType("direction", void 0, __assertType__su__1__2_eu.bind(void 0, direction));
|
|
456
|
+
__assertType("duration", void 0, __assertType__optional_su__string__2_eu.bind(void 0, duration));
|
|
457
|
+
this.assertSupportsCommand(import_Types.WindowCoveringCommand, import_Types.WindowCoveringCommand.StartLevelChange);
|
|
458
|
+
const cc = new WindowCoveringCCStartLevelChange({
|
|
459
|
+
nodeId: this.endpoint.nodeId,
|
|
460
|
+
endpointIndex: this.endpoint.index,
|
|
461
|
+
parameter,
|
|
462
|
+
direction,
|
|
463
|
+
duration
|
|
464
|
+
});
|
|
465
|
+
return this.host.sendCommand(cc, this.commandOptions);
|
|
466
|
+
}
|
|
467
|
+
async stopLevelChange(parameter) {
|
|
468
|
+
__assertType("parameter", "WindowCoveringParameter", __assertType__WindowCoveringParameter.bind(void 0, parameter));
|
|
469
|
+
this.assertSupportsCommand(import_Types.WindowCoveringCommand, import_Types.WindowCoveringCommand.StopLevelChange);
|
|
470
|
+
const cc = new WindowCoveringCCStopLevelChange({
|
|
471
|
+
nodeId: this.endpoint.nodeId,
|
|
472
|
+
endpointIndex: this.endpoint.index,
|
|
473
|
+
parameter
|
|
474
|
+
});
|
|
475
|
+
return this.host.sendCommand(cc, this.commandOptions);
|
|
476
|
+
}
|
|
477
|
+
};
|
|
478
|
+
return WindowCoveringCCAPI2 = _classThis;
|
|
479
|
+
})();
|
|
480
|
+
let WindowCoveringCC = (() => {
|
|
481
|
+
let _classDecorators = [(0, import_CommandClassDecorators.commandClass)(import_core.CommandClasses["Window Covering"]), (0, import_CommandClassDecorators.implementedVersion)(1), (0, import_CommandClassDecorators.ccValues)(WindowCoveringCCValues)];
|
|
482
|
+
let _classDescriptor;
|
|
483
|
+
let _classExtraInitializers = [];
|
|
484
|
+
let _classThis;
|
|
485
|
+
let _classSuper = import_CommandClass.CommandClass;
|
|
486
|
+
var WindowCoveringCC2 = class extends _classSuper {
|
|
487
|
+
static {
|
|
488
|
+
_classThis = this;
|
|
489
|
+
}
|
|
490
|
+
static {
|
|
491
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
492
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
493
|
+
WindowCoveringCC2 = _classThis = _classDescriptor.value;
|
|
494
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
495
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
496
|
+
}
|
|
497
|
+
async interview(ctx) {
|
|
498
|
+
const node = this.getNode(ctx);
|
|
499
|
+
const endpoint = this.getEndpoint(ctx);
|
|
500
|
+
const api = import_API.CCAPI.create(import_core.CommandClasses["Window Covering"], ctx, endpoint).withOptions({
|
|
501
|
+
priority: import_core.MessagePriority.NodeQuery
|
|
502
|
+
});
|
|
454
503
|
ctx.logNode(node.id, {
|
|
455
504
|
endpoint: this.endpointIndex,
|
|
456
|
-
message:
|
|
457
|
-
direction: "
|
|
505
|
+
message: `Interviewing ${this.ccName}...`,
|
|
506
|
+
direction: "none"
|
|
458
507
|
});
|
|
459
|
-
|
|
460
|
-
this.
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
508
|
+
ctx.logNode(node.id, {
|
|
509
|
+
endpoint: this.endpointIndex,
|
|
510
|
+
message: "querying supported window covering parameters...",
|
|
511
|
+
direction: "outbound"
|
|
512
|
+
});
|
|
513
|
+
const supported = await api.getSupported();
|
|
514
|
+
if (supported?.length) {
|
|
515
|
+
const logMessage = `supported window covering parameters:
|
|
516
|
+
${supported.map((p) => `\xB7 ${(0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, p)}`).join("\n")}`;
|
|
517
|
+
ctx.logNode(node.id, {
|
|
518
|
+
endpoint: this.endpointIndex,
|
|
519
|
+
message: logMessage,
|
|
520
|
+
direction: "inbound"
|
|
521
|
+
});
|
|
522
|
+
for (const param of supported) {
|
|
523
|
+
this.setMetadata(ctx, WindowCoveringCCValues.currentValue(param));
|
|
524
|
+
this.setMetadata(ctx, WindowCoveringCCValues.targetValue(param));
|
|
525
|
+
this.setMetadata(ctx, WindowCoveringCCValues.duration(param));
|
|
526
|
+
this.setMetadata(ctx, WindowCoveringCCValues.levelChangeUp(param));
|
|
527
|
+
this.setMetadata(ctx, WindowCoveringCCValues.levelChangeDown(param));
|
|
528
|
+
if (param % 2 === 1) {
|
|
529
|
+
ctx.logNode(node.id, {
|
|
530
|
+
endpoint: this.endpointIndex,
|
|
531
|
+
message: `querying position for parameter ${(0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, param)}...`,
|
|
532
|
+
direction: "outbound"
|
|
533
|
+
});
|
|
534
|
+
await api.get(param);
|
|
535
|
+
}
|
|
472
536
|
}
|
|
473
537
|
}
|
|
538
|
+
this.setInterviewComplete(ctx, true);
|
|
474
539
|
}
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
return (
|
|
540
|
+
translatePropertyKey(ctx, property, propertyKey) {
|
|
541
|
+
if (typeof propertyKey === "number") {
|
|
542
|
+
return (0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, propertyKey);
|
|
543
|
+
}
|
|
544
|
+
return super.translatePropertyKey(ctx, property, propertyKey);
|
|
480
545
|
}
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
};
|
|
484
|
-
|
|
485
|
-
(0, import_CommandClassDecorators.
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
let
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
546
|
+
};
|
|
547
|
+
return WindowCoveringCC2 = _classThis;
|
|
548
|
+
})();
|
|
549
|
+
let WindowCoveringCCSupportedReport = (() => {
|
|
550
|
+
let _classDecorators = [(0, import_CommandClassDecorators.CCCommand)(import_Types.WindowCoveringCommand.SupportedReport), (0, import_CommandClassDecorators.ccValueProperty)("supportedParameters", WindowCoveringCCValues.supportedParameters)];
|
|
551
|
+
let _classDescriptor;
|
|
552
|
+
let _classExtraInitializers = [];
|
|
553
|
+
let _classThis;
|
|
554
|
+
let _classSuper = WindowCoveringCC;
|
|
555
|
+
var WindowCoveringCCSupportedReport2 = class extends _classSuper {
|
|
556
|
+
static {
|
|
557
|
+
_classThis = this;
|
|
558
|
+
}
|
|
559
|
+
static {
|
|
560
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
561
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
562
|
+
WindowCoveringCCSupportedReport2 = _classThis = _classDescriptor.value;
|
|
563
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
564
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
565
|
+
}
|
|
566
|
+
constructor(options) {
|
|
567
|
+
super(options);
|
|
568
|
+
this.supportedParameters = options.supportedParameters;
|
|
569
|
+
}
|
|
570
|
+
static from(raw, ctx) {
|
|
571
|
+
(0, import_core.validatePayload)(raw.payload.length >= 1);
|
|
572
|
+
const numBitmaskBytes = raw.payload[0] & 15;
|
|
573
|
+
(0, import_core.validatePayload)(raw.payload.length >= 1 + numBitmaskBytes);
|
|
574
|
+
const bitmask = raw.payload.subarray(1, 1 + numBitmaskBytes);
|
|
575
|
+
const supportedParameters = (0, import_core.parseBitMask)(bitmask, import_Types.WindowCoveringParameter["Outbound Left (no position)"]);
|
|
576
|
+
return new this({
|
|
577
|
+
nodeId: ctx.sourceNodeId,
|
|
578
|
+
supportedParameters
|
|
579
|
+
});
|
|
580
|
+
}
|
|
581
|
+
supportedParameters;
|
|
582
|
+
serialize(ctx) {
|
|
583
|
+
const bitmask = (0, import_core.encodeBitMask)(this.supportedParameters, void 0, import_Types.WindowCoveringParameter["Outbound Left (no position)"]).subarray(0, 15);
|
|
584
|
+
const numBitmaskBytes = bitmask.length & 15;
|
|
585
|
+
this.payload = import_safe.Bytes.concat([
|
|
586
|
+
import_safe.Bytes.from([numBitmaskBytes]),
|
|
587
|
+
bitmask.subarray(0, numBitmaskBytes)
|
|
588
|
+
]);
|
|
589
|
+
return super.serialize(ctx);
|
|
590
|
+
}
|
|
591
|
+
toLogEntry(ctx) {
|
|
592
|
+
return {
|
|
593
|
+
...super.toLogEntry(ctx),
|
|
594
|
+
message: {
|
|
595
|
+
"supported parameters": this.supportedParameters.map((p) => `
|
|
520
596
|
\xB7 ${(0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, p)}`).join("")
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
};
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
]
|
|
531
|
-
let
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
}
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
597
|
+
}
|
|
598
|
+
};
|
|
599
|
+
}
|
|
600
|
+
};
|
|
601
|
+
return WindowCoveringCCSupportedReport2 = _classThis;
|
|
602
|
+
})();
|
|
603
|
+
let WindowCoveringCCSupportedGet = (() => {
|
|
604
|
+
let _classDecorators = [(0, import_CommandClassDecorators.CCCommand)(import_Types.WindowCoveringCommand.SupportedGet), (0, import_CommandClassDecorators.expectedCCResponse)(WindowCoveringCCSupportedReport)];
|
|
605
|
+
let _classDescriptor;
|
|
606
|
+
let _classExtraInitializers = [];
|
|
607
|
+
let _classThis;
|
|
608
|
+
let _classSuper = WindowCoveringCC;
|
|
609
|
+
var WindowCoveringCCSupportedGet2 = class extends _classSuper {
|
|
610
|
+
static {
|
|
611
|
+
_classThis = this;
|
|
612
|
+
}
|
|
613
|
+
static {
|
|
614
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
615
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
616
|
+
WindowCoveringCCSupportedGet2 = _classThis = _classDescriptor.value;
|
|
617
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
618
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
619
|
+
}
|
|
620
|
+
};
|
|
621
|
+
return WindowCoveringCCSupportedGet2 = _classThis;
|
|
622
|
+
})();
|
|
623
|
+
let WindowCoveringCCReport = (() => {
|
|
624
|
+
let _classDecorators = [(0, import_CommandClassDecorators.CCCommand)(import_Types.WindowCoveringCommand.Report), (0, import_CommandClassDecorators.ccValueProperty)("currentValue", WindowCoveringCCValues.currentValue, (self) => [self.parameter]), (0, import_CommandClassDecorators.ccValueProperty)("targetValue", WindowCoveringCCValues.targetValue, (self) => [self.parameter]), (0, import_CommandClassDecorators.ccValueProperty)("duration", WindowCoveringCCValues.duration, (self) => [self.parameter])];
|
|
625
|
+
let _classDescriptor;
|
|
626
|
+
let _classExtraInitializers = [];
|
|
627
|
+
let _classThis;
|
|
628
|
+
let _classSuper = WindowCoveringCC;
|
|
629
|
+
var WindowCoveringCCReport2 = class extends _classSuper {
|
|
630
|
+
static {
|
|
631
|
+
_classThis = this;
|
|
632
|
+
}
|
|
633
|
+
static {
|
|
634
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
635
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
636
|
+
WindowCoveringCCReport2 = _classThis = _classDescriptor.value;
|
|
637
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
638
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
639
|
+
}
|
|
640
|
+
constructor(options) {
|
|
641
|
+
super(options);
|
|
642
|
+
this.parameter = options.parameter;
|
|
643
|
+
this.currentValue = options.currentValue;
|
|
644
|
+
this.targetValue = options.targetValue;
|
|
645
|
+
this.duration = options.duration;
|
|
646
|
+
}
|
|
647
|
+
static from(raw, ctx) {
|
|
648
|
+
(0, import_core.validatePayload)(raw.payload.length >= 4);
|
|
649
|
+
const parameter = raw.payload[0];
|
|
650
|
+
const currentValue = raw.payload[1];
|
|
651
|
+
const targetValue = raw.payload[2];
|
|
652
|
+
const duration = import_core.Duration.parseReport(raw.payload[3]) ?? import_core.Duration.unknown();
|
|
653
|
+
return new this({
|
|
654
|
+
nodeId: ctx.sourceNodeId,
|
|
655
|
+
parameter,
|
|
656
|
+
currentValue,
|
|
657
|
+
targetValue,
|
|
658
|
+
duration
|
|
659
|
+
});
|
|
660
|
+
}
|
|
661
|
+
parameter;
|
|
662
|
+
currentValue;
|
|
663
|
+
targetValue;
|
|
664
|
+
duration;
|
|
665
|
+
toLogEntry(ctx) {
|
|
666
|
+
return {
|
|
667
|
+
...super.toLogEntry(ctx),
|
|
668
|
+
message: {
|
|
669
|
+
parameter: (0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, this.parameter),
|
|
670
|
+
"current value": this.currentValue,
|
|
671
|
+
"target value": this.targetValue,
|
|
672
|
+
duration: this.duration.toString()
|
|
673
|
+
}
|
|
674
|
+
};
|
|
675
|
+
}
|
|
676
|
+
};
|
|
677
|
+
return WindowCoveringCCReport2 = _classThis;
|
|
678
|
+
})();
|
|
587
679
|
function testResponseForWindowCoveringGet(sent, received) {
|
|
588
680
|
return received.parameter === sent.parameter;
|
|
589
681
|
}
|
|
590
|
-
let WindowCoveringCCGet =
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
682
|
+
let WindowCoveringCCGet = (() => {
|
|
683
|
+
let _classDecorators = [(0, import_CommandClassDecorators.CCCommand)(import_Types.WindowCoveringCommand.Get), (0, import_CommandClassDecorators.expectedCCResponse)(WindowCoveringCCReport, testResponseForWindowCoveringGet)];
|
|
684
|
+
let _classDescriptor;
|
|
685
|
+
let _classExtraInitializers = [];
|
|
686
|
+
let _classThis;
|
|
687
|
+
let _classSuper = WindowCoveringCC;
|
|
688
|
+
var WindowCoveringCCGet2 = class extends _classSuper {
|
|
689
|
+
static {
|
|
690
|
+
_classThis = this;
|
|
691
|
+
}
|
|
692
|
+
static {
|
|
693
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
694
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
695
|
+
WindowCoveringCCGet2 = _classThis = _classDescriptor.value;
|
|
696
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
697
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
698
|
+
}
|
|
699
|
+
constructor(options) {
|
|
700
|
+
super(options);
|
|
701
|
+
this.parameter = options.parameter;
|
|
702
|
+
}
|
|
703
|
+
static from(raw, ctx) {
|
|
704
|
+
(0, import_core.validatePayload)(raw.payload.length >= 1);
|
|
705
|
+
const parameter = raw.payload[0];
|
|
706
|
+
return new this({
|
|
707
|
+
nodeId: ctx.sourceNodeId,
|
|
708
|
+
parameter
|
|
709
|
+
});
|
|
710
|
+
}
|
|
711
|
+
parameter;
|
|
712
|
+
serialize(ctx) {
|
|
713
|
+
this.payload = import_safe.Bytes.from([this.parameter]);
|
|
714
|
+
return super.serialize(ctx);
|
|
715
|
+
}
|
|
716
|
+
toLogEntry(ctx) {
|
|
717
|
+
return {
|
|
718
|
+
...super.toLogEntry(ctx),
|
|
719
|
+
message: {
|
|
720
|
+
parameter: (0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, this.parameter)
|
|
721
|
+
}
|
|
722
|
+
};
|
|
723
|
+
}
|
|
724
|
+
};
|
|
725
|
+
return WindowCoveringCCGet2 = _classThis;
|
|
726
|
+
})();
|
|
727
|
+
let WindowCoveringCCSet = (() => {
|
|
728
|
+
let _classDecorators = [(0, import_CommandClassDecorators.CCCommand)(import_Types.WindowCoveringCommand.Set), (0, import_CommandClassDecorators.useSupervision)()];
|
|
729
|
+
let _classDescriptor;
|
|
730
|
+
let _classExtraInitializers = [];
|
|
731
|
+
let _classThis;
|
|
732
|
+
let _classSuper = WindowCoveringCC;
|
|
733
|
+
var WindowCoveringCCSet2 = class extends _classSuper {
|
|
734
|
+
static {
|
|
735
|
+
_classThis = this;
|
|
736
|
+
}
|
|
737
|
+
static {
|
|
738
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
739
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
740
|
+
WindowCoveringCCSet2 = _classThis = _classDescriptor.value;
|
|
741
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
742
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
743
|
+
}
|
|
744
|
+
constructor(options) {
|
|
745
|
+
super(options);
|
|
746
|
+
this.targetValues = options.targetValues;
|
|
747
|
+
this.duration = import_core.Duration.from(options.duration);
|
|
748
|
+
}
|
|
749
|
+
static from(raw, ctx) {
|
|
750
|
+
(0, import_core.validatePayload)(raw.payload.length >= 1);
|
|
751
|
+
const numEntries = raw.payload[0] & 31;
|
|
752
|
+
(0, import_core.validatePayload)(raw.payload.length >= 1 + numEntries * 2);
|
|
753
|
+
const targetValues = [];
|
|
754
|
+
for (let i = 0; i < numEntries; i++) {
|
|
755
|
+
const offset = 1 + i * 2;
|
|
756
|
+
targetValues.push({
|
|
757
|
+
parameter: raw.payload[offset],
|
|
758
|
+
value: raw.payload[offset + 1]
|
|
759
|
+
});
|
|
613
760
|
}
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
constructor(options) {
|
|
623
|
-
super(options);
|
|
624
|
-
this.targetValues = options.targetValues;
|
|
625
|
-
this.duration = import_core.Duration.from(options.duration);
|
|
626
|
-
}
|
|
627
|
-
static from(raw, ctx) {
|
|
628
|
-
(0, import_core.validatePayload)(raw.payload.length >= 1);
|
|
629
|
-
const numEntries = raw.payload[0] & 31;
|
|
630
|
-
(0, import_core.validatePayload)(raw.payload.length >= 1 + numEntries * 2);
|
|
631
|
-
const targetValues = [];
|
|
632
|
-
for (let i = 0; i < numEntries; i++) {
|
|
633
|
-
const offset = 1 + i * 2;
|
|
634
|
-
targetValues.push({
|
|
635
|
-
parameter: raw.payload[offset],
|
|
636
|
-
value: raw.payload[offset + 1]
|
|
761
|
+
let duration;
|
|
762
|
+
if (raw.payload.length >= 2 + numEntries * 2) {
|
|
763
|
+
duration = import_core.Duration.parseSet(raw.payload[1 + numEntries * 2]);
|
|
764
|
+
}
|
|
765
|
+
return new this({
|
|
766
|
+
nodeId: ctx.sourceNodeId,
|
|
767
|
+
targetValues,
|
|
768
|
+
duration
|
|
637
769
|
});
|
|
638
770
|
}
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
771
|
+
targetValues;
|
|
772
|
+
duration;
|
|
773
|
+
serialize(ctx) {
|
|
774
|
+
const numEntries = this.targetValues.length & 31;
|
|
775
|
+
this.payload = new import_safe.Bytes(2 + numEntries * 2);
|
|
776
|
+
this.payload[0] = numEntries;
|
|
777
|
+
for (let i = 0; i < numEntries; i++) {
|
|
778
|
+
const offset = 1 + i * 2;
|
|
779
|
+
this.payload[offset] = this.targetValues[i].parameter;
|
|
780
|
+
this.payload[offset + 1] = this.targetValues[i].value;
|
|
781
|
+
}
|
|
782
|
+
this.payload[this.payload.length - 1] = (this.duration ?? import_core.Duration.default()).serializeSet();
|
|
783
|
+
return super.serialize(ctx);
|
|
642
784
|
}
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
targetValues
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
for (let i = 0; i < numEntries; i++) {
|
|
656
|
-
const offset = 1 + i * 2;
|
|
657
|
-
this.payload[offset] = this.targetValues[i].parameter;
|
|
658
|
-
this.payload[offset + 1] = this.targetValues[i].value;
|
|
659
|
-
}
|
|
660
|
-
this.payload[this.payload.length - 1] = (this.duration ?? import_core.Duration.default()).serializeSet();
|
|
661
|
-
return super.serialize(ctx);
|
|
662
|
-
}
|
|
663
|
-
toLogEntry(ctx) {
|
|
664
|
-
const message = {};
|
|
665
|
-
for (const { parameter, value } of this.targetValues) {
|
|
666
|
-
message[(0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, parameter)] = value;
|
|
785
|
+
toLogEntry(ctx) {
|
|
786
|
+
const message = {};
|
|
787
|
+
for (const { parameter, value } of this.targetValues) {
|
|
788
|
+
message[(0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, parameter)] = value;
|
|
789
|
+
}
|
|
790
|
+
if (this.duration) {
|
|
791
|
+
message.duration = this.duration.toString();
|
|
792
|
+
}
|
|
793
|
+
return {
|
|
794
|
+
...super.toLogEntry(ctx),
|
|
795
|
+
message
|
|
796
|
+
};
|
|
667
797
|
}
|
|
668
|
-
|
|
669
|
-
|
|
798
|
+
};
|
|
799
|
+
return WindowCoveringCCSet2 = _classThis;
|
|
800
|
+
})();
|
|
801
|
+
let WindowCoveringCCStartLevelChange = (() => {
|
|
802
|
+
let _classDecorators = [(0, import_CommandClassDecorators.CCCommand)(import_Types.WindowCoveringCommand.StartLevelChange), (0, import_CommandClassDecorators.useSupervision)()];
|
|
803
|
+
let _classDescriptor;
|
|
804
|
+
let _classExtraInitializers = [];
|
|
805
|
+
let _classThis;
|
|
806
|
+
let _classSuper = WindowCoveringCC;
|
|
807
|
+
var WindowCoveringCCStartLevelChange2 = class extends _classSuper {
|
|
808
|
+
static {
|
|
809
|
+
_classThis = this;
|
|
670
810
|
}
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
WindowCoveringCCSet = WindowCoveringCCSet_1 = __decorate([
|
|
678
|
-
(0, import_CommandClassDecorators.CCCommand)(import_Types.WindowCoveringCommand.Set),
|
|
679
|
-
(0, import_CommandClassDecorators.useSupervision)()
|
|
680
|
-
], WindowCoveringCCSet);
|
|
681
|
-
let WindowCoveringCCStartLevelChange = WindowCoveringCCStartLevelChange_1 = class WindowCoveringCCStartLevelChange2 extends WindowCoveringCC {
|
|
682
|
-
constructor(options) {
|
|
683
|
-
super(options);
|
|
684
|
-
this.parameter = options.parameter;
|
|
685
|
-
this.direction = options.direction;
|
|
686
|
-
this.duration = import_core.Duration.from(options.duration);
|
|
687
|
-
}
|
|
688
|
-
static from(raw, ctx) {
|
|
689
|
-
(0, import_core.validatePayload)(raw.payload.length >= 2);
|
|
690
|
-
const direction = !!(raw.payload[0] & 64) ? "down" : "up";
|
|
691
|
-
const parameter = raw.payload[1];
|
|
692
|
-
let duration;
|
|
693
|
-
if (raw.payload.length >= 3) {
|
|
694
|
-
duration = import_core.Duration.parseSet(raw.payload[2]);
|
|
695
|
-
}
|
|
696
|
-
return new WindowCoveringCCStartLevelChange_1({
|
|
697
|
-
nodeId: ctx.sourceNodeId,
|
|
698
|
-
direction,
|
|
699
|
-
parameter,
|
|
700
|
-
duration
|
|
701
|
-
});
|
|
702
|
-
}
|
|
703
|
-
parameter;
|
|
704
|
-
direction;
|
|
705
|
-
duration;
|
|
706
|
-
serialize(ctx) {
|
|
707
|
-
this.payload = import_safe.Bytes.from([
|
|
708
|
-
this.direction === "down" ? 64 : 0,
|
|
709
|
-
this.parameter,
|
|
710
|
-
(this.duration ?? import_core.Duration.default()).serializeSet()
|
|
711
|
-
]);
|
|
712
|
-
return super.serialize(ctx);
|
|
713
|
-
}
|
|
714
|
-
toLogEntry(ctx) {
|
|
715
|
-
const message = {
|
|
716
|
-
parameter: (0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, this.parameter),
|
|
717
|
-
direction: this.direction
|
|
718
|
-
};
|
|
719
|
-
if (this.duration) {
|
|
720
|
-
message.duration = this.duration.toString();
|
|
811
|
+
static {
|
|
812
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
813
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
814
|
+
WindowCoveringCCStartLevelChange2 = _classThis = _classDescriptor.value;
|
|
815
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
816
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
721
817
|
}
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
}
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
]
|
|
732
|
-
let
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
this.parameter = options.parameter;
|
|
736
|
-
}
|
|
737
|
-
static from(raw, ctx) {
|
|
738
|
-
(0, import_core.validatePayload)(raw.payload.length >= 1);
|
|
739
|
-
const parameter = raw.payload[0];
|
|
740
|
-
return new WindowCoveringCCStopLevelChange_1({
|
|
741
|
-
nodeId: ctx.sourceNodeId,
|
|
742
|
-
parameter
|
|
743
|
-
});
|
|
744
|
-
}
|
|
745
|
-
parameter;
|
|
746
|
-
serialize(ctx) {
|
|
747
|
-
this.payload = import_safe.Bytes.from([this.parameter]);
|
|
748
|
-
return super.serialize(ctx);
|
|
749
|
-
}
|
|
750
|
-
toLogEntry(ctx) {
|
|
751
|
-
return {
|
|
752
|
-
...super.toLogEntry(ctx),
|
|
753
|
-
message: {
|
|
754
|
-
parameter: (0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, this.parameter)
|
|
818
|
+
constructor(options) {
|
|
819
|
+
super(options);
|
|
820
|
+
this.parameter = options.parameter;
|
|
821
|
+
this.direction = options.direction;
|
|
822
|
+
this.duration = import_core.Duration.from(options.duration);
|
|
823
|
+
}
|
|
824
|
+
static from(raw, ctx) {
|
|
825
|
+
(0, import_core.validatePayload)(raw.payload.length >= 2);
|
|
826
|
+
const direction = !!(raw.payload[0] & 64) ? "down" : "up";
|
|
827
|
+
const parameter = raw.payload[1];
|
|
828
|
+
let duration;
|
|
829
|
+
if (raw.payload.length >= 3) {
|
|
830
|
+
duration = import_core.Duration.parseSet(raw.payload[2]);
|
|
755
831
|
}
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
832
|
+
return new this({
|
|
833
|
+
nodeId: ctx.sourceNodeId,
|
|
834
|
+
direction,
|
|
835
|
+
parameter,
|
|
836
|
+
duration
|
|
837
|
+
});
|
|
838
|
+
}
|
|
839
|
+
parameter;
|
|
840
|
+
direction;
|
|
841
|
+
duration;
|
|
842
|
+
serialize(ctx) {
|
|
843
|
+
this.payload = import_safe.Bytes.from([
|
|
844
|
+
this.direction === "down" ? 64 : 0,
|
|
845
|
+
this.parameter,
|
|
846
|
+
(this.duration ?? import_core.Duration.default()).serializeSet()
|
|
847
|
+
]);
|
|
848
|
+
return super.serialize(ctx);
|
|
849
|
+
}
|
|
850
|
+
toLogEntry(ctx) {
|
|
851
|
+
const message = {
|
|
852
|
+
parameter: (0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, this.parameter),
|
|
853
|
+
direction: this.direction
|
|
854
|
+
};
|
|
855
|
+
if (this.duration) {
|
|
856
|
+
message.duration = this.duration.toString();
|
|
857
|
+
}
|
|
858
|
+
return {
|
|
859
|
+
...super.toLogEntry(ctx),
|
|
860
|
+
message
|
|
861
|
+
};
|
|
862
|
+
}
|
|
863
|
+
};
|
|
864
|
+
return WindowCoveringCCStartLevelChange2 = _classThis;
|
|
865
|
+
})();
|
|
866
|
+
let WindowCoveringCCStopLevelChange = (() => {
|
|
867
|
+
let _classDecorators = [(0, import_CommandClassDecorators.CCCommand)(import_Types.WindowCoveringCommand.StopLevelChange), (0, import_CommandClassDecorators.useSupervision)()];
|
|
868
|
+
let _classDescriptor;
|
|
869
|
+
let _classExtraInitializers = [];
|
|
870
|
+
let _classThis;
|
|
871
|
+
let _classSuper = WindowCoveringCC;
|
|
872
|
+
var WindowCoveringCCStopLevelChange2 = class extends _classSuper {
|
|
873
|
+
static {
|
|
874
|
+
_classThis = this;
|
|
875
|
+
}
|
|
876
|
+
static {
|
|
877
|
+
const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
|
|
878
|
+
__esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
|
|
879
|
+
WindowCoveringCCStopLevelChange2 = _classThis = _classDescriptor.value;
|
|
880
|
+
if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
|
|
881
|
+
__runInitializers(_classThis, _classExtraInitializers);
|
|
882
|
+
}
|
|
883
|
+
constructor(options) {
|
|
884
|
+
super(options);
|
|
885
|
+
this.parameter = options.parameter;
|
|
886
|
+
}
|
|
887
|
+
static from(raw, ctx) {
|
|
888
|
+
(0, import_core.validatePayload)(raw.payload.length >= 1);
|
|
889
|
+
const parameter = raw.payload[0];
|
|
890
|
+
return new this({
|
|
891
|
+
nodeId: ctx.sourceNodeId,
|
|
892
|
+
parameter
|
|
893
|
+
});
|
|
894
|
+
}
|
|
895
|
+
parameter;
|
|
896
|
+
serialize(ctx) {
|
|
897
|
+
this.payload = import_safe.Bytes.from([this.parameter]);
|
|
898
|
+
return super.serialize(ctx);
|
|
899
|
+
}
|
|
900
|
+
toLogEntry(ctx) {
|
|
901
|
+
return {
|
|
902
|
+
...super.toLogEntry(ctx),
|
|
903
|
+
message: {
|
|
904
|
+
parameter: (0, import_safe2.getEnumMemberName)(import_Types.WindowCoveringParameter, this.parameter)
|
|
905
|
+
}
|
|
906
|
+
};
|
|
907
|
+
}
|
|
908
|
+
};
|
|
909
|
+
return WindowCoveringCCStopLevelChange2 = _classThis;
|
|
910
|
+
})();
|
|
763
911
|
// Annotate the CommonJS export names for ESM import in node:
|
|
764
912
|
0 && (module.exports = {
|
|
765
913
|
WindowCoveringCC,
|