@zwave-js/cc 11.14.0 → 12.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/cc/AlarmSensorCC.js +19 -7
- package/build/cc/AlarmSensorCC.js.map +1 -1
- package/build/cc/AssociationCC.js +29 -11
- package/build/cc/AssociationCC.js.map +1 -1
- package/build/cc/AssociationGroupInfoCC.js +32 -11
- package/build/cc/AssociationGroupInfoCC.js.map +1 -1
- package/build/cc/BarrierOperatorCC.js +107 -92
- package/build/cc/BarrierOperatorCC.js.map +1 -1
- package/build/cc/BasicCC.js +63 -58
- package/build/cc/BasicCC.js.map +1 -1
- package/build/cc/BatteryCC.js +26 -7
- package/build/cc/BatteryCC.js.map +1 -1
- package/build/cc/BinarySensorCC.js +16 -6
- package/build/cc/BinarySensorCC.js.map +1 -1
- package/build/cc/BinarySwitchCC.js +56 -50
- package/build/cc/BinarySwitchCC.js.map +1 -1
- package/build/cc/CRC16CC.js +9 -5
- package/build/cc/CRC16CC.js.map +1 -1
- package/build/cc/CentralSceneCC.js +27 -10
- package/build/cc/CentralSceneCC.js.map +1 -1
- package/build/cc/ClimateControlScheduleCC.js +31 -11
- package/build/cc/ClimateControlScheduleCC.js.map +1 -1
- package/build/cc/ClockCC.js +16 -5
- package/build/cc/ClockCC.js.map +1 -1
- package/build/cc/ColorSwitchCC.js +33 -10
- package/build/cc/ColorSwitchCC.js.map +1 -1
- package/build/cc/ConfigurationCC.js +84 -24
- package/build/cc/ConfigurationCC.js.map +1 -1
- package/build/cc/DeviceResetLocallyCC.js +6 -3
- package/build/cc/DeviceResetLocallyCC.js.map +1 -1
- package/build/cc/DoorLockCC.js +63 -12
- package/build/cc/DoorLockCC.js.map +1 -1
- package/build/cc/DoorLockLoggingCC.d.ts.map +1 -1
- package/build/cc/DoorLockLoggingCC.js +17 -7
- package/build/cc/DoorLockLoggingCC.js.map +1 -1
- package/build/cc/EnergyProductionCC.d.ts.map +1 -1
- package/build/cc/EnergyProductionCC.js +13 -5
- package/build/cc/EnergyProductionCC.js.map +1 -1
- package/build/cc/EntryControlCC.d.ts.map +1 -1
- package/build/cc/EntryControlCC.js +39 -14
- package/build/cc/EntryControlCC.js.map +1 -1
- package/build/cc/FirmwareUpdateMetaDataCC.js +69 -14
- package/build/cc/FirmwareUpdateMetaDataCC.js.map +1 -1
- package/build/cc/HailCC.js +2 -1
- package/build/cc/HailCC.js.map +1 -1
- package/build/cc/HumidityControlModeCC.js +17 -7
- package/build/cc/HumidityControlModeCC.js.map +1 -1
- package/build/cc/HumidityControlOperatingStateCC.js +9 -4
- package/build/cc/HumidityControlOperatingStateCC.js.map +1 -1
- package/build/cc/HumidityControlSetpointCC.js +41 -14
- package/build/cc/HumidityControlSetpointCC.js.map +1 -1
- package/build/cc/InclusionControllerCC.js +12 -4
- package/build/cc/InclusionControllerCC.js.map +1 -1
- package/build/cc/IndicatorCC.js +32 -11
- package/build/cc/IndicatorCC.js.map +1 -1
- package/build/cc/IrrigationCC.js +112 -27
- package/build/cc/IrrigationCC.js.map +1 -1
- package/build/cc/LanguageCC.js +14 -5
- package/build/cc/LanguageCC.js.map +1 -1
- package/build/cc/LockCC.js +12 -5
- package/build/cc/LockCC.js.map +1 -1
- package/build/cc/ManufacturerProprietaryCC.js +12 -3
- package/build/cc/ManufacturerProprietaryCC.js.map +1 -1
- package/build/cc/ManufacturerSpecificCC.js +19 -7
- package/build/cc/ManufacturerSpecificCC.js.map +1 -1
- package/build/cc/MeterCC.js +31 -10
- package/build/cc/MeterCC.js.map +1 -1
- package/build/cc/MultiChannelAssociationCC.js +30 -9
- package/build/cc/MultiChannelAssociationCC.js.map +1 -1
- package/build/cc/MultiChannelCC.d.ts.map +1 -1
- package/build/cc/MultiChannelCC.js +61 -22
- package/build/cc/MultiChannelCC.js.map +1 -1
- package/build/cc/MultiCommandCC.js +8 -4
- package/build/cc/MultiCommandCC.js.map +1 -1
- package/build/cc/MultilevelSensorCC.d.ts.map +1 -1
- package/build/cc/MultilevelSensorCC.js +27 -9
- package/build/cc/MultilevelSensorCC.js.map +1 -1
- package/build/cc/MultilevelSwitchCC.js +111 -95
- package/build/cc/MultilevelSwitchCC.js.map +1 -1
- package/build/cc/NoOperationCC.js +4 -2
- package/build/cc/NoOperationCC.js.map +1 -1
- package/build/cc/NodeNamingCC.js +22 -10
- package/build/cc/NodeNamingCC.js.map +1 -1
- package/build/cc/NotificationCC.d.ts.map +1 -1
- package/build/cc/NotificationCC.js +43 -13
- package/build/cc/NotificationCC.js.map +1 -1
- package/build/cc/PowerlevelCC.js +26 -8
- package/build/cc/PowerlevelCC.js.map +1 -1
- package/build/cc/ProtectionCC.js +41 -16
- package/build/cc/ProtectionCC.js.map +1 -1
- package/build/cc/SceneActivationCC.js +8 -3
- package/build/cc/SceneActivationCC.js.map +1 -1
- package/build/cc/SceneActuatorConfigurationCC.js +17 -5
- package/build/cc/SceneActuatorConfigurationCC.js.map +1 -1
- package/build/cc/SceneControllerConfigurationCC.js +17 -5
- package/build/cc/SceneControllerConfigurationCC.js.map +1 -1
- package/build/cc/ScheduleEntryLockCC.js +109 -20
- package/build/cc/ScheduleEntryLockCC.js.map +1 -1
- package/build/cc/Security2CC.js +84 -32
- package/build/cc/Security2CC.js.map +1 -1
- package/build/cc/SecurityCC.js +47 -21
- package/build/cc/SecurityCC.js.map +1 -1
- package/build/cc/SoundSwitchCC.d.ts.map +1 -1
- package/build/cc/SoundSwitchCC.js +38 -13
- package/build/cc/SoundSwitchCC.js.map +1 -1
- package/build/cc/SupervisionCC.js +18 -6
- package/build/cc/SupervisionCC.js.map +1 -1
- package/build/cc/ThermostatFanModeCC.js +19 -7
- package/build/cc/ThermostatFanModeCC.js.map +1 -1
- package/build/cc/ThermostatFanStateCC.js +9 -4
- package/build/cc/ThermostatFanStateCC.js.map +1 -1
- package/build/cc/ThermostatModeCC.js +22 -10
- package/build/cc/ThermostatModeCC.js.map +1 -1
- package/build/cc/ThermostatOperatingStateCC.js +9 -4
- package/build/cc/ThermostatOperatingStateCC.js.map +1 -1
- package/build/cc/ThermostatSetbackCC.js +15 -5
- package/build/cc/ThermostatSetbackCC.js.map +1 -1
- package/build/cc/ThermostatSetpointCC.d.ts.map +1 -1
- package/build/cc/ThermostatSetpointCC.js +36 -13
- package/build/cc/ThermostatSetpointCC.js.map +1 -1
- package/build/cc/TimeCC.js +32 -9
- package/build/cc/TimeCC.js.map +1 -1
- package/build/cc/TimeParametersCC.js +13 -5
- package/build/cc/TimeParametersCC.js.map +1 -1
- package/build/cc/TransportServiceCC.js +37 -15
- package/build/cc/TransportServiceCC.js.map +1 -1
- package/build/cc/UserCodeCC.d.ts.map +1 -1
- package/build/cc/UserCodeCC.js +77 -31
- package/build/cc/UserCodeCC.js.map +1 -1
- package/build/cc/VersionCC.js +41 -14
- package/build/cc/VersionCC.js.map +1 -1
- package/build/cc/WakeUpCC.js +27 -9
- package/build/cc/WakeUpCC.js.map +1 -1
- package/build/cc/WindowCoveringCC.js +114 -97
- package/build/cc/WindowCoveringCC.js.map +1 -1
- package/build/cc/ZWavePlusCC.js +13 -4
- package/build/cc/ZWavePlusCC.js.map +1 -1
- package/build/cc/ZWaveProtocolCC.d.ts.map +1 -1
- package/build/cc/ZWaveProtocolCC.js +173 -48
- package/build/cc/ZWaveProtocolCC.js.map +1 -1
- package/build/cc/manufacturerProprietary/FibaroCC.js +19 -7
- package/build/cc/manufacturerProprietary/FibaroCC.js.map +1 -1
- package/build/lib/API.js +10 -3
- package/build/lib/API.js.map +1 -1
- package/build/lib/CommandClass.js +28 -7
- package/build/lib/CommandClass.js.map +1 -1
- package/build/lib/Security2/Extension.js +18 -6
- package/build/lib/Security2/Extension.js.map +1 -1
- package/package.json +33 -31
|
@@ -31,13 +31,14 @@ function bitmask2DataRate(mask) {
|
|
|
31
31
|
? core_1.ZWaveDataRate["40k"]
|
|
32
32
|
: core_1.ZWaveDataRate["9k6"];
|
|
33
33
|
}
|
|
34
|
-
let ZWaveProtocolCC =
|
|
34
|
+
let ZWaveProtocolCC = class ZWaveProtocolCC extends CommandClass_1.CommandClass {
|
|
35
35
|
};
|
|
36
|
+
exports.ZWaveProtocolCC = ZWaveProtocolCC;
|
|
36
37
|
exports.ZWaveProtocolCC = ZWaveProtocolCC = __decorate([
|
|
37
38
|
(0, CommandClassDecorators_1.commandClass)(core_1.CommandClasses["Z-Wave Protocol"]),
|
|
38
39
|
(0, CommandClassDecorators_1.implementedVersion)(1)
|
|
39
40
|
], ZWaveProtocolCC);
|
|
40
|
-
let ZWaveProtocolCCNodeInformationFrame =
|
|
41
|
+
let ZWaveProtocolCCNodeInformationFrame = class ZWaveProtocolCCNodeInformationFrame extends ZWaveProtocolCC {
|
|
41
42
|
constructor(host, options) {
|
|
42
43
|
super(host, options);
|
|
43
44
|
let nif;
|
|
@@ -61,21 +62,36 @@ let ZWaveProtocolCCNodeInformationFrame = exports.ZWaveProtocolCCNodeInformation
|
|
|
61
62
|
this.supportsBeaming = nif.supportsBeaming;
|
|
62
63
|
this.supportedCCs = nif.supportedCCs;
|
|
63
64
|
}
|
|
65
|
+
basicDeviceClass;
|
|
66
|
+
genericDeviceClass;
|
|
67
|
+
specificDeviceClass;
|
|
68
|
+
isListening;
|
|
69
|
+
isFrequentListening;
|
|
70
|
+
isRouting;
|
|
71
|
+
supportedDataRates;
|
|
72
|
+
protocolVersion;
|
|
73
|
+
optionalFunctionality;
|
|
74
|
+
nodeType;
|
|
75
|
+
supportsSecurity;
|
|
76
|
+
supportsBeaming;
|
|
77
|
+
supportedCCs;
|
|
64
78
|
serialize() {
|
|
65
79
|
this.payload = (0, core_1.encodeNodeInformationFrame)(this);
|
|
66
80
|
return super.serialize();
|
|
67
81
|
}
|
|
68
82
|
};
|
|
83
|
+
exports.ZWaveProtocolCCNodeInformationFrame = ZWaveProtocolCCNodeInformationFrame;
|
|
69
84
|
exports.ZWaveProtocolCCNodeInformationFrame = ZWaveProtocolCCNodeInformationFrame = __decorate([
|
|
70
85
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.NodeInformationFrame)
|
|
71
86
|
], ZWaveProtocolCCNodeInformationFrame);
|
|
72
|
-
let ZWaveProtocolCCRequestNodeInformationFrame =
|
|
87
|
+
let ZWaveProtocolCCRequestNodeInformationFrame = class ZWaveProtocolCCRequestNodeInformationFrame extends ZWaveProtocolCC {
|
|
73
88
|
};
|
|
89
|
+
exports.ZWaveProtocolCCRequestNodeInformationFrame = ZWaveProtocolCCRequestNodeInformationFrame;
|
|
74
90
|
exports.ZWaveProtocolCCRequestNodeInformationFrame = ZWaveProtocolCCRequestNodeInformationFrame = __decorate([
|
|
75
91
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.RequestNodeInformationFrame),
|
|
76
92
|
(0, CommandClassDecorators_1.expectedCCResponse)(ZWaveProtocolCCNodeInformationFrame)
|
|
77
93
|
], ZWaveProtocolCCRequestNodeInformationFrame);
|
|
78
|
-
let ZWaveProtocolCCAssignIDs =
|
|
94
|
+
let ZWaveProtocolCCAssignIDs = class ZWaveProtocolCCAssignIDs extends ZWaveProtocolCC {
|
|
79
95
|
constructor(host, options) {
|
|
80
96
|
super(host, options);
|
|
81
97
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -88,6 +104,8 @@ let ZWaveProtocolCCAssignIDs = exports.ZWaveProtocolCCAssignIDs = class ZWavePro
|
|
|
88
104
|
this.homeId = options.homeId;
|
|
89
105
|
}
|
|
90
106
|
}
|
|
107
|
+
assignedNodeId;
|
|
108
|
+
homeId;
|
|
91
109
|
serialize() {
|
|
92
110
|
this.payload = Buffer.allocUnsafe(5);
|
|
93
111
|
this.payload[0] = this.assignedNodeId;
|
|
@@ -95,10 +113,11 @@ let ZWaveProtocolCCAssignIDs = exports.ZWaveProtocolCCAssignIDs = class ZWavePro
|
|
|
95
113
|
return super.serialize();
|
|
96
114
|
}
|
|
97
115
|
};
|
|
116
|
+
exports.ZWaveProtocolCCAssignIDs = ZWaveProtocolCCAssignIDs;
|
|
98
117
|
exports.ZWaveProtocolCCAssignIDs = ZWaveProtocolCCAssignIDs = __decorate([
|
|
99
118
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.AssignIDs)
|
|
100
119
|
], ZWaveProtocolCCAssignIDs);
|
|
101
|
-
let ZWaveProtocolCCFindNodesInRange =
|
|
120
|
+
let ZWaveProtocolCCFindNodesInRange = class ZWaveProtocolCCFindNodesInRange extends ZWaveProtocolCC {
|
|
102
121
|
constructor(host, options) {
|
|
103
122
|
super(host, options);
|
|
104
123
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -106,8 +125,8 @@ let ZWaveProtocolCCFindNodesInRange = exports.ZWaveProtocolCCFindNodesInRange =
|
|
|
106
125
|
const speedPresent = this.payload[0] & 128;
|
|
107
126
|
const bitmaskLength = this.payload[0] & 31;
|
|
108
127
|
(0, core_1.validatePayload)(this.payload.length >= 1 + bitmaskLength);
|
|
109
|
-
this.candidateNodeIds = (0, core_1.parseBitMask)(this.payload.
|
|
110
|
-
const rest = this.payload.
|
|
128
|
+
this.candidateNodeIds = (0, core_1.parseBitMask)(this.payload.subarray(1, 1 + bitmaskLength));
|
|
129
|
+
const rest = this.payload.subarray(1 + bitmaskLength);
|
|
111
130
|
if (speedPresent) {
|
|
112
131
|
(0, core_1.validatePayload)(rest.length >= 1);
|
|
113
132
|
if (rest.length === 1) {
|
|
@@ -137,6 +156,9 @@ let ZWaveProtocolCCFindNodesInRange = exports.ZWaveProtocolCCFindNodesInRange =
|
|
|
137
156
|
this.dataRate = options.dataRate ?? core_1.ZWaveDataRate["9k6"];
|
|
138
157
|
}
|
|
139
158
|
}
|
|
159
|
+
candidateNodeIds;
|
|
160
|
+
wakeUpTime;
|
|
161
|
+
dataRate;
|
|
140
162
|
serialize() {
|
|
141
163
|
const nodesBitmask = (0, core_1.encodeBitMask)(this.candidateNodeIds, core_1.MAX_NODES);
|
|
142
164
|
const speedAndLength = 128 | nodesBitmask.length;
|
|
@@ -148,17 +170,18 @@ let ZWaveProtocolCCFindNodesInRange = exports.ZWaveProtocolCCFindNodesInRange =
|
|
|
148
170
|
return super.serialize();
|
|
149
171
|
}
|
|
150
172
|
};
|
|
173
|
+
exports.ZWaveProtocolCCFindNodesInRange = ZWaveProtocolCCFindNodesInRange;
|
|
151
174
|
exports.ZWaveProtocolCCFindNodesInRange = ZWaveProtocolCCFindNodesInRange = __decorate([
|
|
152
175
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.FindNodesInRange)
|
|
153
176
|
], ZWaveProtocolCCFindNodesInRange);
|
|
154
|
-
let ZWaveProtocolCCRangeInfo =
|
|
177
|
+
let ZWaveProtocolCCRangeInfo = class ZWaveProtocolCCRangeInfo extends ZWaveProtocolCC {
|
|
155
178
|
constructor(host, options) {
|
|
156
179
|
super(host, options);
|
|
157
180
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
158
181
|
(0, core_1.validatePayload)(this.payload.length >= 1);
|
|
159
182
|
const bitmaskLength = this.payload[0] & 31;
|
|
160
183
|
(0, core_1.validatePayload)(this.payload.length >= 1 + bitmaskLength);
|
|
161
|
-
this.neighborNodeIds = (0, core_1.parseBitMask)(this.payload.
|
|
184
|
+
this.neighborNodeIds = (0, core_1.parseBitMask)(this.payload.subarray(1, 1 + bitmaskLength));
|
|
162
185
|
if (this.payload.length >= 2 + bitmaskLength) {
|
|
163
186
|
this.wakeUpTime = (0, _Types_1.parseWakeUpTime)(this.payload[1 + bitmaskLength]);
|
|
164
187
|
}
|
|
@@ -168,6 +191,8 @@ let ZWaveProtocolCCRangeInfo = exports.ZWaveProtocolCCRangeInfo = class ZWavePro
|
|
|
168
191
|
this.wakeUpTime = options.wakeUpTime;
|
|
169
192
|
}
|
|
170
193
|
}
|
|
194
|
+
neighborNodeIds;
|
|
195
|
+
wakeUpTime;
|
|
171
196
|
serialize() {
|
|
172
197
|
const nodesBitmask = (0, core_1.encodeBitMask)(this.neighborNodeIds, core_1.MAX_NODES);
|
|
173
198
|
this.payload = Buffer.concat([
|
|
@@ -180,16 +205,18 @@ let ZWaveProtocolCCRangeInfo = exports.ZWaveProtocolCCRangeInfo = class ZWavePro
|
|
|
180
205
|
return super.serialize();
|
|
181
206
|
}
|
|
182
207
|
};
|
|
208
|
+
exports.ZWaveProtocolCCRangeInfo = ZWaveProtocolCCRangeInfo;
|
|
183
209
|
exports.ZWaveProtocolCCRangeInfo = ZWaveProtocolCCRangeInfo = __decorate([
|
|
184
210
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.RangeInfo)
|
|
185
211
|
], ZWaveProtocolCCRangeInfo);
|
|
186
|
-
let ZWaveProtocolCCGetNodesInRange =
|
|
212
|
+
let ZWaveProtocolCCGetNodesInRange = class ZWaveProtocolCCGetNodesInRange extends ZWaveProtocolCC {
|
|
187
213
|
};
|
|
214
|
+
exports.ZWaveProtocolCCGetNodesInRange = ZWaveProtocolCCGetNodesInRange;
|
|
188
215
|
exports.ZWaveProtocolCCGetNodesInRange = ZWaveProtocolCCGetNodesInRange = __decorate([
|
|
189
216
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.GetNodesInRange),
|
|
190
217
|
(0, CommandClassDecorators_1.expectedCCResponse)(ZWaveProtocolCCRangeInfo)
|
|
191
218
|
], ZWaveProtocolCCGetNodesInRange);
|
|
192
|
-
let ZWaveProtocolCCCommandComplete =
|
|
219
|
+
let ZWaveProtocolCCCommandComplete = class ZWaveProtocolCCCommandComplete extends ZWaveProtocolCC {
|
|
193
220
|
constructor(host, options) {
|
|
194
221
|
super(host, options);
|
|
195
222
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -200,15 +227,17 @@ let ZWaveProtocolCCCommandComplete = exports.ZWaveProtocolCCCommandComplete = cl
|
|
|
200
227
|
this.sequenceNumber = options.sequenceNumber;
|
|
201
228
|
}
|
|
202
229
|
}
|
|
230
|
+
sequenceNumber;
|
|
203
231
|
serialize() {
|
|
204
232
|
this.payload = Buffer.from([this.sequenceNumber]);
|
|
205
233
|
return super.serialize();
|
|
206
234
|
}
|
|
207
235
|
};
|
|
236
|
+
exports.ZWaveProtocolCCCommandComplete = ZWaveProtocolCCCommandComplete;
|
|
208
237
|
exports.ZWaveProtocolCCCommandComplete = ZWaveProtocolCCCommandComplete = __decorate([
|
|
209
238
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.CommandComplete)
|
|
210
239
|
], ZWaveProtocolCCCommandComplete);
|
|
211
|
-
let ZWaveProtocolCCTransferPresentation =
|
|
240
|
+
let ZWaveProtocolCCTransferPresentation = class ZWaveProtocolCCTransferPresentation extends ZWaveProtocolCC {
|
|
212
241
|
constructor(host, options) {
|
|
213
242
|
super(host, options);
|
|
214
243
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -227,6 +256,9 @@ let ZWaveProtocolCCTransferPresentation = exports.ZWaveProtocolCCTransferPresent
|
|
|
227
256
|
this.excludeNode = options.excludeNode;
|
|
228
257
|
}
|
|
229
258
|
}
|
|
259
|
+
supportsNWI;
|
|
260
|
+
includeNode;
|
|
261
|
+
excludeNode;
|
|
230
262
|
serialize() {
|
|
231
263
|
this.payload = Buffer.from([
|
|
232
264
|
(this.supportsNWI ? 0b0001 : 0)
|
|
@@ -236,10 +268,11 @@ let ZWaveProtocolCCTransferPresentation = exports.ZWaveProtocolCCTransferPresent
|
|
|
236
268
|
return super.serialize();
|
|
237
269
|
}
|
|
238
270
|
};
|
|
271
|
+
exports.ZWaveProtocolCCTransferPresentation = ZWaveProtocolCCTransferPresentation;
|
|
239
272
|
exports.ZWaveProtocolCCTransferPresentation = ZWaveProtocolCCTransferPresentation = __decorate([
|
|
240
273
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.TransferPresentation)
|
|
241
274
|
], ZWaveProtocolCCTransferPresentation);
|
|
242
|
-
let ZWaveProtocolCCTransferNodeInformation =
|
|
275
|
+
let ZWaveProtocolCCTransferNodeInformation = class ZWaveProtocolCCTransferNodeInformation extends ZWaveProtocolCC {
|
|
243
276
|
constructor(host, options) {
|
|
244
277
|
super(host, options);
|
|
245
278
|
let info;
|
|
@@ -247,7 +280,7 @@ let ZWaveProtocolCCTransferNodeInformation = exports.ZWaveProtocolCCTransferNode
|
|
|
247
280
|
(0, core_1.validatePayload)(this.payload.length >= 2);
|
|
248
281
|
this.sequenceNumber = this.payload[0];
|
|
249
282
|
this.sourceNodeId = this.payload[1];
|
|
250
|
-
info = (0, core_1.parseNodeProtocolInfoAndDeviceClass)(this.payload.
|
|
283
|
+
info = (0, core_1.parseNodeProtocolInfoAndDeviceClass)(this.payload.subarray(2)).info;
|
|
251
284
|
}
|
|
252
285
|
else {
|
|
253
286
|
this.sequenceNumber = options.sequenceNumber;
|
|
@@ -267,6 +300,20 @@ let ZWaveProtocolCCTransferNodeInformation = exports.ZWaveProtocolCCTransferNode
|
|
|
267
300
|
this.supportsSecurity = info.supportsSecurity;
|
|
268
301
|
this.supportsBeaming = info.supportsBeaming;
|
|
269
302
|
}
|
|
303
|
+
sequenceNumber;
|
|
304
|
+
sourceNodeId;
|
|
305
|
+
basicDeviceClass;
|
|
306
|
+
genericDeviceClass;
|
|
307
|
+
specificDeviceClass;
|
|
308
|
+
isListening;
|
|
309
|
+
isFrequentListening;
|
|
310
|
+
isRouting;
|
|
311
|
+
supportedDataRates;
|
|
312
|
+
protocolVersion;
|
|
313
|
+
optionalFunctionality;
|
|
314
|
+
nodeType;
|
|
315
|
+
supportsSecurity;
|
|
316
|
+
supportsBeaming;
|
|
270
317
|
serialize() {
|
|
271
318
|
this.payload = Buffer.concat([
|
|
272
319
|
Buffer.from([this.sequenceNumber, this.sourceNodeId]),
|
|
@@ -275,10 +322,11 @@ let ZWaveProtocolCCTransferNodeInformation = exports.ZWaveProtocolCCTransferNode
|
|
|
275
322
|
return super.serialize();
|
|
276
323
|
}
|
|
277
324
|
};
|
|
325
|
+
exports.ZWaveProtocolCCTransferNodeInformation = ZWaveProtocolCCTransferNodeInformation;
|
|
278
326
|
exports.ZWaveProtocolCCTransferNodeInformation = ZWaveProtocolCCTransferNodeInformation = __decorate([
|
|
279
327
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.TransferNodeInformation)
|
|
280
328
|
], ZWaveProtocolCCTransferNodeInformation);
|
|
281
|
-
let ZWaveProtocolCCTransferRangeInformation =
|
|
329
|
+
let ZWaveProtocolCCTransferRangeInformation = class ZWaveProtocolCCTransferRangeInformation extends ZWaveProtocolCC {
|
|
282
330
|
constructor(host, options) {
|
|
283
331
|
super(host, options);
|
|
284
332
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -287,7 +335,7 @@ let ZWaveProtocolCCTransferRangeInformation = exports.ZWaveProtocolCCTransferRan
|
|
|
287
335
|
this.testedNodeId = this.payload[1];
|
|
288
336
|
const bitmaskLength = this.payload[2];
|
|
289
337
|
(0, core_1.validatePayload)(this.payload.length >= 3 + bitmaskLength);
|
|
290
|
-
this.neighborNodeIds = (0, core_1.parseBitMask)(this.payload.
|
|
338
|
+
this.neighborNodeIds = (0, core_1.parseBitMask)(this.payload.subarray(3, 3 + bitmaskLength));
|
|
291
339
|
}
|
|
292
340
|
else {
|
|
293
341
|
this.sequenceNumber = options.sequenceNumber;
|
|
@@ -295,6 +343,9 @@ let ZWaveProtocolCCTransferRangeInformation = exports.ZWaveProtocolCCTransferRan
|
|
|
295
343
|
this.neighborNodeIds = options.neighborNodeIds;
|
|
296
344
|
}
|
|
297
345
|
}
|
|
346
|
+
sequenceNumber;
|
|
347
|
+
testedNodeId;
|
|
348
|
+
neighborNodeIds;
|
|
298
349
|
serialize() {
|
|
299
350
|
const nodesBitmask = (0, core_1.encodeBitMask)(this.neighborNodeIds, core_1.MAX_NODES);
|
|
300
351
|
this.payload = Buffer.concat([
|
|
@@ -308,10 +359,11 @@ let ZWaveProtocolCCTransferRangeInformation = exports.ZWaveProtocolCCTransferRan
|
|
|
308
359
|
return super.serialize();
|
|
309
360
|
}
|
|
310
361
|
};
|
|
362
|
+
exports.ZWaveProtocolCCTransferRangeInformation = ZWaveProtocolCCTransferRangeInformation;
|
|
311
363
|
exports.ZWaveProtocolCCTransferRangeInformation = ZWaveProtocolCCTransferRangeInformation = __decorate([
|
|
312
364
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.TransferRangeInformation)
|
|
313
365
|
], ZWaveProtocolCCTransferRangeInformation);
|
|
314
|
-
let ZWaveProtocolCCTransferEnd =
|
|
366
|
+
let ZWaveProtocolCCTransferEnd = class ZWaveProtocolCCTransferEnd extends ZWaveProtocolCC {
|
|
315
367
|
constructor(host, options) {
|
|
316
368
|
super(host, options);
|
|
317
369
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -322,15 +374,17 @@ let ZWaveProtocolCCTransferEnd = exports.ZWaveProtocolCCTransferEnd = class ZWav
|
|
|
322
374
|
this.status = options.status;
|
|
323
375
|
}
|
|
324
376
|
}
|
|
377
|
+
status;
|
|
325
378
|
serialize() {
|
|
326
379
|
this.payload = Buffer.from([this.status]);
|
|
327
380
|
return super.serialize();
|
|
328
381
|
}
|
|
329
382
|
};
|
|
383
|
+
exports.ZWaveProtocolCCTransferEnd = ZWaveProtocolCCTransferEnd;
|
|
330
384
|
exports.ZWaveProtocolCCTransferEnd = ZWaveProtocolCCTransferEnd = __decorate([
|
|
331
385
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.TransferEnd)
|
|
332
386
|
], ZWaveProtocolCCTransferEnd);
|
|
333
|
-
let ZWaveProtocolCCAssignReturnRoute =
|
|
387
|
+
let ZWaveProtocolCCAssignReturnRoute = class ZWaveProtocolCCAssignReturnRoute extends ZWaveProtocolCC {
|
|
334
388
|
constructor(host, options) {
|
|
335
389
|
super(host, options);
|
|
336
390
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -338,7 +392,7 @@ let ZWaveProtocolCCAssignReturnRoute = exports.ZWaveProtocolCCAssignReturnRoute
|
|
|
338
392
|
this.destinationNodeId = this.payload[0];
|
|
339
393
|
this.routeIndex = this.payload[1] >>> 4;
|
|
340
394
|
const numRepeaters = this.payload[1] & 0b1111;
|
|
341
|
-
this.repeaters = [...this.payload.
|
|
395
|
+
this.repeaters = [...this.payload.subarray(2, 2 + numRepeaters)];
|
|
342
396
|
const speedAndWakeup = this.payload[2 + numRepeaters];
|
|
343
397
|
this.destinationSpeed = bitmask2DataRate((speedAndWakeup >>> 3) & 0b111);
|
|
344
398
|
this.destinationWakeUp = (speedAndWakeup >>> 1) & 0b11;
|
|
@@ -354,6 +408,11 @@ let ZWaveProtocolCCAssignReturnRoute = exports.ZWaveProtocolCCAssignReturnRoute
|
|
|
354
408
|
this.destinationSpeed = options.destinationSpeed;
|
|
355
409
|
}
|
|
356
410
|
}
|
|
411
|
+
destinationNodeId;
|
|
412
|
+
routeIndex;
|
|
413
|
+
repeaters;
|
|
414
|
+
destinationWakeUp;
|
|
415
|
+
destinationSpeed;
|
|
357
416
|
serialize() {
|
|
358
417
|
const routeByte = (this.routeIndex << 4) | this.repeaters.length;
|
|
359
418
|
const speedMask = dataRate2Bitmask(this.destinationSpeed);
|
|
@@ -367,17 +426,18 @@ let ZWaveProtocolCCAssignReturnRoute = exports.ZWaveProtocolCCAssignReturnRoute
|
|
|
367
426
|
return super.serialize();
|
|
368
427
|
}
|
|
369
428
|
};
|
|
429
|
+
exports.ZWaveProtocolCCAssignReturnRoute = ZWaveProtocolCCAssignReturnRoute;
|
|
370
430
|
exports.ZWaveProtocolCCAssignReturnRoute = ZWaveProtocolCCAssignReturnRoute = __decorate([
|
|
371
431
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.AssignReturnRoute)
|
|
372
432
|
], ZWaveProtocolCCAssignReturnRoute);
|
|
373
|
-
let ZWaveProtocolCCNewNodeRegistered =
|
|
433
|
+
let ZWaveProtocolCCNewNodeRegistered = class ZWaveProtocolCCNewNodeRegistered extends ZWaveProtocolCC {
|
|
374
434
|
constructor(host, options) {
|
|
375
435
|
super(host, options);
|
|
376
436
|
let nif;
|
|
377
437
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
378
438
|
(0, core_1.validatePayload)(this.payload.length >= 1);
|
|
379
439
|
this.newNodeId = this.payload[0];
|
|
380
|
-
nif = (0, core_1.parseNodeInformationFrame)(this.payload.
|
|
440
|
+
nif = (0, core_1.parseNodeInformationFrame)(this.payload.subarray(1));
|
|
381
441
|
}
|
|
382
442
|
else {
|
|
383
443
|
this.newNodeId = options.newNodeId;
|
|
@@ -397,6 +457,20 @@ let ZWaveProtocolCCNewNodeRegistered = exports.ZWaveProtocolCCNewNodeRegistered
|
|
|
397
457
|
this.supportsBeaming = nif.supportsBeaming;
|
|
398
458
|
this.supportedCCs = nif.supportedCCs;
|
|
399
459
|
}
|
|
460
|
+
newNodeId;
|
|
461
|
+
basicDeviceClass;
|
|
462
|
+
genericDeviceClass;
|
|
463
|
+
specificDeviceClass;
|
|
464
|
+
isListening;
|
|
465
|
+
isFrequentListening;
|
|
466
|
+
isRouting;
|
|
467
|
+
supportedDataRates;
|
|
468
|
+
protocolVersion;
|
|
469
|
+
optionalFunctionality;
|
|
470
|
+
nodeType;
|
|
471
|
+
supportsSecurity;
|
|
472
|
+
supportsBeaming;
|
|
473
|
+
supportedCCs;
|
|
400
474
|
serialize() {
|
|
401
475
|
this.payload = Buffer.concat([
|
|
402
476
|
Buffer.from([this.newNodeId]),
|
|
@@ -405,23 +479,28 @@ let ZWaveProtocolCCNewNodeRegistered = exports.ZWaveProtocolCCNewNodeRegistered
|
|
|
405
479
|
return super.serialize();
|
|
406
480
|
}
|
|
407
481
|
};
|
|
482
|
+
exports.ZWaveProtocolCCNewNodeRegistered = ZWaveProtocolCCNewNodeRegistered;
|
|
408
483
|
exports.ZWaveProtocolCCNewNodeRegistered = ZWaveProtocolCCNewNodeRegistered = __decorate([
|
|
409
484
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.NewNodeRegistered)
|
|
410
485
|
], ZWaveProtocolCCNewNodeRegistered);
|
|
411
|
-
let ZWaveProtocolCCNewRangeRegistered =
|
|
486
|
+
let ZWaveProtocolCCNewRangeRegistered = class ZWaveProtocolCCNewRangeRegistered extends ZWaveProtocolCC {
|
|
412
487
|
constructor(host, options) {
|
|
413
488
|
super(host, options);
|
|
414
489
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
415
490
|
(0, core_1.validatePayload)(this.payload.length >= 2);
|
|
416
491
|
this.testedNodeId = this.payload[0];
|
|
417
492
|
const numNeighbors = this.payload[1];
|
|
418
|
-
this.neighborNodeIds = [
|
|
493
|
+
this.neighborNodeIds = [
|
|
494
|
+
...this.payload.subarray(2, 2 + numNeighbors),
|
|
495
|
+
];
|
|
419
496
|
}
|
|
420
497
|
else {
|
|
421
498
|
this.testedNodeId = options.testedNodeId;
|
|
422
499
|
this.neighborNodeIds = options.neighborNodeIds;
|
|
423
500
|
}
|
|
424
501
|
}
|
|
502
|
+
testedNodeId;
|
|
503
|
+
neighborNodeIds;
|
|
425
504
|
serialize() {
|
|
426
505
|
const nodesBitmask = (0, core_1.encodeBitMask)(this.neighborNodeIds, core_1.MAX_NODES);
|
|
427
506
|
this.payload = Buffer.concat([
|
|
@@ -431,10 +510,11 @@ let ZWaveProtocolCCNewRangeRegistered = exports.ZWaveProtocolCCNewRangeRegistere
|
|
|
431
510
|
return super.serialize();
|
|
432
511
|
}
|
|
433
512
|
};
|
|
513
|
+
exports.ZWaveProtocolCCNewRangeRegistered = ZWaveProtocolCCNewRangeRegistered;
|
|
434
514
|
exports.ZWaveProtocolCCNewRangeRegistered = ZWaveProtocolCCNewRangeRegistered = __decorate([
|
|
435
515
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.NewRangeRegistered)
|
|
436
516
|
], ZWaveProtocolCCNewRangeRegistered);
|
|
437
|
-
let ZWaveProtocolCCTransferNewPrimaryControllerComplete =
|
|
517
|
+
let ZWaveProtocolCCTransferNewPrimaryControllerComplete = class ZWaveProtocolCCTransferNewPrimaryControllerComplete extends ZWaveProtocolCC {
|
|
438
518
|
constructor(host, options) {
|
|
439
519
|
super(host, options);
|
|
440
520
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -445,20 +525,23 @@ let ZWaveProtocolCCTransferNewPrimaryControllerComplete = exports.ZWaveProtocolC
|
|
|
445
525
|
this.genericDeviceClass = options.genericDeviceClass;
|
|
446
526
|
}
|
|
447
527
|
}
|
|
528
|
+
genericDeviceClass;
|
|
448
529
|
serialize() {
|
|
449
530
|
this.payload = Buffer.from([this.genericDeviceClass]);
|
|
450
531
|
return super.serialize();
|
|
451
532
|
}
|
|
452
533
|
};
|
|
534
|
+
exports.ZWaveProtocolCCTransferNewPrimaryControllerComplete = ZWaveProtocolCCTransferNewPrimaryControllerComplete;
|
|
453
535
|
exports.ZWaveProtocolCCTransferNewPrimaryControllerComplete = ZWaveProtocolCCTransferNewPrimaryControllerComplete = __decorate([
|
|
454
536
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.TransferNewPrimaryControllerComplete)
|
|
455
537
|
], ZWaveProtocolCCTransferNewPrimaryControllerComplete);
|
|
456
|
-
let ZWaveProtocolCCAutomaticControllerUpdateStart =
|
|
538
|
+
let ZWaveProtocolCCAutomaticControllerUpdateStart = class ZWaveProtocolCCAutomaticControllerUpdateStart extends ZWaveProtocolCC {
|
|
457
539
|
};
|
|
540
|
+
exports.ZWaveProtocolCCAutomaticControllerUpdateStart = ZWaveProtocolCCAutomaticControllerUpdateStart;
|
|
458
541
|
exports.ZWaveProtocolCCAutomaticControllerUpdateStart = ZWaveProtocolCCAutomaticControllerUpdateStart = __decorate([
|
|
459
542
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.AutomaticControllerUpdateStart)
|
|
460
543
|
], ZWaveProtocolCCAutomaticControllerUpdateStart);
|
|
461
|
-
let ZWaveProtocolCCSUCNodeID =
|
|
544
|
+
let ZWaveProtocolCCSUCNodeID = class ZWaveProtocolCCSUCNodeID extends ZWaveProtocolCC {
|
|
462
545
|
constructor(host, options) {
|
|
463
546
|
super(host, options);
|
|
464
547
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -472,15 +555,18 @@ let ZWaveProtocolCCSUCNodeID = exports.ZWaveProtocolCCSUCNodeID = class ZWavePro
|
|
|
472
555
|
this.isSIS = options.isSIS;
|
|
473
556
|
}
|
|
474
557
|
}
|
|
558
|
+
sucNodeId;
|
|
559
|
+
isSIS;
|
|
475
560
|
serialize() {
|
|
476
561
|
this.payload = Buffer.from([this.sucNodeId, this.isSIS ? 0b1 : 0]);
|
|
477
562
|
return super.serialize();
|
|
478
563
|
}
|
|
479
564
|
};
|
|
565
|
+
exports.ZWaveProtocolCCSUCNodeID = ZWaveProtocolCCSUCNodeID;
|
|
480
566
|
exports.ZWaveProtocolCCSUCNodeID = ZWaveProtocolCCSUCNodeID = __decorate([
|
|
481
567
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.SUCNodeID)
|
|
482
568
|
], ZWaveProtocolCCSUCNodeID);
|
|
483
|
-
let ZWaveProtocolCCSetSUC =
|
|
569
|
+
let ZWaveProtocolCCSetSUC = class ZWaveProtocolCCSetSUC extends ZWaveProtocolCC {
|
|
484
570
|
constructor(host, options) {
|
|
485
571
|
super(host, options);
|
|
486
572
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -493,15 +579,17 @@ let ZWaveProtocolCCSetSUC = exports.ZWaveProtocolCCSetSUC = class ZWaveProtocolC
|
|
|
493
579
|
this.enableSIS = options.enableSIS;
|
|
494
580
|
}
|
|
495
581
|
}
|
|
582
|
+
enableSIS;
|
|
496
583
|
serialize() {
|
|
497
584
|
this.payload = Buffer.from([0x01, this.enableSIS ? 0b1 : 0]);
|
|
498
585
|
return super.serialize();
|
|
499
586
|
}
|
|
500
587
|
};
|
|
588
|
+
exports.ZWaveProtocolCCSetSUC = ZWaveProtocolCCSetSUC;
|
|
501
589
|
exports.ZWaveProtocolCCSetSUC = ZWaveProtocolCCSetSUC = __decorate([
|
|
502
590
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.SetSUC)
|
|
503
591
|
], ZWaveProtocolCCSetSUC);
|
|
504
|
-
let ZWaveProtocolCCSetSUCAck =
|
|
592
|
+
let ZWaveProtocolCCSetSUCAck = class ZWaveProtocolCCSetSUCAck extends ZWaveProtocolCC {
|
|
505
593
|
constructor(host, options) {
|
|
506
594
|
super(host, options);
|
|
507
595
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -515,6 +603,8 @@ let ZWaveProtocolCCSetSUCAck = exports.ZWaveProtocolCCSetSUCAck = class ZWavePro
|
|
|
515
603
|
this.isSIS = options.isSIS;
|
|
516
604
|
}
|
|
517
605
|
}
|
|
606
|
+
accepted;
|
|
607
|
+
isSIS;
|
|
518
608
|
serialize() {
|
|
519
609
|
this.payload = Buffer.from([
|
|
520
610
|
this.accepted ? 0x01 : 0x00,
|
|
@@ -523,20 +613,22 @@ let ZWaveProtocolCCSetSUCAck = exports.ZWaveProtocolCCSetSUCAck = class ZWavePro
|
|
|
523
613
|
return super.serialize();
|
|
524
614
|
}
|
|
525
615
|
};
|
|
616
|
+
exports.ZWaveProtocolCCSetSUCAck = ZWaveProtocolCCSetSUCAck;
|
|
526
617
|
exports.ZWaveProtocolCCSetSUCAck = ZWaveProtocolCCSetSUCAck = __decorate([
|
|
527
618
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.SetSUCAck)
|
|
528
619
|
], ZWaveProtocolCCSetSUCAck);
|
|
529
|
-
let ZWaveProtocolCCAssignSUCReturnRoute =
|
|
620
|
+
let ZWaveProtocolCCAssignSUCReturnRoute = class ZWaveProtocolCCAssignSUCReturnRoute extends ZWaveProtocolCCAssignReturnRoute {
|
|
530
621
|
};
|
|
622
|
+
exports.ZWaveProtocolCCAssignSUCReturnRoute = ZWaveProtocolCCAssignSUCReturnRoute;
|
|
531
623
|
exports.ZWaveProtocolCCAssignSUCReturnRoute = ZWaveProtocolCCAssignSUCReturnRoute = __decorate([
|
|
532
624
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.AssignSUCReturnRoute)
|
|
533
625
|
], ZWaveProtocolCCAssignSUCReturnRoute);
|
|
534
|
-
let ZWaveProtocolCCStaticRouteRequest =
|
|
626
|
+
let ZWaveProtocolCCStaticRouteRequest = class ZWaveProtocolCCStaticRouteRequest extends ZWaveProtocolCC {
|
|
535
627
|
constructor(host, options) {
|
|
536
628
|
super(host, options);
|
|
537
629
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
538
630
|
(0, core_1.validatePayload)(this.payload.length >= 5);
|
|
539
|
-
this.nodeIds = [...this.payload.
|
|
631
|
+
this.nodeIds = [...this.payload.subarray(0, 5)].filter((id) => id > 0 && id <= core_1.MAX_NODES);
|
|
540
632
|
}
|
|
541
633
|
else {
|
|
542
634
|
if (options.nodeIds.some((n) => n < 1 || n > core_1.MAX_NODES)) {
|
|
@@ -545,6 +637,7 @@ let ZWaveProtocolCCStaticRouteRequest = exports.ZWaveProtocolCCStaticRouteReques
|
|
|
545
637
|
this.nodeIds = options.nodeIds;
|
|
546
638
|
}
|
|
547
639
|
}
|
|
640
|
+
nodeIds;
|
|
548
641
|
serialize() {
|
|
549
642
|
this.payload = Buffer.alloc(5, 0);
|
|
550
643
|
for (let i = 0; i < this.nodeIds.length && i < 5; i++) {
|
|
@@ -553,10 +646,11 @@ let ZWaveProtocolCCStaticRouteRequest = exports.ZWaveProtocolCCStaticRouteReques
|
|
|
553
646
|
return super.serialize();
|
|
554
647
|
}
|
|
555
648
|
};
|
|
649
|
+
exports.ZWaveProtocolCCStaticRouteRequest = ZWaveProtocolCCStaticRouteRequest;
|
|
556
650
|
exports.ZWaveProtocolCCStaticRouteRequest = ZWaveProtocolCCStaticRouteRequest = __decorate([
|
|
557
651
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.StaticRouteRequest)
|
|
558
652
|
], ZWaveProtocolCCStaticRouteRequest);
|
|
559
|
-
let ZWaveProtocolCCLost =
|
|
653
|
+
let ZWaveProtocolCCLost = class ZWaveProtocolCCLost extends ZWaveProtocolCC {
|
|
560
654
|
constructor(host, options) {
|
|
561
655
|
super(host, options);
|
|
562
656
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -567,15 +661,17 @@ let ZWaveProtocolCCLost = exports.ZWaveProtocolCCLost = class ZWaveProtocolCCLos
|
|
|
567
661
|
this.lostNodeId = options.lostNodeId;
|
|
568
662
|
}
|
|
569
663
|
}
|
|
664
|
+
lostNodeId;
|
|
570
665
|
serialize() {
|
|
571
666
|
this.payload = Buffer.from([this.lostNodeId]);
|
|
572
667
|
return super.serialize();
|
|
573
668
|
}
|
|
574
669
|
};
|
|
670
|
+
exports.ZWaveProtocolCCLost = ZWaveProtocolCCLost;
|
|
575
671
|
exports.ZWaveProtocolCCLost = ZWaveProtocolCCLost = __decorate([
|
|
576
672
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.Lost)
|
|
577
673
|
], ZWaveProtocolCCLost);
|
|
578
|
-
let ZWaveProtocolCCAcceptLost =
|
|
674
|
+
let ZWaveProtocolCCAcceptLost = class ZWaveProtocolCCAcceptLost extends ZWaveProtocolCC {
|
|
579
675
|
constructor(host, options) {
|
|
580
676
|
super(host, options);
|
|
581
677
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -587,15 +683,17 @@ let ZWaveProtocolCCAcceptLost = exports.ZWaveProtocolCCAcceptLost = class ZWaveP
|
|
|
587
683
|
this.accepted = options.accepted;
|
|
588
684
|
}
|
|
589
685
|
}
|
|
686
|
+
accepted;
|
|
590
687
|
serialize() {
|
|
591
688
|
this.payload = Buffer.from([this.accepted ? 0x05 : 0x04]);
|
|
592
689
|
return super.serialize();
|
|
593
690
|
}
|
|
594
691
|
};
|
|
692
|
+
exports.ZWaveProtocolCCAcceptLost = ZWaveProtocolCCAcceptLost;
|
|
595
693
|
exports.ZWaveProtocolCCAcceptLost = ZWaveProtocolCCAcceptLost = __decorate([
|
|
596
694
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.AcceptLost)
|
|
597
695
|
], ZWaveProtocolCCAcceptLost);
|
|
598
|
-
let ZWaveProtocolCCNOPPower =
|
|
696
|
+
let ZWaveProtocolCCNOPPower = class ZWaveProtocolCCNOPPower extends ZWaveProtocolCC {
|
|
599
697
|
constructor(host, options) {
|
|
600
698
|
super(host, options);
|
|
601
699
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -635,27 +733,33 @@ let ZWaveProtocolCCNOPPower = exports.ZWaveProtocolCCNOPPower = class ZWaveProto
|
|
|
635
733
|
this.powerDampening = options.powerDampening;
|
|
636
734
|
}
|
|
637
735
|
}
|
|
736
|
+
// Power dampening in (negative) dBm. A value of 2 means -2 dBm.
|
|
737
|
+
powerDampening;
|
|
638
738
|
serialize() {
|
|
639
739
|
this.payload = Buffer.from([0, this.powerDampening]);
|
|
640
740
|
return super.serialize();
|
|
641
741
|
}
|
|
642
742
|
};
|
|
743
|
+
exports.ZWaveProtocolCCNOPPower = ZWaveProtocolCCNOPPower;
|
|
643
744
|
exports.ZWaveProtocolCCNOPPower = ZWaveProtocolCCNOPPower = __decorate([
|
|
644
745
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.NOPPower)
|
|
645
746
|
], ZWaveProtocolCCNOPPower);
|
|
646
|
-
let ZWaveProtocolCCReservedIDs =
|
|
747
|
+
let ZWaveProtocolCCReservedIDs = class ZWaveProtocolCCReservedIDs extends ZWaveProtocolCC {
|
|
647
748
|
constructor(host, options) {
|
|
648
749
|
super(host, options);
|
|
649
750
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
650
751
|
(0, core_1.validatePayload)(this.payload.length >= 1);
|
|
651
752
|
const numNodeIDs = this.payload[0];
|
|
652
753
|
(0, core_1.validatePayload)(this.payload.length >= 1 + numNodeIDs);
|
|
653
|
-
this.reservedNodeIDs = [
|
|
754
|
+
this.reservedNodeIDs = [
|
|
755
|
+
...this.payload.subarray(1, 1 + numNodeIDs),
|
|
756
|
+
];
|
|
654
757
|
}
|
|
655
758
|
else {
|
|
656
759
|
this.reservedNodeIDs = options.reservedNodeIDs;
|
|
657
760
|
}
|
|
658
761
|
}
|
|
762
|
+
reservedNodeIDs;
|
|
659
763
|
serialize() {
|
|
660
764
|
this.payload = Buffer.from([
|
|
661
765
|
this.reservedNodeIDs.length,
|
|
@@ -664,10 +768,11 @@ let ZWaveProtocolCCReservedIDs = exports.ZWaveProtocolCCReservedIDs = class ZWav
|
|
|
664
768
|
return super.serialize();
|
|
665
769
|
}
|
|
666
770
|
};
|
|
771
|
+
exports.ZWaveProtocolCCReservedIDs = ZWaveProtocolCCReservedIDs;
|
|
667
772
|
exports.ZWaveProtocolCCReservedIDs = ZWaveProtocolCCReservedIDs = __decorate([
|
|
668
773
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.ReservedIDs)
|
|
669
774
|
], ZWaveProtocolCCReservedIDs);
|
|
670
|
-
let ZWaveProtocolCCReserveNodeIDs =
|
|
775
|
+
let ZWaveProtocolCCReserveNodeIDs = class ZWaveProtocolCCReserveNodeIDs extends ZWaveProtocolCC {
|
|
671
776
|
constructor(host, options) {
|
|
672
777
|
super(host, options);
|
|
673
778
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -678,16 +783,18 @@ let ZWaveProtocolCCReserveNodeIDs = exports.ZWaveProtocolCCReserveNodeIDs = clas
|
|
|
678
783
|
this.numNodeIDs = options.numNodeIDs;
|
|
679
784
|
}
|
|
680
785
|
}
|
|
786
|
+
numNodeIDs;
|
|
681
787
|
serialize() {
|
|
682
788
|
this.payload = Buffer.from([this.numNodeIDs]);
|
|
683
789
|
return super.serialize();
|
|
684
790
|
}
|
|
685
791
|
};
|
|
792
|
+
exports.ZWaveProtocolCCReserveNodeIDs = ZWaveProtocolCCReserveNodeIDs;
|
|
686
793
|
exports.ZWaveProtocolCCReserveNodeIDs = ZWaveProtocolCCReserveNodeIDs = __decorate([
|
|
687
794
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.ReserveNodeIDs),
|
|
688
795
|
(0, CommandClassDecorators_1.expectedCCResponse)(ZWaveProtocolCCReservedIDs)
|
|
689
796
|
], ZWaveProtocolCCReserveNodeIDs);
|
|
690
|
-
let ZWaveProtocolCCNodesExistReply =
|
|
797
|
+
let ZWaveProtocolCCNodesExistReply = class ZWaveProtocolCCNodesExistReply extends ZWaveProtocolCC {
|
|
691
798
|
constructor(host, options) {
|
|
692
799
|
super(host, options);
|
|
693
800
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -700,6 +807,8 @@ let ZWaveProtocolCCNodesExistReply = exports.ZWaveProtocolCCNodesExistReply = cl
|
|
|
700
807
|
this.nodeListUpdated = options.nodeListUpdated;
|
|
701
808
|
}
|
|
702
809
|
}
|
|
810
|
+
nodeMaskType;
|
|
811
|
+
nodeListUpdated;
|
|
703
812
|
serialize() {
|
|
704
813
|
this.payload = Buffer.from([
|
|
705
814
|
this.nodeMaskType,
|
|
@@ -708,13 +817,14 @@ let ZWaveProtocolCCNodesExistReply = exports.ZWaveProtocolCCNodesExistReply = cl
|
|
|
708
817
|
return super.serialize();
|
|
709
818
|
}
|
|
710
819
|
};
|
|
820
|
+
exports.ZWaveProtocolCCNodesExistReply = ZWaveProtocolCCNodesExistReply;
|
|
711
821
|
exports.ZWaveProtocolCCNodesExistReply = ZWaveProtocolCCNodesExistReply = __decorate([
|
|
712
822
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.NodesExistReply)
|
|
713
823
|
], ZWaveProtocolCCNodesExistReply);
|
|
714
824
|
function testResponseForZWaveProtocolNodesExist(sent, received) {
|
|
715
825
|
return received.nodeMaskType === sent.nodeMaskType;
|
|
716
826
|
}
|
|
717
|
-
let ZWaveProtocolCCNodesExist =
|
|
827
|
+
let ZWaveProtocolCCNodesExist = class ZWaveProtocolCCNodesExist extends ZWaveProtocolCC {
|
|
718
828
|
constructor(host, options) {
|
|
719
829
|
super(host, options);
|
|
720
830
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -722,13 +832,15 @@ let ZWaveProtocolCCNodesExist = exports.ZWaveProtocolCCNodesExist = class ZWaveP
|
|
|
722
832
|
this.nodeMaskType = this.payload[0];
|
|
723
833
|
const numNodeIDs = this.payload[1];
|
|
724
834
|
(0, core_1.validatePayload)(this.payload.length >= 2 + numNodeIDs);
|
|
725
|
-
this.nodeIDs = [...this.payload.
|
|
835
|
+
this.nodeIDs = [...this.payload.subarray(2, 2 + numNodeIDs)];
|
|
726
836
|
}
|
|
727
837
|
else {
|
|
728
838
|
this.nodeMaskType = options.nodeMaskType;
|
|
729
839
|
this.nodeIDs = options.nodeIDs;
|
|
730
840
|
}
|
|
731
841
|
}
|
|
842
|
+
nodeMaskType;
|
|
843
|
+
nodeIDs;
|
|
732
844
|
serialize() {
|
|
733
845
|
this.payload = Buffer.from([
|
|
734
846
|
this.nodeMaskType,
|
|
@@ -738,11 +850,12 @@ let ZWaveProtocolCCNodesExist = exports.ZWaveProtocolCCNodesExist = class ZWaveP
|
|
|
738
850
|
return super.serialize();
|
|
739
851
|
}
|
|
740
852
|
};
|
|
853
|
+
exports.ZWaveProtocolCCNodesExist = ZWaveProtocolCCNodesExist;
|
|
741
854
|
exports.ZWaveProtocolCCNodesExist = ZWaveProtocolCCNodesExist = __decorate([
|
|
742
855
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.NodesExist),
|
|
743
856
|
(0, CommandClassDecorators_1.expectedCCResponse)(ZWaveProtocolCCNodesExistReply, testResponseForZWaveProtocolNodesExist)
|
|
744
857
|
], ZWaveProtocolCCNodesExist);
|
|
745
|
-
let ZWaveProtocolCCSetNWIMode =
|
|
858
|
+
let ZWaveProtocolCCSetNWIMode = class ZWaveProtocolCCSetNWIMode extends ZWaveProtocolCC {
|
|
746
859
|
constructor(host, options) {
|
|
747
860
|
super(host, options);
|
|
748
861
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -755,6 +868,8 @@ let ZWaveProtocolCCSetNWIMode = exports.ZWaveProtocolCCSetNWIMode = class ZWaveP
|
|
|
755
868
|
this.timeoutMinutes = options.timeoutMinutes;
|
|
756
869
|
}
|
|
757
870
|
}
|
|
871
|
+
enabled;
|
|
872
|
+
timeoutMinutes;
|
|
758
873
|
serialize() {
|
|
759
874
|
this.payload = Buffer.from([
|
|
760
875
|
this.enabled ? 0x01 : 0x00,
|
|
@@ -763,15 +878,17 @@ let ZWaveProtocolCCSetNWIMode = exports.ZWaveProtocolCCSetNWIMode = class ZWaveP
|
|
|
763
878
|
return super.serialize();
|
|
764
879
|
}
|
|
765
880
|
};
|
|
881
|
+
exports.ZWaveProtocolCCSetNWIMode = ZWaveProtocolCCSetNWIMode;
|
|
766
882
|
exports.ZWaveProtocolCCSetNWIMode = ZWaveProtocolCCSetNWIMode = __decorate([
|
|
767
883
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.SetNWIMode)
|
|
768
884
|
], ZWaveProtocolCCSetNWIMode);
|
|
769
|
-
let ZWaveProtocolCCExcludeRequest =
|
|
885
|
+
let ZWaveProtocolCCExcludeRequest = class ZWaveProtocolCCExcludeRequest extends ZWaveProtocolCCNodeInformationFrame {
|
|
770
886
|
};
|
|
887
|
+
exports.ZWaveProtocolCCExcludeRequest = ZWaveProtocolCCExcludeRequest;
|
|
771
888
|
exports.ZWaveProtocolCCExcludeRequest = ZWaveProtocolCCExcludeRequest = __decorate([
|
|
772
889
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.ExcludeRequest)
|
|
773
890
|
], ZWaveProtocolCCExcludeRequest);
|
|
774
|
-
let ZWaveProtocolCCAssignReturnRoutePriority =
|
|
891
|
+
let ZWaveProtocolCCAssignReturnRoutePriority = class ZWaveProtocolCCAssignReturnRoutePriority extends ZWaveProtocolCC {
|
|
775
892
|
constructor(host, options) {
|
|
776
893
|
super(host, options);
|
|
777
894
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
@@ -784,25 +901,29 @@ let ZWaveProtocolCCAssignReturnRoutePriority = exports.ZWaveProtocolCCAssignRetu
|
|
|
784
901
|
this.routeNumber = options.routeNumber;
|
|
785
902
|
}
|
|
786
903
|
}
|
|
904
|
+
targetNodeId;
|
|
905
|
+
routeNumber;
|
|
787
906
|
serialize() {
|
|
788
907
|
this.payload = Buffer.from([this.targetNodeId, this.routeNumber]);
|
|
789
908
|
return super.serialize();
|
|
790
909
|
}
|
|
791
910
|
};
|
|
911
|
+
exports.ZWaveProtocolCCAssignReturnRoutePriority = ZWaveProtocolCCAssignReturnRoutePriority;
|
|
792
912
|
exports.ZWaveProtocolCCAssignReturnRoutePriority = ZWaveProtocolCCAssignReturnRoutePriority = __decorate([
|
|
793
913
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.AssignReturnRoutePriority)
|
|
794
914
|
], ZWaveProtocolCCAssignReturnRoutePriority);
|
|
795
|
-
let ZWaveProtocolCCAssignSUCReturnRoutePriority =
|
|
915
|
+
let ZWaveProtocolCCAssignSUCReturnRoutePriority = class ZWaveProtocolCCAssignSUCReturnRoutePriority extends ZWaveProtocolCCAssignReturnRoutePriority {
|
|
796
916
|
};
|
|
917
|
+
exports.ZWaveProtocolCCAssignSUCReturnRoutePriority = ZWaveProtocolCCAssignSUCReturnRoutePriority;
|
|
797
918
|
exports.ZWaveProtocolCCAssignSUCReturnRoutePriority = ZWaveProtocolCCAssignSUCReturnRoutePriority = __decorate([
|
|
798
919
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.AssignSUCReturnRoutePriority)
|
|
799
920
|
], ZWaveProtocolCCAssignSUCReturnRoutePriority);
|
|
800
|
-
let ZWaveProtocolCCSmartStartIncludedNodeInformation =
|
|
921
|
+
let ZWaveProtocolCCSmartStartIncludedNodeInformation = class ZWaveProtocolCCSmartStartIncludedNodeInformation extends ZWaveProtocolCC {
|
|
801
922
|
constructor(host, options) {
|
|
802
923
|
super(host, options);
|
|
803
924
|
if ((0, CommandClass_1.gotDeserializationOptions)(options)) {
|
|
804
925
|
(0, core_1.validatePayload)(this.payload.length >= 4);
|
|
805
|
-
this.nwiHomeId = this.payload.
|
|
926
|
+
this.nwiHomeId = this.payload.subarray(0, 4);
|
|
806
927
|
}
|
|
807
928
|
else {
|
|
808
929
|
if (options.nwiHomeId.length !== 4) {
|
|
@@ -811,21 +932,25 @@ let ZWaveProtocolCCSmartStartIncludedNodeInformation = exports.ZWaveProtocolCCSm
|
|
|
811
932
|
this.nwiHomeId = options.nwiHomeId;
|
|
812
933
|
}
|
|
813
934
|
}
|
|
935
|
+
nwiHomeId;
|
|
814
936
|
serialize() {
|
|
815
937
|
this.payload = Buffer.from(this.nwiHomeId);
|
|
816
938
|
return super.serialize();
|
|
817
939
|
}
|
|
818
940
|
};
|
|
941
|
+
exports.ZWaveProtocolCCSmartStartIncludedNodeInformation = ZWaveProtocolCCSmartStartIncludedNodeInformation;
|
|
819
942
|
exports.ZWaveProtocolCCSmartStartIncludedNodeInformation = ZWaveProtocolCCSmartStartIncludedNodeInformation = __decorate([
|
|
820
943
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.SmartStartIncludedNodeInformation)
|
|
821
944
|
], ZWaveProtocolCCSmartStartIncludedNodeInformation);
|
|
822
|
-
let ZWaveProtocolCCSmartStartPrime =
|
|
945
|
+
let ZWaveProtocolCCSmartStartPrime = class ZWaveProtocolCCSmartStartPrime extends ZWaveProtocolCCNodeInformationFrame {
|
|
823
946
|
};
|
|
947
|
+
exports.ZWaveProtocolCCSmartStartPrime = ZWaveProtocolCCSmartStartPrime;
|
|
824
948
|
exports.ZWaveProtocolCCSmartStartPrime = ZWaveProtocolCCSmartStartPrime = __decorate([
|
|
825
949
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.SmartStartPrime)
|
|
826
950
|
], ZWaveProtocolCCSmartStartPrime);
|
|
827
|
-
let ZWaveProtocolCCSmartStartInclusionRequest =
|
|
951
|
+
let ZWaveProtocolCCSmartStartInclusionRequest = class ZWaveProtocolCCSmartStartInclusionRequest extends ZWaveProtocolCCNodeInformationFrame {
|
|
828
952
|
};
|
|
953
|
+
exports.ZWaveProtocolCCSmartStartInclusionRequest = ZWaveProtocolCCSmartStartInclusionRequest;
|
|
829
954
|
exports.ZWaveProtocolCCSmartStartInclusionRequest = ZWaveProtocolCCSmartStartInclusionRequest = __decorate([
|
|
830
955
|
(0, CommandClassDecorators_1.CCCommand)(_Types_1.ZWaveProtocolCommand.SmartStartInclusionRequest)
|
|
831
956
|
], ZWaveProtocolCCSmartStartInclusionRequest);
|