@willieee802/zigbee-herdsman 0.49.1 → 0.49.2
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/dist/adapter/adapter.d.ts +66 -0
- package/dist/adapter/adapter.js +110 -0
- package/dist/adapter/adapter.js.map +1 -0
- package/dist/adapter/adapterDiscovery.d.ts +34 -0
- package/dist/adapter/adapterDiscovery.js +646 -0
- package/dist/adapter/adapterDiscovery.js.map +1 -0
- package/dist/adapter/const.d.ts +9 -0
- package/dist/adapter/const.js +48 -0
- package/dist/adapter/const.js.map +1 -0
- package/dist/adapter/deconz/adapter/deconzAdapter.d.ts +61 -0
- package/dist/adapter/deconz/adapter/deconzAdapter.js +719 -0
- package/dist/adapter/deconz/adapter/deconzAdapter.js.map +1 -0
- package/dist/adapter/deconz/driver/constants.d.ts +210 -0
- package/dist/adapter/deconz/driver/constants.d.ts.map +1 -0
- package/dist/adapter/deconz/driver/constants.js +139 -0
- package/dist/adapter/deconz/driver/constants.js.map +1 -0
- package/dist/adapter/deconz/driver/driver.d.ts +111 -0
- package/dist/adapter/deconz/driver/driver.d.ts.map +1 -0
- package/dist/adapter/deconz/driver/driver.js +1362 -0
- package/dist/adapter/deconz/driver/driver.js.map +1 -0
- package/dist/adapter/deconz/driver/frame.d.ts +6 -0
- package/dist/adapter/deconz/driver/frame.d.ts.map +1 -0
- package/dist/adapter/deconz/driver/frame.js +13 -0
- package/dist/adapter/deconz/driver/frame.js.map +1 -0
- package/dist/adapter/deconz/driver/frameParser.d.ts +5 -0
- package/dist/adapter/deconz/driver/frameParser.d.ts.map +1 -0
- package/dist/adapter/deconz/driver/frameParser.js +700 -0
- package/dist/adapter/deconz/driver/frameParser.js.map +1 -0
- package/dist/adapter/deconz/driver/parser.d.ts +10 -0
- package/dist/adapter/deconz/driver/parser.d.ts.map +1 -0
- package/dist/adapter/deconz/driver/parser.js +39 -0
- package/dist/adapter/deconz/driver/parser.js.map +1 -0
- package/dist/adapter/deconz/driver/writer.d.ts +8 -0
- package/dist/adapter/deconz/driver/writer.d.ts.map +1 -0
- package/dist/adapter/deconz/driver/writer.js +53 -0
- package/dist/adapter/deconz/driver/writer.js.map +1 -0
- package/dist/adapter/ember/adapter/emberAdapter.d.ts +338 -0
- package/dist/adapter/ember/adapter/emberAdapter.js +1663 -0
- package/dist/adapter/ember/adapter/emberAdapter.js.map +1 -0
- package/dist/adapter/ember/adapter/endpoints.d.ts +27 -0
- package/dist/adapter/ember/adapter/endpoints.js +69 -0
- package/dist/adapter/ember/adapter/endpoints.js.map +1 -0
- package/dist/adapter/ember/adapter/oneWaitress.d.ts +112 -0
- package/dist/adapter/ember/adapter/oneWaitress.js +233 -0
- package/dist/adapter/ember/adapter/oneWaitress.js.map +1 -0
- package/dist/adapter/ember/adapter/tokensManager.d.ts +69 -0
- package/dist/adapter/ember/adapter/tokensManager.js +684 -0
- package/dist/adapter/ember/adapter/tokensManager.js.map +1 -0
- package/dist/adapter/ember/consts.d.ts +107 -0
- package/dist/adapter/ember/consts.d.ts.map +1 -0
- package/dist/adapter/ember/consts.js +155 -0
- package/dist/adapter/ember/consts.js.map +1 -0
- package/dist/adapter/ember/enums.d.ts +1568 -0
- package/dist/adapter/ember/enums.d.ts.map +1 -0
- package/dist/adapter/ember/enums.js +1697 -0
- package/dist/adapter/ember/enums.js.map +1 -0
- package/dist/adapter/ember/ezsp/buffalo.d.ts +166 -0
- package/dist/adapter/ember/ezsp/buffalo.d.ts.map +1 -0
- package/dist/adapter/ember/ezsp/buffalo.js +1133 -0
- package/dist/adapter/ember/ezsp/buffalo.js.map +1 -0
- package/dist/adapter/ember/ezsp/consts.d.ts +117 -0
- package/dist/adapter/ember/ezsp/consts.d.ts.map +1 -0
- package/dist/adapter/ember/ezsp/consts.js +129 -0
- package/dist/adapter/ember/ezsp/consts.js.map +1 -0
- package/dist/adapter/ember/ezsp/enums.d.ts +1016 -0
- package/dist/adapter/ember/ezsp/enums.d.ts.map +1 -0
- package/dist/adapter/ember/ezsp/enums.js +1103 -0
- package/dist/adapter/ember/ezsp/enums.js.map +1 -0
- package/dist/adapter/ember/ezsp/ezsp.d.ts +2951 -0
- package/dist/adapter/ember/ezsp/ezsp.js +7119 -0
- package/dist/adapter/ember/ezsp/ezsp.js.map +1 -0
- package/dist/adapter/ember/ezspError.d.ts +6 -0
- package/dist/adapter/ember/ezspError.d.ts.map +1 -0
- package/dist/adapter/ember/ezspError.js +13 -0
- package/dist/adapter/ember/ezspError.js.map +1 -0
- package/dist/adapter/ember/types.d.ts +787 -0
- package/dist/adapter/ember/types.d.ts.map +1 -0
- package/dist/adapter/ember/types.js +3 -0
- package/dist/adapter/ember/types.js.map +1 -0
- package/dist/adapter/ember/uart/ash.d.ts +434 -0
- package/dist/adapter/ember/uart/ash.d.ts.map +1 -0
- package/dist/adapter/ember/uart/ash.js +1561 -0
- package/dist/adapter/ember/uart/ash.js.map +1 -0
- package/dist/adapter/ember/uart/consts.d.ts +91 -0
- package/dist/adapter/ember/uart/consts.d.ts.map +1 -0
- package/dist/adapter/ember/uart/consts.js +100 -0
- package/dist/adapter/ember/uart/consts.js.map +1 -0
- package/dist/adapter/ember/uart/enums.d.ts +191 -0
- package/dist/adapter/ember/uart/enums.d.ts.map +1 -0
- package/dist/adapter/ember/uart/enums.js +156 -0
- package/dist/adapter/ember/uart/enums.js.map +1 -0
- package/dist/adapter/ember/uart/parser.d.ts +7 -0
- package/dist/adapter/ember/uart/parser.d.ts.map +1 -0
- package/dist/adapter/ember/uart/parser.js +32 -0
- package/dist/adapter/ember/uart/parser.js.map +1 -0
- package/dist/adapter/ember/uart/queues.d.ts +84 -0
- package/dist/adapter/ember/uart/queues.d.ts.map +1 -0
- package/dist/adapter/ember/uart/queues.js +213 -0
- package/dist/adapter/ember/uart/queues.js.map +1 -0
- package/dist/adapter/ember/uart/writer.d.ts +13 -0
- package/dist/adapter/ember/uart/writer.d.ts.map +1 -0
- package/dist/adapter/ember/uart/writer.js +42 -0
- package/dist/adapter/ember/uart/writer.js.map +1 -0
- package/dist/adapter/ember/utils/initters.d.ts +20 -0
- package/dist/adapter/ember/utils/initters.js +92 -0
- package/dist/adapter/ember/utils/initters.js.map +1 -0
- package/dist/adapter/ember/utils/math.d.ts +41 -0
- package/dist/adapter/ember/utils/math.d.ts.map +1 -0
- package/dist/adapter/ember/utils/math.js +80 -0
- package/dist/adapter/ember/utils/math.js.map +1 -0
- package/dist/adapter/events.d.ts +24 -0
- package/dist/adapter/events.js +3 -0
- package/dist/adapter/events.js.map +1 -0
- package/dist/adapter/ezsp/adapter/backup.d.ts +13 -0
- package/dist/adapter/ezsp/adapter/backup.js +89 -0
- package/dist/adapter/ezsp/adapter/backup.js.map +1 -0
- package/dist/adapter/ezsp/adapter/ezspAdapter.d.ts +53 -0
- package/dist/adapter/ezsp/adapter/ezspAdapter.js +464 -0
- package/dist/adapter/ezsp/adapter/ezspAdapter.js.map +1 -0
- package/dist/adapter/ezsp/driver/commands.d.ts +37 -0
- package/dist/adapter/ezsp/driver/commands.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/commands.js +2387 -0
- package/dist/adapter/ezsp/driver/commands.js.map +1 -0
- package/dist/adapter/ezsp/driver/consts.d.ts +11 -0
- package/dist/adapter/ezsp/driver/consts.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/consts.js +14 -0
- package/dist/adapter/ezsp/driver/consts.js.map +1 -0
- package/dist/adapter/ezsp/driver/driver.d.ts +96 -0
- package/dist/adapter/ezsp/driver/driver.js +852 -0
- package/dist/adapter/ezsp/driver/driver.js.map +1 -0
- package/dist/adapter/ezsp/driver/ezsp.d.ts +104 -0
- package/dist/adapter/ezsp/driver/ezsp.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/ezsp.js +678 -0
- package/dist/adapter/ezsp/driver/ezsp.js.map +1 -0
- package/dist/adapter/ezsp/driver/frame.d.ts +39 -0
- package/dist/adapter/ezsp/driver/frame.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/frame.js +101 -0
- package/dist/adapter/ezsp/driver/frame.js.map +1 -0
- package/dist/adapter/ezsp/driver/index.d.ts +4 -0
- package/dist/adapter/ezsp/driver/index.js +8 -0
- package/dist/adapter/ezsp/driver/index.js.map +1 -0
- package/dist/adapter/ezsp/driver/multicast.d.ts +16 -0
- package/dist/adapter/ezsp/driver/multicast.js +74 -0
- package/dist/adapter/ezsp/driver/multicast.js.map +1 -0
- package/dist/adapter/ezsp/driver/parser.d.ts +9 -0
- package/dist/adapter/ezsp/driver/parser.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/parser.js +109 -0
- package/dist/adapter/ezsp/driver/parser.js.map +1 -0
- package/dist/adapter/ezsp/driver/types/basic.d.ts +62 -0
- package/dist/adapter/ezsp/driver/types/basic.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/types/basic.js +187 -0
- package/dist/adapter/ezsp/driver/types/basic.js.map +1 -0
- package/dist/adapter/ezsp/driver/types/index.d.ts +9 -0
- package/dist/adapter/ezsp/driver/types/index.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/types/index.js +137 -0
- package/dist/adapter/ezsp/driver/types/index.js.map +1 -0
- package/dist/adapter/ezsp/driver/types/named.d.ts +1287 -0
- package/dist/adapter/ezsp/driver/types/named.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/types/named.js +2337 -0
- package/dist/adapter/ezsp/driver/types/named.js.map +1 -0
- package/dist/adapter/ezsp/driver/types/struct.d.ts +270 -0
- package/dist/adapter/ezsp/driver/types/struct.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/types/struct.js +869 -0
- package/dist/adapter/ezsp/driver/types/struct.js.map +1 -0
- package/dist/adapter/ezsp/driver/uart.d.ts +46 -0
- package/dist/adapter/ezsp/driver/uart.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/uart.js +390 -0
- package/dist/adapter/ezsp/driver/uart.js.map +1 -0
- package/dist/adapter/ezsp/driver/utils/crc16ccitt.d.ts +5 -0
- package/dist/adapter/ezsp/driver/utils/crc16ccitt.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/utils/crc16ccitt.js +37 -0
- package/dist/adapter/ezsp/driver/utils/crc16ccitt.js.map +1 -0
- package/dist/adapter/ezsp/driver/utils/index.d.ts +5 -0
- package/dist/adapter/ezsp/driver/utils/index.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/utils/index.js +35 -0
- package/dist/adapter/ezsp/driver/utils/index.js.map +1 -0
- package/dist/adapter/ezsp/driver/writer.d.ts +12 -0
- package/dist/adapter/ezsp/driver/writer.d.ts.map +1 -0
- package/dist/adapter/ezsp/driver/writer.js +92 -0
- package/dist/adapter/ezsp/driver/writer.js.map +1 -0
- package/dist/adapter/index.d.ts +4 -0
- package/dist/adapter/index.js +41 -0
- package/dist/adapter/index.js.map +1 -0
- package/dist/adapter/serialPort.d.ts +19 -0
- package/dist/adapter/serialPort.d.ts.map +1 -0
- package/dist/adapter/serialPort.js +51 -0
- package/dist/adapter/serialPort.js.map +1 -0
- package/dist/adapter/tstype.d.ts +52 -0
- package/dist/adapter/tstype.d.ts.map +1 -0
- package/dist/adapter/tstype.js +3 -0
- package/dist/adapter/tstype.js.map +1 -0
- package/dist/adapter/utils.d.ts +8 -0
- package/dist/adapter/utils.d.ts.map +1 -0
- package/dist/adapter/utils.js +42 -0
- package/dist/adapter/utils.js.map +1 -0
- package/dist/adapter/z-stack/adapter/adapter-backup.d.ts +62 -0
- package/dist/adapter/z-stack/adapter/adapter-backup.d.ts.map +1 -0
- package/dist/adapter/z-stack/adapter/adapter-backup.js +469 -0
- package/dist/adapter/z-stack/adapter/adapter-backup.js.map +1 -0
- package/dist/adapter/z-stack/adapter/adapter-nv-memory.d.ts +150 -0
- package/dist/adapter/z-stack/adapter/adapter-nv-memory.d.ts.map +1 -0
- package/dist/adapter/z-stack/adapter/adapter-nv-memory.js +279 -0
- package/dist/adapter/z-stack/adapter/adapter-nv-memory.js.map +1 -0
- package/dist/adapter/z-stack/adapter/endpoints.d.ts +12 -0
- package/dist/adapter/z-stack/adapter/endpoints.js +87 -0
- package/dist/adapter/z-stack/adapter/endpoints.js.map +1 -0
- package/dist/adapter/z-stack/adapter/manager.d.ts +86 -0
- package/dist/adapter/z-stack/adapter/manager.js +493 -0
- package/dist/adapter/z-stack/adapter/manager.js.map +1 -0
- package/dist/adapter/z-stack/adapter/tstype.d.ts +7 -0
- package/dist/adapter/z-stack/adapter/tstype.d.ts.map +1 -0
- package/dist/adapter/z-stack/adapter/tstype.js +10 -0
- package/dist/adapter/z-stack/adapter/tstype.js.map +1 -0
- package/dist/adapter/z-stack/adapter/zStackAdapter.d.ts +85 -0
- package/dist/adapter/z-stack/adapter/zStackAdapter.js +924 -0
- package/dist/adapter/z-stack/adapter/zStackAdapter.js.map +1 -0
- package/dist/adapter/z-stack/constants/af.d.ts +24 -0
- package/dist/adapter/z-stack/constants/af.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/af.js +28 -0
- package/dist/adapter/z-stack/constants/af.js.map +1 -0
- package/dist/adapter/z-stack/constants/common.d.ts +279 -0
- package/dist/adapter/z-stack/constants/common.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/common.js +290 -0
- package/dist/adapter/z-stack/constants/common.js.map +1 -0
- package/dist/adapter/z-stack/constants/dbg.d.ts +23 -0
- package/dist/adapter/z-stack/constants/dbg.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/dbg.js +25 -0
- package/dist/adapter/z-stack/constants/dbg.js.map +1 -0
- package/dist/adapter/z-stack/constants/index.d.ts +11 -0
- package/dist/adapter/z-stack/constants/index.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/index.js +58 -0
- package/dist/adapter/z-stack/constants/index.js.map +1 -0
- package/dist/adapter/z-stack/constants/mac.d.ts +128 -0
- package/dist/adapter/z-stack/constants/mac.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/mac.js +130 -0
- package/dist/adapter/z-stack/constants/mac.js.map +1 -0
- package/dist/adapter/z-stack/constants/sapi.d.ts +25 -0
- package/dist/adapter/z-stack/constants/sapi.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/sapi.js +27 -0
- package/dist/adapter/z-stack/constants/sapi.js.map +1 -0
- package/dist/adapter/z-stack/constants/sys.d.ts +72 -0
- package/dist/adapter/z-stack/constants/sys.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/sys.js +74 -0
- package/dist/adapter/z-stack/constants/sys.js.map +1 -0
- package/dist/adapter/z-stack/constants/util.d.ts +82 -0
- package/dist/adapter/z-stack/constants/util.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/util.js +84 -0
- package/dist/adapter/z-stack/constants/util.js.map +1 -0
- package/dist/adapter/z-stack/constants/utils.d.ts +5 -0
- package/dist/adapter/z-stack/constants/utils.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/utils.js +14 -0
- package/dist/adapter/z-stack/constants/utils.js.map +1 -0
- package/dist/adapter/z-stack/constants/zdo.d.ts +103 -0
- package/dist/adapter/z-stack/constants/zdo.d.ts.map +1 -0
- package/dist/adapter/z-stack/constants/zdo.js +105 -0
- package/dist/adapter/z-stack/constants/zdo.js.map +1 -0
- package/dist/adapter/z-stack/models/startup-options.d.ts +13 -0
- package/dist/adapter/z-stack/models/startup-options.js +3 -0
- package/dist/adapter/z-stack/models/startup-options.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/address-manager-entry.d.ts +23 -0
- package/dist/adapter/z-stack/structs/entries/address-manager-entry.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/address-manager-entry.js +43 -0
- package/dist/adapter/z-stack/structs/entries/address-manager-entry.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/address-manager-table.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/address-manager-table.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/address-manager-table.js +24 -0
- package/dist/adapter/z-stack/structs/entries/address-manager-table.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/aps-link-key-data-entry.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/aps-link-key-data-entry.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/aps-link-key-data-entry.js +16 -0
- package/dist/adapter/z-stack/structs/entries/aps-link-key-data-entry.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/aps-link-key-data-table.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/aps-link-key-data-table.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/aps-link-key-data-table.js +25 -0
- package/dist/adapter/z-stack/structs/entries/aps-link-key-data-table.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-entry.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-entry.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-entry.js +23 -0
- package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-entry.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-table.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-table.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-table.js +25 -0
- package/dist/adapter/z-stack/structs/entries/aps-tc-link-key-table.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/channel-list.d.ts +8 -0
- package/dist/adapter/z-stack/structs/entries/channel-list.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/channel-list.js +12 -0
- package/dist/adapter/z-stack/structs/entries/channel-list.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/has-configured.d.ts +8 -0
- package/dist/adapter/z-stack/structs/entries/has-configured.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/has-configured.js +22 -0
- package/dist/adapter/z-stack/structs/entries/has-configured.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/index.d.ts +17 -0
- package/dist/adapter/z-stack/structs/entries/index.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/index.js +33 -0
- package/dist/adapter/z-stack/structs/entries/index.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nib.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/nib.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nib.js +72 -0
- package/dist/adapter/z-stack/structs/entries/nib.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-key-descriptor.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/nwk-key-descriptor.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-key-descriptor.js +21 -0
- package/dist/adapter/z-stack/structs/entries/nwk-key-descriptor.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-key.d.ts +8 -0
- package/dist/adapter/z-stack/structs/entries/nwk-key.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-key.js +19 -0
- package/dist/adapter/z-stack/structs/entries/nwk-key.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-pan-id.d.ts +8 -0
- package/dist/adapter/z-stack/structs/entries/nwk-pan-id.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-pan-id.js +12 -0
- package/dist/adapter/z-stack/structs/entries/nwk-pan-id.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-entry.d.ts +13 -0
- package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-entry.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-entry.js +22 -0
- package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-entry.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-table.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-table.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-table.js +24 -0
- package/dist/adapter/z-stack/structs/entries/nwk-sec-material-descriptor-table.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/security-manager-entry.d.ts +20 -0
- package/dist/adapter/z-stack/structs/entries/security-manager-entry.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/security-manager-entry.js +35 -0
- package/dist/adapter/z-stack/structs/entries/security-manager-entry.js.map +1 -0
- package/dist/adapter/z-stack/structs/entries/security-manager-table.d.ts +10 -0
- package/dist/adapter/z-stack/structs/entries/security-manager-table.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/entries/security-manager-table.js +25 -0
- package/dist/adapter/z-stack/structs/entries/security-manager-table.js.map +1 -0
- package/dist/adapter/z-stack/structs/index.d.ts +5 -0
- package/dist/adapter/z-stack/structs/index.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/index.js +21 -0
- package/dist/adapter/z-stack/structs/index.js.map +1 -0
- package/dist/adapter/z-stack/structs/serializable-memory-object.d.ts +13 -0
- package/dist/adapter/z-stack/structs/serializable-memory-object.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/serializable-memory-object.js +3 -0
- package/dist/adapter/z-stack/structs/serializable-memory-object.js.map +1 -0
- package/dist/adapter/z-stack/structs/struct.d.ts +99 -0
- package/dist/adapter/z-stack/structs/struct.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/struct.js +308 -0
- package/dist/adapter/z-stack/structs/struct.js.map +1 -0
- package/dist/adapter/z-stack/structs/table.d.ts +94 -0
- package/dist/adapter/z-stack/structs/table.d.ts.map +1 -0
- package/dist/adapter/z-stack/structs/table.js +167 -0
- package/dist/adapter/z-stack/structs/table.js.map +1 -0
- package/dist/adapter/z-stack/unpi/constants.d.ts +29 -0
- package/dist/adapter/z-stack/unpi/constants.d.ts.map +1 -0
- package/dist/adapter/z-stack/unpi/constants.js +40 -0
- package/dist/adapter/z-stack/unpi/constants.js.map +1 -0
- package/dist/adapter/z-stack/unpi/frame.d.ts +15 -0
- package/dist/adapter/z-stack/unpi/frame.d.ts.map +1 -0
- package/dist/adapter/z-stack/unpi/frame.js +53 -0
- package/dist/adapter/z-stack/unpi/frame.js.map +1 -0
- package/dist/adapter/z-stack/unpi/index.d.ts +5 -0
- package/dist/adapter/z-stack/unpi/index.d.ts.map +1 -0
- package/dist/adapter/z-stack/unpi/index.js +44 -0
- package/dist/adapter/z-stack/unpi/index.js.map +1 -0
- package/dist/adapter/z-stack/unpi/parser.d.ts +10 -0
- package/dist/adapter/z-stack/unpi/parser.d.ts.map +1 -0
- package/dist/adapter/z-stack/unpi/parser.js +94 -0
- package/dist/adapter/z-stack/unpi/parser.js.map +1 -0
- package/dist/adapter/z-stack/unpi/writer.d.ts +9 -0
- package/dist/adapter/z-stack/unpi/writer.d.ts.map +1 -0
- package/dist/adapter/z-stack/unpi/writer.js +66 -0
- package/dist/adapter/z-stack/unpi/writer.js.map +1 -0
- package/dist/adapter/z-stack/utils/channel-list.d.ts +21 -0
- package/dist/adapter/z-stack/utils/channel-list.d.ts.map +1 -0
- package/dist/adapter/z-stack/utils/channel-list.js +45 -0
- package/dist/adapter/z-stack/utils/channel-list.js.map +1 -0
- package/dist/adapter/z-stack/utils/index.d.ts +3 -0
- package/dist/adapter/z-stack/utils/index.d.ts.map +1 -0
- package/dist/adapter/z-stack/utils/index.js +19 -0
- package/dist/adapter/z-stack/utils/index.js.map +1 -0
- package/dist/adapter/z-stack/utils/network-options.d.ts +9 -0
- package/dist/adapter/z-stack/utils/network-options.d.ts.map +1 -0
- package/dist/adapter/z-stack/utils/network-options.js +22 -0
- package/dist/adapter/z-stack/utils/network-options.js.map +1 -0
- package/dist/adapter/z-stack/znp/buffaloZnp.d.ts +10 -0
- package/dist/adapter/z-stack/znp/buffaloZnp.d.ts.map +1 -0
- package/dist/adapter/z-stack/znp/buffaloZnp.js +162 -0
- package/dist/adapter/z-stack/znp/buffaloZnp.js.map +1 -0
- package/dist/adapter/z-stack/znp/definition.d.ts +18 -0
- package/dist/adapter/z-stack/znp/definition.d.ts.map +1 -0
- package/dist/adapter/z-stack/znp/definition.js +2703 -0
- package/dist/adapter/z-stack/znp/definition.js.map +1 -0
- package/dist/adapter/z-stack/znp/index.d.ts +3 -0
- package/dist/adapter/z-stack/znp/index.d.ts.map +1 -0
- package/dist/adapter/z-stack/znp/index.js +8 -0
- package/dist/adapter/z-stack/znp/index.js.map +1 -0
- package/dist/adapter/z-stack/znp/parameterType.d.ts +19 -0
- package/dist/adapter/z-stack/znp/parameterType.d.ts.map +1 -0
- package/dist/adapter/z-stack/znp/parameterType.js +22 -0
- package/dist/adapter/z-stack/znp/parameterType.js.map +1 -0
- package/dist/adapter/z-stack/znp/tstype.d.ts +40 -0
- package/dist/adapter/z-stack/znp/tstype.d.ts.map +1 -0
- package/dist/adapter/z-stack/znp/tstype.js +3 -0
- package/dist/adapter/z-stack/znp/tstype.js.map +1 -0
- package/dist/adapter/z-stack/znp/utils.d.ts +4 -0
- package/dist/adapter/z-stack/znp/utils.d.ts.map +1 -0
- package/dist/adapter/z-stack/znp/utils.js +12 -0
- package/dist/adapter/z-stack/znp/utils.js.map +1 -0
- package/dist/adapter/z-stack/znp/znp.d.ts +43 -0
- package/dist/adapter/z-stack/znp/znp.d.ts.map +1 -0
- package/dist/adapter/z-stack/znp/znp.js +295 -0
- package/dist/adapter/z-stack/znp/znp.js.map +1 -0
- package/dist/adapter/z-stack/znp/zpiObject.d.ts +19 -0
- package/dist/adapter/z-stack/znp/zpiObject.d.ts.map +1 -0
- package/dist/adapter/z-stack/znp/zpiObject.js +121 -0
- package/dist/adapter/z-stack/znp/zpiObject.js.map +1 -0
- package/dist/adapter/zboss/adapter/zbossAdapter.d.ts +44 -0
- package/dist/adapter/zboss/adapter/zbossAdapter.js +365 -0
- package/dist/adapter/zboss/adapter/zbossAdapter.js.map +1 -0
- package/dist/adapter/zboss/commands.d.ts +20 -0
- package/dist/adapter/zboss/commands.d.ts.map +1 -0
- package/dist/adapter/zboss/commands.js +1141 -0
- package/dist/adapter/zboss/commands.js.map +1 -0
- package/dist/adapter/zboss/consts.d.ts +9 -0
- package/dist/adapter/zboss/consts.d.ts.map +1 -0
- package/dist/adapter/zboss/consts.js +12 -0
- package/dist/adapter/zboss/consts.js.map +1 -0
- package/dist/adapter/zboss/driver.d.ts +55 -0
- package/dist/adapter/zboss/driver.js +358 -0
- package/dist/adapter/zboss/driver.js.map +1 -0
- package/dist/adapter/zboss/enums.d.ts +301 -0
- package/dist/adapter/zboss/enums.d.ts.map +1 -0
- package/dist/adapter/zboss/enums.js +359 -0
- package/dist/adapter/zboss/enums.js.map +1 -0
- package/dist/adapter/zboss/frame.d.ts +34 -0
- package/dist/adapter/zboss/reader.d.ts +8 -0
- package/dist/adapter/zboss/reader.d.ts.map +1 -0
- package/dist/adapter/zboss/reader.js +59 -0
- package/dist/adapter/zboss/reader.js.map +1 -0
- package/dist/adapter/zboss/types.d.ts +2 -0
- package/dist/adapter/zboss/types.d.ts.map +1 -0
- package/dist/adapter/zboss/types.js +3 -0
- package/dist/adapter/zboss/types.js.map +1 -0
- package/dist/adapter/zboss/uart.d.ts +38 -0
- package/dist/adapter/zboss/uart.js +373 -0
- package/dist/adapter/zboss/uart.js.map +1 -0
- package/dist/adapter/zboss/utils.d.ts +9 -0
- package/dist/adapter/zboss/utils.d.ts.map +1 -0
- package/dist/adapter/zboss/utils.js +56 -0
- package/dist/adapter/zboss/utils.js.map +1 -0
- package/dist/adapter/zboss/writer.d.ts +14 -0
- package/dist/adapter/zboss/writer.d.ts.map +1 -0
- package/dist/adapter/zboss/writer.js +41 -0
- package/dist/adapter/zboss/writer.js.map +1 -0
- package/dist/adapter/zigate/adapter/patchZdoBuffaloBE.d.ts +5 -0
- package/dist/adapter/zigate/adapter/patchZdoBuffaloBE.d.ts.map +1 -0
- package/dist/adapter/zigate/adapter/patchZdoBuffaloBE.js +26 -0
- package/dist/adapter/zigate/adapter/patchZdoBuffaloBE.js.map +1 -0
- package/dist/adapter/zigate/adapter/zigateAdapter.d.ts +63 -0
- package/dist/adapter/zigate/adapter/zigateAdapter.js +462 -0
- package/dist/adapter/zigate/adapter/zigateAdapter.js.map +1 -0
- package/dist/adapter/zigate/driver/buffaloZiGate.d.ts +22 -0
- package/dist/adapter/zigate/driver/commandType.d.ts +42 -0
- package/dist/adapter/zigate/driver/commandType.d.ts.map +1 -0
- package/dist/adapter/zigate/driver/commandType.js +381 -0
- package/dist/adapter/zigate/driver/commandType.js.map +1 -0
- package/dist/adapter/zigate/driver/constants.d.ts +116 -0
- package/dist/adapter/zigate/driver/constants.d.ts.map +1 -0
- package/dist/adapter/zigate/driver/constants.js +147 -0
- package/dist/adapter/zigate/driver/constants.js.map +1 -0
- package/dist/adapter/zigate/driver/frame.d.ts +26 -0
- package/dist/adapter/zigate/driver/frame.d.ts.map +1 -0
- package/dist/adapter/zigate/driver/frame.js +161 -0
- package/dist/adapter/zigate/driver/frame.js.map +1 -0
- package/dist/adapter/zigate/driver/messageType.d.ts +13 -0
- package/dist/adapter/zigate/driver/messageType.d.ts.map +1 -0
- package/dist/adapter/zigate/driver/messageType.js +281 -0
- package/dist/adapter/zigate/driver/messageType.js.map +1 -0
- package/dist/adapter/zigate/driver/parameterType.d.ts +25 -0
- package/dist/adapter/zigate/driver/parameterType.d.ts.map +1 -0
- package/dist/adapter/zigate/driver/parameterType.js +31 -0
- package/dist/adapter/zigate/driver/parameterType.js.map +1 -0
- package/dist/adapter/zigate/driver/ziGateObject.d.ts +23 -0
- package/dist/adapter/zigate/driver/ziGateObject.js +117 -0
- package/dist/adapter/zigate/driver/ziGateObject.js.map +1 -0
- package/dist/adapter/zigate/driver/zigate.d.ts +47 -0
- package/dist/adapter/zigate/driver/zigate.js +364 -0
- package/dist/adapter/zigate/driver/zigate.js.map +1 -0
- package/dist/adapter/zoh/adapter/utils.d.ts +16 -0
- package/dist/adapter/zoh/adapter/utils.d.ts.map +1 -0
- package/dist/adapter/zoh/adapter/utils.js +31 -0
- package/dist/adapter/zoh/adapter/utils.js.map +1 -0
- package/dist/adapter/zoh/adapter/zohAdapter.d.ts +100 -0
- package/dist/adapter/zoh/adapter/zohAdapter.js +715 -0
- package/dist/adapter/zoh/adapter/zohAdapter.js.map +1 -0
- package/dist/buffalo/buffalo.d.ts +67 -0
- package/dist/buffalo/buffalo.d.ts.map +1 -0
- package/dist/buffalo/buffalo.js +275 -0
- package/dist/buffalo/buffalo.js.map +1 -0
- package/dist/buffalo/index.d.ts +2 -0
- package/dist/buffalo/index.d.ts.map +1 -0
- package/dist/buffalo/index.js +6 -0
- package/dist/buffalo/index.js.map +1 -0
- package/dist/controller/controller.d.ts +155 -0
- package/dist/controller/database.d.ts +21 -0
- package/dist/controller/database.js +128 -0
- package/dist/controller/database.js.map +1 -0
- package/dist/controller/events.d.ts +44 -0
- package/dist/controller/greenPower.d.ts +78 -0
- package/dist/controller/helpers/index.d.ts +2 -0
- package/dist/controller/helpers/index.js +38 -0
- package/dist/controller/helpers/index.js.map +1 -0
- package/dist/controller/helpers/installCodes.d.ts +27 -0
- package/dist/controller/helpers/installCodes.d.ts.map +1 -0
- package/dist/controller/helpers/installCodes.js +90 -0
- package/dist/controller/helpers/installCodes.js.map +1 -0
- package/dist/controller/helpers/ota.d.ts +53 -0
- package/dist/controller/helpers/request.d.ts +22 -0
- package/dist/controller/helpers/request.js +82 -0
- package/dist/controller/helpers/request.js.map +1 -0
- package/dist/controller/helpers/requestQueue.d.ts +13 -0
- package/dist/controller/helpers/requestQueue.js +109 -0
- package/dist/controller/helpers/requestQueue.js.map +1 -0
- package/dist/controller/helpers/zclFrameConverter.d.ts +7 -0
- package/dist/controller/helpers/zclTransactionSequenceNumber.d.ts +8 -0
- package/dist/controller/helpers/zclTransactionSequenceNumber.d.ts.map +1 -0
- package/dist/controller/helpers/zclTransactionSequenceNumber.js +14 -0
- package/dist/controller/helpers/zclTransactionSequenceNumber.js.map +1 -0
- package/dist/controller/index.d.ts +6 -0
- package/dist/controller/index.js +9 -0
- package/dist/controller/index.js.map +1 -0
- package/dist/controller/model/device.d.ts +150 -0
- package/dist/controller/model/endpoint.d.ts +150 -0
- package/dist/controller/model/entity.d.ts +18 -0
- package/dist/controller/model/entity.js +35 -0
- package/dist/controller/model/entity.js.map +1 -0
- package/dist/controller/model/group.d.ts +50 -0
- package/dist/controller/model/index.d.ts +6 -0
- package/dist/controller/model/index.js +14 -0
- package/dist/controller/model/index.js.map +1 -0
- package/dist/controller/model/konnextConfig.d.ts +7 -0
- package/dist/controller/model/konnextConfig.d.ts.map +1 -0
- package/dist/controller/model/konnextConfig.js +3 -0
- package/dist/controller/model/konnextConfig.js.map +1 -0
- package/dist/controller/model/zigbeeEntity.d.ts +8 -0
- package/dist/controller/model/zigbeeEntity.js +11 -0
- package/dist/controller/model/zigbeeEntity.js.map +1 -0
- package/dist/controller/touchlink.d.ts +20 -0
- package/dist/controller/touchlink.js +169 -0
- package/dist/controller/touchlink.js.map +1 -0
- package/dist/controller/tstype.d.ts +152 -0
- package/dist/index.d.ts +13 -0
- package/dist/index.js +54 -0
- package/dist/index.js.map +1 -0
- package/dist/models/backup-storage-legacy.d.ts +25 -0
- package/dist/models/backup-storage-legacy.d.ts.map +1 -0
- package/dist/models/backup-storage-legacy.js +3 -0
- package/dist/models/backup-storage-legacy.js.map +1 -0
- package/dist/models/backup-storage-unified.d.ts +50 -0
- package/dist/models/backup-storage-unified.d.ts.map +1 -0
- package/dist/models/backup-storage-unified.js +3 -0
- package/dist/models/backup-storage-unified.js.map +1 -0
- package/dist/models/backup.d.ts +37 -0
- package/dist/models/backup.d.ts.map +1 -0
- package/dist/models/backup.js +3 -0
- package/dist/models/backup.js.map +1 -0
- package/dist/models/index.d.ts +5 -0
- package/dist/models/index.d.ts.map +1 -0
- package/dist/models/index.js +22 -0
- package/dist/models/index.js.map +1 -0
- package/dist/models/network-options.d.ts +12 -0
- package/dist/models/network-options.d.ts.map +1 -0
- package/dist/models/network-options.js +3 -0
- package/dist/models/network-options.js.map +1 -0
- package/dist/utils/aes.d.ts +40 -0
- package/dist/utils/aes.d.ts.map +1 -0
- package/dist/utils/aes.js +207 -0
- package/dist/utils/aes.js.map +1 -0
- package/dist/utils/async-mutex.d.ts +7 -0
- package/dist/utils/async-mutex.d.ts.map +1 -0
- package/dist/utils/async-mutex.js +31 -0
- package/dist/utils/async-mutex.js.map +1 -0
- package/dist/utils/backup.d.ts +21 -0
- package/dist/utils/backup.d.ts.map +1 -0
- package/dist/utils/backup.js +179 -0
- package/dist/utils/backup.js.map +1 -0
- package/dist/utils/index.d.ts +6 -0
- package/dist/utils/index.d.ts.map +1 -0
- package/dist/utils/index.js +45 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/logger.d.ts +9 -0
- package/dist/utils/logger.d.ts.map +1 -0
- package/dist/utils/logger.js +14 -0
- package/dist/utils/logger.js.map +1 -0
- package/dist/utils/patchBigIntSerialization.d.ts +2 -0
- package/dist/utils/patchBigIntSerialization.d.ts.map +1 -0
- package/dist/utils/patchBigIntSerialization.js +9 -0
- package/dist/utils/patchBigIntSerialization.js.map +1 -0
- package/dist/utils/queue.d.ts +8 -0
- package/dist/utils/queue.d.ts.map +1 -0
- package/dist/utils/queue.js +67 -0
- package/dist/utils/queue.js.map +1 -0
- package/dist/utils/timeService.d.ts +6 -0
- package/dist/utils/utils.d.ts +5 -0
- package/dist/utils/utils.d.ts.map +1 -0
- package/dist/utils/utils.js +24 -0
- package/dist/utils/utils.js.map +1 -0
- package/dist/utils/wait.d.ts +2 -0
- package/dist/utils/wait.d.ts.map +1 -0
- package/dist/utils/wait.js +9 -0
- package/dist/utils/wait.js.map +1 -0
- package/dist/utils/waitress.d.ts +23 -0
- package/dist/utils/waitress.d.ts.map +1 -0
- package/dist/utils/waitress.js +76 -0
- package/dist/utils/waitress.js.map +1 -0
- package/dist/zspec/consts.d.ts +75 -0
- package/dist/zspec/consts.d.ts.map +1 -0
- package/dist/zspec/consts.js +79 -0
- package/dist/zspec/consts.js.map +1 -0
- package/dist/zspec/enums.d.ts +19 -0
- package/dist/zspec/enums.d.ts.map +1 -0
- package/dist/zspec/enums.js +27 -0
- package/dist/zspec/enums.js.map +1 -0
- package/dist/zspec/index.d.ts +4 -0
- package/dist/zspec/index.d.ts.map +1 -0
- package/dist/zspec/index.js +43 -0
- package/dist/zspec/index.js.map +1 -0
- package/dist/zspec/tstypes.d.ts +19 -0
- package/dist/zspec/tstypes.d.ts.map +1 -0
- package/dist/zspec/tstypes.js +3 -0
- package/dist/zspec/tstypes.js.map +1 -0
- package/dist/zspec/utils.d.ts +77 -0
- package/dist/zspec/utils.d.ts.map +1 -0
- package/dist/zspec/utils.js +217 -0
- package/dist/zspec/utils.js.map +1 -0
- package/dist/zspec/zcl/buffaloZcl.d.ts +43 -0
- package/dist/zspec/zcl/definition/cluster.d.ts +3 -0
- package/dist/zspec/zcl/definition/consts.d.ts +9 -0
- package/dist/zspec/zcl/definition/consts.d.ts.map +1 -0
- package/dist/zspec/zcl/definition/consts.js +27 -0
- package/dist/zspec/zcl/definition/consts.js.map +1 -0
- package/dist/zspec/zcl/definition/datatypes.d.ts +2173 -0
- package/dist/zspec/zcl/definition/datatypes.d.ts.map +1 -0
- package/dist/zspec/zcl/definition/datatypes.js +2315 -0
- package/dist/zspec/zcl/definition/datatypes.js.map +1 -0
- package/dist/zspec/zcl/definition/enums.d.ts +205 -0
- package/dist/zspec/zcl/definition/enums.d.ts.map +1 -0
- package/dist/zspec/zcl/definition/enums.js +218 -0
- package/dist/zspec/zcl/definition/enums.js.map +1 -0
- package/dist/zspec/zcl/definition/foundation.d.ts +10 -0
- package/dist/zspec/zcl/definition/manufacturerCode.d.ts +729 -0
- package/dist/zspec/zcl/definition/manufacturerCode.d.ts.map +1 -0
- package/dist/zspec/zcl/definition/manufacturerCode.js +734 -0
- package/dist/zspec/zcl/definition/manufacturerCode.js.map +1 -0
- package/dist/zspec/zcl/definition/status.d.ts +69 -0
- package/dist/zspec/zcl/definition/status.d.ts.map +1 -0
- package/dist/zspec/zcl/definition/status.js +74 -0
- package/dist/zspec/zcl/definition/status.js.map +1 -0
- package/dist/zspec/zcl/index.d.ts +12 -0
- package/dist/zspec/zcl/utils.d.ts +15 -0
- package/dist/zspec/zcl/zclFrame.d.ts +49 -0
- package/dist/zspec/zcl/zclHeader.d.ts +16 -0
- package/dist/zspec/zcl/zclStatusError.d.ts +6 -0
- package/dist/zspec/zcl/zclStatusError.d.ts.map +1 -0
- package/dist/zspec/zcl/zclStatusError.js +13 -0
- package/dist/zspec/zcl/zclStatusError.js.map +1 -0
- package/dist/zspec/zdo/buffaloZdo.d.ts +407 -0
- package/dist/zspec/zdo/buffaloZdo.d.ts.map +1 -0
- package/dist/zspec/zdo/buffaloZdo.js +1919 -0
- package/dist/zspec/zdo/buffaloZdo.js.map +1 -0
- package/dist/zspec/zdo/definition/clusters.d.ts +624 -0
- package/dist/zspec/zdo/definition/clusters.d.ts.map +1 -0
- package/dist/zspec/zdo/definition/clusters.js +686 -0
- package/dist/zspec/zdo/definition/clusters.js.map +1 -0
- package/dist/zspec/zdo/definition/consts.d.ts +13 -0
- package/dist/zspec/zdo/definition/consts.d.ts.map +1 -0
- package/dist/zspec/zdo/definition/consts.js +16 -0
- package/dist/zspec/zdo/definition/consts.js.map +1 -0
- package/dist/zspec/zdo/definition/enums.d.ts +85 -0
- package/dist/zspec/zdo/definition/enums.d.ts.map +1 -0
- package/dist/zspec/zdo/definition/enums.js +103 -0
- package/dist/zspec/zdo/definition/enums.js.map +1 -0
- package/dist/zspec/zdo/definition/status.d.ts +99 -0
- package/dist/zspec/zdo/definition/status.d.ts.map +1 -0
- package/dist/zspec/zdo/definition/status.js +108 -0
- package/dist/zspec/zdo/definition/status.js.map +1 -0
- package/dist/zspec/zdo/definition/tstypes.d.ts +955 -0
- package/dist/zspec/zdo/definition/tstypes.d.ts.map +1 -0
- package/dist/zspec/zdo/definition/tstypes.js +4 -0
- package/dist/zspec/zdo/definition/tstypes.js.map +1 -0
- package/dist/zspec/zdo/index.d.ts +8 -0
- package/dist/zspec/zdo/index.d.ts.map +1 -0
- package/dist/zspec/zdo/index.js +51 -0
- package/dist/zspec/zdo/index.js.map +1 -0
- package/dist/zspec/zdo/utils.d.ts +24 -0
- package/dist/zspec/zdo/utils.d.ts.map +1 -0
- package/dist/zspec/zdo/utils.js +74 -0
- package/dist/zspec/zdo/utils.js.map +1 -0
- package/dist/zspec/zdo/zdoStatusError.d.ts +6 -0
- package/dist/zspec/zdo/zdoStatusError.d.ts.map +1 -0
- package/dist/zspec/zdo/zdoStatusError.js +13 -0
- package/dist/zspec/zdo/zdoStatusError.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,1133 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* v8 ignore start */
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.EzspBuffalo = void 0;
|
|
8
|
+
const buffalo_1 = __importDefault(require("../../../buffalo/buffalo"));
|
|
9
|
+
const consts_1 = require("../consts");
|
|
10
|
+
const enums_1 = require("../enums");
|
|
11
|
+
const math_1 = require("../utils/math");
|
|
12
|
+
const consts_2 = require("./consts");
|
|
13
|
+
/**
|
|
14
|
+
* Handle EmberStatus deprecation in v14+ for previous versions
|
|
15
|
+
*/
|
|
16
|
+
const EMBER_TO_SL_STATUS_MAP = new Map([
|
|
17
|
+
[0x02 /*BAD_ARGUMENT*/, enums_1.SLStatus.INVALID_PARAMETER],
|
|
18
|
+
[0x18 /*NO_BUFFERS*/, enums_1.SLStatus.ALLOCATION_FAILED],
|
|
19
|
+
[0x19 /*PACKET_HANDOFF_DROP_PACKET*/, enums_1.SLStatus.ZIGBEE_PACKET_HANDOFF_DROPPED],
|
|
20
|
+
[0x66 /*DELIVERY_FAILED*/, enums_1.SLStatus.ZIGBEE_DELIVERY_FAILED],
|
|
21
|
+
[0x70 /*INVALID_CALL*/, enums_1.SLStatus.INVALID_STATE],
|
|
22
|
+
[0x72 /*MAX_MESSAGE_LIMIT_REACHED*/, enums_1.SLStatus.ZIGBEE_MAX_MESSAGE_LIMIT_REACHED],
|
|
23
|
+
[0x74 /*MESSAGE_TOO_LONG*/, enums_1.SLStatus.MESSAGE_TOO_LONG],
|
|
24
|
+
[0x75 /*BINDING_IS_ACTIVE*/, enums_1.SLStatus.ZIGBEE_BINDING_IS_ACTIVE],
|
|
25
|
+
[0x76 /*ADDRESS_TABLE_ENTRY_IS_ACTIVE*/, enums_1.SLStatus.ZIGBEE_ADDRESS_TABLE_ENTRY_IS_ACTIVE],
|
|
26
|
+
[0x90 /*NETWORK_UP*/, enums_1.SLStatus.NETWORK_UP],
|
|
27
|
+
[0x91 /*NETWORK_DOWN*/, enums_1.SLStatus.NETWORK_DOWN],
|
|
28
|
+
[0x93 /*NOT_JOINED*/, enums_1.SLStatus.NOT_JOINED],
|
|
29
|
+
[0x95 /*INVALID_SECURITY_LEVEL*/, enums_1.SLStatus.ZIGBEE_INVALID_SECURITY_LEVEL],
|
|
30
|
+
[0x96 /*MOVE_FAILED*/, enums_1.SLStatus.ZIGBEE_MOVE_FAILED],
|
|
31
|
+
[0x99 /*NODE_ID_CHANGED*/, enums_1.SLStatus.ZIGBEE_NODE_ID_CHANGED],
|
|
32
|
+
[0x9a /*PAN_ID_CHANGED*/, enums_1.SLStatus.ZIGBEE_PAN_ID_CHANGED],
|
|
33
|
+
[0x9b /*CHANNEL_CHANGED*/, enums_1.SLStatus.ZIGBEE_CHANNEL_CHANGED],
|
|
34
|
+
[0x9c /*NETWORK_OPENED*/, enums_1.SLStatus.ZIGBEE_NETWORK_OPENED],
|
|
35
|
+
[0x9d /*NETWORK_CLOSED*/, enums_1.SLStatus.ZIGBEE_NETWORK_CLOSED],
|
|
36
|
+
[0xa1 /*NETWORK_BUSY*/, enums_1.SLStatus.BUSY],
|
|
37
|
+
[0xa4 /*BINDING_HAS_CHANGED*/, enums_1.SLStatus.ZIGBEE_BINDING_HAS_CHANGED],
|
|
38
|
+
[0xa5 /*INSUFFICIENT_RANDOM_DATA*/, enums_1.SLStatus.ZIGBEE_INSUFFICIENT_RANDOM_DATA],
|
|
39
|
+
[0xa6 /*APS_ENCRYPTION_ERROR*/, enums_1.SLStatus.ZIGBEE_APS_ENCRYPTION_ERROR],
|
|
40
|
+
[0xa9 /*SOURCE_ROUTE_FAILURE*/, enums_1.SLStatus.ZIGBEE_SOURCE_ROUTE_FAILURE],
|
|
41
|
+
[0xa8 /*SECURITY_STATE_NOT_SET*/, enums_1.SLStatus.ZIGBEE_SECURITY_STATE_NOT_SET],
|
|
42
|
+
[0xaa /*MANY_TO_ONE_ROUTE_FAILURE*/, enums_1.SLStatus.ZIGBEE_MANY_TO_ONE_ROUTE_FAILURE],
|
|
43
|
+
[0xac /*RECEIVED_KEY_IN_THE_CLEAR*/, enums_1.SLStatus.ZIGBEE_RECEIVED_KEY_IN_THE_CLEAR],
|
|
44
|
+
[0xad /*NO_NETWORK_KEY_RECEIVED*/, enums_1.SLStatus.ZIGBEE_NO_NETWORK_KEY_RECEIVED],
|
|
45
|
+
[0xae /*NO_LINK_KEY_RECEIVED*/, enums_1.SLStatus.ZIGBEE_NO_LINK_KEY_RECEIVED],
|
|
46
|
+
[0xaf /*PRECONFIGURED_KEY_REQUIRED*/, enums_1.SLStatus.ZIGBEE_PRECONFIGURED_KEY_REQUIRED],
|
|
47
|
+
[0xb0 /*STACK_AND_HARDWARE_MISMATCH*/, enums_1.SLStatus.ZIGBEE_STACK_AND_HARDWARE_MISMATCH],
|
|
48
|
+
[0xb5 /*LIBRARY_NOT_PRESENT*/, enums_1.SLStatus.NOT_AVAILABLE],
|
|
49
|
+
[0xb8 /*TOO_SOON_FOR_SWITCH_KEY*/, enums_1.SLStatus.ZIGBEE_TOO_SOON_FOR_SWITCH_KEY],
|
|
50
|
+
[0xb9 /*SIGNATURE_VERIFY_FAILURE*/, enums_1.SLStatus.ZIGBEE_SIGNATURE_VERIFY_FAILURE],
|
|
51
|
+
[0xbb /*KEY_NOT_AUTHORIZED*/, enums_1.SLStatus.ZIGBEE_KEY_NOT_AUTHORIZED],
|
|
52
|
+
[0xbc /*TRUST_CENTER_EUI_HAS_CHANGED*/, enums_1.SLStatus.ZIGBEE_TRUST_CENTER_SWAP_EUI_HAS_CHANGED],
|
|
53
|
+
[0xbe /*IEEE_ADDRESS_DISCOVERY_IN_PROGRESS*/, enums_1.SLStatus.ZIGBEE_IEEE_ADDRESS_DISCOVERY_IN_PROGRESS],
|
|
54
|
+
[0xbf /*TRUST_CENTER_SWAPPED_OUT_EUI_HAS_NOT_CHANGED*/, enums_1.SLStatus.ZIGBEE_TRUST_CENTER_SWAP_EUI_HAS_NOT_CHANGED],
|
|
55
|
+
]);
|
|
56
|
+
class EzspBuffalo extends buffalo_1.default {
|
|
57
|
+
getBufferLength() {
|
|
58
|
+
return this.buffer.length;
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Set the byte at given position without affecting the internal position tracker.
|
|
62
|
+
* @param position
|
|
63
|
+
* @param value
|
|
64
|
+
*/
|
|
65
|
+
setCommandByte(position, value) {
|
|
66
|
+
this.buffer.writeUInt8(value, position);
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Get the byte at given position without affecting the internal position tracker.
|
|
70
|
+
* @param position
|
|
71
|
+
* @returns
|
|
72
|
+
*/
|
|
73
|
+
getCommandByte(position) {
|
|
74
|
+
return this.buffer.readUInt8(position);
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Get the byte at given position without affecting the internal position tracker.
|
|
78
|
+
* @param position
|
|
79
|
+
* @returns
|
|
80
|
+
*/
|
|
81
|
+
getResponseByte(position) {
|
|
82
|
+
return this.buffer.readUInt8(position);
|
|
83
|
+
}
|
|
84
|
+
getExtFrameControl() {
|
|
85
|
+
return (this.getResponseByte(consts_2.EZSP_EXTENDED_FRAME_CONTROL_HB_INDEX) << 8) | this.getResponseByte(consts_2.EZSP_EXTENDED_FRAME_CONTROL_LB_INDEX);
|
|
86
|
+
}
|
|
87
|
+
getExtFrameId() {
|
|
88
|
+
return (this.getResponseByte(consts_2.EZSP_EXTENDED_FRAME_ID_HB_INDEX) << 8) | this.getResponseByte(consts_2.EZSP_EXTENDED_FRAME_ID_LB_INDEX);
|
|
89
|
+
}
|
|
90
|
+
getFrameId() {
|
|
91
|
+
if ((this.getResponseByte(consts_2.EZSP_EXTENDED_FRAME_CONTROL_HB_INDEX) & consts_2.EZSP_EXTENDED_FRAME_FORMAT_VERSION_MASK) ===
|
|
92
|
+
consts_2.EZSP_EXTENDED_FRAME_FORMAT_VERSION) {
|
|
93
|
+
return this.getExtFrameId();
|
|
94
|
+
}
|
|
95
|
+
return this.getResponseByte(consts_2.EZSP_FRAME_ID_INDEX);
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Get the frame control, ID and params index according to format version.
|
|
99
|
+
* Throws if frame control is unsupported (using reserved).
|
|
100
|
+
* @returns Anything but SUCCESS should stop further processing.
|
|
101
|
+
*/
|
|
102
|
+
getResponseMetadata() {
|
|
103
|
+
let status = enums_1.EzspStatus.SUCCESS;
|
|
104
|
+
let frameControl;
|
|
105
|
+
let frameId;
|
|
106
|
+
let parametersIndex;
|
|
107
|
+
if ((this.getResponseByte(consts_2.EZSP_EXTENDED_FRAME_CONTROL_HB_INDEX) & consts_2.EZSP_EXTENDED_FRAME_FORMAT_VERSION_MASK) ===
|
|
108
|
+
consts_2.EZSP_EXTENDED_FRAME_FORMAT_VERSION) {
|
|
109
|
+
// use extended ezsp frame format
|
|
110
|
+
frameControl = this.getExtFrameControl();
|
|
111
|
+
frameId = this.getExtFrameId();
|
|
112
|
+
parametersIndex = consts_2.EZSP_EXTENDED_PARAMETERS_INDEX;
|
|
113
|
+
if ((0, math_1.highByte)(frameControl) & consts_2.EZSP_EXTENDED_FRAME_CONTROL_RESERVED_MASK) {
|
|
114
|
+
// reject if unsupported frame
|
|
115
|
+
status = enums_1.EzspStatus.ERROR_UNSUPPORTED_CONTROL;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
else {
|
|
119
|
+
// use legacy ezsp frame format
|
|
120
|
+
frameControl = this.getResponseByte(consts_2.EZSP_FRAME_CONTROL_INDEX);
|
|
121
|
+
frameId = this.getResponseByte(consts_2.EZSP_FRAME_ID_INDEX);
|
|
122
|
+
parametersIndex = consts_2.EZSP_PARAMETERS_INDEX;
|
|
123
|
+
}
|
|
124
|
+
return [status, frameControl, frameId, parametersIndex];
|
|
125
|
+
}
|
|
126
|
+
/**
|
|
127
|
+
* Get a copy of the rest of the buffer (from current position to end).
|
|
128
|
+
* WARNING: Make sure the length is appropriate, if alloc'ed longer, it will return everything until the end.
|
|
129
|
+
* @returns
|
|
130
|
+
*/
|
|
131
|
+
readRest() {
|
|
132
|
+
return Buffer.from(this.buffer.subarray(this.position));
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* This is mostly used for payload/encryption stuff.
|
|
136
|
+
* Copies the buffer to avoid memory referencing issues since Ezsp has a single buffer allocated.
|
|
137
|
+
* @param length
|
|
138
|
+
* @returns
|
|
139
|
+
*/
|
|
140
|
+
readBufferCopy(length) {
|
|
141
|
+
return Buffer.from(this.readBuffer(length));
|
|
142
|
+
}
|
|
143
|
+
/**
|
|
144
|
+
* Write a uint8_t for payload length, followed by payload buffer (copied at post-length position).
|
|
145
|
+
*
|
|
146
|
+
* WARNING: `payload` must have a valid length (as in, not a Buffer allocated to longer length).
|
|
147
|
+
* Should be passed with getWritten() in most cases.
|
|
148
|
+
* @param payload
|
|
149
|
+
*/
|
|
150
|
+
writePayload(payload) {
|
|
151
|
+
this.writeUInt8(payload.length);
|
|
152
|
+
this.position += payload.copy(this.buffer, this.position);
|
|
153
|
+
}
|
|
154
|
+
/**
|
|
155
|
+
* Read a uint8_t for payload length, followed by payload buffer (using post-length position).
|
|
156
|
+
* @returns
|
|
157
|
+
*/
|
|
158
|
+
readPayload() {
|
|
159
|
+
const messageLength = this.readUInt8();
|
|
160
|
+
return this.readBufferCopy(messageLength);
|
|
161
|
+
}
|
|
162
|
+
writeEmberNetworkParameters(value) {
|
|
163
|
+
this.writeListUInt8(value.extendedPanId);
|
|
164
|
+
this.writeUInt16(value.panId);
|
|
165
|
+
this.writeUInt8(value.radioTxPower);
|
|
166
|
+
this.writeUInt8(value.radioChannel);
|
|
167
|
+
this.writeUInt8(value.joinMethod);
|
|
168
|
+
this.writeUInt16(value.nwkManagerId);
|
|
169
|
+
this.writeUInt8(value.nwkUpdateId);
|
|
170
|
+
this.writeUInt32(value.channels);
|
|
171
|
+
}
|
|
172
|
+
readEmberNetworkParameters() {
|
|
173
|
+
const extendedPanId = this.readListUInt8(consts_2.EXTENDED_PAN_ID_SIZE);
|
|
174
|
+
const panId = this.readUInt16();
|
|
175
|
+
const radioTxPower = this.readUInt8();
|
|
176
|
+
const radioChannel = this.readUInt8();
|
|
177
|
+
const joinMethod = this.readUInt8();
|
|
178
|
+
const nwkManagerId = this.readUInt16();
|
|
179
|
+
const nwkUpdateId = this.readUInt8();
|
|
180
|
+
const channels = this.readUInt32();
|
|
181
|
+
return {
|
|
182
|
+
extendedPanId,
|
|
183
|
+
panId,
|
|
184
|
+
radioTxPower,
|
|
185
|
+
radioChannel,
|
|
186
|
+
joinMethod,
|
|
187
|
+
nwkManagerId,
|
|
188
|
+
nwkUpdateId,
|
|
189
|
+
channels,
|
|
190
|
+
};
|
|
191
|
+
}
|
|
192
|
+
writeEmberMultiPhyRadioParameters(value) {
|
|
193
|
+
this.writeUInt8(value.radioTxPower);
|
|
194
|
+
this.writeUInt8(value.radioPage);
|
|
195
|
+
this.writeUInt8(value.radioChannel);
|
|
196
|
+
}
|
|
197
|
+
readEmberMultiPhyRadioParameters() {
|
|
198
|
+
const radioTxPower = this.readUInt8();
|
|
199
|
+
const radioPage = this.readUInt8();
|
|
200
|
+
const radioChannel = this.readUInt8();
|
|
201
|
+
return { radioTxPower, radioPage, radioChannel };
|
|
202
|
+
}
|
|
203
|
+
writeEmberApsFrame(value) {
|
|
204
|
+
this.writeUInt16(value.profileId);
|
|
205
|
+
this.writeUInt16(value.clusterId);
|
|
206
|
+
this.writeUInt8(value.sourceEndpoint);
|
|
207
|
+
this.writeUInt8(value.destinationEndpoint);
|
|
208
|
+
this.writeUInt16(value.options);
|
|
209
|
+
this.writeUInt16(value.groupId);
|
|
210
|
+
this.writeUInt8(value.sequence);
|
|
211
|
+
// this.writeUInt8(value.radius);// XXX: not in gecko_sdk, appended with separate param
|
|
212
|
+
}
|
|
213
|
+
readEmberApsFrame() {
|
|
214
|
+
const profileId = this.readUInt16();
|
|
215
|
+
const clusterId = this.readUInt16();
|
|
216
|
+
const sourceEndpoint = this.readUInt8();
|
|
217
|
+
const destinationEndpoint = this.readUInt8();
|
|
218
|
+
const options = this.readUInt16();
|
|
219
|
+
const groupId = this.readUInt16();
|
|
220
|
+
const sequence = this.readUInt8();
|
|
221
|
+
// const radius = this.readUInt8();// XXX: not in gecko_sdk, appended with separate param
|
|
222
|
+
return {
|
|
223
|
+
profileId,
|
|
224
|
+
clusterId,
|
|
225
|
+
sourceEndpoint,
|
|
226
|
+
destinationEndpoint,
|
|
227
|
+
options,
|
|
228
|
+
groupId,
|
|
229
|
+
sequence,
|
|
230
|
+
// radius,
|
|
231
|
+
};
|
|
232
|
+
}
|
|
233
|
+
writeEmberBindingTableEntry(value) {
|
|
234
|
+
this.writeUInt8(value.type);
|
|
235
|
+
this.writeUInt8(value.local);
|
|
236
|
+
this.writeUInt16(value.clusterId);
|
|
237
|
+
this.writeUInt8(value.remote);
|
|
238
|
+
this.writeIeeeAddr(value.identifier);
|
|
239
|
+
this.writeUInt8(value.networkIndex);
|
|
240
|
+
}
|
|
241
|
+
readEmberBindingTableEntry() {
|
|
242
|
+
const type = this.readUInt8();
|
|
243
|
+
const local = this.readUInt8();
|
|
244
|
+
const clusterId = this.readUInt16();
|
|
245
|
+
const remote = this.readUInt8();
|
|
246
|
+
const identifier = this.readIeeeAddr();
|
|
247
|
+
const networkIndex = this.readUInt8();
|
|
248
|
+
return {
|
|
249
|
+
type,
|
|
250
|
+
local,
|
|
251
|
+
clusterId,
|
|
252
|
+
remote,
|
|
253
|
+
identifier,
|
|
254
|
+
networkIndex,
|
|
255
|
+
};
|
|
256
|
+
}
|
|
257
|
+
writeEmberMulticastTableEntry(value) {
|
|
258
|
+
this.writeUInt16(value.multicastId);
|
|
259
|
+
this.writeUInt8(value.endpoint);
|
|
260
|
+
this.writeUInt8(value.networkIndex);
|
|
261
|
+
}
|
|
262
|
+
readEmberMulticastTableEntry() {
|
|
263
|
+
const multicastId = this.readUInt16();
|
|
264
|
+
const endpoint = this.readUInt8();
|
|
265
|
+
// XXX: not in gecko_sdk? as workaround check length for now since used at end in just one place
|
|
266
|
+
const networkIndex = this.isMore() ? this.readUInt8() : 0x00;
|
|
267
|
+
return { multicastId, endpoint, networkIndex };
|
|
268
|
+
}
|
|
269
|
+
writeEmberBeaconClassificationParams(value) {
|
|
270
|
+
this.writeUInt8(value.minRssiForReceivingPkts);
|
|
271
|
+
this.writeUInt16(value.beaconClassificationMask);
|
|
272
|
+
}
|
|
273
|
+
readEmberBeaconClassificationParams() {
|
|
274
|
+
const minRssiForReceivingPkts = this.readUInt8(); // Int8...
|
|
275
|
+
const beaconClassificationMask = this.readUInt16();
|
|
276
|
+
return { minRssiForReceivingPkts, beaconClassificationMask };
|
|
277
|
+
}
|
|
278
|
+
writeEmberNeighborTableEntry(value) {
|
|
279
|
+
this.writeUInt16(value.shortId);
|
|
280
|
+
this.writeUInt8(value.averageLqi);
|
|
281
|
+
this.writeUInt8(value.inCost);
|
|
282
|
+
this.writeUInt8(value.outCost);
|
|
283
|
+
this.writeUInt8(value.age);
|
|
284
|
+
this.writeIeeeAddr(value.longId);
|
|
285
|
+
}
|
|
286
|
+
readEmberNeighborTableEntry() {
|
|
287
|
+
const shortId = this.readUInt16();
|
|
288
|
+
const averageLqi = this.readUInt8();
|
|
289
|
+
const inCost = this.readUInt8();
|
|
290
|
+
const outCost = this.readUInt8();
|
|
291
|
+
const age = this.readUInt8();
|
|
292
|
+
const longId = this.readIeeeAddr();
|
|
293
|
+
return {
|
|
294
|
+
shortId,
|
|
295
|
+
averageLqi,
|
|
296
|
+
inCost,
|
|
297
|
+
outCost,
|
|
298
|
+
age,
|
|
299
|
+
longId,
|
|
300
|
+
};
|
|
301
|
+
}
|
|
302
|
+
writeEmberRouteTableEntry(value) {
|
|
303
|
+
this.writeUInt16(value.destination);
|
|
304
|
+
this.writeUInt16(value.nextHop);
|
|
305
|
+
this.writeUInt8(value.status);
|
|
306
|
+
this.writeUInt8(value.age);
|
|
307
|
+
this.writeUInt8(value.concentratorType);
|
|
308
|
+
this.writeUInt8(value.routeRecordState);
|
|
309
|
+
}
|
|
310
|
+
readEmberRouteTableEntry() {
|
|
311
|
+
const destination = this.readUInt16();
|
|
312
|
+
const nextHop = this.readUInt16();
|
|
313
|
+
const status = this.readUInt8();
|
|
314
|
+
const age = this.readUInt8();
|
|
315
|
+
const concentratorType = this.readUInt8();
|
|
316
|
+
const routeRecordState = this.readUInt8();
|
|
317
|
+
return {
|
|
318
|
+
destination,
|
|
319
|
+
nextHop,
|
|
320
|
+
status,
|
|
321
|
+
age,
|
|
322
|
+
concentratorType,
|
|
323
|
+
routeRecordState,
|
|
324
|
+
};
|
|
325
|
+
}
|
|
326
|
+
writeEmberKeyData(value) {
|
|
327
|
+
this.writeBuffer(value.contents, consts_2.EMBER_ENCRYPTION_KEY_SIZE);
|
|
328
|
+
}
|
|
329
|
+
readEmberKeyData() {
|
|
330
|
+
const contents = this.readBufferCopy(consts_2.EMBER_ENCRYPTION_KEY_SIZE);
|
|
331
|
+
return { contents };
|
|
332
|
+
}
|
|
333
|
+
writeSecManKey(value) {
|
|
334
|
+
this.writeEmberKeyData(value);
|
|
335
|
+
}
|
|
336
|
+
readSecManKey() {
|
|
337
|
+
return this.readEmberKeyData();
|
|
338
|
+
}
|
|
339
|
+
writeSecManContext(value) {
|
|
340
|
+
this.writeUInt8(value.coreKeyType);
|
|
341
|
+
this.writeUInt8(value.keyIndex);
|
|
342
|
+
this.writeUInt16(value.derivedType);
|
|
343
|
+
this.writeIeeeAddr(value.eui64);
|
|
344
|
+
this.writeUInt8(value.multiNetworkIndex);
|
|
345
|
+
this.writeUInt8(value.flags);
|
|
346
|
+
this.writeUInt32(value.psaKeyAlgPermission);
|
|
347
|
+
}
|
|
348
|
+
readSecManContext() {
|
|
349
|
+
const coreKeyType = this.readUInt8();
|
|
350
|
+
const keyIndex = this.readUInt8();
|
|
351
|
+
const derivedType = this.readUInt16();
|
|
352
|
+
const eui64 = this.readIeeeAddr();
|
|
353
|
+
const multiNetworkIndex = this.readUInt8();
|
|
354
|
+
const flags = this.readUInt8();
|
|
355
|
+
const psaKeyAlgPermission = this.readUInt32();
|
|
356
|
+
return {
|
|
357
|
+
coreKeyType,
|
|
358
|
+
keyIndex,
|
|
359
|
+
derivedType,
|
|
360
|
+
eui64,
|
|
361
|
+
multiNetworkIndex,
|
|
362
|
+
flags,
|
|
363
|
+
psaKeyAlgPermission,
|
|
364
|
+
};
|
|
365
|
+
}
|
|
366
|
+
writeSecManNetworkKeyInfo(value) {
|
|
367
|
+
this.writeUInt8(value.networkKeySet ? 1 : 0);
|
|
368
|
+
this.writeUInt8(value.alternateNetworkKeySet ? 1 : 0);
|
|
369
|
+
this.writeUInt8(value.networkKeySequenceNumber);
|
|
370
|
+
this.writeUInt8(value.altNetworkKeySequenceNumber);
|
|
371
|
+
this.writeUInt32(value.networkKeyFrameCounter);
|
|
372
|
+
}
|
|
373
|
+
readSecManNetworkKeyInfo() {
|
|
374
|
+
const networkKeySet = this.readUInt8() !== 0;
|
|
375
|
+
const alternateNetworkKeySet = this.readUInt8() !== 0;
|
|
376
|
+
const networkKeySequenceNumber = this.readUInt8();
|
|
377
|
+
const altNetworkKeySequenceNumber = this.readUInt8();
|
|
378
|
+
const networkKeyFrameCounter = this.readUInt32();
|
|
379
|
+
return {
|
|
380
|
+
networkKeySet: networkKeySet,
|
|
381
|
+
alternateNetworkKeySet: alternateNetworkKeySet,
|
|
382
|
+
networkKeySequenceNumber: networkKeySequenceNumber,
|
|
383
|
+
altNetworkKeySequenceNumber: altNetworkKeySequenceNumber,
|
|
384
|
+
networkKeyFrameCounter: networkKeyFrameCounter,
|
|
385
|
+
};
|
|
386
|
+
}
|
|
387
|
+
writeSecManAPSKeyMetadata(value) {
|
|
388
|
+
this.writeUInt16(value.bitmask);
|
|
389
|
+
this.writeUInt32(value.outgoingFrameCounter);
|
|
390
|
+
this.writeUInt32(value.incomingFrameCounter);
|
|
391
|
+
this.writeUInt16(value.ttlInSeconds);
|
|
392
|
+
}
|
|
393
|
+
readSecManAPSKeyMetadata() {
|
|
394
|
+
const bitmask = this.readUInt16();
|
|
395
|
+
const outgoingFrameCounter = this.readUInt32();
|
|
396
|
+
const incomingFrameCounter = this.readUInt32();
|
|
397
|
+
const ttlInSeconds = this.readUInt16();
|
|
398
|
+
return {
|
|
399
|
+
bitmask,
|
|
400
|
+
outgoingFrameCounter,
|
|
401
|
+
incomingFrameCounter,
|
|
402
|
+
ttlInSeconds,
|
|
403
|
+
};
|
|
404
|
+
}
|
|
405
|
+
writeEmberInitialSecurityState(value) {
|
|
406
|
+
this.writeUInt16(value.bitmask);
|
|
407
|
+
this.writeEmberKeyData(value.preconfiguredKey);
|
|
408
|
+
this.writeEmberKeyData(value.networkKey);
|
|
409
|
+
this.writeUInt8(value.networkKeySequenceNumber);
|
|
410
|
+
this.writeIeeeAddr(value.preconfiguredTrustCenterEui64);
|
|
411
|
+
}
|
|
412
|
+
readEmberInitialSecurityState() {
|
|
413
|
+
const bitmask = this.readUInt16();
|
|
414
|
+
const preconfiguredKey = this.readEmberKeyData();
|
|
415
|
+
const networkKey = this.readEmberKeyData();
|
|
416
|
+
const networkKeySequenceNumber = this.readUInt8();
|
|
417
|
+
const preconfiguredTrustCenterEui64 = this.readIeeeAddr();
|
|
418
|
+
return {
|
|
419
|
+
bitmask,
|
|
420
|
+
preconfiguredKey,
|
|
421
|
+
networkKey,
|
|
422
|
+
networkKeySequenceNumber,
|
|
423
|
+
preconfiguredTrustCenterEui64,
|
|
424
|
+
};
|
|
425
|
+
}
|
|
426
|
+
writeEmberCurrentSecurityState(value) {
|
|
427
|
+
this.writeUInt16(value.bitmask);
|
|
428
|
+
this.writeIeeeAddr(value.trustCenterLongAddress);
|
|
429
|
+
}
|
|
430
|
+
readEmberCurrentSecurityState() {
|
|
431
|
+
const bitmask = this.readUInt16();
|
|
432
|
+
const trustCenterLongAddress = this.readIeeeAddr();
|
|
433
|
+
return { bitmask, trustCenterLongAddress };
|
|
434
|
+
}
|
|
435
|
+
writeEmberChildData(value) {
|
|
436
|
+
this.writeIeeeAddr(value.eui64);
|
|
437
|
+
this.writeUInt8(value.type);
|
|
438
|
+
this.writeUInt16(value.id);
|
|
439
|
+
this.writeUInt8(value.phy);
|
|
440
|
+
this.writeUInt8(value.power);
|
|
441
|
+
this.writeUInt8(value.timeout);
|
|
442
|
+
this.writeUInt32(value.remainingTimeout);
|
|
443
|
+
}
|
|
444
|
+
readEmberChildData() {
|
|
445
|
+
const eui64 = this.readIeeeAddr();
|
|
446
|
+
const type = this.readUInt8();
|
|
447
|
+
const id = this.readUInt16();
|
|
448
|
+
const phy = this.readUInt8();
|
|
449
|
+
const power = this.readUInt8();
|
|
450
|
+
const timeout = this.readUInt8();
|
|
451
|
+
const remainingTimeout = this.readUInt32();
|
|
452
|
+
return {
|
|
453
|
+
eui64,
|
|
454
|
+
type,
|
|
455
|
+
id,
|
|
456
|
+
phy,
|
|
457
|
+
power,
|
|
458
|
+
timeout,
|
|
459
|
+
remainingTimeout,
|
|
460
|
+
};
|
|
461
|
+
}
|
|
462
|
+
readEmberZigbeeNetwork() {
|
|
463
|
+
const channel = this.readUInt8();
|
|
464
|
+
const panId = this.readUInt16();
|
|
465
|
+
const extendedPanId = this.readListUInt8(consts_2.EXTENDED_PAN_ID_SIZE);
|
|
466
|
+
const allowingJoin = this.readUInt8() !== 0;
|
|
467
|
+
const stackProfile = this.readUInt8();
|
|
468
|
+
const nwkUpdateId = this.readUInt8();
|
|
469
|
+
return {
|
|
470
|
+
channel,
|
|
471
|
+
panId,
|
|
472
|
+
extendedPanId,
|
|
473
|
+
allowingJoin,
|
|
474
|
+
stackProfile,
|
|
475
|
+
nwkUpdateId,
|
|
476
|
+
};
|
|
477
|
+
}
|
|
478
|
+
writeEmberZigbeeNetwork(value) {
|
|
479
|
+
this.writeUInt8(value.channel);
|
|
480
|
+
this.writeUInt16(value.panId);
|
|
481
|
+
this.writeListUInt8(value.extendedPanId);
|
|
482
|
+
this.writeUInt8(value.allowingJoin ? 1 : 0);
|
|
483
|
+
this.writeUInt8(value.stackProfile);
|
|
484
|
+
this.writeUInt8(value.nwkUpdateId);
|
|
485
|
+
}
|
|
486
|
+
writeEmberCertificateData(value) {
|
|
487
|
+
this.writeBuffer(value.contents, consts_2.EMBER_CERTIFICATE_SIZE);
|
|
488
|
+
}
|
|
489
|
+
readEmberCertificateData() {
|
|
490
|
+
const contents = this.readBufferCopy(consts_2.EMBER_CERTIFICATE_SIZE);
|
|
491
|
+
return { contents };
|
|
492
|
+
}
|
|
493
|
+
writeEmberPublicKeyData(value) {
|
|
494
|
+
this.writeBuffer(value.contents, consts_2.EMBER_PUBLIC_KEY_SIZE);
|
|
495
|
+
}
|
|
496
|
+
readEmberPublicKeyData() {
|
|
497
|
+
const contents = this.readBufferCopy(consts_2.EMBER_PUBLIC_KEY_SIZE);
|
|
498
|
+
return { contents };
|
|
499
|
+
}
|
|
500
|
+
writeEmberPrivateKeyData(value) {
|
|
501
|
+
this.writeBuffer(value.contents, consts_2.EMBER_PRIVATE_KEY_SIZE);
|
|
502
|
+
}
|
|
503
|
+
readEmberPrivateKeyData() {
|
|
504
|
+
const contents = this.readBufferCopy(consts_2.EMBER_PRIVATE_KEY_SIZE);
|
|
505
|
+
return { contents };
|
|
506
|
+
}
|
|
507
|
+
writeEmberSmacData(value) {
|
|
508
|
+
this.writeBuffer(value.contents, consts_2.EMBER_SMAC_SIZE);
|
|
509
|
+
}
|
|
510
|
+
readEmberSmacData() {
|
|
511
|
+
const contents = this.readBufferCopy(consts_2.EMBER_SMAC_SIZE);
|
|
512
|
+
return { contents };
|
|
513
|
+
}
|
|
514
|
+
writeEmberSignatureData(value) {
|
|
515
|
+
this.writeBuffer(value.contents, consts_2.EMBER_SIGNATURE_SIZE);
|
|
516
|
+
}
|
|
517
|
+
readEmberSignatureData() {
|
|
518
|
+
const contents = this.readBufferCopy(consts_2.EMBER_SIGNATURE_SIZE);
|
|
519
|
+
return { contents };
|
|
520
|
+
}
|
|
521
|
+
writeEmberCertificate283k1Data(value) {
|
|
522
|
+
this.writeBuffer(value.contents, consts_2.EMBER_CERTIFICATE_283K1_SIZE);
|
|
523
|
+
}
|
|
524
|
+
readEmberCertificate283k1Data() {
|
|
525
|
+
const contents = this.readBufferCopy(consts_2.EMBER_CERTIFICATE_283K1_SIZE);
|
|
526
|
+
return { contents };
|
|
527
|
+
}
|
|
528
|
+
writeEmberPublicKey283k1Data(value) {
|
|
529
|
+
this.writeBuffer(value.contents, consts_2.EMBER_PUBLIC_KEY_283K1_SIZE);
|
|
530
|
+
}
|
|
531
|
+
readEmberPublicKey283k1Data() {
|
|
532
|
+
const contents = this.readBufferCopy(consts_2.EMBER_PUBLIC_KEY_283K1_SIZE);
|
|
533
|
+
return { contents };
|
|
534
|
+
}
|
|
535
|
+
writeEmberPrivateKey283k1Data(value) {
|
|
536
|
+
this.writeBuffer(value.contents, consts_2.EMBER_PRIVATE_KEY_283K1_SIZE);
|
|
537
|
+
}
|
|
538
|
+
readEmberPrivateKey283k1Data() {
|
|
539
|
+
const contents = this.readBufferCopy(consts_2.EMBER_PRIVATE_KEY_283K1_SIZE);
|
|
540
|
+
return { contents };
|
|
541
|
+
}
|
|
542
|
+
writeEmberSignature283k1Data(value) {
|
|
543
|
+
this.writeBuffer(value.contents, consts_2.EMBER_SIGNATURE_283K1_SIZE);
|
|
544
|
+
}
|
|
545
|
+
readEmberSignature283k1Data() {
|
|
546
|
+
const contents = this.readBufferCopy(consts_2.EMBER_SIGNATURE_283K1_SIZE);
|
|
547
|
+
return { contents };
|
|
548
|
+
}
|
|
549
|
+
writeEmberAesMmoHashContext(context) {
|
|
550
|
+
this.writeBuffer(context.result, consts_2.EMBER_AES_HASH_BLOCK_SIZE);
|
|
551
|
+
this.writeUInt32(context.length);
|
|
552
|
+
}
|
|
553
|
+
readEmberAesMmoHashContext() {
|
|
554
|
+
const result = this.readBufferCopy(consts_2.EMBER_AES_HASH_BLOCK_SIZE);
|
|
555
|
+
const length = this.readUInt32();
|
|
556
|
+
return { result, length };
|
|
557
|
+
}
|
|
558
|
+
writeEmberMessageDigest(value) {
|
|
559
|
+
this.writeBuffer(value.contents, consts_2.EMBER_AES_HASH_BLOCK_SIZE);
|
|
560
|
+
}
|
|
561
|
+
readEmberMessageDigest() {
|
|
562
|
+
const contents = this.readBufferCopy(consts_2.EMBER_AES_HASH_BLOCK_SIZE);
|
|
563
|
+
return { contents };
|
|
564
|
+
}
|
|
565
|
+
writeEmberNetworkInitStruct(networkInitStruct) {
|
|
566
|
+
this.writeUInt16(networkInitStruct.bitmask);
|
|
567
|
+
}
|
|
568
|
+
readEmberNetworkInitStruct() {
|
|
569
|
+
const bitmask = this.readUInt16();
|
|
570
|
+
return { bitmask };
|
|
571
|
+
}
|
|
572
|
+
writeEmberZllNetwork(network) {
|
|
573
|
+
this.writeEmberZigbeeNetwork(network.zigbeeNetwork);
|
|
574
|
+
this.writeEmberZllSecurityAlgorithmData(network.securityAlgorithm);
|
|
575
|
+
this.writeIeeeAddr(network.eui64);
|
|
576
|
+
this.writeUInt16(network.nodeId);
|
|
577
|
+
this.writeUInt16(network.state);
|
|
578
|
+
this.writeUInt8(network.nodeType);
|
|
579
|
+
this.writeUInt8(network.numberSubDevices);
|
|
580
|
+
this.writeUInt8(network.totalGroupIdentifiers);
|
|
581
|
+
this.writeUInt8(network.rssiCorrection);
|
|
582
|
+
}
|
|
583
|
+
readEmberZllNetwork() {
|
|
584
|
+
const zigbeeNetwork = this.readEmberZigbeeNetwork();
|
|
585
|
+
const securityAlgorithm = this.readEmberZllSecurityAlgorithmData();
|
|
586
|
+
const eui64 = this.readIeeeAddr();
|
|
587
|
+
const nodeId = this.readUInt16();
|
|
588
|
+
const state = this.readUInt16();
|
|
589
|
+
const nodeType = this.readUInt8();
|
|
590
|
+
const numberSubDevices = this.readUInt8();
|
|
591
|
+
const totalGroupIdentifiers = this.readUInt8();
|
|
592
|
+
const rssiCorrection = this.readUInt8();
|
|
593
|
+
return {
|
|
594
|
+
zigbeeNetwork,
|
|
595
|
+
securityAlgorithm,
|
|
596
|
+
eui64,
|
|
597
|
+
nodeId,
|
|
598
|
+
state,
|
|
599
|
+
nodeType,
|
|
600
|
+
numberSubDevices,
|
|
601
|
+
totalGroupIdentifiers,
|
|
602
|
+
rssiCorrection,
|
|
603
|
+
};
|
|
604
|
+
}
|
|
605
|
+
writeEmberZllSecurityAlgorithmData(data) {
|
|
606
|
+
this.writeUInt32(data.transactionId);
|
|
607
|
+
this.writeUInt32(data.responseId);
|
|
608
|
+
this.writeUInt16(data.bitmask);
|
|
609
|
+
}
|
|
610
|
+
readEmberZllSecurityAlgorithmData() {
|
|
611
|
+
const transactionId = this.readUInt32();
|
|
612
|
+
const responseId = this.readUInt32();
|
|
613
|
+
const bitmask = this.readUInt16();
|
|
614
|
+
return { transactionId, responseId, bitmask };
|
|
615
|
+
}
|
|
616
|
+
writeEmberZllInitialSecurityState(state) {
|
|
617
|
+
this.writeUInt32(state.bitmask);
|
|
618
|
+
this.writeUInt8(state.keyIndex);
|
|
619
|
+
this.writeEmberKeyData(state.encryptionKey);
|
|
620
|
+
this.writeEmberKeyData(state.preconfiguredKey);
|
|
621
|
+
}
|
|
622
|
+
writeEmberTokTypeStackZllData(data) {
|
|
623
|
+
this.writeUInt32(data.bitmask);
|
|
624
|
+
this.writeUInt16(data.freeNodeIdMin);
|
|
625
|
+
this.writeUInt16(data.freeNodeIdMax);
|
|
626
|
+
this.writeUInt16(data.myGroupIdMin);
|
|
627
|
+
this.writeUInt16(data.freeGroupIdMin);
|
|
628
|
+
this.writeUInt16(data.freeGroupIdMax);
|
|
629
|
+
this.writeUInt8(data.rssiCorrection);
|
|
630
|
+
}
|
|
631
|
+
readEmberTokTypeStackZllData() {
|
|
632
|
+
const bitmask = this.readUInt32();
|
|
633
|
+
const freeNodeIdMin = this.readUInt16();
|
|
634
|
+
const freeNodeIdMax = this.readUInt16();
|
|
635
|
+
const myGroupIdMin = this.readUInt16();
|
|
636
|
+
const freeGroupIdMin = this.readUInt16();
|
|
637
|
+
const freeGroupIdMax = this.readUInt16();
|
|
638
|
+
const rssiCorrection = this.readUInt8();
|
|
639
|
+
return {
|
|
640
|
+
bitmask,
|
|
641
|
+
freeNodeIdMin,
|
|
642
|
+
freeNodeIdMax,
|
|
643
|
+
myGroupIdMin,
|
|
644
|
+
freeGroupIdMin,
|
|
645
|
+
freeGroupIdMax,
|
|
646
|
+
rssiCorrection,
|
|
647
|
+
};
|
|
648
|
+
}
|
|
649
|
+
writeEmberTokTypeStackZllSecurity(security) {
|
|
650
|
+
this.writeUInt32(security.bitmask);
|
|
651
|
+
this.writeUInt8(security.keyIndex);
|
|
652
|
+
this.writeBuffer(security.encryptionKey, consts_2.EMBER_ENCRYPTION_KEY_SIZE);
|
|
653
|
+
this.writeBuffer(security.preconfiguredKey, consts_2.EMBER_ENCRYPTION_KEY_SIZE);
|
|
654
|
+
}
|
|
655
|
+
readEmberTokTypeStackZllSecurity() {
|
|
656
|
+
const bitmask = this.readUInt32();
|
|
657
|
+
const keyIndex = this.readUInt8();
|
|
658
|
+
const encryptionKey = this.readBufferCopy(consts_2.EMBER_ENCRYPTION_KEY_SIZE);
|
|
659
|
+
const preconfiguredKey = this.readBufferCopy(consts_2.EMBER_ENCRYPTION_KEY_SIZE);
|
|
660
|
+
return {
|
|
661
|
+
bitmask,
|
|
662
|
+
keyIndex,
|
|
663
|
+
encryptionKey,
|
|
664
|
+
preconfiguredKey,
|
|
665
|
+
};
|
|
666
|
+
}
|
|
667
|
+
writeEmberGpAddress(value) {
|
|
668
|
+
this.writeUInt8(value.applicationId);
|
|
669
|
+
if (value.applicationId === enums_1.EmberGpApplicationId.SOURCE_ID) {
|
|
670
|
+
this.writeUInt32(value.sourceId);
|
|
671
|
+
this.writeUInt32(value.sourceId); // filler
|
|
672
|
+
}
|
|
673
|
+
else if (value.applicationId === enums_1.EmberGpApplicationId.IEEE_ADDRESS) {
|
|
674
|
+
this.writeIeeeAddr(value.gpdIeeeAddress);
|
|
675
|
+
}
|
|
676
|
+
this.writeUInt8(value.endpoint);
|
|
677
|
+
}
|
|
678
|
+
readEmberGpAddress() {
|
|
679
|
+
const applicationId = this.readUInt8();
|
|
680
|
+
if (applicationId === enums_1.EmberGpApplicationId.SOURCE_ID) {
|
|
681
|
+
const sourceId = this.readUInt32();
|
|
682
|
+
this.readUInt32(); // filler
|
|
683
|
+
const endpoint = this.readUInt8();
|
|
684
|
+
return { applicationId, sourceId, endpoint };
|
|
685
|
+
}
|
|
686
|
+
if (applicationId === enums_1.EmberGpApplicationId.IEEE_ADDRESS) {
|
|
687
|
+
const gpdIeeeAddress = this.readIeeeAddr();
|
|
688
|
+
const endpoint = this.readUInt8();
|
|
689
|
+
return { applicationId, gpdIeeeAddress, endpoint };
|
|
690
|
+
}
|
|
691
|
+
throw new Error(`Invalid GP applicationId ${applicationId}.`);
|
|
692
|
+
}
|
|
693
|
+
readEmberGpSinkList() {
|
|
694
|
+
const list = [];
|
|
695
|
+
for (let i = 0; i < consts_1.GP_SINK_LIST_ENTRIES; i++) {
|
|
696
|
+
const type = this.readUInt8();
|
|
697
|
+
switch (type) {
|
|
698
|
+
case enums_1.EmberGpSinkType.D_GROUPCAST:
|
|
699
|
+
case enums_1.EmberGpSinkType.GROUPCAST: {
|
|
700
|
+
const alias = this.readUInt16();
|
|
701
|
+
const groupID = this.readUInt16();
|
|
702
|
+
// fillers
|
|
703
|
+
this.readUInt16();
|
|
704
|
+
this.readUInt16();
|
|
705
|
+
this.readUInt16();
|
|
706
|
+
list.push({
|
|
707
|
+
type,
|
|
708
|
+
groupcast: {
|
|
709
|
+
alias,
|
|
710
|
+
groupID,
|
|
711
|
+
},
|
|
712
|
+
});
|
|
713
|
+
break;
|
|
714
|
+
}
|
|
715
|
+
// case EmberGpSinkType.FULL_UNICAST:
|
|
716
|
+
// case EmberGpSinkType.LW_UNICAST:
|
|
717
|
+
// case EmberGpSinkType.UNUSED:
|
|
718
|
+
default: {
|
|
719
|
+
const sinkNodeId = this.readUInt16();
|
|
720
|
+
const sinkEUI = this.readIeeeAddr();
|
|
721
|
+
list.push({
|
|
722
|
+
type,
|
|
723
|
+
unicast: {
|
|
724
|
+
sinkNodeId,
|
|
725
|
+
sinkEUI,
|
|
726
|
+
},
|
|
727
|
+
});
|
|
728
|
+
break;
|
|
729
|
+
}
|
|
730
|
+
}
|
|
731
|
+
}
|
|
732
|
+
return list;
|
|
733
|
+
}
|
|
734
|
+
writeEmberGpSinkList(value) {
|
|
735
|
+
for (let i = 0; i < consts_1.GP_SINK_LIST_ENTRIES; i++) {
|
|
736
|
+
const entry = value[i];
|
|
737
|
+
this.writeUInt8(entry.type);
|
|
738
|
+
switch (entry.type) {
|
|
739
|
+
case enums_1.EmberGpSinkType.D_GROUPCAST:
|
|
740
|
+
case enums_1.EmberGpSinkType.GROUPCAST: {
|
|
741
|
+
this.writeUInt16(entry.groupcast.alias);
|
|
742
|
+
this.writeUInt16(entry.groupcast.groupID);
|
|
743
|
+
//fillers
|
|
744
|
+
this.writeUInt16(entry.groupcast.alias);
|
|
745
|
+
this.writeUInt16(entry.groupcast.groupID);
|
|
746
|
+
this.writeUInt16(entry.groupcast.alias);
|
|
747
|
+
break;
|
|
748
|
+
}
|
|
749
|
+
// case EmberGpSinkType.FULL_UNICAST:
|
|
750
|
+
// case EmberGpSinkType.LW_UNICAST:
|
|
751
|
+
// case EmberGpSinkType.UNUSED:
|
|
752
|
+
default: {
|
|
753
|
+
this.writeUInt16(entry.unicast.sinkNodeId);
|
|
754
|
+
this.writeIeeeAddr(entry.unicast.sinkEUI);
|
|
755
|
+
break;
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
}
|
|
759
|
+
}
|
|
760
|
+
readEmberGpProxyTableEntry() {
|
|
761
|
+
const status = this.readUInt8();
|
|
762
|
+
const options = this.readUInt32();
|
|
763
|
+
const gpd = this.readEmberGpAddress();
|
|
764
|
+
const assignedAlias = this.readUInt16();
|
|
765
|
+
const securityOptions = this.readUInt8();
|
|
766
|
+
const gpdSecurityFrameCounter = this.readUInt32();
|
|
767
|
+
const gpdKey = this.readEmberKeyData();
|
|
768
|
+
const sinkList = this.readEmberGpSinkList();
|
|
769
|
+
const groupcastRadius = this.readUInt8();
|
|
770
|
+
const searchCounter = this.readUInt8();
|
|
771
|
+
return {
|
|
772
|
+
status,
|
|
773
|
+
options,
|
|
774
|
+
gpd,
|
|
775
|
+
assignedAlias,
|
|
776
|
+
securityOptions,
|
|
777
|
+
gpdSecurityFrameCounter,
|
|
778
|
+
gpdKey,
|
|
779
|
+
sinkList,
|
|
780
|
+
groupcastRadius,
|
|
781
|
+
searchCounter,
|
|
782
|
+
};
|
|
783
|
+
}
|
|
784
|
+
writeEmberGpProxyTableEntry(value) {
|
|
785
|
+
this.writeUInt8(value.status);
|
|
786
|
+
this.writeUInt32(value.options);
|
|
787
|
+
this.writeEmberGpAddress(value.gpd);
|
|
788
|
+
this.writeUInt16(value.assignedAlias);
|
|
789
|
+
this.writeUInt8(value.securityOptions);
|
|
790
|
+
this.writeUInt32(value.gpdSecurityFrameCounter);
|
|
791
|
+
this.writeEmberKeyData(value.gpdKey);
|
|
792
|
+
this.writeEmberGpSinkList(value.sinkList);
|
|
793
|
+
this.writeUInt8(value.groupcastRadius);
|
|
794
|
+
this.writeUInt8(value.searchCounter);
|
|
795
|
+
}
|
|
796
|
+
readEmberGpSinkTableEntry() {
|
|
797
|
+
const status = this.readUInt8();
|
|
798
|
+
const options = this.readUInt16();
|
|
799
|
+
const gpd = this.readEmberGpAddress();
|
|
800
|
+
const deviceId = this.readUInt8();
|
|
801
|
+
const sinkList = this.readEmberGpSinkList();
|
|
802
|
+
const assignedAlias = this.readUInt16();
|
|
803
|
+
const groupcastRadius = this.readUInt8();
|
|
804
|
+
const securityOptions = this.readUInt8();
|
|
805
|
+
const gpdSecurityFrameCounter = this.readUInt32();
|
|
806
|
+
const gpdKey = this.readEmberKeyData();
|
|
807
|
+
return {
|
|
808
|
+
status,
|
|
809
|
+
options,
|
|
810
|
+
gpd,
|
|
811
|
+
deviceId,
|
|
812
|
+
sinkList,
|
|
813
|
+
assignedAlias,
|
|
814
|
+
groupcastRadius,
|
|
815
|
+
securityOptions,
|
|
816
|
+
gpdSecurityFrameCounter,
|
|
817
|
+
gpdKey,
|
|
818
|
+
};
|
|
819
|
+
}
|
|
820
|
+
writeEmberGpSinkTableEntry(value) {
|
|
821
|
+
this.writeUInt8(value.status);
|
|
822
|
+
this.writeUInt16(value.options);
|
|
823
|
+
this.writeEmberGpAddress(value.gpd);
|
|
824
|
+
this.writeUInt8(value.deviceId);
|
|
825
|
+
this.writeEmberGpSinkList(value.sinkList);
|
|
826
|
+
this.writeUInt16(value.assignedAlias);
|
|
827
|
+
this.writeUInt8(value.groupcastRadius);
|
|
828
|
+
this.writeUInt8(value.securityOptions);
|
|
829
|
+
this.writeUInt32(value.gpdSecurityFrameCounter);
|
|
830
|
+
this.writeEmberKeyData(value.gpdKey);
|
|
831
|
+
}
|
|
832
|
+
writeEmberDutyCycleLimits(limits) {
|
|
833
|
+
this.writeUInt16(limits.limitThresh);
|
|
834
|
+
this.writeUInt16(limits.critThresh);
|
|
835
|
+
this.writeUInt16(limits.suspLimit);
|
|
836
|
+
}
|
|
837
|
+
readEmberDutyCycleLimits() {
|
|
838
|
+
const limitThresh = this.readUInt16();
|
|
839
|
+
const critThresh = this.readUInt16();
|
|
840
|
+
const suspLimit = this.readUInt16();
|
|
841
|
+
return {
|
|
842
|
+
limitThresh,
|
|
843
|
+
critThresh,
|
|
844
|
+
suspLimit,
|
|
845
|
+
};
|
|
846
|
+
}
|
|
847
|
+
writeEmberPerDeviceDutyCycle(maxDevices, arrayOfDeviceDutyCycles) {
|
|
848
|
+
this.writeUInt16(maxDevices);
|
|
849
|
+
for (let i = 0; i < maxDevices; i++) {
|
|
850
|
+
this.writeUInt16(arrayOfDeviceDutyCycles[i].nodeId);
|
|
851
|
+
this.writeUInt16(arrayOfDeviceDutyCycles[i].dutyCycleConsumed);
|
|
852
|
+
}
|
|
853
|
+
}
|
|
854
|
+
readEmberPerDeviceDutyCycle() {
|
|
855
|
+
const maxDevices = this.readUInt8();
|
|
856
|
+
const arrayOfDeviceDutyCycles = [];
|
|
857
|
+
for (let i = 0; i < maxDevices; i++) {
|
|
858
|
+
const nodeId = this.readUInt16();
|
|
859
|
+
const dutyCycleConsumed = this.readUInt16();
|
|
860
|
+
arrayOfDeviceDutyCycles.push({ nodeId, dutyCycleConsumed });
|
|
861
|
+
}
|
|
862
|
+
return arrayOfDeviceDutyCycles;
|
|
863
|
+
}
|
|
864
|
+
readEmberZllDeviceInfoRecord() {
|
|
865
|
+
const ieeeAddress = this.readIeeeAddr();
|
|
866
|
+
const endpointId = this.readUInt8();
|
|
867
|
+
const profileId = this.readUInt16();
|
|
868
|
+
const deviceId = this.readUInt16();
|
|
869
|
+
const version = this.readUInt8();
|
|
870
|
+
const groupIdCount = this.readUInt8();
|
|
871
|
+
return {
|
|
872
|
+
ieeeAddress,
|
|
873
|
+
endpointId,
|
|
874
|
+
profileId,
|
|
875
|
+
deviceId,
|
|
876
|
+
version,
|
|
877
|
+
groupIdCount,
|
|
878
|
+
};
|
|
879
|
+
}
|
|
880
|
+
readEmberZllInitialSecurityState() {
|
|
881
|
+
const bitmask = this.readUInt32();
|
|
882
|
+
const keyIndex = this.readUInt8();
|
|
883
|
+
const encryptionKey = this.readEmberKeyData();
|
|
884
|
+
const preconfiguredKey = this.readEmberKeyData();
|
|
885
|
+
return {
|
|
886
|
+
bitmask,
|
|
887
|
+
keyIndex,
|
|
888
|
+
encryptionKey,
|
|
889
|
+
preconfiguredKey,
|
|
890
|
+
};
|
|
891
|
+
}
|
|
892
|
+
readEmberZllAddressAssignment() {
|
|
893
|
+
const nodeId = this.readUInt16();
|
|
894
|
+
const freeNodeIdMin = this.readUInt16();
|
|
895
|
+
const freeNodeIdMax = this.readUInt16();
|
|
896
|
+
const groupIdMin = this.readUInt16();
|
|
897
|
+
const groupIdMax = this.readUInt16();
|
|
898
|
+
const freeGroupIdMin = this.readUInt16();
|
|
899
|
+
const freeGroupIdMax = this.readUInt16();
|
|
900
|
+
return {
|
|
901
|
+
nodeId,
|
|
902
|
+
freeNodeIdMin,
|
|
903
|
+
freeNodeIdMax,
|
|
904
|
+
groupIdMin,
|
|
905
|
+
groupIdMax,
|
|
906
|
+
freeGroupIdMin,
|
|
907
|
+
freeGroupIdMax,
|
|
908
|
+
};
|
|
909
|
+
}
|
|
910
|
+
writeEmberBeaconIterator(value) {
|
|
911
|
+
this.writeUInt8(value.beacon.channel);
|
|
912
|
+
this.writeUInt8(value.beacon.lqi);
|
|
913
|
+
this.writeUInt8(value.beacon.rssi);
|
|
914
|
+
this.writeUInt8(value.beacon.depth);
|
|
915
|
+
this.writeUInt8(value.beacon.nwkUpdateId);
|
|
916
|
+
this.writeUInt8(value.beacon.power);
|
|
917
|
+
this.writeUInt8(value.beacon.parentPriority);
|
|
918
|
+
this.writeUInt8(value.beacon.enhanced ? 1 : 0);
|
|
919
|
+
this.writeUInt8(value.beacon.permitJoin ? 1 : 0);
|
|
920
|
+
this.writeUInt8(value.beacon.hasCapacity ? 1 : 0);
|
|
921
|
+
this.writeUInt16(value.beacon.panId);
|
|
922
|
+
this.writeUInt16(value.beacon.sender);
|
|
923
|
+
this.writeListUInt8(value.beacon.extendedPanId);
|
|
924
|
+
this.writeUInt8(value.index);
|
|
925
|
+
}
|
|
926
|
+
readEmberBeaconIterator() {
|
|
927
|
+
const channel = this.readUInt8();
|
|
928
|
+
const lqi = this.readUInt8();
|
|
929
|
+
const rssi = this.readUInt8();
|
|
930
|
+
const depth = this.readUInt8();
|
|
931
|
+
const nwkUpdateId = this.readUInt8();
|
|
932
|
+
const power = this.readUInt8();
|
|
933
|
+
const parentPriority = this.readUInt8();
|
|
934
|
+
const enhanced = this.readUInt8() !== 0;
|
|
935
|
+
const permitJoin = this.readUInt8() !== 0;
|
|
936
|
+
const hasCapacity = this.readUInt8() !== 0;
|
|
937
|
+
const panId = this.readUInt16();
|
|
938
|
+
const sender = this.readUInt16();
|
|
939
|
+
const extendedPanId = this.readListUInt8(consts_2.EXTENDED_PAN_ID_SIZE);
|
|
940
|
+
const index = this.readUInt8();
|
|
941
|
+
return {
|
|
942
|
+
beacon: {
|
|
943
|
+
channel,
|
|
944
|
+
lqi,
|
|
945
|
+
rssi,
|
|
946
|
+
depth,
|
|
947
|
+
nwkUpdateId,
|
|
948
|
+
power,
|
|
949
|
+
parentPriority,
|
|
950
|
+
enhanced,
|
|
951
|
+
permitJoin,
|
|
952
|
+
hasCapacity,
|
|
953
|
+
panId,
|
|
954
|
+
sender,
|
|
955
|
+
extendedPanId,
|
|
956
|
+
supportedKeyNegotiationMethods: 0,
|
|
957
|
+
extendedBeacon: false,
|
|
958
|
+
tcConnectivity: true,
|
|
959
|
+
longUptime: true,
|
|
960
|
+
preferParent: true,
|
|
961
|
+
macDataPollKeepalive: true,
|
|
962
|
+
endDeviceKeepalive: true,
|
|
963
|
+
},
|
|
964
|
+
index,
|
|
965
|
+
};
|
|
966
|
+
}
|
|
967
|
+
writeEmberBeaconData(value) {
|
|
968
|
+
this.writeUInt8(value.channel);
|
|
969
|
+
this.writeUInt8(value.lqi);
|
|
970
|
+
this.writeUInt8(value.rssi);
|
|
971
|
+
this.writeUInt8(value.depth);
|
|
972
|
+
this.writeUInt8(value.nwkUpdateId);
|
|
973
|
+
this.writeUInt8(value.power);
|
|
974
|
+
this.writeUInt8(value.parentPriority);
|
|
975
|
+
this.writeUInt8(value.enhanced ? 1 : 0);
|
|
976
|
+
this.writeUInt8(value.permitJoin ? 1 : 0);
|
|
977
|
+
this.writeUInt8(value.hasCapacity ? 1 : 0);
|
|
978
|
+
this.writeUInt16(value.panId);
|
|
979
|
+
this.writeUInt16(value.sender);
|
|
980
|
+
this.writeListUInt8(value.extendedPanId);
|
|
981
|
+
}
|
|
982
|
+
readEmberBeaconData() {
|
|
983
|
+
const channel = this.readUInt8();
|
|
984
|
+
const lqi = this.readUInt8();
|
|
985
|
+
const rssi = this.readUInt8();
|
|
986
|
+
const depth = this.readUInt8();
|
|
987
|
+
const nwkUpdateId = this.readUInt8();
|
|
988
|
+
const power = this.readUInt8();
|
|
989
|
+
const parentPriority = this.readUInt8();
|
|
990
|
+
const enhanced = this.readUInt8() !== 0;
|
|
991
|
+
const permitJoin = this.readUInt8() !== 0;
|
|
992
|
+
const hasCapacity = this.readUInt8() !== 0;
|
|
993
|
+
const panId = this.readUInt16();
|
|
994
|
+
const sender = this.readUInt16();
|
|
995
|
+
const extendedPanId = this.readListUInt8(consts_2.EXTENDED_PAN_ID_SIZE);
|
|
996
|
+
return {
|
|
997
|
+
channel,
|
|
998
|
+
lqi,
|
|
999
|
+
rssi,
|
|
1000
|
+
depth,
|
|
1001
|
+
nwkUpdateId,
|
|
1002
|
+
power,
|
|
1003
|
+
parentPriority,
|
|
1004
|
+
enhanced,
|
|
1005
|
+
permitJoin,
|
|
1006
|
+
hasCapacity,
|
|
1007
|
+
panId,
|
|
1008
|
+
sender,
|
|
1009
|
+
extendedPanId,
|
|
1010
|
+
supportedKeyNegotiationMethods: 0,
|
|
1011
|
+
extendedBeacon: false,
|
|
1012
|
+
tcConnectivity: true,
|
|
1013
|
+
longUptime: true,
|
|
1014
|
+
preferParent: true,
|
|
1015
|
+
macDataPollKeepalive: true,
|
|
1016
|
+
endDeviceKeepalive: true,
|
|
1017
|
+
};
|
|
1018
|
+
}
|
|
1019
|
+
writeEmberTokenData(tokenData) {
|
|
1020
|
+
this.writeUInt32(tokenData.size);
|
|
1021
|
+
this.writeBuffer(tokenData.data, tokenData.size);
|
|
1022
|
+
}
|
|
1023
|
+
readEmberTokenData() {
|
|
1024
|
+
const size = this.readUInt32();
|
|
1025
|
+
const data = this.readBufferCopy(size);
|
|
1026
|
+
return { size, data };
|
|
1027
|
+
}
|
|
1028
|
+
readEmberTokenInfo() {
|
|
1029
|
+
const nvm3Key = this.readUInt32();
|
|
1030
|
+
const isCnt = this.readUInt8() !== 0;
|
|
1031
|
+
const isIdx = this.readUInt8() !== 0;
|
|
1032
|
+
const size = this.readUInt8();
|
|
1033
|
+
const arraySize = this.readUInt8();
|
|
1034
|
+
return {
|
|
1035
|
+
nvm3Key,
|
|
1036
|
+
isCnt,
|
|
1037
|
+
isIdx,
|
|
1038
|
+
size,
|
|
1039
|
+
arraySize,
|
|
1040
|
+
};
|
|
1041
|
+
}
|
|
1042
|
+
writeEmberTokenInfo(tokenInfo) {
|
|
1043
|
+
this.writeUInt32(tokenInfo.nvm3Key);
|
|
1044
|
+
this.writeUInt8(tokenInfo.isCnt ? 1 : 0);
|
|
1045
|
+
this.writeUInt8(tokenInfo.isIdx ? 1 : 0);
|
|
1046
|
+
this.writeUInt8(tokenInfo.size);
|
|
1047
|
+
this.writeUInt8(tokenInfo.arraySize);
|
|
1048
|
+
}
|
|
1049
|
+
/**
|
|
1050
|
+
* EZSP switched to using SLStatus for command returns from version 14.
|
|
1051
|
+
* @param version EZSP protocol version in use
|
|
1052
|
+
* @param mapFromEmber If true, map from EmberStatus, otherwise map from EzspStatus
|
|
1053
|
+
* @returns EzspStatus, EmberStatus or SLStatus as SLStatus
|
|
1054
|
+
*/
|
|
1055
|
+
readStatus(version, mapFromEmber = true) {
|
|
1056
|
+
if (version < 0x0e) {
|
|
1057
|
+
const status = this.readUInt8();
|
|
1058
|
+
// skip lookup if SUCCESS (always zero)
|
|
1059
|
+
if (status === enums_1.SLStatus.OK) {
|
|
1060
|
+
return status;
|
|
1061
|
+
}
|
|
1062
|
+
if (mapFromEmber) {
|
|
1063
|
+
// use mapped value, or pass as-is if none found
|
|
1064
|
+
return EMBER_TO_SL_STATUS_MAP.get(status) ?? status;
|
|
1065
|
+
}
|
|
1066
|
+
// EzspStatus mapping to SLStatus is always same code
|
|
1067
|
+
return enums_1.SLStatus.ZIGBEE_EZSP_ERROR;
|
|
1068
|
+
}
|
|
1069
|
+
return this.readUInt32();
|
|
1070
|
+
}
|
|
1071
|
+
readEmberEndpointDescription() {
|
|
1072
|
+
const profileId = this.readUInt16();
|
|
1073
|
+
const deviceId = this.readUInt16();
|
|
1074
|
+
const deviceVersion = this.readUInt8();
|
|
1075
|
+
const inputClusterCount = this.readUInt8();
|
|
1076
|
+
const outputClusterCount = this.readUInt8();
|
|
1077
|
+
return {
|
|
1078
|
+
profileId,
|
|
1079
|
+
deviceId,
|
|
1080
|
+
deviceVersion,
|
|
1081
|
+
inputClusterCount,
|
|
1082
|
+
outputClusterCount,
|
|
1083
|
+
};
|
|
1084
|
+
}
|
|
1085
|
+
/** @deprecated removed in EZSP v16 in favor of @see readEmber802154RadioPriorities */
|
|
1086
|
+
readEmberMultiprotocolPriorities() {
|
|
1087
|
+
const backgroundRx = this.readUInt8();
|
|
1088
|
+
const tx = this.readUInt8();
|
|
1089
|
+
const activeRx = this.readUInt8();
|
|
1090
|
+
return { backgroundRx, tx, activeRx };
|
|
1091
|
+
}
|
|
1092
|
+
/** @deprecated removed in EZSP v16 in favor of @see writeEmber802154RadioPriorities */
|
|
1093
|
+
writeEmberMultiprotocolPriorities(priorities) {
|
|
1094
|
+
this.writeUInt8(priorities.backgroundRx);
|
|
1095
|
+
this.writeUInt8(priorities.tx);
|
|
1096
|
+
this.writeUInt8(priorities.activeRx);
|
|
1097
|
+
}
|
|
1098
|
+
readEmber802154RadioPriorities() {
|
|
1099
|
+
const backgroundRx = this.readUInt8();
|
|
1100
|
+
const minTxPriority = this.readUInt8();
|
|
1101
|
+
const txStep = this.readUInt8();
|
|
1102
|
+
const maxTxPriority = this.readUInt8();
|
|
1103
|
+
const activeRx = this.readUInt8();
|
|
1104
|
+
return { backgroundRx, minTxPriority, txStep, maxTxPriority, activeRx };
|
|
1105
|
+
}
|
|
1106
|
+
writeEmber802154RadioPriorities(priorities) {
|
|
1107
|
+
this.writeUInt8(priorities.backgroundRx);
|
|
1108
|
+
this.writeUInt8(priorities.minTxPriority);
|
|
1109
|
+
this.writeUInt8(priorities.txStep);
|
|
1110
|
+
this.writeUInt8(priorities.maxTxPriority);
|
|
1111
|
+
this.writeUInt8(priorities.activeRx);
|
|
1112
|
+
}
|
|
1113
|
+
readEmberRxPacketInfo() {
|
|
1114
|
+
const senderShortId = this.readUInt16();
|
|
1115
|
+
const senderLongId = this.readIeeeAddr();
|
|
1116
|
+
const bindingIndex = this.readUInt8();
|
|
1117
|
+
const addressIndex = this.readUInt8();
|
|
1118
|
+
const lastHopLqi = this.readUInt8();
|
|
1119
|
+
const lastHopRssi = this.readInt8(); // SDK: (int8_t)fetchInt8u();
|
|
1120
|
+
const lastHopTimestamp = this.readUInt32();
|
|
1121
|
+
return {
|
|
1122
|
+
senderShortId,
|
|
1123
|
+
senderLongId,
|
|
1124
|
+
bindingIndex,
|
|
1125
|
+
addressIndex,
|
|
1126
|
+
lastHopLqi,
|
|
1127
|
+
lastHopRssi,
|
|
1128
|
+
lastHopTimestamp,
|
|
1129
|
+
};
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
exports.EzspBuffalo = EzspBuffalo;
|
|
1133
|
+
//# sourceMappingURL=buffalo.js.map
|