@willieee802/zigbee-herdsman 0.15.0 → 0.15.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.
Files changed (345) hide show
  1. package/dist/adapter/adapter.d.ts +61 -61
  2. package/dist/adapter/adapter.d.ts.map +1 -1
  3. package/dist/adapter/adapter.js +146 -100
  4. package/dist/adapter/adapter.js.map +1 -1
  5. package/dist/adapter/deconz/adapter/deconzAdapter.d.ts +68 -68
  6. package/dist/adapter/deconz/adapter/deconzAdapter.d.ts.map +1 -1
  7. package/dist/adapter/deconz/adapter/deconzAdapter.js +1060 -1063
  8. package/dist/adapter/deconz/adapter/deconzAdapter.js.map +1 -1
  9. package/dist/adapter/deconz/adapter/index.d.ts +2 -2
  10. package/dist/adapter/deconz/adapter/index.js +10 -10
  11. package/dist/adapter/deconz/driver/constants.d.ts +104 -104
  12. package/dist/adapter/deconz/driver/constants.js +55 -55
  13. package/dist/adapter/deconz/driver/driver.d.ts +81 -81
  14. package/dist/adapter/deconz/driver/driver.js +732 -732
  15. package/dist/adapter/deconz/driver/frame.d.ts +6 -6
  16. package/dist/adapter/deconz/driver/frame.js +13 -13
  17. package/dist/adapter/deconz/driver/frameParser.d.ts +2 -2
  18. package/dist/adapter/deconz/driver/frameParser.js +443 -443
  19. package/dist/adapter/deconz/driver/parser.d.ts +12 -12
  20. package/dist/adapter/deconz/driver/parser.js +61 -61
  21. package/dist/adapter/deconz/driver/writer.d.ts +8 -8
  22. package/dist/adapter/deconz/driver/writer.js +44 -44
  23. package/dist/adapter/events.d.ts +47 -47
  24. package/dist/adapter/events.js +14 -14
  25. package/dist/adapter/ezsp/adapter/backup.d.ts +9 -9
  26. package/dist/adapter/ezsp/adapter/backup.js +53 -53
  27. package/dist/adapter/ezsp/adapter/ezspAdapter.d.ts +59 -59
  28. package/dist/adapter/ezsp/adapter/ezspAdapter.js +585 -585
  29. package/dist/adapter/ezsp/adapter/index.d.ts +2 -2
  30. package/dist/adapter/ezsp/adapter/index.js +10 -10
  31. package/dist/adapter/ezsp/driver/commands.d.ts +36 -34
  32. package/dist/adapter/ezsp/driver/commands.d.ts.map +1 -1
  33. package/dist/adapter/ezsp/driver/commands.js +2359 -2357
  34. package/dist/adapter/ezsp/driver/commands.js.map +1 -1
  35. package/dist/adapter/ezsp/driver/consts.d.ts +10 -10
  36. package/dist/adapter/ezsp/driver/consts.js +13 -13
  37. package/dist/adapter/ezsp/driver/driver.d.ts +103 -103
  38. package/dist/adapter/ezsp/driver/driver.js +639 -639
  39. package/dist/adapter/ezsp/driver/driver.js.map +1 -1
  40. package/dist/adapter/ezsp/driver/ezsp.d.ts +96 -96
  41. package/dist/adapter/ezsp/driver/ezsp.d.ts.map +1 -1
  42. package/dist/adapter/ezsp/driver/ezsp.js +586 -577
  43. package/dist/adapter/ezsp/driver/ezsp.js.map +1 -1
  44. package/dist/adapter/ezsp/driver/index.d.ts +3 -3
  45. package/dist/adapter/ezsp/driver/index.js +8 -8
  46. package/dist/adapter/ezsp/driver/multicast.d.ts +12 -12
  47. package/dist/adapter/ezsp/driver/multicast.js +74 -74
  48. package/dist/adapter/ezsp/driver/parser.d.ts +12 -12
  49. package/dist/adapter/ezsp/driver/parser.js +111 -111
  50. package/dist/adapter/ezsp/driver/types/basic.d.ts +62 -62
  51. package/dist/adapter/ezsp/driver/types/basic.js +208 -208
  52. package/dist/adapter/ezsp/driver/types/basic.js.map +1 -1
  53. package/dist/adapter/ezsp/driver/types/index.d.ts +9 -9
  54. package/dist/adapter/ezsp/driver/types/index.js +133 -133
  55. package/dist/adapter/ezsp/driver/types/named.d.ts +697 -697
  56. package/dist/adapter/ezsp/driver/types/named.js +1726 -1726
  57. package/dist/adapter/ezsp/driver/types/named.js.map +1 -1
  58. package/dist/adapter/ezsp/driver/types/struct.d.ts +251 -251
  59. package/dist/adapter/ezsp/driver/types/struct.js +708 -708
  60. package/dist/adapter/ezsp/driver/types/struct.js.map +1 -1
  61. package/dist/adapter/ezsp/driver/uart.d.ts +44 -44
  62. package/dist/adapter/ezsp/driver/uart.d.ts.map +1 -1
  63. package/dist/adapter/ezsp/driver/uart.js +368 -366
  64. package/dist/adapter/ezsp/driver/uart.js.map +1 -1
  65. package/dist/adapter/ezsp/driver/utils/crc16ccitt.d.ts +2 -2
  66. package/dist/adapter/ezsp/driver/utils/crc16ccitt.js +55 -55
  67. package/dist/adapter/ezsp/driver/utils/index.d.ts +18 -18
  68. package/dist/adapter/ezsp/driver/utils/index.js +67 -67
  69. package/dist/adapter/ezsp/driver/writer.d.ts +13 -13
  70. package/dist/adapter/ezsp/driver/writer.js +88 -88
  71. package/dist/adapter/index.d.ts +4 -4
  72. package/dist/adapter/index.js +35 -35
  73. package/dist/adapter/serialPort.d.ts +8 -8
  74. package/dist/adapter/serialPort.js +22 -22
  75. package/dist/adapter/serialPort.js.map +1 -1
  76. package/dist/adapter/serialPortUtils.d.ts +12 -12
  77. package/dist/adapter/serialPortUtils.js +18 -18
  78. package/dist/adapter/socketPortUtils.d.ts +10 -10
  79. package/dist/adapter/socketPortUtils.js +16 -16
  80. package/dist/adapter/tstype.d.ts +85 -85
  81. package/dist/adapter/tstype.js +2 -2
  82. package/dist/adapter/z-stack/adapter/adapter-backup.d.ts +62 -62
  83. package/dist/adapter/z-stack/adapter/adapter-backup.js +441 -441
  84. package/dist/adapter/z-stack/adapter/adapter-nv-memory.d.ts +150 -150
  85. package/dist/adapter/z-stack/adapter/adapter-nv-memory.js +258 -258
  86. package/dist/adapter/z-stack/adapter/endpoints.d.ts +11 -11
  87. package/dist/adapter/z-stack/adapter/endpoints.js +73 -73
  88. package/dist/adapter/z-stack/adapter/index.d.ts +2 -2
  89. package/dist/adapter/z-stack/adapter/index.js +8 -8
  90. package/dist/adapter/z-stack/adapter/manager.d.ts +86 -86
  91. package/dist/adapter/z-stack/adapter/manager.js +476 -476
  92. package/dist/adapter/z-stack/adapter/tstype.d.ts +6 -6
  93. package/dist/adapter/z-stack/adapter/tstype.js +10 -10
  94. package/dist/adapter/z-stack/adapter/zStackAdapter.d.ts +81 -81
  95. package/dist/adapter/z-stack/adapter/zStackAdapter.js +868 -868
  96. package/dist/adapter/z-stack/constants/af.d.ts +23 -23
  97. package/dist/adapter/z-stack/constants/af.js +27 -27
  98. package/dist/adapter/z-stack/constants/common.d.ts +278 -278
  99. package/dist/adapter/z-stack/constants/common.js +289 -289
  100. package/dist/adapter/z-stack/constants/dbg.d.ts +22 -22
  101. package/dist/adapter/z-stack/constants/dbg.js +24 -24
  102. package/dist/adapter/z-stack/constants/index.d.ts +10 -10
  103. package/dist/adapter/z-stack/constants/index.js +47 -47
  104. package/dist/adapter/z-stack/constants/mac.d.ts +127 -127
  105. package/dist/adapter/z-stack/constants/mac.js +129 -129
  106. package/dist/adapter/z-stack/constants/sapi.d.ts +24 -24
  107. package/dist/adapter/z-stack/constants/sapi.js +26 -26
  108. package/dist/adapter/z-stack/constants/sys.d.ts +71 -71
  109. package/dist/adapter/z-stack/constants/sys.js +73 -73
  110. package/dist/adapter/z-stack/constants/util.d.ts +81 -81
  111. package/dist/adapter/z-stack/constants/util.js +83 -83
  112. package/dist/adapter/z-stack/constants/utils.d.ts +4 -4
  113. package/dist/adapter/z-stack/constants/utils.js +14 -14
  114. package/dist/adapter/z-stack/constants/zdo.d.ts +102 -102
  115. package/dist/adapter/z-stack/constants/zdo.js +104 -104
  116. package/dist/adapter/z-stack/models/index.d.ts +1 -1
  117. package/dist/adapter/z-stack/models/index.js +17 -17
  118. package/dist/adapter/z-stack/models/startup-options.d.ts +12 -12
  119. package/dist/adapter/z-stack/models/startup-options.js +2 -2
  120. package/dist/adapter/z-stack/structs/entries/address-manager-entry.d.ts +23 -23
  121. package/dist/adapter/z-stack/structs/entries/address-manager-entry.js +45 -45
  122. package/dist/adapter/z-stack/structs/entries/address-manager-table.d.ts +10 -10
  123. package/dist/adapter/z-stack/structs/entries/address-manager-table.js +22 -22
  124. package/dist/adapter/z-stack/structs/entries/aps-link-key-data-entry.d.ts +10 -10
  125. package/dist/adapter/z-stack/structs/entries/aps-link-key-data-entry.js +21 -21
  126. package/dist/adapter/z-stack/structs/entries/aps-link-key-data-table.d.ts +10 -10
  127. package/dist/adapter/z-stack/structs/entries/aps-link-key-data-table.js +23 -23
  128. package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-entry.d.ts +10 -10
  129. package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-entry.js +24 -24
  130. package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-table.d.ts +10 -10
  131. package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-table.js +23 -23
  132. package/dist/adapter/z-stack/structs/entries/channel-list.d.ts +8 -8
  133. package/dist/adapter/z-stack/structs/entries/channel-list.js +15 -15
  134. package/dist/adapter/z-stack/structs/entries/has-configured.d.ts +8 -8
  135. package/dist/adapter/z-stack/structs/entries/has-configured.js +16 -16
  136. package/dist/adapter/z-stack/structs/entries/index.d.ts +16 -16
  137. package/dist/adapter/z-stack/structs/entries/index.js +32 -32
  138. package/dist/adapter/z-stack/structs/entries/nib.d.ts +10 -10
  139. package/dist/adapter/z-stack/structs/entries/nib.js +68 -68
  140. package/dist/adapter/z-stack/structs/entries/nwk-key-descriptor.d.ts +10 -10
  141. package/dist/adapter/z-stack/structs/entries/nwk-key-descriptor.js +18 -18
  142. package/dist/adapter/z-stack/structs/entries/nwk-key.d.ts +8 -8
  143. package/dist/adapter/z-stack/structs/entries/nwk-key.js +15 -15
  144. package/dist/adapter/z-stack/structs/entries/nwk-pan-id.d.ts +8 -8
  145. package/dist/adapter/z-stack/structs/entries/nwk-pan-id.js +15 -15
  146. package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-entry.d.ts +13 -13
  147. package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-entry.js +23 -23
  148. package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-table.d.ts +10 -10
  149. package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-table.js +22 -22
  150. package/dist/adapter/z-stack/structs/entries/security-manager-entry.d.ts +20 -20
  151. package/dist/adapter/z-stack/structs/entries/security-manager-entry.js +36 -36
  152. package/dist/adapter/z-stack/structs/entries/security-manager-table.d.ts +10 -10
  153. package/dist/adapter/z-stack/structs/entries/security-manager-table.js +24 -24
  154. package/dist/adapter/z-stack/structs/index.d.ts +4 -4
  155. package/dist/adapter/z-stack/structs/index.js +20 -20
  156. package/dist/adapter/z-stack/structs/serializable-memory-object.d.ts +13 -13
  157. package/dist/adapter/z-stack/structs/serializable-memory-object.js +2 -2
  158. package/dist/adapter/z-stack/structs/struct.d.ts +99 -99
  159. package/dist/adapter/z-stack/structs/struct.js +295 -295
  160. package/dist/adapter/z-stack/structs/table.d.ts +94 -94
  161. package/dist/adapter/z-stack/structs/table.js +161 -161
  162. package/dist/adapter/z-stack/unpi/constants.d.ts +28 -28
  163. package/dist/adapter/z-stack/unpi/constants.js +41 -41
  164. package/dist/adapter/z-stack/unpi/frame.d.ts +16 -16
  165. package/dist/adapter/z-stack/unpi/frame.js +48 -48
  166. package/dist/adapter/z-stack/unpi/index.d.ts +5 -5
  167. package/dist/adapter/z-stack/unpi/index.js +37 -37
  168. package/dist/adapter/z-stack/unpi/parser.d.ts +10 -10
  169. package/dist/adapter/z-stack/unpi/parser.js +74 -74
  170. package/dist/adapter/z-stack/unpi/writer.d.ts +10 -10
  171. package/dist/adapter/z-stack/unpi/writer.js +44 -44
  172. package/dist/adapter/z-stack/utils/channel-list.d.ts +20 -20
  173. package/dist/adapter/z-stack/utils/channel-list.js +40 -40
  174. package/dist/adapter/z-stack/utils/index.d.ts +2 -2
  175. package/dist/adapter/z-stack/utils/index.js +18 -18
  176. package/dist/adapter/z-stack/utils/network-options.d.ts +8 -8
  177. package/dist/adapter/z-stack/utils/network-options.js +22 -22
  178. package/dist/adapter/z-stack/znp/buffaloZnp.d.ts +11 -11
  179. package/dist/adapter/z-stack/znp/buffaloZnp.js +113 -113
  180. package/dist/adapter/z-stack/znp/definition.d.ts +5 -5
  181. package/dist/adapter/z-stack/znp/definition.js +3050 -3050
  182. package/dist/adapter/z-stack/znp/index.d.ts +3 -3
  183. package/dist/adapter/z-stack/znp/index.js +10 -10
  184. package/dist/adapter/z-stack/znp/parameterType.d.ts +22 -22
  185. package/dist/adapter/z-stack/znp/parameterType.js +25 -25
  186. package/dist/adapter/z-stack/znp/tstype.d.ts +21 -21
  187. package/dist/adapter/z-stack/znp/tstype.js +2 -2
  188. package/dist/adapter/z-stack/znp/znp.d.ts +43 -43
  189. package/dist/adapter/z-stack/znp/znp.js +325 -325
  190. package/dist/adapter/z-stack/znp/zpiObject.d.ts +19 -19
  191. package/dist/adapter/z-stack/znp/zpiObject.js +96 -96
  192. package/dist/adapter/zigate/adapter/index.d.ts +2 -2
  193. package/dist/adapter/zigate/adapter/index.js +10 -10
  194. package/dist/adapter/zigate/adapter/zigateAdapter.d.ts +69 -69
  195. package/dist/adapter/zigate/adapter/zigateAdapter.js +678 -678
  196. package/dist/adapter/zigate/debug.d.ts +7 -7
  197. package/dist/adapter/zigate/debug.js +22 -22
  198. package/dist/adapter/zigate/driver/buffaloZiGate.d.ts +18 -18
  199. package/dist/adapter/zigate/driver/buffaloZiGate.js +139 -139
  200. package/dist/adapter/zigate/driver/commandType.d.ts +41 -41
  201. package/dist/adapter/zigate/driver/commandType.js +385 -385
  202. package/dist/adapter/zigate/driver/constants.d.ts +276 -276
  203. package/dist/adapter/zigate/driver/constants.js +371 -371
  204. package/dist/adapter/zigate/driver/frame.d.ts +26 -26
  205. package/dist/adapter/zigate/driver/frame.js +172 -172
  206. package/dist/adapter/zigate/driver/frame.js.map +1 -1
  207. package/dist/adapter/zigate/driver/messageType.d.ts +11 -11
  208. package/dist/adapter/zigate/driver/messageType.js +278 -278
  209. package/dist/adapter/zigate/driver/parameterType.d.ts +20 -20
  210. package/dist/adapter/zigate/driver/parameterType.js +23 -23
  211. package/dist/adapter/zigate/driver/ziGateObject.d.ts +23 -23
  212. package/dist/adapter/zigate/driver/ziGateObject.js +106 -106
  213. package/dist/adapter/zigate/driver/zigate.d.ts +49 -49
  214. package/dist/adapter/zigate/driver/zigate.js +303 -303
  215. package/dist/buffalo/buffalo.d.ts +50 -48
  216. package/dist/buffalo/buffalo.d.ts.map +1 -1
  217. package/dist/buffalo/buffalo.js +322 -307
  218. package/dist/buffalo/buffalo.js.map +1 -1
  219. package/dist/buffalo/index.d.ts +3 -3
  220. package/dist/buffalo/index.js +33 -33
  221. package/dist/buffalo/tstype.d.ts +8 -8
  222. package/dist/buffalo/tstype.js +2 -2
  223. package/dist/controller/controller.d.ts +110 -110
  224. package/dist/controller/controller.js +607 -607
  225. package/dist/controller/database.d.ts +18 -18
  226. package/dist/controller/database.js +93 -93
  227. package/dist/controller/events.d.ts +55 -55
  228. package/dist/controller/events.d.ts.map +1 -1
  229. package/dist/controller/events.js +101 -99
  230. package/dist/controller/events.js.map +1 -1
  231. package/dist/controller/greenPower.d.ts +12 -12
  232. package/dist/controller/greenPower.js +220 -220
  233. package/dist/controller/helpers/index.d.ts +2 -2
  234. package/dist/controller/helpers/index.js +28 -28
  235. package/dist/controller/helpers/request.d.ts +23 -0
  236. package/dist/controller/helpers/request.d.ts.map +1 -0
  237. package/dist/controller/helpers/request.js +72 -0
  238. package/dist/controller/helpers/request.js.map +1 -0
  239. package/dist/controller/helpers/zclFrameConverter.d.ts +7 -7
  240. package/dist/controller/helpers/zclFrameConverter.js +31 -31
  241. package/dist/controller/helpers/zclTransactionSequenceNumber.d.ts +5 -5
  242. package/dist/controller/helpers/zclTransactionSequenceNumber.js +13 -13
  243. package/dist/controller/index.d.ts +5 -5
  244. package/dist/controller/index.js +8 -8
  245. package/dist/controller/logger-stub.d.ts +6 -6
  246. package/dist/controller/logger-stub.js +2 -2
  247. package/dist/controller/model/device.d.ts +132 -127
  248. package/dist/controller/model/device.d.ts.map +1 -1
  249. package/dist/controller/model/device.js +708 -681
  250. package/dist/controller/model/device.js.map +1 -1
  251. package/dist/controller/model/endpoint.d.ts +131 -128
  252. package/dist/controller/model/endpoint.d.ts.map +1 -1
  253. package/dist/controller/model/endpoint.js +817 -665
  254. package/dist/controller/model/endpoint.js.map +1 -1
  255. package/dist/controller/model/entity.d.ts +14 -14
  256. package/dist/controller/model/entity.js +26 -26
  257. package/dist/controller/model/group.d.ts +39 -39
  258. package/dist/controller/model/group.js +221 -221
  259. package/dist/controller/model/index.d.ts +5 -5
  260. package/dist/controller/model/index.js +14 -14
  261. package/dist/controller/touchlink.d.ts +19 -19
  262. package/dist/controller/touchlink.js +157 -157
  263. package/dist/controller/tstype.d.ts +21 -20
  264. package/dist/controller/tstype.d.ts.map +1 -1
  265. package/dist/controller/tstype.js +9 -9
  266. package/dist/controller/tstype.js.map +1 -1
  267. package/dist/index.d.ts +3 -3
  268. package/dist/index.js +33 -33
  269. package/dist/models/backup-storage-legacy.d.ts +26 -26
  270. package/dist/models/backup-storage-legacy.js +2 -2
  271. package/dist/models/backup-storage-unified.d.ts +49 -49
  272. package/dist/models/backup-storage-unified.js +2 -2
  273. package/dist/models/backup.d.ts +37 -37
  274. package/dist/models/backup.js +2 -2
  275. package/dist/models/index.d.ts +4 -4
  276. package/dist/models/index.js +20 -20
  277. package/dist/models/network-options.d.ts +12 -12
  278. package/dist/models/network-options.js +2 -2
  279. package/dist/utils/assertString.d.ts +2 -2
  280. package/dist/utils/assertString.js +8 -8
  281. package/dist/utils/backup.d.ts +20 -20
  282. package/dist/utils/backup.js +187 -187
  283. package/dist/utils/equalsPartial.d.ts +2 -2
  284. package/dist/utils/equalsPartial.js +11 -11
  285. package/dist/utils/index.d.ts +9 -9
  286. package/dist/utils/index.js +45 -45
  287. package/dist/utils/isNumberArray.d.ts +2 -2
  288. package/dist/utils/isNumberArray.js +6 -6
  289. package/dist/utils/queue.d.ts +11 -11
  290. package/dist/utils/queue.js +50 -50
  291. package/dist/utils/realpathSync.d.ts +2 -2
  292. package/dist/utils/realpathSync.js +12 -12
  293. package/dist/utils/wait.d.ts +2 -2
  294. package/dist/utils/wait.js +8 -8
  295. package/dist/utils/waitress.d.ts +21 -21
  296. package/dist/utils/waitress.js +61 -61
  297. package/dist/zcl/buffaloZcl.d.ts +41 -41
  298. package/dist/zcl/buffaloZcl.js +591 -591
  299. package/dist/zcl/definition/buffaloZclDataType.d.ts +17 -17
  300. package/dist/zcl/definition/buffaloZclDataType.js +20 -20
  301. package/dist/zcl/definition/cluster.d.ts +29 -29
  302. package/dist/zcl/definition/cluster.d.ts.map +1 -1
  303. package/dist/zcl/definition/cluster.js +5335 -5215
  304. package/dist/zcl/definition/cluster.js.map +1 -1
  305. package/dist/zcl/definition/dataType.d.ts +59 -59
  306. package/dist/zcl/definition/dataType.d.ts.map +1 -1
  307. package/dist/zcl/definition/dataType.js +64 -64
  308. package/dist/zcl/definition/dataType.js.map +1 -1
  309. package/dist/zcl/definition/direction.d.ts +5 -5
  310. package/dist/zcl/definition/direction.js +8 -8
  311. package/dist/zcl/definition/endpointDeviceType.d.ts +4 -4
  312. package/dist/zcl/definition/endpointDeviceType.js +15 -15
  313. package/dist/zcl/definition/foundation.d.ts +11 -11
  314. package/dist/zcl/definition/foundation.js +167 -167
  315. package/dist/zcl/definition/frameControl.d.ts +10 -10
  316. package/dist/zcl/definition/frameControl.js +2 -2
  317. package/dist/zcl/definition/frameType.d.ts +5 -5
  318. package/dist/zcl/definition/frameType.js +8 -8
  319. package/dist/zcl/definition/index.d.ts +13 -13
  320. package/dist/zcl/definition/index.js +51 -51
  321. package/dist/zcl/definition/manufacturerCode.d.ts +1074 -1074
  322. package/dist/zcl/definition/manufacturerCode.js +1079 -1079
  323. package/dist/zcl/definition/powerSource.d.ts +4 -4
  324. package/dist/zcl/definition/powerSource.js +12 -12
  325. package/dist/zcl/definition/status.d.ts +38 -38
  326. package/dist/zcl/definition/status.js +41 -41
  327. package/dist/zcl/definition/tstype.d.ts +16 -16
  328. package/dist/zcl/definition/tstype.js +2 -2
  329. package/dist/zcl/index.d.ts +15 -15
  330. package/dist/zcl/index.js +55 -55
  331. package/dist/zcl/tstype.d.ts +56 -56
  332. package/dist/zcl/tstype.js +10 -10
  333. package/dist/zcl/utils.d.ts +6 -6
  334. package/dist/zcl/utils.js +165 -165
  335. package/dist/zcl/zclFrame.d.ts +45 -45
  336. package/dist/zcl/zclFrame.js +347 -347
  337. package/dist/zcl/zclStatusError.d.ts +5 -5
  338. package/dist/zcl/zclStatusError.js +13 -13
  339. package/package.json +1 -1
  340. package/.github/ISSUE_TEMPLATE/config.yml +0 -5
  341. package/.github/dependabot.yml +0 -6
  342. package/.github/workflows/ci.yml +0 -40
  343. package/.github/workflows/release_please.yml +0 -20
  344. package/.github/workflows/stale.yml +0 -20
  345. package/.github/workflows/update_deps.yml +0 -29
@@ -1,709 +1,709 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
25
- Object.defineProperty(exports, "__esModule", { value: true });
26
- exports.EmberIeeeRawFrame = exports.EmberRawFrame = exports.EmberRoutingTable = exports.EmberRoutingTableEntry = exports.EmberNeighbors = exports.EmberNeighbor = exports.EmberMultiAddress = exports.EmberSimpleDescriptor = exports.EmberNodeDescriptor = exports.EmberGpSinkListEntry = exports.EmberGpAddress = exports.EmberRf4cePairingTableEntry = exports.EmberRf4ceApplicationInfo = exports.EmberRf4ceVendorInfo = exports.EmberTokTypeStackZllSecurity = exports.EmberTokTypeStackZllData = exports.EmberZllAddressAssignment = exports.EmberZllDeviceInfoRecord = exports.EmberZllInitialSecurityState = exports.EmberZllNetwork = exports.EmberZllSecurityAlgorithmData = exports.EmberNetworkInitStruct = exports.EmberKeyStruct = exports.EmberCurrentSecurityState = exports.EmberInitialSecurityState = exports.EmberRouteTableEntry = exports.EmberNeighborTableEntry = exports.EmberAesMmoHashContext = exports.EmberMessageDigest = exports.EmberSignature283k1Data = exports.EmberPrivateKey283k1Data = exports.EmberPublicKey283k1Data = exports.EmberCertificate283k1Data = exports.EmberSignatureData = exports.EmberSmacData = exports.EmberPrivateKeyData = exports.EmberPublicKeyData = exports.EmberCertificateData = exports.EmberKeyData = exports.EmberMulticastTableEntry = exports.EmberBindingTableEntry = exports.EmberApsFrame = exports.EmberZigbeeNetwork = exports.EmberNetworkParameters = exports.EzspStruct = void 0;
27
- /* istanbul ignore file */
28
- /* eslint-disable @typescript-eslint/explicit-module-boundary-types */
29
- const basic = __importStar(require("./basic"));
30
- const named = __importStar(require("./named"));
31
- class EzspStruct {
32
- /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
33
- static serialize(cls, obj) {
34
- /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
35
- return Buffer.concat(cls._fields.map((field) => {
36
- const value = obj[field[0]];
37
- console.assert(field[1]);
38
- return field[1].serialize(field[1], value);
39
- }));
40
- }
41
- /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
42
- static deserialize(cls, data) {
43
- const r = new cls();
44
- for (const [field_name, field_type] of cls._fields) {
45
- let v;
46
- [v, data] = field_type.deserialize(field_type, data);
47
- r[field_name] = v;
48
- }
49
- return [r, data];
50
- }
51
- toString() {
52
- return `${this.constructor.name}: ${JSON.stringify(this)}`;
53
- }
54
- }
55
- exports.EzspStruct = EzspStruct;
56
- class EmberNetworkParameters extends EzspStruct {
57
- }
58
- exports.EmberNetworkParameters = EmberNetworkParameters;
59
- EmberNetworkParameters._fields = [
60
- // The network's extended PAN identifier.
61
- ['extendedPanId', basic.fixed_list(8, basic.uint8_t)],
62
- // The network's PAN identifier.
63
- ['panId', basic.uint16_t],
64
- // A power setting, in dBm.
65
- ['radioTxPower', basic.uint8_t],
66
- // A radio channel.
67
- ['radioChannel', basic.uint8_t],
68
- // The method used to initially join the network.
69
- ['joinMethod', named.EmberJoinMethod],
70
- // NWK Manager ID. The ID of the network manager in the current network.
71
- // This may only be set at joining when using USE_NWK_COMMISSIONING as
72
- // the join method.
73
- ['nwkManagerId', named.EmberNodeId],
74
- // NWK Update ID. The value of the ZigBee nwkUpdateId known by the
75
- // stack. This is used to determine the newest instance of the network
76
- // after a PAN ID or channel change. This may only be set at joining
77
- // when using USE_NWK_COMMISSIONING as the join method.
78
- ['nwkUpdateId', basic.uint8_t],
79
- // NWK channel mask. The list of preferred channels that the NWK manager
80
- // has told this device to use when searching for the network. This may
81
- // only be set at joining when using USE_NWK_COMMISSIONING as the join
82
- // method.
83
- ['channels', basic.uint32_t],
84
- ];
85
- class EmberZigbeeNetwork extends EzspStruct {
86
- }
87
- exports.EmberZigbeeNetwork = EmberZigbeeNetwork;
88
- // The parameters of a ZigBee network.
89
- EmberZigbeeNetwork._fields = [
90
- // The 802.15.4 channel associated with the network.
91
- ['channel', basic.uint8_t],
92
- // The network's PAN identifier.
93
- ['panId', basic.uint16_t],
94
- // The network's extended PAN identifier.
95
- ['extendedPanId', basic.fixed_list(8, basic.uint8_t)],
96
- // Whether the network is allowing MAC associations.
97
- ['allowingJoin', named.Bool],
98
- // The Stack Profile associated with the network.
99
- ['stackProfile', basic.uint8_t],
100
- // The instance of the Network.
101
- ['nwkUpdateId', basic.uint8_t],
102
- ];
103
- class EmberApsFrame extends EzspStruct {
104
- }
105
- exports.EmberApsFrame = EmberApsFrame;
106
- // ZigBee APS frame parameters.
107
- EmberApsFrame._fields = [
108
- // The application profile ID that describes the format of the message.
109
- ['profileId', basic.uint16_t],
110
- // The cluster ID for this message.
111
- ['clusterId', basic.uint16_t],
112
- // The source endpoint.
113
- ['sourceEndpoint', basic.uint8_t],
114
- // The destination endpoint.
115
- ['destinationEndpoint', basic.uint8_t],
116
- // A bitmask of options.
117
- ['options', named.EmberApsOption],
118
- // The group ID for this message, if it is multicast mode.
119
- ['groupId', basic.uint16_t],
120
- // The sequence number.
121
- ['sequence', basic.uint8_t],
122
- ];
123
- class EmberBindingTableEntry extends EzspStruct {
124
- }
125
- exports.EmberBindingTableEntry = EmberBindingTableEntry;
126
- // An entry in the binding table.
127
- EmberBindingTableEntry._fields = [
128
- // The type of binding.
129
- ['type', named.EmberBindingType],
130
- // The endpoint on the local node.
131
- ['local', basic.uint8_t],
132
- // A cluster ID that matches one from the local endpoint's simple
133
- // descriptor.This cluster ID is set by the provisioning application to
134
- // indicate which part an endpoint's functionality is bound to this
135
- // particular remote node and is used to distinguish between unicast and
136
- // multicast bindings.Note that a binding can be used to send messages
137
- // with any cluster ID, not just that listed in the binding.
138
- ['clusterId', basic.uint16_t],
139
- // The endpoint on the remote node [specified by identifier].
140
- ['remote', basic.uint8_t],
141
- // A 64- bit identifier.This is either the destination EUI64 [for
142
- // unicasts] or the 64- bit group address [for multicasts].
143
- ['identifier', named.EmberEUI64],
144
- // The index of the network the binding belongs to.
145
- ['networkIndex', basic.uint8_t],
146
- ];
147
- class EmberMulticastTableEntry extends EzspStruct {
148
- }
149
- exports.EmberMulticastTableEntry = EmberMulticastTableEntry;
150
- // A multicast table entry indicates that a particular endpoint is a member
151
- // of a particular multicast group.Only devices with an endpoint in a
152
- // multicast group will receive messages sent to that multicast group.
153
- EmberMulticastTableEntry._fields = [
154
- // The multicast group ID.
155
- ['multicastId', named.EmberMulticastId],
156
- // The endpoint that is a member, or 0 if this entry is not in use[the
157
- // ZDO is not a member of any multicast groups.]
158
- ['endpoint', basic.uint8_t],
159
- // The network index of the network the entry is related to.
160
- ['networkIndex', basic.uint8_t],
161
- ];
162
- class EmberKeyData extends EzspStruct {
163
- }
164
- exports.EmberKeyData = EmberKeyData;
165
- // A 128- bit key.
166
- EmberKeyData._fields = [
167
- // The key data.
168
- ['contents', basic.fixed_list(16, basic.uint8_t)],
169
- ];
170
- class EmberCertificateData extends EzspStruct {
171
- }
172
- exports.EmberCertificateData = EmberCertificateData;
173
- // The implicit certificate used in CBKE.
174
- EmberCertificateData._fields = [
175
- // The certificate data.
176
- ['contents', basic.fixed_list(48, basic.uint8_t)],
177
- ];
178
- class EmberPublicKeyData extends EzspStruct {
179
- }
180
- exports.EmberPublicKeyData = EmberPublicKeyData;
181
- // The public key data used in CBKE.
182
- EmberPublicKeyData._fields = [
183
- // The public key data.
184
- ['contents', basic.fixed_list(22, basic.uint8_t)],
185
- ];
186
- class EmberPrivateKeyData extends EzspStruct {
187
- }
188
- exports.EmberPrivateKeyData = EmberPrivateKeyData;
189
- // The private key data used in CBKE.
190
- EmberPrivateKeyData._fields = [
191
- // The private key data.
192
- ['contents', basic.fixed_list(21, basic.uint8_t)],
193
- ];
194
- class EmberSmacData extends EzspStruct {
195
- }
196
- exports.EmberSmacData = EmberSmacData;
197
- // The Shared Message Authentication Code data used in CBKE.
198
- EmberSmacData._fields = [
199
- // The Shared Message Authentication Code data.
200
- ['contents', basic.fixed_list(16, basic.uint8_t)],
201
- ];
202
- class EmberSignatureData extends EzspStruct {
203
- }
204
- exports.EmberSignatureData = EmberSignatureData;
205
- // An ECDSA signature
206
- EmberSignatureData._fields = [
207
- // The signature data.
208
- ['contents', basic.fixed_list(42, basic.uint8_t)],
209
- ];
210
- class EmberCertificate283k1Data extends EzspStruct {
211
- }
212
- exports.EmberCertificate283k1Data = EmberCertificate283k1Data;
213
- // The implicit certificate used in CBKE.
214
- EmberCertificate283k1Data._fields = [
215
- // The 283k1 certificate data.
216
- ['contents', basic.fixed_list(74, basic.uint8_t)],
217
- ];
218
- class EmberPublicKey283k1Data extends EzspStruct {
219
- }
220
- exports.EmberPublicKey283k1Data = EmberPublicKey283k1Data;
221
- // The public key data used in CBKE.
222
- EmberPublicKey283k1Data._fields = [
223
- // The 283k1 public key data.
224
- ['contents', basic.fixed_list(37, basic.uint8_t)],
225
- ];
226
- class EmberPrivateKey283k1Data extends EzspStruct {
227
- }
228
- exports.EmberPrivateKey283k1Data = EmberPrivateKey283k1Data;
229
- // The private key data used in CBKE.
230
- EmberPrivateKey283k1Data._fields = [
231
- // The 283k1 private key data.
232
- ['contents', basic.fixed_list(36, basic.uint8_t)],
233
- ];
234
- class EmberSignature283k1Data extends EzspStruct {
235
- }
236
- exports.EmberSignature283k1Data = EmberSignature283k1Data;
237
- // An ECDSA signature
238
- EmberSignature283k1Data._fields = [
239
- // The 283k1 signature data.
240
- ['contents', basic.fixed_list(72, basic.uint8_t)],
241
- ];
242
- class EmberMessageDigest extends EzspStruct {
243
- }
244
- exports.EmberMessageDigest = EmberMessageDigest;
245
- // The calculated digest of a message
246
- EmberMessageDigest._fields = [
247
- // The calculated digest of a message.
248
- ['contents', basic.fixed_list(16, basic.uint8_t)],
249
- ];
250
- class EmberAesMmoHashContext extends EzspStruct {
251
- }
252
- exports.EmberAesMmoHashContext = EmberAesMmoHashContext;
253
- // The hash context for an ongoing hash operation.
254
- EmberAesMmoHashContext._fields = [
255
- // The result of ongoing the hash operation.
256
- ['result', basic.fixed_list(16, basic.uint8_t)],
257
- // The total length of the data that has been hashed so far.
258
- ['length', basic.uint32_t],
259
- ];
260
- class EmberNeighborTableEntry extends EzspStruct {
261
- }
262
- exports.EmberNeighborTableEntry = EmberNeighborTableEntry;
263
- // A neighbor table entry stores information about the reliability of RF
264
- // links to and from neighboring nodes.
265
- EmberNeighborTableEntry._fields = [
266
- // The neighbor's two byte network id
267
- ['shortId', basic.uint16_t],
268
- // An exponentially weighted moving average of the link quality values
269
- // of incoming packets from this neighbor as reported by the PHY.
270
- ['averageLqi', basic.uint8_t],
271
- // The incoming cost for this neighbor, computed from the average LQI.
272
- // Values range from 1 for a good link to 7 for a bad link.
273
- ['inCost', basic.uint8_t],
274
- // The outgoing cost for this neighbor, obtained from the most recently
275
- // received neighbor exchange message from the neighbor. A value of zero
276
- // means that a neighbor exchange message from the neighbor has not been
277
- // received recently enough, or that our id was not present in the most
278
- // recently received one.
279
- ['outCost', basic.uint8_t],
280
- // The number of aging periods elapsed since a link status message was
281
- // last received from this neighbor. The aging period is 16 seconds.
282
- ['age', basic.uint8_t],
283
- // The 8 byte EUI64 of the neighbor.
284
- ['longId', named.EmberEUI64],
285
- ];
286
- class EmberRouteTableEntry extends EzspStruct {
287
- }
288
- exports.EmberRouteTableEntry = EmberRouteTableEntry;
289
- // A route table entry stores information about the next hop along the route
290
- // to the destination.
291
- EmberRouteTableEntry._fields = [
292
- // The short id of the destination. A value of 0xFFFF indicates the
293
- // entry is unused.
294
- ['destination', basic.uint16_t],
295
- // The short id of the next hop to this destination.
296
- ['nextHop', basic.uint16_t],
297
- // Indicates whether this entry is active [0], being discovered [1]],
298
- // unused [3], or validating [4].
299
- ['status', basic.uint8_t],
300
- // The number of seconds since this route entry was last used to send a
301
- // packet.
302
- ['age', basic.uint8_t],
303
- // Indicates whether this destination is a High RAM Concentrator [2], a
304
- // Low RAM Concentrator [1], or not a concentrator [0].
305
- ['concentratorType', basic.uint8_t],
306
- // For a High RAM Concentrator, indicates whether a route record is
307
- // needed [2], has been sent [1], or is no long needed [0] because a
308
- // source routed message from the concentrator has been received.
309
- ['routeRecordState', basic.uint8_t],
310
- ];
311
- class EmberInitialSecurityState extends EzspStruct {
312
- }
313
- exports.EmberInitialSecurityState = EmberInitialSecurityState;
314
- // The security data used to set the configuration for the stack, or the
315
- // retrieved configuration currently in use.
316
- EmberInitialSecurityState._fields = [
317
- // A bitmask indicating the security state used to indicate what the
318
- // security configuration will be when the device forms or joins the
319
- // network.
320
- ['bitmask', named.EmberInitialSecurityBitmask],
321
- // The pre-configured Key data that should be used when forming or
322
- // joining the network. The security bitmask must be set with the
323
- // HAVE_PRECONFIGURED_KEY bit to indicate that the key contains valid
324
- // data.
325
- ['preconfiguredKey', EmberKeyData],
326
- // The Network Key that should be used by the Trust Center when it forms
327
- // the network, or the Network Key currently in use by a joined device.
328
- // The security bitmask must be set with HAVE_NETWORK_KEY to indicate
329
- // that the key contains valid data.
330
- ['networkKey', EmberKeyData],
331
- // The sequence number associated with the network key. This is only
332
- // valid if the HAVE_NETWORK_KEY has been set in the security bitmask.
333
- ['networkKeySequenceNumber', basic.uint8_t],
334
- // This is the long address of the trust center on the network that will
335
- // be joined. It is usually NOT set prior to joining the network and
336
- // instead it is learned during the joining message exchange. This field
337
- // is only examined if HAVE_TRUST_CENTER_EUI64 is set in the
338
- // EmberInitialSecurityState::bitmask. Most devices should clear that
339
- // bit and leave this field alone. This field must be set when using
340
- // commissioning mode.
341
- ['preconfiguredTrustCenterEui64', named.EmberEUI64],
342
- ];
343
- class EmberCurrentSecurityState extends EzspStruct {
344
- }
345
- exports.EmberCurrentSecurityState = EmberCurrentSecurityState;
346
- // The security options and information currently used by the stack.
347
- EmberCurrentSecurityState._fields = [
348
- // A bitmask indicating the security options currently in use by a
349
- // device joined in the network.
350
- ['bitmask', named.EmberCurrentSecurityBitmask],
351
- // The IEEE Address of the Trust Center device.
352
- ['trustCenterLongAddress', named.EmberEUI64],
353
- ];
354
- class EmberKeyStruct extends EzspStruct {
355
- }
356
- exports.EmberKeyStruct = EmberKeyStruct;
357
- // A structure containing a key and its associated data.
358
- EmberKeyStruct._fields = [
359
- // A bitmask indicating the presence of data within the various fields
360
- // in the structure.
361
- ['bitmask', named.EmberKeyStructBitmask],
362
- // The type of the key.
363
- ['type', named.EmberKeyType],
364
- // The actual key data.
365
- ['key', EmberKeyData],
366
- // The outgoing frame counter associated with the key.
367
- ['outgoingFrameCounter', basic.uint32_t],
368
- // The frame counter of the partner device associated with the key.
369
- ['incomingFrameCounter', basic.uint32_t],
370
- // The sequence number associated with the key.
371
- ['sequenceNumber', basic.uint8_t],
372
- // The IEEE address of the partner device also in possession of the key.
373
- ['partnerEUI64', named.EmberEUI64],
374
- ];
375
- class EmberNetworkInitStruct extends EzspStruct {
376
- }
377
- exports.EmberNetworkInitStruct = EmberNetworkInitStruct;
378
- // Network Initialization parameters.
379
- EmberNetworkInitStruct._fields = [
380
- // Configuration options for network init.
381
- ['bitmask', named.EmberNetworkInitBitmask],
382
- ];
383
- class EmberZllSecurityAlgorithmData extends EzspStruct {
384
- }
385
- exports.EmberZllSecurityAlgorithmData = EmberZllSecurityAlgorithmData;
386
- // Data associated with the ZLL security algorithm.
387
- EmberZllSecurityAlgorithmData._fields = [
388
- // Transaction identifier.
389
- ['transactionId', basic.uint32_t],
390
- // Response identifier.
391
- ['responseId', basic.uint32_t],
392
- // Bitmask.
393
- ['bitmask', basic.uint16_t],
394
- ];
395
- class EmberZllNetwork extends EzspStruct {
396
- }
397
- exports.EmberZllNetwork = EmberZllNetwork;
398
- // The parameters of a ZLL network.
399
- EmberZllNetwork._fields = [
400
- // The parameters of a ZigBee network.
401
- ['zigbeeNetwork', EmberZigbeeNetwork],
402
- // Data associated with the ZLL security algorithm.
403
- ['securityAlgorithm', EmberZllSecurityAlgorithmData],
404
- // Associated EUI64.
405
- ['eui64', named.EmberEUI64],
406
- // The node id.
407
- ['nodeId', named.EmberNodeId],
408
- // The ZLL state.
409
- ['state', named.EmberZllState],
410
- // The node type.
411
- ['nodeType', named.EmberNodeType],
412
- // The number of sub devices.
413
- ['numberSubDevices', basic.uint8_t],
414
- // The total number of group identifiers.
415
- ['totalGroupIdentifiers', basic.uint8_t],
416
- // RSSI correction value.
417
- ['rssiCorrection', basic.uint8_t],
418
- ];
419
- class EmberZllInitialSecurityState extends EzspStruct {
420
- }
421
- exports.EmberZllInitialSecurityState = EmberZllInitialSecurityState;
422
- // Describes the initial security features and requirements that will be
423
- // used when forming or joining ZLL networks.
424
- EmberZllInitialSecurityState._fields = [
425
- // Unused bitmask; reserved for future use.
426
- ['bitmask', basic.uint32_t],
427
- // The key encryption algorithm advertised by the application.
428
- ['keyIndex', named.EmberZllKeyIndex],
429
- // The encryption key for use by algorithms that require it.
430
- ['encryptionKey', EmberKeyData],
431
- // The pre-configured link key used during classical ZigBee
432
- // commissioning.
433
- ['preconfiguredKey', EmberKeyData],
434
- ];
435
- class EmberZllDeviceInfoRecord extends EzspStruct {
436
- }
437
- exports.EmberZllDeviceInfoRecord = EmberZllDeviceInfoRecord;
438
- // Information about a specific ZLL Device.
439
- EmberZllDeviceInfoRecord._fields = [
440
- // EUI64 associated with the device.
441
- ['ieeeAddress', named.EmberEUI64],
442
- // Endpoint id.
443
- ['endpointId', basic.uint8_t],
444
- // Profile id.
445
- ['profileId', basic.uint16_t],
446
- // Device id.
447
- ['deviceId', basic.uint16_t],
448
- // Associated version.
449
- ['version', basic.uint8_t],
450
- // Number of relevant group ids.
451
- ['groupIdCount', basic.uint8_t],
452
- ];
453
- class EmberZllAddressAssignment extends EzspStruct {
454
- }
455
- exports.EmberZllAddressAssignment = EmberZllAddressAssignment;
456
- // ZLL address assignment data.
457
- EmberZllAddressAssignment._fields = [
458
- // Relevant node id.
459
- ['nodeId', named.EmberNodeId],
460
- // Minimum free node id.
461
- ['freeNodeIdMin', named.EmberNodeId],
462
- // Maximum free node id.
463
- ['freeNodeIdMax', named.EmberNodeId],
464
- // Minimum group id.
465
- ['groupIdMin', named.EmberMulticastId],
466
- // Maximum group id.
467
- ['groupIdMax', named.EmberMulticastId],
468
- // Minimum free group id.
469
- ['freeGroupIdMin', named.EmberMulticastId],
470
- // Maximum free group id.
471
- ['freeGroupIdMax', named.EmberMulticastId],
472
- ];
473
- class EmberTokTypeStackZllData extends EzspStruct {
474
- }
475
- exports.EmberTokTypeStackZllData = EmberTokTypeStackZllData;
476
- // Public API for ZLL stack data token.
477
- EmberTokTypeStackZllData._fields = [
478
- // Token bitmask.
479
- ['bitmask', basic.uint32_t],
480
- // Minimum free node id.
481
- ['freeNodeIdMin', basic.uint16_t],
482
- // Maximum free node id.
483
- ['freeNodeIdMax', basic.uint16_t],
484
- // Local minimum group id.
485
- ['myGroupIdMin', basic.uint16_t],
486
- // Minimum free group id.
487
- ['freeGroupIdMin', basic.uint16_t],
488
- // Maximum free group id.
489
- ['freeGroupIdMax', basic.uint16_t],
490
- // RSSI correction value.
491
- ['rssiCorrection', basic.uint8_t],
492
- ];
493
- class EmberTokTypeStackZllSecurity extends EzspStruct {
494
- }
495
- exports.EmberTokTypeStackZllSecurity = EmberTokTypeStackZllSecurity;
496
- // Public API for ZLL stack security token.
497
- EmberTokTypeStackZllSecurity._fields = [
498
- // Token bitmask.
499
- ['bitmask', basic.uint32_t],
500
- // Key index.
501
- ['keyIndex', basic.uint8_t],
502
- // Encryption key.
503
- ['encryptionKey', basic.fixed_list(16, basic.uint8_t)],
504
- // Preconfigured key.
505
- ['preconfiguredKey', basic.fixed_list(16, basic.uint8_t)],
506
- ];
507
- class EmberRf4ceVendorInfo extends EzspStruct {
508
- }
509
- exports.EmberRf4ceVendorInfo = EmberRf4ceVendorInfo;
510
- // The RF4CE vendor information block.
511
- EmberRf4ceVendorInfo._fields = [
512
- // The vendor identifier field shall contain the vendor identifier of
513
- // the node.
514
- ['vendorId', basic.uint16_t],
515
- // The vendor string field shall contain the vendor string of the node.
516
- ['vendorString', basic.fixed_list(7, basic.uint8_t)],
517
- ];
518
- class EmberRf4ceApplicationInfo extends EzspStruct {
519
- }
520
- exports.EmberRf4ceApplicationInfo = EmberRf4ceApplicationInfo;
521
- // The RF4CE application information block.
522
- EmberRf4ceApplicationInfo._fields = [
523
- // The application capabilities field shall contain information relating
524
- // to the capabilities of the application of the node.
525
- ['capabilities', named.EmberRf4ceApplicationCapabilities],
526
- // The user string field shall contain the user specified identification
527
- // string.
528
- ['userString', basic.fixed_list(15, basic.uint8_t)],
529
- // The device type list field shall contain the list of device types
530
- // supported by the node.
531
- ['deviceTypeList', basic.fixed_list(3, basic.uint8_t)],
532
- // The profile ID list field shall contain the list of profile
533
- // identifiers disclosed as supported by the node.
534
- ['profileIdList', basic.fixed_list(7, basic.uint8_t)],
535
- ];
536
- class EmberRf4cePairingTableEntry extends EzspStruct {
537
- }
538
- exports.EmberRf4cePairingTableEntry = EmberRf4cePairingTableEntry;
539
- // The internal representation of an RF4CE pairing table entry.
540
- EmberRf4cePairingTableEntry._fields = [
541
- // The link key to be used to secure this pairing link.
542
- ['securityLinkKey', EmberKeyData],
543
- // The IEEE address of the destination device.
544
- ['destLongId', named.EmberEUI64],
545
- // The frame counter last received from the recipient node.
546
- ['frameCounter', basic.uint32_t],
547
- // The network address to be assumed by the source device.
548
- ['sourceNodeId', named.EmberNodeId],
549
- // The PAN identifier of the destination device.
550
- ['destPanId', named.EmberPanId],
551
- // The network address of the destination device.
552
- ['destNodeId', named.EmberNodeId],
553
- // The vendor ID of the destination device.
554
- ['destVendorId', basic.uint16_t],
555
- // The list of profiles supported by the destination device.
556
- ['destProfileIdList', basic.fixed_list(7, basic.uint8_t)],
557
- // The length of the list of supported profiles.
558
- ['destProfileIdListLength', basic.uint8_t],
559
- // Info byte.
560
- ['info', basic.uint8_t],
561
- // The expected channel of the destination device.
562
- ['channel', basic.uint8_t],
563
- // The node capabilities of the recipient node.
564
- ['capabilities', basic.uint8_t],
565
- // Last MAC sequence number seen on this pairing link.
566
- ['lastSeqn', basic.uint8_t],
567
- ];
568
- class EmberGpAddress extends EzspStruct {
569
- }
570
- exports.EmberGpAddress = EmberGpAddress;
571
- // A GP address structure.
572
- EmberGpAddress._fields = [
573
- // The GPD's EUI64.
574
- ['gpdIeeeAddress', named.EmberEUI64],
575
- // The GPD's source ID.
576
- ['sourceId', basic.uint32_t],
577
- // The GPD Application ID.
578
- ['applicationId', basic.uint8_t],
579
- // The GPD endpoint.
580
- ['endpoint', basic.uint8_t],
581
- ];
582
- class EmberGpSinkListEntry extends EzspStruct {
583
- }
584
- exports.EmberGpSinkListEntry = EmberGpSinkListEntry;
585
- // A sink list entry
586
- EmberGpSinkListEntry._fields = [
587
- // The sink list type.
588
- ['type', basic.uint8_t],
589
- // The EUI64 of the target sink.
590
- ['sinkEUI', named.EmberEUI64],
591
- // The short address of the target sink.
592
- ['sinkNodeId', named.EmberNodeId],
593
- ];
594
- class EmberNodeDescriptor extends EzspStruct {
595
- }
596
- exports.EmberNodeDescriptor = EmberNodeDescriptor;
597
- EmberNodeDescriptor._fields = [
598
- ['byte1', basic.uint8_t],
599
- ['byte2', basic.uint8_t],
600
- ['mac_capability_flags', basic.uint8_t],
601
- ['manufacturer_code', basic.uint16_t],
602
- ['maximum_buffer_size', basic.uint8_t],
603
- ['maximum_incoming_transfer_size', basic.uint16_t],
604
- ['server_mask', basic.uint16_t],
605
- ['maximum_outgoing_transfer_size', basic.uint16_t],
606
- ['descriptor_capability_field', basic.uint8_t],
607
- ];
608
- class EmberSimpleDescriptor extends EzspStruct {
609
- }
610
- exports.EmberSimpleDescriptor = EmberSimpleDescriptor;
611
- EmberSimpleDescriptor._fields = [
612
- ['endpoint', basic.uint8_t],
613
- ['profileid', basic.uint16_t],
614
- ['deviceid', basic.uint16_t],
615
- ['deviceversion', basic.uint8_t],
616
- ['inclusterlist', basic.LVList(basic.uint16_t)],
617
- ['outclusterlist', basic.LVList(basic.uint16_t)],
618
- ];
619
- class EmberMultiAddress extends EzspStruct {
620
- /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
621
- static serialize(cls, obj) {
622
- const addrmode = obj['addrmode'];
623
- /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
624
- const fields = (addrmode == 3) ? cls.fields3 : cls.fields1;
625
- /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
626
- return Buffer.concat(fields.map((field) => {
627
- const value = obj[field[0]];
628
- console.assert(field[1]);
629
- return field[1].serialize(field[1], value);
630
- }));
631
- }
632
- }
633
- exports.EmberMultiAddress = EmberMultiAddress;
634
- EmberMultiAddress.fields3 = [
635
- ['addrmode', basic.uint8_t],
636
- ['ieee', named.EmberEUI64],
637
- ['endpoint', basic.uint8_t],
638
- ];
639
- EmberMultiAddress.fields1 = [
640
- ['addrmode', basic.uint8_t],
641
- ['nwk', named.EmberNodeId],
642
- ];
643
- class EmberNeighbor extends EzspStruct {
644
- }
645
- exports.EmberNeighbor = EmberNeighbor;
646
- EmberNeighbor._fields = [
647
- ['extendedpanid', basic.fixed_list(8, basic.uint8_t)],
648
- ['ieee', named.EmberEUI64],
649
- ['nodeid', named.EmberNodeId],
650
- ['packed', basic.uint8_t],
651
- ['permitjoining', basic.uint8_t],
652
- ['depth', basic.uint8_t],
653
- ['lqi', basic.uint8_t],
654
- ];
655
- class EmberNeighbors extends EzspStruct {
656
- }
657
- exports.EmberNeighbors = EmberNeighbors;
658
- EmberNeighbors._fields = [
659
- ['entries', basic.uint8_t],
660
- ['startindex', basic.uint8_t],
661
- ['neighbors', basic.LVList(EmberNeighbor)],
662
- ];
663
- class EmberRoutingTableEntry extends EzspStruct {
664
- }
665
- exports.EmberRoutingTableEntry = EmberRoutingTableEntry;
666
- EmberRoutingTableEntry._fields = [
667
- ['destination', basic.uint16_t],
668
- ['status', basic.uint8_t],
669
- ['nexthop', basic.uint16_t],
670
- ];
671
- class EmberRoutingTable extends EzspStruct {
672
- }
673
- exports.EmberRoutingTable = EmberRoutingTable;
674
- EmberRoutingTable._fields = [
675
- ['entries', basic.uint8_t],
676
- ['startindex', basic.uint8_t],
677
- ['table', basic.LVList(EmberRoutingTableEntry)],
678
- ];
679
- class EmberRawFrame extends EzspStruct {
680
- }
681
- exports.EmberRawFrame = EmberRawFrame;
682
- EmberRawFrame._fields = [
683
- ['ieeeFrameControl', basic.uint16_t],
684
- ['sequence', basic.uint8_t],
685
- ['destPanId', named.EmberPanId],
686
- ['destNodeId', named.EmberNodeId],
687
- ['sourcePanId', named.EmberPanId],
688
- ['ieeeAddress', named.EmberEUI64],
689
- ['nwkFrameControl', basic.uint16_t],
690
- ['appFrameControl', basic.uint8_t],
691
- ['clusterId', basic.uint16_t],
692
- ['profileId', basic.uint16_t],
693
- ];
694
- class EmberIeeeRawFrame extends EzspStruct {
695
- }
696
- exports.EmberIeeeRawFrame = EmberIeeeRawFrame;
697
- EmberIeeeRawFrame._fields = [
698
- ['ieeeFrameControl', basic.uint16_t],
699
- ['sequence', basic.uint8_t],
700
- ['destPanId', named.EmberPanId],
701
- ['destAddress', named.EmberEUI64],
702
- ['sourcePanId', named.EmberPanId],
703
- ['sourceAddress', named.EmberEUI64],
704
- ['nwkFrameControl', basic.uint16_t],
705
- ['appFrameControl', basic.uint8_t],
706
- ['clusterId', basic.uint16_t],
707
- ['profileId', basic.uint16_t],
708
- ];
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || function (mod) {
19
+ if (mod && mod.__esModule) return mod;
20
+ var result = {};
21
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
+ __setModuleDefault(result, mod);
23
+ return result;
24
+ };
25
+ Object.defineProperty(exports, "__esModule", { value: true });
26
+ exports.EmberIeeeRawFrame = exports.EmberRawFrame = exports.EmberRoutingTable = exports.EmberRoutingTableEntry = exports.EmberNeighbors = exports.EmberNeighbor = exports.EmberMultiAddress = exports.EmberSimpleDescriptor = exports.EmberNodeDescriptor = exports.EmberGpSinkListEntry = exports.EmberGpAddress = exports.EmberRf4cePairingTableEntry = exports.EmberRf4ceApplicationInfo = exports.EmberRf4ceVendorInfo = exports.EmberTokTypeStackZllSecurity = exports.EmberTokTypeStackZllData = exports.EmberZllAddressAssignment = exports.EmberZllDeviceInfoRecord = exports.EmberZllInitialSecurityState = exports.EmberZllNetwork = exports.EmberZllSecurityAlgorithmData = exports.EmberNetworkInitStruct = exports.EmberKeyStruct = exports.EmberCurrentSecurityState = exports.EmberInitialSecurityState = exports.EmberRouteTableEntry = exports.EmberNeighborTableEntry = exports.EmberAesMmoHashContext = exports.EmberMessageDigest = exports.EmberSignature283k1Data = exports.EmberPrivateKey283k1Data = exports.EmberPublicKey283k1Data = exports.EmberCertificate283k1Data = exports.EmberSignatureData = exports.EmberSmacData = exports.EmberPrivateKeyData = exports.EmberPublicKeyData = exports.EmberCertificateData = exports.EmberKeyData = exports.EmberMulticastTableEntry = exports.EmberBindingTableEntry = exports.EmberApsFrame = exports.EmberZigbeeNetwork = exports.EmberNetworkParameters = exports.EzspStruct = void 0;
27
+ /* istanbul ignore file */
28
+ /* eslint-disable @typescript-eslint/explicit-module-boundary-types */
29
+ const basic = __importStar(require("./basic"));
30
+ const named = __importStar(require("./named"));
31
+ class EzspStruct {
32
+ /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
33
+ static serialize(cls, obj) {
34
+ /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
35
+ return Buffer.concat(cls._fields.map((field) => {
36
+ const value = obj[field[0]];
37
+ console.assert(field[1]);
38
+ return field[1].serialize(field[1], value);
39
+ }));
40
+ }
41
+ /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
42
+ static deserialize(cls, data) {
43
+ const r = new cls();
44
+ for (const [field_name, field_type] of cls._fields) {
45
+ let v;
46
+ [v, data] = field_type.deserialize(field_type, data);
47
+ r[field_name] = v;
48
+ }
49
+ return [r, data];
50
+ }
51
+ toString() {
52
+ return `${this.constructor.name}: ${JSON.stringify(this)}`;
53
+ }
54
+ }
55
+ exports.EzspStruct = EzspStruct;
56
+ class EmberNetworkParameters extends EzspStruct {
57
+ }
58
+ EmberNetworkParameters._fields = [
59
+ // The network's extended PAN identifier.
60
+ ['extendedPanId', basic.fixed_list(8, basic.uint8_t)],
61
+ // The network's PAN identifier.
62
+ ['panId', basic.uint16_t],
63
+ // A power setting, in dBm.
64
+ ['radioTxPower', basic.uint8_t],
65
+ // A radio channel.
66
+ ['radioChannel', basic.uint8_t],
67
+ // The method used to initially join the network.
68
+ ['joinMethod', named.EmberJoinMethod],
69
+ // NWK Manager ID. The ID of the network manager in the current network.
70
+ // This may only be set at joining when using USE_NWK_COMMISSIONING as
71
+ // the join method.
72
+ ['nwkManagerId', named.EmberNodeId],
73
+ // NWK Update ID. The value of the ZigBee nwkUpdateId known by the
74
+ // stack. This is used to determine the newest instance of the network
75
+ // after a PAN ID or channel change. This may only be set at joining
76
+ // when using USE_NWK_COMMISSIONING as the join method.
77
+ ['nwkUpdateId', basic.uint8_t],
78
+ // NWK channel mask. The list of preferred channels that the NWK manager
79
+ // has told this device to use when searching for the network. This may
80
+ // only be set at joining when using USE_NWK_COMMISSIONING as the join
81
+ // method.
82
+ ['channels', basic.uint32_t],
83
+ ];
84
+ exports.EmberNetworkParameters = EmberNetworkParameters;
85
+ class EmberZigbeeNetwork extends EzspStruct {
86
+ }
87
+ // The parameters of a ZigBee network.
88
+ EmberZigbeeNetwork._fields = [
89
+ // The 802.15.4 channel associated with the network.
90
+ ['channel', basic.uint8_t],
91
+ // The network's PAN identifier.
92
+ ['panId', basic.uint16_t],
93
+ // The network's extended PAN identifier.
94
+ ['extendedPanId', basic.fixed_list(8, basic.uint8_t)],
95
+ // Whether the network is allowing MAC associations.
96
+ ['allowingJoin', named.Bool],
97
+ // The Stack Profile associated with the network.
98
+ ['stackProfile', basic.uint8_t],
99
+ // The instance of the Network.
100
+ ['nwkUpdateId', basic.uint8_t],
101
+ ];
102
+ exports.EmberZigbeeNetwork = EmberZigbeeNetwork;
103
+ class EmberApsFrame extends EzspStruct {
104
+ }
105
+ // ZigBee APS frame parameters.
106
+ EmberApsFrame._fields = [
107
+ // The application profile ID that describes the format of the message.
108
+ ['profileId', basic.uint16_t],
109
+ // The cluster ID for this message.
110
+ ['clusterId', basic.uint16_t],
111
+ // The source endpoint.
112
+ ['sourceEndpoint', basic.uint8_t],
113
+ // The destination endpoint.
114
+ ['destinationEndpoint', basic.uint8_t],
115
+ // A bitmask of options.
116
+ ['options', named.EmberApsOption],
117
+ // The group ID for this message, if it is multicast mode.
118
+ ['groupId', basic.uint16_t],
119
+ // The sequence number.
120
+ ['sequence', basic.uint8_t],
121
+ ];
122
+ exports.EmberApsFrame = EmberApsFrame;
123
+ class EmberBindingTableEntry extends EzspStruct {
124
+ }
125
+ // An entry in the binding table.
126
+ EmberBindingTableEntry._fields = [
127
+ // The type of binding.
128
+ ['type', named.EmberBindingType],
129
+ // The endpoint on the local node.
130
+ ['local', basic.uint8_t],
131
+ // A cluster ID that matches one from the local endpoint's simple
132
+ // descriptor.This cluster ID is set by the provisioning application to
133
+ // indicate which part an endpoint's functionality is bound to this
134
+ // particular remote node and is used to distinguish between unicast and
135
+ // multicast bindings.Note that a binding can be used to send messages
136
+ // with any cluster ID, not just that listed in the binding.
137
+ ['clusterId', basic.uint16_t],
138
+ // The endpoint on the remote node [specified by identifier].
139
+ ['remote', basic.uint8_t],
140
+ // A 64- bit identifier.This is either the destination EUI64 [for
141
+ // unicasts] or the 64- bit group address [for multicasts].
142
+ ['identifier', named.EmberEUI64],
143
+ // The index of the network the binding belongs to.
144
+ ['networkIndex', basic.uint8_t],
145
+ ];
146
+ exports.EmberBindingTableEntry = EmberBindingTableEntry;
147
+ class EmberMulticastTableEntry extends EzspStruct {
148
+ }
149
+ // A multicast table entry indicates that a particular endpoint is a member
150
+ // of a particular multicast group.Only devices with an endpoint in a
151
+ // multicast group will receive messages sent to that multicast group.
152
+ EmberMulticastTableEntry._fields = [
153
+ // The multicast group ID.
154
+ ['multicastId', named.EmberMulticastId],
155
+ // The endpoint that is a member, or 0 if this entry is not in use[the
156
+ // ZDO is not a member of any multicast groups.]
157
+ ['endpoint', basic.uint8_t],
158
+ // The network index of the network the entry is related to.
159
+ ['networkIndex', basic.uint8_t],
160
+ ];
161
+ exports.EmberMulticastTableEntry = EmberMulticastTableEntry;
162
+ class EmberKeyData extends EzspStruct {
163
+ }
164
+ // A 128- bit key.
165
+ EmberKeyData._fields = [
166
+ // The key data.
167
+ ['contents', basic.fixed_list(16, basic.uint8_t)],
168
+ ];
169
+ exports.EmberKeyData = EmberKeyData;
170
+ class EmberCertificateData extends EzspStruct {
171
+ }
172
+ // The implicit certificate used in CBKE.
173
+ EmberCertificateData._fields = [
174
+ // The certificate data.
175
+ ['contents', basic.fixed_list(48, basic.uint8_t)],
176
+ ];
177
+ exports.EmberCertificateData = EmberCertificateData;
178
+ class EmberPublicKeyData extends EzspStruct {
179
+ }
180
+ // The public key data used in CBKE.
181
+ EmberPublicKeyData._fields = [
182
+ // The public key data.
183
+ ['contents', basic.fixed_list(22, basic.uint8_t)],
184
+ ];
185
+ exports.EmberPublicKeyData = EmberPublicKeyData;
186
+ class EmberPrivateKeyData extends EzspStruct {
187
+ }
188
+ // The private key data used in CBKE.
189
+ EmberPrivateKeyData._fields = [
190
+ // The private key data.
191
+ ['contents', basic.fixed_list(21, basic.uint8_t)],
192
+ ];
193
+ exports.EmberPrivateKeyData = EmberPrivateKeyData;
194
+ class EmberSmacData extends EzspStruct {
195
+ }
196
+ // The Shared Message Authentication Code data used in CBKE.
197
+ EmberSmacData._fields = [
198
+ // The Shared Message Authentication Code data.
199
+ ['contents', basic.fixed_list(16, basic.uint8_t)],
200
+ ];
201
+ exports.EmberSmacData = EmberSmacData;
202
+ class EmberSignatureData extends EzspStruct {
203
+ }
204
+ // An ECDSA signature
205
+ EmberSignatureData._fields = [
206
+ // The signature data.
207
+ ['contents', basic.fixed_list(42, basic.uint8_t)],
208
+ ];
209
+ exports.EmberSignatureData = EmberSignatureData;
210
+ class EmberCertificate283k1Data extends EzspStruct {
211
+ }
212
+ // The implicit certificate used in CBKE.
213
+ EmberCertificate283k1Data._fields = [
214
+ // The 283k1 certificate data.
215
+ ['contents', basic.fixed_list(74, basic.uint8_t)],
216
+ ];
217
+ exports.EmberCertificate283k1Data = EmberCertificate283k1Data;
218
+ class EmberPublicKey283k1Data extends EzspStruct {
219
+ }
220
+ // The public key data used in CBKE.
221
+ EmberPublicKey283k1Data._fields = [
222
+ // The 283k1 public key data.
223
+ ['contents', basic.fixed_list(37, basic.uint8_t)],
224
+ ];
225
+ exports.EmberPublicKey283k1Data = EmberPublicKey283k1Data;
226
+ class EmberPrivateKey283k1Data extends EzspStruct {
227
+ }
228
+ // The private key data used in CBKE.
229
+ EmberPrivateKey283k1Data._fields = [
230
+ // The 283k1 private key data.
231
+ ['contents', basic.fixed_list(36, basic.uint8_t)],
232
+ ];
233
+ exports.EmberPrivateKey283k1Data = EmberPrivateKey283k1Data;
234
+ class EmberSignature283k1Data extends EzspStruct {
235
+ }
236
+ // An ECDSA signature
237
+ EmberSignature283k1Data._fields = [
238
+ // The 283k1 signature data.
239
+ ['contents', basic.fixed_list(72, basic.uint8_t)],
240
+ ];
241
+ exports.EmberSignature283k1Data = EmberSignature283k1Data;
242
+ class EmberMessageDigest extends EzspStruct {
243
+ }
244
+ // The calculated digest of a message
245
+ EmberMessageDigest._fields = [
246
+ // The calculated digest of a message.
247
+ ['contents', basic.fixed_list(16, basic.uint8_t)],
248
+ ];
249
+ exports.EmberMessageDigest = EmberMessageDigest;
250
+ class EmberAesMmoHashContext extends EzspStruct {
251
+ }
252
+ // The hash context for an ongoing hash operation.
253
+ EmberAesMmoHashContext._fields = [
254
+ // The result of ongoing the hash operation.
255
+ ['result', basic.fixed_list(16, basic.uint8_t)],
256
+ // The total length of the data that has been hashed so far.
257
+ ['length', basic.uint32_t],
258
+ ];
259
+ exports.EmberAesMmoHashContext = EmberAesMmoHashContext;
260
+ class EmberNeighborTableEntry extends EzspStruct {
261
+ }
262
+ // A neighbor table entry stores information about the reliability of RF
263
+ // links to and from neighboring nodes.
264
+ EmberNeighborTableEntry._fields = [
265
+ // The neighbor's two byte network id
266
+ ['shortId', basic.uint16_t],
267
+ // An exponentially weighted moving average of the link quality values
268
+ // of incoming packets from this neighbor as reported by the PHY.
269
+ ['averageLqi', basic.uint8_t],
270
+ // The incoming cost for this neighbor, computed from the average LQI.
271
+ // Values range from 1 for a good link to 7 for a bad link.
272
+ ['inCost', basic.uint8_t],
273
+ // The outgoing cost for this neighbor, obtained from the most recently
274
+ // received neighbor exchange message from the neighbor. A value of zero
275
+ // means that a neighbor exchange message from the neighbor has not been
276
+ // received recently enough, or that our id was not present in the most
277
+ // recently received one.
278
+ ['outCost', basic.uint8_t],
279
+ // The number of aging periods elapsed since a link status message was
280
+ // last received from this neighbor. The aging period is 16 seconds.
281
+ ['age', basic.uint8_t],
282
+ // The 8 byte EUI64 of the neighbor.
283
+ ['longId', named.EmberEUI64],
284
+ ];
285
+ exports.EmberNeighborTableEntry = EmberNeighborTableEntry;
286
+ class EmberRouteTableEntry extends EzspStruct {
287
+ }
288
+ // A route table entry stores information about the next hop along the route
289
+ // to the destination.
290
+ EmberRouteTableEntry._fields = [
291
+ // The short id of the destination. A value of 0xFFFF indicates the
292
+ // entry is unused.
293
+ ['destination', basic.uint16_t],
294
+ // The short id of the next hop to this destination.
295
+ ['nextHop', basic.uint16_t],
296
+ // Indicates whether this entry is active [0], being discovered [1]],
297
+ // unused [3], or validating [4].
298
+ ['status', basic.uint8_t],
299
+ // The number of seconds since this route entry was last used to send a
300
+ // packet.
301
+ ['age', basic.uint8_t],
302
+ // Indicates whether this destination is a High RAM Concentrator [2], a
303
+ // Low RAM Concentrator [1], or not a concentrator [0].
304
+ ['concentratorType', basic.uint8_t],
305
+ // For a High RAM Concentrator, indicates whether a route record is
306
+ // needed [2], has been sent [1], or is no long needed [0] because a
307
+ // source routed message from the concentrator has been received.
308
+ ['routeRecordState', basic.uint8_t],
309
+ ];
310
+ exports.EmberRouteTableEntry = EmberRouteTableEntry;
311
+ class EmberInitialSecurityState extends EzspStruct {
312
+ }
313
+ // The security data used to set the configuration for the stack, or the
314
+ // retrieved configuration currently in use.
315
+ EmberInitialSecurityState._fields = [
316
+ // A bitmask indicating the security state used to indicate what the
317
+ // security configuration will be when the device forms or joins the
318
+ // network.
319
+ ['bitmask', named.EmberInitialSecurityBitmask],
320
+ // The pre-configured Key data that should be used when forming or
321
+ // joining the network. The security bitmask must be set with the
322
+ // HAVE_PRECONFIGURED_KEY bit to indicate that the key contains valid
323
+ // data.
324
+ ['preconfiguredKey', EmberKeyData],
325
+ // The Network Key that should be used by the Trust Center when it forms
326
+ // the network, or the Network Key currently in use by a joined device.
327
+ // The security bitmask must be set with HAVE_NETWORK_KEY to indicate
328
+ // that the key contains valid data.
329
+ ['networkKey', EmberKeyData],
330
+ // The sequence number associated with the network key. This is only
331
+ // valid if the HAVE_NETWORK_KEY has been set in the security bitmask.
332
+ ['networkKeySequenceNumber', basic.uint8_t],
333
+ // This is the long address of the trust center on the network that will
334
+ // be joined. It is usually NOT set prior to joining the network and
335
+ // instead it is learned during the joining message exchange. This field
336
+ // is only examined if HAVE_TRUST_CENTER_EUI64 is set in the
337
+ // EmberInitialSecurityState::bitmask. Most devices should clear that
338
+ // bit and leave this field alone. This field must be set when using
339
+ // commissioning mode.
340
+ ['preconfiguredTrustCenterEui64', named.EmberEUI64],
341
+ ];
342
+ exports.EmberInitialSecurityState = EmberInitialSecurityState;
343
+ class EmberCurrentSecurityState extends EzspStruct {
344
+ }
345
+ // The security options and information currently used by the stack.
346
+ EmberCurrentSecurityState._fields = [
347
+ // A bitmask indicating the security options currently in use by a
348
+ // device joined in the network.
349
+ ['bitmask', named.EmberCurrentSecurityBitmask],
350
+ // The IEEE Address of the Trust Center device.
351
+ ['trustCenterLongAddress', named.EmberEUI64],
352
+ ];
353
+ exports.EmberCurrentSecurityState = EmberCurrentSecurityState;
354
+ class EmberKeyStruct extends EzspStruct {
355
+ }
356
+ // A structure containing a key and its associated data.
357
+ EmberKeyStruct._fields = [
358
+ // A bitmask indicating the presence of data within the various fields
359
+ // in the structure.
360
+ ['bitmask', named.EmberKeyStructBitmask],
361
+ // The type of the key.
362
+ ['type', named.EmberKeyType],
363
+ // The actual key data.
364
+ ['key', EmberKeyData],
365
+ // The outgoing frame counter associated with the key.
366
+ ['outgoingFrameCounter', basic.uint32_t],
367
+ // The frame counter of the partner device associated with the key.
368
+ ['incomingFrameCounter', basic.uint32_t],
369
+ // The sequence number associated with the key.
370
+ ['sequenceNumber', basic.uint8_t],
371
+ // The IEEE address of the partner device also in possession of the key.
372
+ ['partnerEUI64', named.EmberEUI64],
373
+ ];
374
+ exports.EmberKeyStruct = EmberKeyStruct;
375
+ class EmberNetworkInitStruct extends EzspStruct {
376
+ }
377
+ // Network Initialization parameters.
378
+ EmberNetworkInitStruct._fields = [
379
+ // Configuration options for network init.
380
+ ['bitmask', named.EmberNetworkInitBitmask],
381
+ ];
382
+ exports.EmberNetworkInitStruct = EmberNetworkInitStruct;
383
+ class EmberZllSecurityAlgorithmData extends EzspStruct {
384
+ }
385
+ // Data associated with the ZLL security algorithm.
386
+ EmberZllSecurityAlgorithmData._fields = [
387
+ // Transaction identifier.
388
+ ['transactionId', basic.uint32_t],
389
+ // Response identifier.
390
+ ['responseId', basic.uint32_t],
391
+ // Bitmask.
392
+ ['bitmask', basic.uint16_t],
393
+ ];
394
+ exports.EmberZllSecurityAlgorithmData = EmberZllSecurityAlgorithmData;
395
+ class EmberZllNetwork extends EzspStruct {
396
+ }
397
+ // The parameters of a ZLL network.
398
+ EmberZllNetwork._fields = [
399
+ // The parameters of a ZigBee network.
400
+ ['zigbeeNetwork', EmberZigbeeNetwork],
401
+ // Data associated with the ZLL security algorithm.
402
+ ['securityAlgorithm', EmberZllSecurityAlgorithmData],
403
+ // Associated EUI64.
404
+ ['eui64', named.EmberEUI64],
405
+ // The node id.
406
+ ['nodeId', named.EmberNodeId],
407
+ // The ZLL state.
408
+ ['state', named.EmberZllState],
409
+ // The node type.
410
+ ['nodeType', named.EmberNodeType],
411
+ // The number of sub devices.
412
+ ['numberSubDevices', basic.uint8_t],
413
+ // The total number of group identifiers.
414
+ ['totalGroupIdentifiers', basic.uint8_t],
415
+ // RSSI correction value.
416
+ ['rssiCorrection', basic.uint8_t],
417
+ ];
418
+ exports.EmberZllNetwork = EmberZllNetwork;
419
+ class EmberZllInitialSecurityState extends EzspStruct {
420
+ }
421
+ // Describes the initial security features and requirements that will be
422
+ // used when forming or joining ZLL networks.
423
+ EmberZllInitialSecurityState._fields = [
424
+ // Unused bitmask; reserved for future use.
425
+ ['bitmask', basic.uint32_t],
426
+ // The key encryption algorithm advertised by the application.
427
+ ['keyIndex', named.EmberZllKeyIndex],
428
+ // The encryption key for use by algorithms that require it.
429
+ ['encryptionKey', EmberKeyData],
430
+ // The pre-configured link key used during classical ZigBee
431
+ // commissioning.
432
+ ['preconfiguredKey', EmberKeyData],
433
+ ];
434
+ exports.EmberZllInitialSecurityState = EmberZllInitialSecurityState;
435
+ class EmberZllDeviceInfoRecord extends EzspStruct {
436
+ }
437
+ // Information about a specific ZLL Device.
438
+ EmberZllDeviceInfoRecord._fields = [
439
+ // EUI64 associated with the device.
440
+ ['ieeeAddress', named.EmberEUI64],
441
+ // Endpoint id.
442
+ ['endpointId', basic.uint8_t],
443
+ // Profile id.
444
+ ['profileId', basic.uint16_t],
445
+ // Device id.
446
+ ['deviceId', basic.uint16_t],
447
+ // Associated version.
448
+ ['version', basic.uint8_t],
449
+ // Number of relevant group ids.
450
+ ['groupIdCount', basic.uint8_t],
451
+ ];
452
+ exports.EmberZllDeviceInfoRecord = EmberZllDeviceInfoRecord;
453
+ class EmberZllAddressAssignment extends EzspStruct {
454
+ }
455
+ // ZLL address assignment data.
456
+ EmberZllAddressAssignment._fields = [
457
+ // Relevant node id.
458
+ ['nodeId', named.EmberNodeId],
459
+ // Minimum free node id.
460
+ ['freeNodeIdMin', named.EmberNodeId],
461
+ // Maximum free node id.
462
+ ['freeNodeIdMax', named.EmberNodeId],
463
+ // Minimum group id.
464
+ ['groupIdMin', named.EmberMulticastId],
465
+ // Maximum group id.
466
+ ['groupIdMax', named.EmberMulticastId],
467
+ // Minimum free group id.
468
+ ['freeGroupIdMin', named.EmberMulticastId],
469
+ // Maximum free group id.
470
+ ['freeGroupIdMax', named.EmberMulticastId],
471
+ ];
472
+ exports.EmberZllAddressAssignment = EmberZllAddressAssignment;
473
+ class EmberTokTypeStackZllData extends EzspStruct {
474
+ }
475
+ // Public API for ZLL stack data token.
476
+ EmberTokTypeStackZllData._fields = [
477
+ // Token bitmask.
478
+ ['bitmask', basic.uint32_t],
479
+ // Minimum free node id.
480
+ ['freeNodeIdMin', basic.uint16_t],
481
+ // Maximum free node id.
482
+ ['freeNodeIdMax', basic.uint16_t],
483
+ // Local minimum group id.
484
+ ['myGroupIdMin', basic.uint16_t],
485
+ // Minimum free group id.
486
+ ['freeGroupIdMin', basic.uint16_t],
487
+ // Maximum free group id.
488
+ ['freeGroupIdMax', basic.uint16_t],
489
+ // RSSI correction value.
490
+ ['rssiCorrection', basic.uint8_t],
491
+ ];
492
+ exports.EmberTokTypeStackZllData = EmberTokTypeStackZllData;
493
+ class EmberTokTypeStackZllSecurity extends EzspStruct {
494
+ }
495
+ // Public API for ZLL stack security token.
496
+ EmberTokTypeStackZllSecurity._fields = [
497
+ // Token bitmask.
498
+ ['bitmask', basic.uint32_t],
499
+ // Key index.
500
+ ['keyIndex', basic.uint8_t],
501
+ // Encryption key.
502
+ ['encryptionKey', basic.fixed_list(16, basic.uint8_t)],
503
+ // Preconfigured key.
504
+ ['preconfiguredKey', basic.fixed_list(16, basic.uint8_t)],
505
+ ];
506
+ exports.EmberTokTypeStackZllSecurity = EmberTokTypeStackZllSecurity;
507
+ class EmberRf4ceVendorInfo extends EzspStruct {
508
+ }
509
+ // The RF4CE vendor information block.
510
+ EmberRf4ceVendorInfo._fields = [
511
+ // The vendor identifier field shall contain the vendor identifier of
512
+ // the node.
513
+ ['vendorId', basic.uint16_t],
514
+ // The vendor string field shall contain the vendor string of the node.
515
+ ['vendorString', basic.fixed_list(7, basic.uint8_t)],
516
+ ];
517
+ exports.EmberRf4ceVendorInfo = EmberRf4ceVendorInfo;
518
+ class EmberRf4ceApplicationInfo extends EzspStruct {
519
+ }
520
+ // The RF4CE application information block.
521
+ EmberRf4ceApplicationInfo._fields = [
522
+ // The application capabilities field shall contain information relating
523
+ // to the capabilities of the application of the node.
524
+ ['capabilities', named.EmberRf4ceApplicationCapabilities],
525
+ // The user string field shall contain the user specified identification
526
+ // string.
527
+ ['userString', basic.fixed_list(15, basic.uint8_t)],
528
+ // The device type list field shall contain the list of device types
529
+ // supported by the node.
530
+ ['deviceTypeList', basic.fixed_list(3, basic.uint8_t)],
531
+ // The profile ID list field shall contain the list of profile
532
+ // identifiers disclosed as supported by the node.
533
+ ['profileIdList', basic.fixed_list(7, basic.uint8_t)],
534
+ ];
535
+ exports.EmberRf4ceApplicationInfo = EmberRf4ceApplicationInfo;
536
+ class EmberRf4cePairingTableEntry extends EzspStruct {
537
+ }
538
+ // The internal representation of an RF4CE pairing table entry.
539
+ EmberRf4cePairingTableEntry._fields = [
540
+ // The link key to be used to secure this pairing link.
541
+ ['securityLinkKey', EmberKeyData],
542
+ // The IEEE address of the destination device.
543
+ ['destLongId', named.EmberEUI64],
544
+ // The frame counter last received from the recipient node.
545
+ ['frameCounter', basic.uint32_t],
546
+ // The network address to be assumed by the source device.
547
+ ['sourceNodeId', named.EmberNodeId],
548
+ // The PAN identifier of the destination device.
549
+ ['destPanId', named.EmberPanId],
550
+ // The network address of the destination device.
551
+ ['destNodeId', named.EmberNodeId],
552
+ // The vendor ID of the destination device.
553
+ ['destVendorId', basic.uint16_t],
554
+ // The list of profiles supported by the destination device.
555
+ ['destProfileIdList', basic.fixed_list(7, basic.uint8_t)],
556
+ // The length of the list of supported profiles.
557
+ ['destProfileIdListLength', basic.uint8_t],
558
+ // Info byte.
559
+ ['info', basic.uint8_t],
560
+ // The expected channel of the destination device.
561
+ ['channel', basic.uint8_t],
562
+ // The node capabilities of the recipient node.
563
+ ['capabilities', basic.uint8_t],
564
+ // Last MAC sequence number seen on this pairing link.
565
+ ['lastSeqn', basic.uint8_t],
566
+ ];
567
+ exports.EmberRf4cePairingTableEntry = EmberRf4cePairingTableEntry;
568
+ class EmberGpAddress extends EzspStruct {
569
+ }
570
+ // A GP address structure.
571
+ EmberGpAddress._fields = [
572
+ // The GPD's EUI64.
573
+ ['gpdIeeeAddress', named.EmberEUI64],
574
+ // The GPD's source ID.
575
+ ['sourceId', basic.uint32_t],
576
+ // The GPD Application ID.
577
+ ['applicationId', basic.uint8_t],
578
+ // The GPD endpoint.
579
+ ['endpoint', basic.uint8_t],
580
+ ];
581
+ exports.EmberGpAddress = EmberGpAddress;
582
+ class EmberGpSinkListEntry extends EzspStruct {
583
+ }
584
+ // A sink list entry
585
+ EmberGpSinkListEntry._fields = [
586
+ // The sink list type.
587
+ ['type', basic.uint8_t],
588
+ // The EUI64 of the target sink.
589
+ ['sinkEUI', named.EmberEUI64],
590
+ // The short address of the target sink.
591
+ ['sinkNodeId', named.EmberNodeId],
592
+ ];
593
+ exports.EmberGpSinkListEntry = EmberGpSinkListEntry;
594
+ class EmberNodeDescriptor extends EzspStruct {
595
+ }
596
+ EmberNodeDescriptor._fields = [
597
+ ['byte1', basic.uint8_t],
598
+ ['byte2', basic.uint8_t],
599
+ ['mac_capability_flags', basic.uint8_t],
600
+ ['manufacturer_code', basic.uint16_t],
601
+ ['maximum_buffer_size', basic.uint8_t],
602
+ ['maximum_incoming_transfer_size', basic.uint16_t],
603
+ ['server_mask', basic.uint16_t],
604
+ ['maximum_outgoing_transfer_size', basic.uint16_t],
605
+ ['descriptor_capability_field', basic.uint8_t],
606
+ ];
607
+ exports.EmberNodeDescriptor = EmberNodeDescriptor;
608
+ class EmberSimpleDescriptor extends EzspStruct {
609
+ }
610
+ EmberSimpleDescriptor._fields = [
611
+ ['endpoint', basic.uint8_t],
612
+ ['profileid', basic.uint16_t],
613
+ ['deviceid', basic.uint16_t],
614
+ ['deviceversion', basic.uint8_t],
615
+ ['inclusterlist', basic.LVList(basic.uint16_t)],
616
+ ['outclusterlist', basic.LVList(basic.uint16_t)],
617
+ ];
618
+ exports.EmberSimpleDescriptor = EmberSimpleDescriptor;
619
+ class EmberMultiAddress extends EzspStruct {
620
+ /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
621
+ static serialize(cls, obj) {
622
+ const addrmode = obj['addrmode'];
623
+ /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
624
+ const fields = (addrmode == 3) ? cls.fields3 : cls.fields1;
625
+ /* eslint-disable-next-line @typescript-eslint/no-explicit-any*/
626
+ return Buffer.concat(fields.map((field) => {
627
+ const value = obj[field[0]];
628
+ console.assert(field[1]);
629
+ return field[1].serialize(field[1], value);
630
+ }));
631
+ }
632
+ }
633
+ EmberMultiAddress.fields3 = [
634
+ ['addrmode', basic.uint8_t],
635
+ ['ieee', named.EmberEUI64],
636
+ ['endpoint', basic.uint8_t],
637
+ ];
638
+ EmberMultiAddress.fields1 = [
639
+ ['addrmode', basic.uint8_t],
640
+ ['nwk', named.EmberNodeId],
641
+ ];
642
+ exports.EmberMultiAddress = EmberMultiAddress;
643
+ class EmberNeighbor extends EzspStruct {
644
+ }
645
+ EmberNeighbor._fields = [
646
+ ['extendedpanid', basic.fixed_list(8, basic.uint8_t)],
647
+ ['ieee', named.EmberEUI64],
648
+ ['nodeid', named.EmberNodeId],
649
+ ['packed', basic.uint8_t],
650
+ ['permitjoining', basic.uint8_t],
651
+ ['depth', basic.uint8_t],
652
+ ['lqi', basic.uint8_t],
653
+ ];
654
+ exports.EmberNeighbor = EmberNeighbor;
655
+ class EmberNeighbors extends EzspStruct {
656
+ }
657
+ EmberNeighbors._fields = [
658
+ ['entries', basic.uint8_t],
659
+ ['startindex', basic.uint8_t],
660
+ ['neighbors', basic.LVList(EmberNeighbor)],
661
+ ];
662
+ exports.EmberNeighbors = EmberNeighbors;
663
+ class EmberRoutingTableEntry extends EzspStruct {
664
+ }
665
+ EmberRoutingTableEntry._fields = [
666
+ ['destination', basic.uint16_t],
667
+ ['status', basic.uint8_t],
668
+ ['nexthop', basic.uint16_t],
669
+ ];
670
+ exports.EmberRoutingTableEntry = EmberRoutingTableEntry;
671
+ class EmberRoutingTable extends EzspStruct {
672
+ }
673
+ EmberRoutingTable._fields = [
674
+ ['entries', basic.uint8_t],
675
+ ['startindex', basic.uint8_t],
676
+ ['table', basic.LVList(EmberRoutingTableEntry)],
677
+ ];
678
+ exports.EmberRoutingTable = EmberRoutingTable;
679
+ class EmberRawFrame extends EzspStruct {
680
+ }
681
+ EmberRawFrame._fields = [
682
+ ['ieeeFrameControl', basic.uint16_t],
683
+ ['sequence', basic.uint8_t],
684
+ ['destPanId', named.EmberPanId],
685
+ ['destNodeId', named.EmberNodeId],
686
+ ['sourcePanId', named.EmberPanId],
687
+ ['ieeeAddress', named.EmberEUI64],
688
+ ['nwkFrameControl', basic.uint16_t],
689
+ ['appFrameControl', basic.uint8_t],
690
+ ['clusterId', basic.uint16_t],
691
+ ['profileId', basic.uint16_t],
692
+ ];
693
+ exports.EmberRawFrame = EmberRawFrame;
694
+ class EmberIeeeRawFrame extends EzspStruct {
695
+ }
696
+ EmberIeeeRawFrame._fields = [
697
+ ['ieeeFrameControl', basic.uint16_t],
698
+ ['sequence', basic.uint8_t],
699
+ ['destPanId', named.EmberPanId],
700
+ ['destAddress', named.EmberEUI64],
701
+ ['sourcePanId', named.EmberPanId],
702
+ ['sourceAddress', named.EmberEUI64],
703
+ ['nwkFrameControl', basic.uint16_t],
704
+ ['appFrameControl', basic.uint8_t],
705
+ ['clusterId', basic.uint16_t],
706
+ ['profileId', basic.uint16_t],
707
+ ];
708
+ exports.EmberIeeeRawFrame = EmberIeeeRawFrame;
709
709
  //# sourceMappingURL=struct.js.map