@ovok/native 0.4.6 → 0.4.8
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/lib/commonjs/modules/bt-device/constants/device-instruction-pdfs.js +3 -1
- package/lib/commonjs/modules/bt-device/constants/device-instruction-pdfs.js.map +1 -1
- package/lib/commonjs/modules/bt-management/constants/integrated-devices-map.js +1 -1
- package/lib/commonjs/modules/bt-management/constants/integrated-devices-map.js.map +1 -1
- package/lib/commonjs/modules/bt-management/index.js +220 -0
- package/lib/commonjs/modules/bt-management/index.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/custom/compile-case-fields.js +49 -0
- package/lib/commonjs/modules/bt-management/services/custom/compile-case-fields.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/custom/compile-case-shape.js +52 -0
- package/lib/commonjs/modules/bt-management/services/custom/compile-case-shape.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-case.js +53 -41
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-case.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-field.js +3 -0
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-field.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-frame.js +48 -2
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-frame.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-lepu.js +98 -0
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-lepu.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/custom/define-custom-device.js +24 -1
- package/lib/commonjs/modules/bt-management/services/custom/define-custom-device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/device-creator.js +19 -8
- package/lib/commonjs/modules/bt-management/services/device-creator.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/aoj/aoj.thermometers.js +85 -0
- package/lib/commonjs/modules/bt-management/services/devices/aoj/aoj.thermometers.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/bp2/bp2.frame-reader.js +8 -74
- package/lib/commonjs/modules/bt-management/services/devices/bp2/bp2.frame-reader.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-command-writer.js +155 -0
- package/lib/commonjs/modules/bt-management/services/devices/bt-command-writer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/bt-connection-handler.js +9 -49
- package/lib/commonjs/modules/bt-management/services/devices/bt-connection-handler.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-data-processor.js +17 -6
- package/lib/commonjs/modules/bt-management/services/devices/bt-data-processor.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-managed-device.js +21 -14
- package/lib/commonjs/modules/bt-management/services/devices/bt-managed-device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js +55 -0
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom.device.js +82 -29
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom.device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/frame-parser.js +2 -1
- package/lib/commonjs/modules/bt-management/services/devices/frame-parser.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.command-builder.js +48 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.command-builder.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.commands.js +37 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.commands.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.device-info.js +83 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.device-info.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.device-names.js +26 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.device-names.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.file-names.js +36 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.file-names.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.file-transfer.js +155 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.file-transfer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.frame-reader.js +98 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.frame-reader.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.frame.js +29 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.frame.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.identity-gate.js +103 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.identity-gate.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.name-match.js +32 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.name-match.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.response-type.js +64 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.response-type.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.transports.js +143 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.transports.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/polling-command-sequencer.js +38 -0
- package/lib/commonjs/modules/bt-management/services/devices/polling-command-sequencer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/sentinel-frame-reader.js +84 -0
- package/lib/commonjs/modules/bt-management/services/devices/sentinel-frame-reader.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js +130 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js +55 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.bp-monitors.js +43 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.bp-monitors.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.duo-control-device.js +113 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.duo-control-device.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.js +120 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.ecg-device.js +92 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.ecg-device.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.ecg-samples.js +64 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.ecg-samples.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.js +94 -0
- package/lib/commonjs/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.bp-monitors.js +124 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.bp-monitors.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.js +113 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.lepod.js +117 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.lepod.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.oximeters.js +82 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.oximeters.js.map +1 -0
- package/lib/commonjs/modules/bt-management/types/command-sequencer.js +6 -0
- package/lib/commonjs/modules/bt-management/types/command-sequencer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/types/custom-checksum-algorithm.js +2 -0
- package/lib/commonjs/modules/bt-management/types/custom-checksum-algorithm.js.map +1 -0
- package/lib/commonjs/modules/bt-management/types/custom-checksum-spec.js +6 -0
- package/lib/commonjs/modules/bt-management/types/custom-checksum-spec.js.map +1 -0
- package/lib/commonjs/modules/bt-management/types/custom-lepu-spec.js +2 -0
- package/lib/commonjs/modules/bt-management/types/custom-lepu-spec.js.map +1 -0
- package/lib/commonjs/modules/bt-management/types/custom-measurement-spec.js +6 -0
- package/lib/commonjs/modules/bt-management/types/custom-measurement-spec.js.map +1 -0
- package/lib/commonjs/modules/bt-management/types/device-command.js +2 -0
- package/lib/commonjs/modules/bt-management/types/device-command.js.map +1 -0
- package/lib/commonjs/modules/bt-management/types/integrated-devices.js +2 -0
- package/lib/commonjs/modules/bt-management/types/integrated-devices.js.map +1 -1
- package/lib/commonjs/modules/bt-management/types/measurement-group.js +6 -0
- package/lib/commonjs/modules/bt-management/types/measurement-group.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/calculate-checksum.js +49 -0
- package/lib/commonjs/modules/bt-management/utils/calculate-checksum.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/create-custom-field-parser.js +21 -0
- package/lib/commonjs/modules/bt-management/utils/create-custom-field-parser.js.map +1 -1
- package/lib/commonjs/modules/bt-management/utils/create-frame-validator.js +9 -0
- package/lib/commonjs/modules/bt-management/utils/create-frame-validator.js.map +1 -1
- package/lib/commonjs/modules/bt-management/utils/hex-to-bytes.js +19 -0
- package/lib/commonjs/modules/bt-management/utils/hex-to-bytes.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/le-32-to-bytes.js +13 -0
- package/lib/commonjs/modules/bt-management/utils/le-32-to-bytes.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/parse-measurement.js +10 -7
- package/lib/commonjs/modules/bt-management/utils/parse-measurement.js.map +1 -1
- package/lib/commonjs/modules/bt-management/utils/reject-custom-reading.js +34 -0
- package/lib/commonjs/modules/bt-management/utils/reject-custom-reading.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/summarise-measurement-for-log.js +22 -0
- package/lib/commonjs/modules/bt-management/utils/summarise-measurement-for-log.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/supported-measurement-type-keys.js +18 -0
- package/lib/commonjs/modules/bt-management/utils/supported-measurement-type-keys.js.map +1 -0
- package/lib/module/modules/bt-device/constants/device-instruction-pdfs.js +3 -1
- package/lib/module/modules/bt-device/constants/device-instruction-pdfs.js.map +1 -1
- package/lib/module/modules/bt-management/constants/integrated-devices-map.js +1 -1
- package/lib/module/modules/bt-management/constants/integrated-devices-map.js.map +1 -1
- package/lib/module/modules/bt-management/index.js +20 -0
- package/lib/module/modules/bt-management/index.js.map +1 -1
- package/lib/module/modules/bt-management/services/custom/compile-case-fields.js +44 -0
- package/lib/module/modules/bt-management/services/custom/compile-case-fields.js.map +1 -0
- package/lib/module/modules/bt-management/services/custom/compile-case-shape.js +48 -0
- package/lib/module/modules/bt-management/services/custom/compile-case-shape.js.map +1 -0
- package/lib/module/modules/bt-management/services/custom/compile-custom-case.js +53 -41
- package/lib/module/modules/bt-management/services/custom/compile-custom-case.js.map +1 -1
- package/lib/module/modules/bt-management/services/custom/compile-custom-field.js +3 -0
- package/lib/module/modules/bt-management/services/custom/compile-custom-field.js.map +1 -1
- package/lib/module/modules/bt-management/services/custom/compile-custom-frame.js +48 -2
- package/lib/module/modules/bt-management/services/custom/compile-custom-frame.js.map +1 -1
- package/lib/module/modules/bt-management/services/custom/compile-custom-lepu.js +93 -0
- package/lib/module/modules/bt-management/services/custom/compile-custom-lepu.js.map +1 -0
- package/lib/module/modules/bt-management/services/custom/define-custom-device.js +24 -1
- package/lib/module/modules/bt-management/services/custom/define-custom-device.js.map +1 -1
- package/lib/module/modules/bt-management/services/device-creator.js +20 -8
- package/lib/module/modules/bt-management/services/device-creator.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/aoj/aoj.thermometers.js +81 -0
- package/lib/module/modules/bt-management/services/devices/aoj/aoj.thermometers.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/bp2/bp2.frame-reader.js +8 -73
- package/lib/module/modules/bt-management/services/devices/bp2/bp2.frame-reader.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-command-writer.js +150 -0
- package/lib/module/modules/bt-management/services/devices/bt-command-writer.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/bt-connection-handler.js +9 -49
- package/lib/module/modules/bt-management/services/devices/bt-connection-handler.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-data-processor.js +17 -6
- package/lib/module/modules/bt-management/services/devices/bt-data-processor.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-managed-device.js +21 -14
- package/lib/module/modules/bt-management/services/devices/bt-managed-device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js +51 -0
- package/lib/module/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/custom/custom.device.js +82 -29
- package/lib/module/modules/bt-management/services/devices/custom/custom.device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/frame-parser.js +2 -1
- package/lib/module/modules/bt-management/services/devices/frame-parser.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.command-builder.js +43 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.command-builder.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.commands.js +33 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.commands.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.device-info.js +79 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.device-info.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.device-names.js +22 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.device-names.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.file-names.js +32 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.file-names.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.file-transfer.js +150 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.file-transfer.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.frame-reader.js +93 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.frame-reader.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.frame.js +24 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.frame.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.identity-gate.js +98 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.identity-gate.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.name-match.js +27 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.name-match.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.response-type.js +59 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.response-type.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.transports.js +140 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.transports.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/polling-command-sequencer.js +34 -0
- package/lib/module/modules/bt-management/services/devices/polling-command-sequencer.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/sentinel-frame-reader.js +79 -0
- package/lib/module/modules/bt-management/services/devices/sentinel-frame-reader.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js +123 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js +50 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.bp-monitors.js +38 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.bp-monitors.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.duo-control-device.js +108 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.duo-control-device.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.js +116 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.ecg-device.js +87 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.ecg-device.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.ecg-samples.js +60 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.ecg-samples.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.js +89 -0
- package/lib/module/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.bp-monitors.js +118 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.bp-monitors.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.js +108 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.lepod.js +114 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.lepod.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.oximeters.js +79 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.oximeters.js.map +1 -0
- package/lib/module/modules/bt-management/types/command-sequencer.js +4 -0
- package/lib/module/modules/bt-management/types/command-sequencer.js.map +1 -0
- package/lib/module/modules/bt-management/types/custom-checksum-algorithm.js +2 -0
- package/lib/module/modules/bt-management/types/custom-checksum-algorithm.js.map +1 -0
- package/lib/module/modules/bt-management/types/custom-checksum-spec.js +4 -0
- package/lib/module/modules/bt-management/types/custom-checksum-spec.js.map +1 -0
- package/lib/module/modules/bt-management/types/custom-device-definition.js.map +1 -1
- package/lib/module/modules/bt-management/types/custom-lepu-spec.js +2 -0
- package/lib/module/modules/bt-management/types/custom-lepu-spec.js.map +1 -0
- package/lib/module/modules/bt-management/types/custom-measurement-spec.js +4 -0
- package/lib/module/modules/bt-management/types/custom-measurement-spec.js.map +1 -0
- package/lib/module/modules/bt-management/types/device-command.js +2 -0
- package/lib/module/modules/bt-management/types/device-command.js.map +1 -0
- package/lib/module/modules/bt-management/types/device-measurement-map.js +3 -3
- package/lib/module/modules/bt-management/types/device-measurement-map.js.map +1 -1
- package/lib/module/modules/bt-management/types/integrated-devices.js +2 -0
- package/lib/module/modules/bt-management/types/integrated-devices.js.map +1 -1
- package/lib/module/modules/bt-management/types/measurement-group.js +4 -0
- package/lib/module/modules/bt-management/types/measurement-group.js.map +1 -0
- package/lib/module/modules/bt-management/utils/calculate-checksum.js +44 -0
- package/lib/module/modules/bt-management/utils/calculate-checksum.js.map +1 -0
- package/lib/module/modules/bt-management/utils/create-custom-field-parser.js +21 -0
- package/lib/module/modules/bt-management/utils/create-custom-field-parser.js.map +1 -1
- package/lib/module/modules/bt-management/utils/create-frame-validator.js +9 -0
- package/lib/module/modules/bt-management/utils/create-frame-validator.js.map +1 -1
- package/lib/module/modules/bt-management/utils/hex-to-bytes.js +14 -0
- package/lib/module/modules/bt-management/utils/hex-to-bytes.js.map +1 -0
- package/lib/module/modules/bt-management/utils/le-32-to-bytes.js +8 -0
- package/lib/module/modules/bt-management/utils/le-32-to-bytes.js.map +1 -0
- package/lib/module/modules/bt-management/utils/parse-measurement.js +10 -7
- package/lib/module/modules/bt-management/utils/parse-measurement.js.map +1 -1
- package/lib/module/modules/bt-management/utils/reject-custom-reading.js +29 -0
- package/lib/module/modules/bt-management/utils/reject-custom-reading.js.map +1 -0
- package/lib/module/modules/bt-management/utils/summarise-measurement-for-log.js +17 -0
- package/lib/module/modules/bt-management/utils/summarise-measurement-for-log.js.map +1 -0
- package/lib/module/modules/bt-management/utils/supported-measurement-type-keys.js +13 -0
- package/lib/module/modules/bt-management/utils/supported-measurement-type-keys.js.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-device/constants/device-instruction-pdfs.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/constants/integrated-devices-map.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/index.d.ts +20 -0
- package/lib/typescript/commonjs/src/modules/bt-management/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-case-fields.d.ts +13 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-case-fields.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-case-shape.d.ts +19 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-case-shape.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-custom-case.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-custom-field.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-custom-frame.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-custom-lepu.d.ts +11 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-custom-lepu.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/define-custom-device.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/device-creator.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/aoj/aoj.thermometers.d.ts +24 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/aoj/aoj.thermometers.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bp2/bp2.frame-reader.d.ts +5 -8
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bp2/bp2.frame-reader.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-command-writer.d.ts +74 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-command-writer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-connection-handler.d.ts +6 -4
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-connection-handler.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-data-processor.d.ts +20 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-data-processor.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-managed-device.d.ts +12 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-managed-device.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts +30 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom.device.d.ts +32 -2
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom.device.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/frame-parser.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.command-builder.d.ts +24 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.command-builder.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.commands.d.ts +32 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.commands.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.device-info.d.ts +27 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.device-info.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.device-names.d.ts +20 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.device-names.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.file-names.d.ts +14 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.file-names.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.file-transfer.d.ts +75 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.file-transfer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.frame-reader.d.ts +28 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.frame-reader.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.frame.d.ts +12 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.frame.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.identity-gate.d.ts +81 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.identity-gate.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.name-match.d.ts +17 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.name-match.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.response-type.d.ts +33 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.response-type.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.transports.d.ts +85 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.transports.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/polling-command-sequencer.d.ts +27 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/polling-command-sequencer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/sentinel-frame-reader.d.ts +52 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/sentinel-frame-reader.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.d.ts +53 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.d.ts +45 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.bp-monitors.d.ts +18 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.bp-monitors.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.duo-control-device.d.ts +19 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.duo-control-device.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.d.ts +45 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.ecg-device.d.ts +30 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.ecg-device.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.ecg-samples.d.ts +39 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.ecg-samples.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.d.ts +35 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.bp-monitors.d.ts +44 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.bp-monitors.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.d.ts +32 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.lepod.d.ts +25 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.lepod.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.oximeters.d.ts +39 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.oximeters.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/command-sequencer.d.ts +26 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/command-sequencer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-case-spec.d.ts +43 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-case-spec.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-checksum-algorithm.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-checksum-algorithm.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-checksum-spec.d.ts +23 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-checksum-spec.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-device-definition.d.ts +5 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-device-definition.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-device-spec.d.ts +12 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-device-spec.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-field-encoding.d.ts +7 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-field-encoding.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-frame-spec.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-frame-spec.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-lepu-spec.d.ts +44 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-lepu-spec.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-measurement-spec.d.ts +9 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-measurement-spec.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/dependent-result-handler-params.d.ts +7 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/dependent-result-handler-params.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-command.d.ts +27 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-command.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-measurement-map.d.ts +2 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-measurement-map.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/integrated-devices.d.ts +3 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/integrated-devices.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/measurement-group.d.ts +14 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/measurement-group.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/parsing-case.d.ts +17 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/parsing-case.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/calculate-checksum.d.ts +13 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/calculate-checksum.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/create-custom-field-parser.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/create-frame-validator.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/hex-to-bytes.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/hex-to-bytes.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/le-32-to-bytes.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/le-32-to-bytes.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/parse-measurement.d.ts +4 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/parse-measurement.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/reject-custom-reading.d.ts +15 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/reject-custom-reading.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/summarise-measurement-for-log.d.ts +9 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/summarise-measurement-for-log.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/supported-measurement-type-keys.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/supported-measurement-type-keys.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-device/constants/device-instruction-pdfs.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/constants/integrated-devices-map.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/index.d.ts +20 -0
- package/lib/typescript/module/src/modules/bt-management/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-case-fields.d.ts +13 -0
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-case-fields.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-case-shape.d.ts +19 -0
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-case-shape.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-custom-case.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-custom-field.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-custom-frame.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-custom-lepu.d.ts +11 -0
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-custom-lepu.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/custom/define-custom-device.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/device-creator.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/aoj/aoj.thermometers.d.ts +24 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/aoj/aoj.thermometers.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bp2/bp2.frame-reader.d.ts +5 -8
- package/lib/typescript/module/src/modules/bt-management/services/devices/bp2/bp2.frame-reader.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-command-writer.d.ts +74 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-command-writer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-connection-handler.d.ts +6 -4
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-connection-handler.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-data-processor.d.ts +20 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-data-processor.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-managed-device.d.ts +12 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-managed-device.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts +30 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom.device.d.ts +32 -2
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom.device.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/frame-parser.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.command-builder.d.ts +24 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.command-builder.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.commands.d.ts +32 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.commands.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.device-info.d.ts +27 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.device-info.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.device-names.d.ts +20 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.device-names.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.file-names.d.ts +14 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.file-names.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.file-transfer.d.ts +75 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.file-transfer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.frame-reader.d.ts +28 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.frame-reader.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.frame.d.ts +12 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.frame.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.identity-gate.d.ts +81 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.identity-gate.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.name-match.d.ts +17 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.name-match.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.response-type.d.ts +33 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.response-type.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.transports.d.ts +85 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.transports.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/polling-command-sequencer.d.ts +27 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/polling-command-sequencer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/sentinel-frame-reader.d.ts +52 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/sentinel-frame-reader.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.d.ts +53 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.d.ts +45 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.bp-monitors.d.ts +18 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.bp-monitors.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.duo-control-device.d.ts +19 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.duo-control-device.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.d.ts +45 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.ecg-device.d.ts +30 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.ecg-device.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.ecg-samples.d.ts +39 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.ecg-samples.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.d.ts +35 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.bp-monitors.d.ts +44 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.bp-monitors.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.d.ts +32 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.lepod.d.ts +25 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.lepod.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.oximeters.d.ts +39 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.oximeters.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/command-sequencer.d.ts +26 -0
- package/lib/typescript/module/src/modules/bt-management/types/command-sequencer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-case-spec.d.ts +43 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-case-spec.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/custom-checksum-algorithm.d.ts +10 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-checksum-algorithm.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-checksum-spec.d.ts +23 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-checksum-spec.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-device-definition.d.ts +5 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-device-definition.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/custom-device-spec.d.ts +12 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-device-spec.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/custom-field-encoding.d.ts +7 -1
- package/lib/typescript/module/src/modules/bt-management/types/custom-field-encoding.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/custom-frame-spec.d.ts +8 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-frame-spec.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/custom-lepu-spec.d.ts +44 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-lepu-spec.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-measurement-spec.d.ts +9 -0
- package/lib/typescript/module/src/modules/bt-management/types/custom-measurement-spec.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/dependent-result-handler-params.d.ts +7 -0
- package/lib/typescript/module/src/modules/bt-management/types/dependent-result-handler-params.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/device-command.d.ts +27 -0
- package/lib/typescript/module/src/modules/bt-management/types/device-command.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/device-measurement-map.d.ts +2 -0
- package/lib/typescript/module/src/modules/bt-management/types/device-measurement-map.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/integrated-devices.d.ts +3 -1
- package/lib/typescript/module/src/modules/bt-management/types/integrated-devices.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/measurement-group.d.ts +14 -0
- package/lib/typescript/module/src/modules/bt-management/types/measurement-group.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/parsing-case.d.ts +17 -0
- package/lib/typescript/module/src/modules/bt-management/types/parsing-case.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/calculate-checksum.d.ts +13 -0
- package/lib/typescript/module/src/modules/bt-management/utils/calculate-checksum.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/create-custom-field-parser.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/create-frame-validator.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/hex-to-bytes.d.ts +10 -0
- package/lib/typescript/module/src/modules/bt-management/utils/hex-to-bytes.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/le-32-to-bytes.d.ts +3 -0
- package/lib/typescript/module/src/modules/bt-management/utils/le-32-to-bytes.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/parse-measurement.d.ts +4 -1
- package/lib/typescript/module/src/modules/bt-management/utils/parse-measurement.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/reject-custom-reading.d.ts +15 -0
- package/lib/typescript/module/src/modules/bt-management/utils/reject-custom-reading.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/summarise-measurement-for-log.d.ts +9 -0
- package/lib/typescript/module/src/modules/bt-management/utils/summarise-measurement-for-log.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/supported-measurement-type-keys.d.ts +10 -0
- package/lib/typescript/module/src/modules/bt-management/utils/supported-measurement-type-keys.d.ts.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["hexToByte","LepuCommand","parseLepuDeviceInfo","describeLepuResponseType","isLepuSuccess","COMMAND_INDEX","LepuIdentityGate","isIdentified","isRefused","constructor","params","initialCommands","commandFor","GET_INFO","nextCommand","frame","undefined","poll","admit","refuse","info","onIdentified","pollCommand","isNarrowed","expectedDeviceTypes","length","includes","deviceType","branchCode","reason","onRefused","command","write","builder","build"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/lepu/lepu.identity-gate.ts"],"mappings":"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","ignoreList":[]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { LEPU_DEVICE_NAMES } from "./lepu.device-names.js";
|
|
4
|
+
const REGEXP_SPECIAL = /[.*+?^${}()|[\]\\]/g;
|
|
5
|
+
const escapeRegExp = value => value.replace(REGEXP_SPECIAL, "\\$&");
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Builds a matcher for one advertised name that cannot also match a longer one.
|
|
9
|
+
*
|
|
10
|
+
* The vendor tests these names with a substring check in a hand-ordered cascade, so `BP2`
|
|
11
|
+
* only fails to match a BP2W because `BP2W` happens to be checked first. Order is a fragile
|
|
12
|
+
* place to keep a safety property: it lives in whoever wrote the list, is invisible at the
|
|
13
|
+
* point of use, and an insertion in the wrong place silently binds the wrong driver.
|
|
14
|
+
*
|
|
15
|
+
* Here the exclusions are derived instead. Every name in the vocabulary that extends this
|
|
16
|
+
* one becomes a negative lookahead, so the matcher is correct wherever it is used and in
|
|
17
|
+
* whatever order it is tried.
|
|
18
|
+
*
|
|
19
|
+
* The match is deliberately open at the end, because these devices advertise a serial after
|
|
20
|
+
* the model - `BP2 1234` - and the serial's shape varies across the family.
|
|
21
|
+
*/
|
|
22
|
+
export const lepuNameMatch = (name, vocabulary = LEPU_DEVICE_NAMES) => {
|
|
23
|
+
const extensions = vocabulary.filter(other => other !== name && other.startsWith(name)).map(other => escapeRegExp(other.slice(name.length)));
|
|
24
|
+
const exclusion = extensions.length > 0 ? `(?!${extensions.join("|")})` : "";
|
|
25
|
+
return new RegExp(`^${escapeRegExp(name)}${exclusion}`);
|
|
26
|
+
};
|
|
27
|
+
//# sourceMappingURL=lepu.name-match.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["LEPU_DEVICE_NAMES","REGEXP_SPECIAL","escapeRegExp","value","replace","lepuNameMatch","name","vocabulary","extensions","filter","other","startsWith","map","slice","length","exclusion","join","RegExp"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/lepu/lepu.name-match.ts"],"mappings":";;AAAA,SAASA,iBAAiB,QAAQ,wBAAqB;AAEvD,MAAMC,cAAc,GAAG,qBAAqB;AAE5C,MAAMC,YAAY,GAAIC,KAAa,IACjCA,KAAK,CAACC,OAAO,CAACH,cAAc,EAAE,MAAM,CAAC;;AAEvC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMI,aAAa,GAAGA,CAC3BC,IAAY,EACZC,UAA6B,GAAGP,iBAAiB,KACtC;EACX,MAAMQ,UAAU,GAAGD,UAAU,CAC1BE,MAAM,CAAEC,KAAK,IAAKA,KAAK,KAAKJ,IAAI,IAAII,KAAK,CAACC,UAAU,CAACL,IAAI,CAAC,CAAC,CAC3DM,GAAG,CAAEF,KAAK,IAAKR,YAAY,CAACQ,KAAK,CAACG,KAAK,CAACP,IAAI,CAACQ,MAAM,CAAC,CAAC,CAAC;EAEzD,MAAMC,SAAS,GACbP,UAAU,CAACM,MAAM,GAAG,CAAC,GAAG,MAAMN,UAAU,CAACQ,IAAI,CAAC,GAAG,CAAC,GAAG,GAAG,EAAE;EAE5D,OAAO,IAAIC,MAAM,CAAC,IAAIf,YAAY,CAACI,IAAI,CAAC,GAAGS,SAAS,EAAE,CAAC;AACzD,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { hexToByte } from "../../../utils/hex-to-byte.js";
|
|
4
|
+
|
|
5
|
+
/** Byte 3 of every frame: the direction on a request, the outcome on a reply. */
|
|
6
|
+
const RESPONSE_TYPE_INDEX = 3;
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* What a Lepu device says about the request it just answered.
|
|
10
|
+
*
|
|
11
|
+
* Only `SUCCESS` means the payload holds what was asked for. Every other value is an error
|
|
12
|
+
* whose payload is not the requested data, so a reply has to be checked before it is
|
|
13
|
+
* decoded - otherwise a refusal is read as a reading, out of whatever bytes happen to
|
|
14
|
+
* follow the header.
|
|
15
|
+
*/
|
|
16
|
+
const LepuResponseType = {
|
|
17
|
+
/** A request, phone to device. Never seen on a reply. */
|
|
18
|
+
REQUEST: 0x00,
|
|
19
|
+
SUCCESS: 0x01,
|
|
20
|
+
/** The device rejected our checksum. */
|
|
21
|
+
CRC_ERROR: 0x02,
|
|
22
|
+
FILE_NOT_FOUND: 0xe0,
|
|
23
|
+
FILE_READ_FAILED: 0xe1,
|
|
24
|
+
FILE_WRITE_FAILED: 0xe2,
|
|
25
|
+
PARAMETER_ILLEGAL: 0xf1,
|
|
26
|
+
PERMISSION_DENIED: 0xf2,
|
|
27
|
+
DECRYPT_FAILED: 0xf3,
|
|
28
|
+
/** Mid-measurement or otherwise occupied. Worth backing off rather than giving up. */
|
|
29
|
+
DEVICE_BUSY: 0xfb,
|
|
30
|
+
COMMAND_FORMAT_ERROR: 0xfc,
|
|
31
|
+
/** The opcode is unknown to this firmware, which is how a feature is detected. */
|
|
32
|
+
COMMAND_NOT_SUPPORTED: 0xfd,
|
|
33
|
+
ERROR: 0xff
|
|
34
|
+
};
|
|
35
|
+
const RESPONSE_TYPE_NAMES = {
|
|
36
|
+
[LepuResponseType.CRC_ERROR]: "it rejected our checksum",
|
|
37
|
+
[LepuResponseType.FILE_NOT_FOUND]: "the file does not exist",
|
|
38
|
+
[LepuResponseType.FILE_READ_FAILED]: "the file could not be read",
|
|
39
|
+
[LepuResponseType.FILE_WRITE_FAILED]: "the file could not be written",
|
|
40
|
+
[LepuResponseType.PARAMETER_ILLEGAL]: "the parameter was rejected",
|
|
41
|
+
[LepuResponseType.PERMISSION_DENIED]: "permission was denied",
|
|
42
|
+
[LepuResponseType.DECRYPT_FAILED]: "it could not decrypt the request",
|
|
43
|
+
[LepuResponseType.DEVICE_BUSY]: "it is busy",
|
|
44
|
+
[LepuResponseType.COMMAND_FORMAT_ERROR]: "the command was malformed",
|
|
45
|
+
[LepuResponseType.COMMAND_NOT_SUPPORTED]: "the opcode is unknown to this firmware",
|
|
46
|
+
[LepuResponseType.ERROR]: "it reported a generic error"
|
|
47
|
+
};
|
|
48
|
+
const lepuResponseType = frame => hexToByte(frame[RESPONSE_TYPE_INDEX] ?? "0");
|
|
49
|
+
const isLepuSuccess = frame => lepuResponseType(frame) === LepuResponseType.SUCCESS;
|
|
50
|
+
|
|
51
|
+
/** Why a device refused, in words, for an error a person will read. */
|
|
52
|
+
const describeLepuResponseType = frame => {
|
|
53
|
+
const type = lepuResponseType(frame);
|
|
54
|
+
const known = RESPONSE_TYPE_NAMES[type];
|
|
55
|
+
const code = `0x${type.toString(16).padStart(2, "0")}`;
|
|
56
|
+
return known ? `${known} (${code})` : `it answered with ${code}`;
|
|
57
|
+
};
|
|
58
|
+
export { describeLepuResponseType, isLepuSuccess, LepuResponseType, lepuResponseType };
|
|
59
|
+
//# sourceMappingURL=lepu.response-type.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["hexToByte","RESPONSE_TYPE_INDEX","LepuResponseType","REQUEST","SUCCESS","CRC_ERROR","FILE_NOT_FOUND","FILE_READ_FAILED","FILE_WRITE_FAILED","PARAMETER_ILLEGAL","PERMISSION_DENIED","DECRYPT_FAILED","DEVICE_BUSY","COMMAND_FORMAT_ERROR","COMMAND_NOT_SUPPORTED","ERROR","RESPONSE_TYPE_NAMES","lepuResponseType","frame","isLepuSuccess","describeLepuResponseType","type","known","code","toString","padStart"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/lepu/lepu.response-type.ts"],"mappings":";;AAAA,SAASA,SAAS,QAAQ,+BAA4B;;AAEtD;AACA,MAAMC,mBAAmB,GAAG,CAAC;;AAE7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,gBAAgB,GAAG;EACvB;EACAC,OAAO,EAAE,IAAI;EAEbC,OAAO,EAAE,IAAI;EAEb;EACAC,SAAS,EAAE,IAAI;EAEfC,cAAc,EAAE,IAAI;EACpBC,gBAAgB,EAAE,IAAI;EACtBC,iBAAiB,EAAE,IAAI;EACvBC,iBAAiB,EAAE,IAAI;EACvBC,iBAAiB,EAAE,IAAI;EACvBC,cAAc,EAAE,IAAI;EAEpB;EACAC,WAAW,EAAE,IAAI;EAEjBC,oBAAoB,EAAE,IAAI;EAE1B;EACAC,qBAAqB,EAAE,IAAI;EAE3BC,KAAK,EAAE;AACT,CAAU;AAEV,MAAMC,mBAAqD,GAAG;EAC5D,CAACd,gBAAgB,CAACG,SAAS,GAAG,0BAA0B;EACxD,CAACH,gBAAgB,CAACI,cAAc,GAAG,yBAAyB;EAC5D,CAACJ,gBAAgB,CAACK,gBAAgB,GAAG,4BAA4B;EACjE,CAACL,gBAAgB,CAACM,iBAAiB,GAAG,+BAA+B;EACrE,CAACN,gBAAgB,CAACO,iBAAiB,GAAG,4BAA4B;EAClE,CAACP,gBAAgB,CAACQ,iBAAiB,GAAG,uBAAuB;EAC7D,CAACR,gBAAgB,CAACS,cAAc,GAAG,kCAAkC;EACrE,CAACT,gBAAgB,CAACU,WAAW,GAAG,YAAY;EAC5C,CAACV,gBAAgB,CAACW,oBAAoB,GAAG,2BAA2B;EACpE,CAACX,gBAAgB,CAACY,qBAAqB,GACrC,wCAAwC;EAC1C,CAACZ,gBAAgB,CAACa,KAAK,GAAG;AAC5B,CAAC;AAED,MAAME,gBAAgB,GAAIC,KAAwB,IAChDlB,SAAS,CAACkB,KAAK,CAACjB,mBAAmB,CAAC,IAAI,GAAG,CAAC;AAE9C,MAAMkB,aAAa,GAAID,KAAwB,IAC7CD,gBAAgB,CAACC,KAAK,CAAC,KAAKhB,gBAAgB,CAACE,OAAO;;AAEtD;AACA,MAAMgB,wBAAwB,GAAIF,KAAwB,IAAa;EACrE,MAAMG,IAAI,GAAGJ,gBAAgB,CAACC,KAAK,CAAC;EACpC,MAAMI,KAAK,GAAGN,mBAAmB,CAACK,IAAI,CAAC;EACvC,MAAME,IAAI,GAAG,KAAKF,IAAI,CAACG,QAAQ,CAAC,EAAE,CAAC,CAACC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE;EAEtD,OAAOH,KAAK,GAAG,GAAGA,KAAK,KAAKC,IAAI,GAAG,GAAG,oBAAoBA,IAAI,EAAE;AAClE,CAAC;AAED,SACEH,wBAAwB,EACxBD,aAAa,EACbjB,gBAAgB,EAChBe,gBAAgB","ignoreList":[]}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { defineCustomDevice } from "../../custom/define-custom-device.js";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Declares a device from the Lepu/Viatom family.
|
|
7
|
+
*
|
|
8
|
+
* Thirty products in that family share one frame format, one CRC and one generic opcode
|
|
9
|
+
* space, and they differ in only three things: which characteristics they expose, what
|
|
10
|
+
* their payload means, and what they call themselves. The first of those is the same for
|
|
11
|
+
* almost all of them and is recorded here; the other two belong to the product and are
|
|
12
|
+
* asked of the caller.
|
|
13
|
+
*
|
|
14
|
+
* Two things a declaration cannot supply, and where they come from:
|
|
15
|
+
*
|
|
16
|
+
* - **The model numbers.** A device reports one in its information reply, but the vendor's
|
|
17
|
+
* own SDK never reads that field back - it binds a driver from the advertised name - so
|
|
18
|
+
* no table of them exists to copy. Declare the device without a `pollCommand`, connect
|
|
19
|
+
* once, and it reports what it is without sending anything that acts.
|
|
20
|
+
* - **The payload layout.** Every product decodes differently, and a guessed offset yields
|
|
21
|
+
* a plausible wrong reading rather than an error. Declared cases are the caller's.
|
|
22
|
+
*
|
|
23
|
+
* Some of these products negotiate encryption in the vendor app (`Bp2`, `Er2` and the
|
|
24
|
+
* oximeters do; `Er1`, `Er3`, `Bp3` and `Lepod` do not). The SDK speaks the cleartext
|
|
25
|
+
* protocol, which is what the BP2 already runs on in production, so a product that turns out
|
|
26
|
+
* to require the handshake will identify itself and then stop rather than mis-report.
|
|
27
|
+
*/
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Most of the family. The vendor's own SDK reference lists 71 products on these three
|
|
31
|
+
* characteristics - the BP2 and BP3 monitors, Er1/Er2/Er3, Lepod, the whole O2Ring and
|
|
32
|
+
* Oxyfit range, Checkme, AirBp - and the SDK's own BP2 driver has run against them on real
|
|
33
|
+
* hardware.
|
|
34
|
+
*/
|
|
35
|
+
const STANDARD_SERVICE = "14839ac4-7d7e-415c-9a42-167340cf2339";
|
|
36
|
+
const STANDARD_WRITE = "8b00ace7-eb0b-49b0-bbe9-9aee0a26e1a3";
|
|
37
|
+
const STANDARD_NOTIFY = "0734594a-a8e7-4b1a-a6b1-cd5243059a57";
|
|
38
|
+
|
|
39
|
+
/** Nine products in the vendor's reference: O2Ring S, the PF-10 wearables and the BBSM bands. */
|
|
40
|
+
const AW1_SERVICE = "e8fb0001-a14b-98f9-831b-4e2941d01248";
|
|
41
|
+
const AW1_WRITE = "e8fb0002-a14b-98f9-831b-4e2941d01248";
|
|
42
|
+
const AW1_NOTIFY = "e8fb0003-a14b-98f9-831b-4e2941d01248";
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Read from an OEM build rather than from the vendor's published reference, which documents
|
|
46
|
+
* no product on these characteristics. Real, but unconfirmed by the vendor and untried here.
|
|
47
|
+
*/
|
|
48
|
+
const DING_SERVICE = "0000fe60-0000-1000-8000-00805f9b34fb";
|
|
49
|
+
const DING_WRITE = "0000fe61-0000-1000-8000-00805f9b34fb";
|
|
50
|
+
const DING_NOTIFY = "0000fe62-0000-1000-8000-00805f9b34fb";
|
|
51
|
+
|
|
52
|
+
/** Also from an OEM build only, and likewise absent from the vendor's published reference. */
|
|
53
|
+
const AI_TELE_SERVICE = "00002760-08c2-11e1-9073-0e8ac72e5450";
|
|
54
|
+
const AI_TELE_WRITE = "00002760-08c2-11e1-9073-0e8ac72e5401";
|
|
55
|
+
const AI_TELE_NOTIFY = "00002760-08c2-11e1-9073-0e8ac72e5402";
|
|
56
|
+
|
|
57
|
+
/** What the vendor app asks for on every one of these links but the Er2's. */
|
|
58
|
+
const PREFERRED_MTU = 247;
|
|
59
|
+
|
|
60
|
+
/** The Er2 negotiates the link minimum, which is why commands are split to fit. */
|
|
61
|
+
const MINIMUM_MTU = 23;
|
|
62
|
+
|
|
63
|
+
/** Long enough for a device that waits on a person to start a measurement. */
|
|
64
|
+
const DEFAULT_STUCK_TIMEOUT_MS = 60_000;
|
|
65
|
+
const START_BYTE = "a5";
|
|
66
|
+
/**
|
|
67
|
+
* The characteristics each group of products exposes, read from the vendor's own managers.
|
|
68
|
+
*
|
|
69
|
+
* `standard` and `aw1` match the vendor's published SDK reference exactly, and `standard`
|
|
70
|
+
* also matches the SDK's existing BP2 driver, which has run against hardware on precisely
|
|
71
|
+
* these UUIDs. `ding` and `aiTele` were read from an OEM build and the vendor documents no
|
|
72
|
+
* product on them, so they are the two entries here that nothing independent confirms.
|
|
73
|
+
*/
|
|
74
|
+
const lepuTransports = {
|
|
75
|
+
standard: {
|
|
76
|
+
serviceUuid: STANDARD_SERVICE,
|
|
77
|
+
notifyUuid: STANDARD_NOTIFY,
|
|
78
|
+
writeUuid: STANDARD_WRITE,
|
|
79
|
+
preferredMtu: PREFERRED_MTU
|
|
80
|
+
},
|
|
81
|
+
/** The same characteristics on a link that will not grow past the minimum. */
|
|
82
|
+
standardSmallMtu: {
|
|
83
|
+
serviceUuid: STANDARD_SERVICE,
|
|
84
|
+
notifyUuid: STANDARD_NOTIFY,
|
|
85
|
+
writeUuid: STANDARD_WRITE,
|
|
86
|
+
preferredMtu: MINIMUM_MTU
|
|
87
|
+
},
|
|
88
|
+
aw1: {
|
|
89
|
+
serviceUuid: AW1_SERVICE,
|
|
90
|
+
notifyUuid: AW1_NOTIFY,
|
|
91
|
+
writeUuid: AW1_WRITE,
|
|
92
|
+
preferredMtu: PREFERRED_MTU
|
|
93
|
+
},
|
|
94
|
+
ding: {
|
|
95
|
+
serviceUuid: DING_SERVICE,
|
|
96
|
+
notifyUuid: DING_NOTIFY,
|
|
97
|
+
writeUuid: DING_WRITE,
|
|
98
|
+
preferredMtu: PREFERRED_MTU
|
|
99
|
+
},
|
|
100
|
+
aiTele: {
|
|
101
|
+
serviceUuid: AI_TELE_SERVICE,
|
|
102
|
+
notifyUuid: AI_TELE_NOTIFY,
|
|
103
|
+
writeUuid: AI_TELE_WRITE,
|
|
104
|
+
preferredMtu: PREFERRED_MTU
|
|
105
|
+
}
|
|
106
|
+
};
|
|
107
|
+
const COMMAND_BYTE = 1;
|
|
108
|
+
const lepuDevice = params => {
|
|
109
|
+
const transport = lepuTransports[params.transport ?? "standard"];
|
|
110
|
+
return defineCustomDevice({
|
|
111
|
+
id: params.id,
|
|
112
|
+
nameMatch: params.nameMatch,
|
|
113
|
+
stuckDataTimeoutMs: params.stuckDataTimeoutMs ?? DEFAULT_STUCK_TIMEOUT_MS,
|
|
114
|
+
preferredMtu: transport.preferredMtu,
|
|
115
|
+
lepu: {
|
|
116
|
+
startBytes: [START_BYTE],
|
|
117
|
+
write: {
|
|
118
|
+
serviceUuid: transport.serviceUuid,
|
|
119
|
+
characteristicUuid: transport.writeUuid
|
|
120
|
+
},
|
|
121
|
+
expectedDeviceTypes: [...(params.expectedDeviceTypes ?? [])],
|
|
122
|
+
...(params.pollCommand === undefined ? {} : {
|
|
123
|
+
pollCommand: params.pollCommand
|
|
124
|
+
})
|
|
125
|
+
},
|
|
126
|
+
services: [{
|
|
127
|
+
uuid: transport.serviceUuid,
|
|
128
|
+
monitor: [{
|
|
129
|
+
uuid: transport.notifyUuid,
|
|
130
|
+
frame: {
|
|
131
|
+
minLengthBytes: params.minLengthBytes
|
|
132
|
+
},
|
|
133
|
+
caseSelectorBytes: params.caseSelectorBytes ?? [COMMAND_BYTE],
|
|
134
|
+
cases: params.cases
|
|
135
|
+
}]
|
|
136
|
+
}]
|
|
137
|
+
});
|
|
138
|
+
};
|
|
139
|
+
export { lepuDevice, lepuTransports };
|
|
140
|
+
//# sourceMappingURL=lepu.transports.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["defineCustomDevice","STANDARD_SERVICE","STANDARD_WRITE","STANDARD_NOTIFY","AW1_SERVICE","AW1_WRITE","AW1_NOTIFY","DING_SERVICE","DING_WRITE","DING_NOTIFY","AI_TELE_SERVICE","AI_TELE_WRITE","AI_TELE_NOTIFY","PREFERRED_MTU","MINIMUM_MTU","DEFAULT_STUCK_TIMEOUT_MS","START_BYTE","lepuTransports","standard","serviceUuid","notifyUuid","writeUuid","preferredMtu","standardSmallMtu","aw1","ding","aiTele","COMMAND_BYTE","lepuDevice","params","transport","id","nameMatch","stuckDataTimeoutMs","lepu","startBytes","write","characteristicUuid","expectedDeviceTypes","pollCommand","undefined","services","uuid","monitor","frame","minLengthBytes","caseSelectorBytes","cases"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/lepu/lepu.transports.ts"],"mappings":";;AAEA,SAASA,kBAAkB,QAAQ,sCAAmC;;AAEtE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,gBAAgB,GAAG,sCAAsC;AAC/D,MAAMC,cAAc,GAAG,sCAAsC;AAC7D,MAAMC,eAAe,GAAG,sCAAsC;;AAE9D;AACA,MAAMC,WAAW,GAAG,sCAAsC;AAC1D,MAAMC,SAAS,GAAG,sCAAsC;AACxD,MAAMC,UAAU,GAAG,sCAAsC;;AAEzD;AACA;AACA;AACA;AACA,MAAMC,YAAY,GAAG,sCAAsC;AAC3D,MAAMC,UAAU,GAAG,sCAAsC;AACzD,MAAMC,WAAW,GAAG,sCAAsC;;AAE1D;AACA,MAAMC,eAAe,GAAG,sCAAsC;AAC9D,MAAMC,aAAa,GAAG,sCAAsC;AAC5D,MAAMC,cAAc,GAAG,sCAAsC;;AAE7D;AACA,MAAMC,aAAa,GAAG,GAAG;;AAEzB;AACA,MAAMC,WAAW,GAAG,EAAE;;AAEtB;AACA,MAAMC,wBAAwB,GAAG,MAAM;AAEvC,MAAMC,UAAU,GAAG,IAAI;AASvB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,cAAc,GAAG;EACrBC,QAAQ,EAAE;IACRC,WAAW,EAAElB,gBAAgB;IAC7BmB,UAAU,EAAEjB,eAAe;IAC3BkB,SAAS,EAAEnB,cAAc;IACzBoB,YAAY,EAAET;EAChB,CAAC;EAED;EACAU,gBAAgB,EAAE;IAChBJ,WAAW,EAAElB,gBAAgB;IAC7BmB,UAAU,EAAEjB,eAAe;IAC3BkB,SAAS,EAAEnB,cAAc;IACzBoB,YAAY,EAAER;EAChB,CAAC;EAEDU,GAAG,EAAE;IACHL,WAAW,EAAEf,WAAW;IACxBgB,UAAU,EAAEd,UAAU;IACtBe,SAAS,EAAEhB,SAAS;IACpBiB,YAAY,EAAET;EAChB,CAAC;EAEDY,IAAI,EAAE;IACJN,WAAW,EAAEZ,YAAY;IACzBa,UAAU,EAAEX,WAAW;IACvBY,SAAS,EAAEb,UAAU;IACrBc,YAAY,EAAET;EAChB,CAAC;EAEDa,MAAM,EAAE;IACNP,WAAW,EAAET,eAAe;IAC5BU,UAAU,EAAER,cAAc;IAC1BS,SAAS,EAAEV,aAAa;IACxBW,YAAY,EAAET;EAChB;AACF,CAAkD;AAmDlD,MAAMc,YAAY,GAAG,CAAC;AAEtB,MAAMC,UAAU,GAAIC,MAAwB,IAA6B;EACvE,MAAMC,SAAS,GAAGb,cAAc,CAACY,MAAM,CAACC,SAAS,IAAI,UAAU,CAAC;EAEhE,OAAO9B,kBAAkB,CAAC;IACxB+B,EAAE,EAAEF,MAAM,CAACE,EAAE;IACbC,SAAS,EAAEH,MAAM,CAACG,SAAS;IAC3BC,kBAAkB,EAAEJ,MAAM,CAACI,kBAAkB,IAAIlB,wBAAwB;IACzEO,YAAY,EAAEQ,SAAS,CAACR,YAAY;IACpCY,IAAI,EAAE;MACJC,UAAU,EAAE,CAACnB,UAAU,CAAC;MACxBoB,KAAK,EAAE;QACLjB,WAAW,EAAEW,SAAS,CAACX,WAAW;QAClCkB,kBAAkB,EAAEP,SAAS,CAACT;MAChC,CAAC;MACDiB,mBAAmB,EAAE,CAAC,IAAIT,MAAM,CAACS,mBAAmB,IAAI,EAAE,CAAC,CAAC;MAC5D,IAAIT,MAAM,CAACU,WAAW,KAAKC,SAAS,GAChC,CAAC,CAAC,GACF;QAAED,WAAW,EAAEV,MAAM,CAACU;MAAY,CAAC;IACzC,CAAC;IACDE,QAAQ,EAAE,CACR;MACEC,IAAI,EAAEZ,SAAS,CAACX,WAAW;MAC3BwB,OAAO,EAAE,CACP;QACED,IAAI,EAAEZ,SAAS,CAACV,UAAU;QAC1BwB,KAAK,EAAE;UAAEC,cAAc,EAAEhB,MAAM,CAACgB;QAAe,CAAC;QAChDC,iBAAiB,EAAEjB,MAAM,CAACiB,iBAAiB,IAAI,CAACnB,YAAY,CAAC;QAC7DoB,KAAK,EAAElB,MAAM,CAACkB;MAChB,CAAC;IAEL,CAAC;EAEL,CAAC,CAAC;AACJ,CAAC;AAED,SAASnB,UAAU,EAAEX,cAAc","ignoreList":[]}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { hexToBytes } from "../../utils/hex-to-bytes.js";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Sends the same commands on connect and after every frame.
|
|
7
|
+
*
|
|
8
|
+
* This is what the SDK did before a device could express anything else, and it remains
|
|
9
|
+
* right for the devices that only ever ask one question: a poll goes out, a reading comes
|
|
10
|
+
* back, and the answer is another poll. Keeping it as a named policy rather than as
|
|
11
|
+
* behaviour built into the transport is what lets a device replace it without every other
|
|
12
|
+
* device changing.
|
|
13
|
+
*/
|
|
14
|
+
class PollingCommandSequencer {
|
|
15
|
+
constructor(commands) {
|
|
16
|
+
this.commands = commands;
|
|
17
|
+
}
|
|
18
|
+
initialCommands = () => this.commands;
|
|
19
|
+
nextCommand = () => this.commands;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Builds the polling policy a device's declared services already describe.
|
|
24
|
+
*
|
|
25
|
+
* A service without a write characteristic contributes nothing, so a listen-only device
|
|
26
|
+
* gets an empty policy and is never written to.
|
|
27
|
+
*/
|
|
28
|
+
const pollingSequencerFor = services => new PollingCommandSequencer(services.flatMap(service => service.writeUuid ? [{
|
|
29
|
+
serviceUuid: service.uuid,
|
|
30
|
+
characteristicUuid: service.writeUuid.uuid,
|
|
31
|
+
frame: hexToBytes(service.writeUuid.mainCommandUuid)
|
|
32
|
+
}] : []));
|
|
33
|
+
export { PollingCommandSequencer, pollingSequencerFor };
|
|
34
|
+
//# sourceMappingURL=polling-command-sequencer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["hexToBytes","PollingCommandSequencer","constructor","commands","initialCommands","nextCommand","pollingSequencerFor","services","flatMap","service","writeUuid","serviceUuid","uuid","characteristicUuid","frame","mainCommandUuid"],"sourceRoot":"../../../../../../src","sources":["modules/bt-management/services/devices/polling-command-sequencer.ts"],"mappings":";;AAGA,SAASA,UAAU,QAAQ,6BAA0B;;AAErD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,uBAAuB,CAA6B;EACjDC,WAAWA,CAAkBC,QAAkC,EAAE;IAAA,KAApCA,QAAkC,GAAlCA,QAAkC;EAAG;EAElEC,eAAe,GAAGA,CAAA,KAAgC,IAAI,CAACD,QAAQ;EAE/DE,WAAW,GAAGA,CAAA,KAAgC,IAAI,CAACF,QAAQ;AACpE;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMG,mBAAmB,GACvBC,QAAuC,IAEvC,IAAIN,uBAAuB,CACzBM,QAAQ,CAACC,OAAO,CAAEC,OAAO,IACvBA,OAAO,CAACC,SAAS,GACb,CACE;EACEC,WAAW,EAAEF,OAAO,CAACG,IAAI;EACzBC,kBAAkB,EAAEJ,OAAO,CAACC,SAAS,CAACE,IAAI;EAC1CE,KAAK,EAAEd,UAAU,CAACS,OAAO,CAACC,SAAS,CAACK,eAAe;AACrD,CAAC,CACF,GACD,EACN,CACF,CAAC;AAEH,SAASd,uBAAuB,EAAEK,mBAAmB","ignoreList":[]}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { FrameReadStatus } from "../../types/frame-read-status.js";
|
|
4
|
+
const lower = byte => (byte ?? "").toLowerCase();
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Reads a reply that ends on a sentinel byte rather than declaring its length.
|
|
8
|
+
*
|
|
9
|
+
* The Veroval duo control answers this way, as serial protocols generally do: a request is
|
|
10
|
+
* answered across as many notifications as it takes and the end is marked, not counted. The
|
|
11
|
+
* reader therefore cannot know how much is coming and holds the buffer until the terminator
|
|
12
|
+
* lands - which is why the cap exists.
|
|
13
|
+
*
|
|
14
|
+
* There is no integrity check to make. A sentinel protocol carries no checksum, so a frame
|
|
15
|
+
* that reaches a parser here has been delimited, not verified, and whatever decodes it is
|
|
16
|
+
* the only thing standing between a corrupted reply and a reported reading. Declare a range
|
|
17
|
+
* for every field.
|
|
18
|
+
*/
|
|
19
|
+
export class SentinelFrameReader {
|
|
20
|
+
constructor(spec) {
|
|
21
|
+
this.spec = spec;
|
|
22
|
+
}
|
|
23
|
+
readFrame(buffer) {
|
|
24
|
+
const first = lower(buffer[0]);
|
|
25
|
+
if (buffer.length > 0 && (this.spec.standaloneBytes ?? []).includes(first)) {
|
|
26
|
+
return {
|
|
27
|
+
status: FrameReadStatus.COMPLETE,
|
|
28
|
+
consumedBytes: 1,
|
|
29
|
+
frame: [first]
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
const start = this.frameStart(buffer);
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* A declared start byte is one byte, so there is no partial match to preserve: a buffer
|
|
36
|
+
* without it holds no frame start and is junk in its entirety.
|
|
37
|
+
*/
|
|
38
|
+
if (start === undefined) {
|
|
39
|
+
return {
|
|
40
|
+
status: FrameReadStatus.INCOMPLETE,
|
|
41
|
+
consumedBytes: buffer.length
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
const end = buffer.findIndex((byte, index) => index >= start && lower(byte) === this.spec.terminator);
|
|
45
|
+
if (end === -1) {
|
|
46
|
+
return this.incompleteOrOverlong(buffer, start);
|
|
47
|
+
}
|
|
48
|
+
return {
|
|
49
|
+
status: FrameReadStatus.COMPLETE,
|
|
50
|
+
consumedBytes: end + 1,
|
|
51
|
+
frame: buffer.slice(start, end)
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Where the payload begins: after the start byte when one is declared, and at zero when
|
|
57
|
+
* none is. A declared start byte that has not arrived means the reply has not begun.
|
|
58
|
+
*/
|
|
59
|
+
frameStart(buffer) {
|
|
60
|
+
if (this.spec.start === undefined) {
|
|
61
|
+
return 0;
|
|
62
|
+
}
|
|
63
|
+
const index = buffer.findIndex(byte => lower(byte) === this.spec.start);
|
|
64
|
+
return index === -1 ? undefined : index + 1;
|
|
65
|
+
}
|
|
66
|
+
incompleteOrOverlong(buffer, start) {
|
|
67
|
+
if (buffer.length - start <= this.spec.maxFrameBytes) {
|
|
68
|
+
return {
|
|
69
|
+
status: FrameReadStatus.INCOMPLETE,
|
|
70
|
+
consumedBytes: 0
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
return {
|
|
74
|
+
status: FrameReadStatus.CORRUPT,
|
|
75
|
+
consumedBytes: buffer.length
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
//# sourceMappingURL=sentinel-frame-reader.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["FrameReadStatus","lower","byte","toLowerCase","SentinelFrameReader","constructor","spec","readFrame","buffer","first","length","standaloneBytes","includes","status","COMPLETE","consumedBytes","frame","start","frameStart","undefined","INCOMPLETE","end","findIndex","index","terminator","incompleteOrOverlong","slice","maxFrameBytes","CORRUPT"],"sourceRoot":"../../../../../../src","sources":["modules/bt-management/services/devices/sentinel-frame-reader.ts"],"mappings":";;AACA,SAASA,eAAe,QAAQ,kCAA+B;AAgC/D,MAAMC,KAAK,GAAIC,IAAwB,IAAa,CAACA,IAAI,IAAI,EAAE,EAAEC,WAAW,CAAC,CAAC;;AAE9E;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,mBAAmB,CAAwB;EAC/CC,WAAWA,CAAkBC,IAAuB,EAAE;IAAA,KAAzBA,IAAuB,GAAvBA,IAAuB;EAAG;EAEvDC,SAASA,CAACC,MAAyB,EAAmB;IAC3D,MAAMC,KAAK,GAAGR,KAAK,CAACO,MAAM,CAAC,CAAC,CAAC,CAAC;IAE9B,IAAIA,MAAM,CAACE,MAAM,GAAG,CAAC,IAAI,CAAC,IAAI,CAACJ,IAAI,CAACK,eAAe,IAAI,EAAE,EAAEC,QAAQ,CAACH,KAAK,CAAC,EAAE;MAC1E,OAAO;QACLI,MAAM,EAAEb,eAAe,CAACc,QAAQ;QAChCC,aAAa,EAAE,CAAC;QAChBC,KAAK,EAAE,CAACP,KAAK;MACf,CAAC;IACH;IAEA,MAAMQ,KAAK,GAAG,IAAI,CAACC,UAAU,CAACV,MAAM,CAAC;;IAErC;AACJ;AACA;AACA;IACI,IAAIS,KAAK,KAAKE,SAAS,EAAE;MACvB,OAAO;QAAEN,MAAM,EAAEb,eAAe,CAACoB,UAAU;QAAEL,aAAa,EAAEP,MAAM,CAACE;MAAO,CAAC;IAC7E;IAEA,MAAMW,GAAG,GAAGb,MAAM,CAACc,SAAS,CAC1B,CAACpB,IAAI,EAAEqB,KAAK,KAAKA,KAAK,IAAIN,KAAK,IAAIhB,KAAK,CAACC,IAAI,CAAC,KAAK,IAAI,CAACI,IAAI,CAACkB,UAC/D,CAAC;IAED,IAAIH,GAAG,KAAK,CAAC,CAAC,EAAE;MACd,OAAO,IAAI,CAACI,oBAAoB,CAACjB,MAAM,EAAES,KAAK,CAAC;IACjD;IAEA,OAAO;MACLJ,MAAM,EAAEb,eAAe,CAACc,QAAQ;MAChCC,aAAa,EAAEM,GAAG,GAAG,CAAC;MACtBL,KAAK,EAAER,MAAM,CAACkB,KAAK,CAACT,KAAK,EAAEI,GAAG;IAChC,CAAC;EACH;;EAEA;AACF;AACA;AACA;EACUH,UAAUA,CAACV,MAAyB,EAAsB;IAChE,IAAI,IAAI,CAACF,IAAI,CAACW,KAAK,KAAKE,SAAS,EAAE;MACjC,OAAO,CAAC;IACV;IAEA,MAAMI,KAAK,GAAGf,MAAM,CAACc,SAAS,CAAEpB,IAAI,IAAKD,KAAK,CAACC,IAAI,CAAC,KAAK,IAAI,CAACI,IAAI,CAACW,KAAK,CAAC;IAEzE,OAAOM,KAAK,KAAK,CAAC,CAAC,GAAGJ,SAAS,GAAGI,KAAK,GAAG,CAAC;EAC7C;EAEQE,oBAAoBA,CAC1BjB,MAAyB,EACzBS,KAAa,EACI;IACjB,IAAIT,MAAM,CAACE,MAAM,GAAGO,KAAK,IAAI,IAAI,CAACX,IAAI,CAACqB,aAAa,EAAE;MACpD,OAAO;QAAEd,MAAM,EAAEb,eAAe,CAACoB,UAAU;QAAEL,aAAa,EAAE;MAAE,CAAC;IACjE;IAEA,OAAO;MAAEF,MAAM,EAAEb,eAAe,CAAC4B,OAAO;MAAEb,aAAa,EAAEP,MAAM,CAACE;IAAO,CAAC;EAC1E;AACF","ignoreList":[]}
|
package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js
ADDED
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { MeasurementTypeKey } from "@ovok/core";
|
|
4
|
+
import { declareProfile, littleEndian } from "./standard-gatt.profile.js";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Declarations for the Bluetooth SIG vital-signs profiles.
|
|
8
|
+
*
|
|
9
|
+
* These are the profiles a compliant patient device implements, and their layouts come from
|
|
10
|
+
* the public specification rather than from reading a vendor's app, so they can be written
|
|
11
|
+
* down exactly instead of inferred.
|
|
12
|
+
*
|
|
13
|
+
* The advertised name stays the caller's, because the SDK matches a scan result by name and
|
|
14
|
+
* every vendor names its hardware differently. A product declares the profile and supplies
|
|
15
|
+
* the name its own hardware advertises.
|
|
16
|
+
*
|
|
17
|
+
* Values are little-endian, as the specification requires. Only the layouts using each
|
|
18
|
+
* catalog's canonical unit are declared: a device reporting kPa, Fahrenheit or pounds needs
|
|
19
|
+
* a conversion a declaration cannot express, and leaving those flag values undeclared means
|
|
20
|
+
* such a device yields no reading rather than one that is quietly wrong.
|
|
21
|
+
*/
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* Blood Pressure Service 0x1810, Blood Pressure Measurement 0x2A35.
|
|
25
|
+
*
|
|
26
|
+
* The pressures sit at bytes 1-4 whatever the flags say. The pulse rate sits behind two of
|
|
27
|
+
* them: bit 1 puts a seven-byte timestamp in front of it and bit 2 says whether it is there
|
|
28
|
+
* at all, so it is read at byte 7 in one shape and byte 14 in the other, and each shape
|
|
29
|
+
* declares the length it needs. A device that reports no pulse still decodes, because the
|
|
30
|
+
* flags value it sends selects a case that never looks for one.
|
|
31
|
+
*/
|
|
32
|
+
const standardBloodPressureDevice = params => declareProfile(params, {
|
|
33
|
+
service: "1810",
|
|
34
|
+
characteristic: "2a35",
|
|
35
|
+
minLengthBytes: 7,
|
|
36
|
+
measurementTypeKey: MeasurementTypeKey.bloodPressure,
|
|
37
|
+
/** mmHg, with and without the timestamp and pulse the pressures sit in front of. */
|
|
38
|
+
selectors: ["00", "02", "04", "06"],
|
|
39
|
+
fields: [littleEndian("systolic", [1, 2], "mmHg", "sfloat"), littleEndian("diastolic", [3, 4], "mmHg", "sfloat")],
|
|
40
|
+
optionalFields: {
|
|
41
|
+
/** Pulse, no timestamp: it follows the mean pressure. */
|
|
42
|
+
"04": {
|
|
43
|
+
fields: [littleEndian("heartRate", [7, 8], "bpm", "sfloat")],
|
|
44
|
+
minLengthBytes: 9
|
|
45
|
+
},
|
|
46
|
+
/** Pulse behind a seven-byte timestamp. */
|
|
47
|
+
"06": {
|
|
48
|
+
fields: [littleEndian("heartRate", [14, 15], "bpm", "sfloat")],
|
|
49
|
+
minLengthBytes: 16
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
|
|
54
|
+
/** Health Thermometer Service 0x1809, Temperature Measurement 0x2A1C. */
|
|
55
|
+
const standardThermometerDevice = params => declareProfile(params, {
|
|
56
|
+
service: "1809",
|
|
57
|
+
characteristic: "2a1c",
|
|
58
|
+
minLengthBytes: 5,
|
|
59
|
+
measurementTypeKey: MeasurementTypeKey.temperature,
|
|
60
|
+
/** Celsius, with and without the timestamp that follows the reading. */
|
|
61
|
+
selectors: ["00", "02"],
|
|
62
|
+
fields: [littleEndian("bodyTemp", [1, 2, 3, 4], "Cel", "float")]
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
/** The SI weight resolution the specification fixes at five grams per count. */
|
|
66
|
+
const WEIGHT_KG_PER_COUNT = 0.005;
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Weight Scale Service 0x181D, Weight Measurement 0x2A9D.
|
|
70
|
+
*
|
|
71
|
+
* The reading is a scaled integer rather than a float, so the resolution is applied here.
|
|
72
|
+
*/
|
|
73
|
+
const standardWeightScaleDevice = params => declareProfile(params, {
|
|
74
|
+
service: "181d",
|
|
75
|
+
characteristic: "2a9d",
|
|
76
|
+
minLengthBytes: 3,
|
|
77
|
+
measurementTypeKey: MeasurementTypeKey.bodyWeight,
|
|
78
|
+
/** Kilograms, with and without the timestamp that follows the reading. */
|
|
79
|
+
selectors: ["00", "02"],
|
|
80
|
+
fields: [{
|
|
81
|
+
...littleEndian("bodyWeight", [1, 2], "kg", "uint"),
|
|
82
|
+
scale: WEIGHT_KG_PER_COUNT,
|
|
83
|
+
decimals: 3
|
|
84
|
+
}]
|
|
85
|
+
});
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* Pulse Oximeter Service 0x1822, PLX Spot-Check Measurement 0x2A5E.
|
|
89
|
+
*
|
|
90
|
+
* Saturation and pulse rate are both required by the catalog, which matches the
|
|
91
|
+
* specification: a spot-check measurement always carries both.
|
|
92
|
+
*/
|
|
93
|
+
const standardPulseOximeterDevice = params => declareProfile(params, {
|
|
94
|
+
service: "1822",
|
|
95
|
+
characteristic: "2a5e",
|
|
96
|
+
minLengthBytes: 5,
|
|
97
|
+
measurementTypeKey: MeasurementTypeKey.bloodOxygenPulseRate,
|
|
98
|
+
selectors: ["00"],
|
|
99
|
+
fields: [littleEndian("bloodOxygen", [1, 2], "%", "sfloat"), littleEndian("pulseRate", [3, 4], "bpm", "sfloat")]
|
|
100
|
+
});
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* Heart Rate Service 0x180D, Heart Rate Measurement 0x2A37.
|
|
104
|
+
*
|
|
105
|
+
* Only the eight-bit layout is declared. The sixteen-bit variant needs byte 2, which would
|
|
106
|
+
* raise `minLengthBytes` to three and reject every eight-bit frame - the common case - so it
|
|
107
|
+
* is left out rather than made to displace it.
|
|
108
|
+
*/
|
|
109
|
+
const standardHeartRateDevice = params => declareProfile(params, {
|
|
110
|
+
service: "180d",
|
|
111
|
+
characteristic: "2a37",
|
|
112
|
+
minLengthBytes: 2,
|
|
113
|
+
measurementTypeKey: MeasurementTypeKey.heartRate,
|
|
114
|
+
selectors: ["00"],
|
|
115
|
+
fields: [{
|
|
116
|
+
name: "heartRate",
|
|
117
|
+
byteIndexes: [1],
|
|
118
|
+
encoding: "uint",
|
|
119
|
+
unit: "bpm"
|
|
120
|
+
}]
|
|
121
|
+
});
|
|
122
|
+
export { standardBloodPressureDevice, standardHeartRateDevice, standardPulseOximeterDevice, standardThermometerDevice, standardWeightScaleDevice };
|
|
123
|
+
//# sourceMappingURL=standard-gatt.devices.js.map
|
package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["MeasurementTypeKey","declareProfile","littleEndian","standardBloodPressureDevice","params","service","characteristic","minLengthBytes","measurementTypeKey","bloodPressure","selectors","fields","optionalFields","standardThermometerDevice","temperature","WEIGHT_KG_PER_COUNT","standardWeightScaleDevice","bodyWeight","scale","decimals","standardPulseOximeterDevice","bloodOxygenPulseRate","standardHeartRateDevice","heartRate","name","byteIndexes","encoding","unit"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.ts"],"mappings":"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","ignoreList":[]}
|
package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { defineCustomDevice } from "../../custom/define-custom-device.js";
|
|
4
|
+
|
|
5
|
+
/** Milliseconds a spot-check device may take to produce its reading. */
|
|
6
|
+
const SPOT_CHECK_TIMEOUT_MS = 60_000;
|
|
7
|
+
const sigUuid = assigned => `0000${assigned}-0000-1000-8000-00805f9b34fb`;
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* The flags byte selects the case, because it decides which optional fields are present and
|
|
11
|
+
* therefore where the later ones sit. Fields common to every shape are declared once; a
|
|
12
|
+
* field a flag adds is declared against the selector that carries it, at the offset that
|
|
13
|
+
* flag combination puts it and with the frame length that shape guarantees.
|
|
14
|
+
*/
|
|
15
|
+
const declareProfile = (params, profile) => defineCustomDevice({
|
|
16
|
+
id: params.id,
|
|
17
|
+
nameMatch: params.nameMatch,
|
|
18
|
+
stuckDataTimeoutMs: params.stuckDataTimeoutMs ?? SPOT_CHECK_TIMEOUT_MS,
|
|
19
|
+
services: [{
|
|
20
|
+
uuid: sigUuid(profile.service),
|
|
21
|
+
monitor: [{
|
|
22
|
+
uuid: sigUuid(profile.characteristic),
|
|
23
|
+
frame: {
|
|
24
|
+
minLengthBytes: profile.minLengthBytes
|
|
25
|
+
},
|
|
26
|
+
caseSelectorBytes: [0],
|
|
27
|
+
cases: profile.selectors.map(selector => {
|
|
28
|
+
const optional = profile.optionalFields?.[selector];
|
|
29
|
+
return {
|
|
30
|
+
selector,
|
|
31
|
+
kind: "result",
|
|
32
|
+
measurementTypeKey: profile.measurementTypeKey,
|
|
33
|
+
fields: [...profile.fields, ...(optional?.fields ?? [])],
|
|
34
|
+
...(optional ? {
|
|
35
|
+
minLengthBytes: optional.minLengthBytes
|
|
36
|
+
} : {})
|
|
37
|
+
};
|
|
38
|
+
})
|
|
39
|
+
}]
|
|
40
|
+
}]
|
|
41
|
+
});
|
|
42
|
+
const littleEndian = (name, byteIndexes, unit, encoding) => ({
|
|
43
|
+
name,
|
|
44
|
+
byteIndexes,
|
|
45
|
+
byteOrder: "little",
|
|
46
|
+
encoding,
|
|
47
|
+
unit
|
|
48
|
+
});
|
|
49
|
+
export { declareProfile, littleEndian, sigUuid };
|
|
50
|
+
//# sourceMappingURL=standard-gatt.profile.js.map
|
package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["defineCustomDevice","SPOT_CHECK_TIMEOUT_MS","sigUuid","assigned","declareProfile","params","profile","id","nameMatch","stuckDataTimeoutMs","services","uuid","service","monitor","characteristic","frame","minLengthBytes","caseSelectorBytes","cases","selectors","map","selector","optional","optionalFields","kind","measurementTypeKey","fields","littleEndian","name","byteIndexes","unit","encoding","byteOrder"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.ts"],"mappings":";;AAIA,SAASA,kBAAkB,QAAQ,sCAAmC;;AAEtE;AACA,MAAMC,qBAAqB,GAAG,MAAM;AAyCpC,MAAMC,OAAO,GAAIC,QAAgB,IAC/B,OAAOA,QAAQ,8BAA8B;;AAE/C;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,cAAc,GAAGA,CACrBC,MAA4B,EAC5BC,OAAoB,KAEpBN,kBAAkB,CAAC;EACjBO,EAAE,EAAEF,MAAM,CAACE,EAAE;EACbC,SAAS,EAAEH,MAAM,CAACG,SAAS;EAC3BC,kBAAkB,EAAEJ,MAAM,CAACI,kBAAkB,IAAIR,qBAAqB;EACtES,QAAQ,EAAE,CACR;IACEC,IAAI,EAAET,OAAO,CAACI,OAAO,CAACM,OAAO,CAAC;IAC9BC,OAAO,EAAE,CACP;MACEF,IAAI,EAAET,OAAO,CAACI,OAAO,CAACQ,cAAc,CAAC;MACrCC,KAAK,EAAE;QAAEC,cAAc,EAAEV,OAAO,CAACU;MAAe,CAAC;MACjDC,iBAAiB,EAAE,CAAC,CAAC,CAAC;MACtBC,KAAK,EAAEZ,OAAO,CAACa,SAAS,CAACC,GAAG,CAAEC,QAAQ,IAAK;QACzC,MAAMC,QAAQ,GAAGhB,OAAO,CAACiB,cAAc,GAAGF,QAAQ,CAAC;QAEnD,OAAO;UACLA,QAAQ;UACRG,IAAI,EAAE,QAAiB;UACvBC,kBAAkB,EAAEnB,OAAO,CAACmB,kBAAkB;UAC9CC,MAAM,EAAE,CAAC,GAAGpB,OAAO,CAACoB,MAAM,EAAE,IAAIJ,QAAQ,EAAEI,MAAM,IAAI,EAAE,CAAC,CAAC;UACxD,IAAIJ,QAAQ,GACR;YAAEN,cAAc,EAAEM,QAAQ,CAACN;UAAe,CAAC,GAC3C,CAAC,CAAC;QACR,CAAC;MACH,CAAC;IACH,CAAC;EAEL,CAAC;AAEL,CAAC,CAAC;AAEJ,MAAMW,YAAY,GAAGA,CACnBC,IAAY,EACZC,WAAqB,EACrBC,IAAY,EACZC,QAAqC,MAChB;EACrBH,IAAI;EACJC,WAAW;EACXG,SAAS,EAAE,QAAQ;EACnBD,QAAQ;EACRD;AACF,CAAC,CAAC;AAEF,SAAS1B,cAAc,EAAEuB,YAAY,EAAEzB,OAAO","ignoreList":[]}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { standardBloodPressureDevice } from "../standard-gatt/standard-gatt.devices.js";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* The Veroval compact+ blood-pressure monitors.
|
|
7
|
+
*
|
|
8
|
+
* There is nothing vendor-specific to decode here: these implement the Bluetooth
|
|
9
|
+
* blood-pressure profile as published - service 0x1810, measurement 0x2A35, notifications on
|
|
10
|
+
* the standard descriptor - so the layout comes from the specification and the SDK already
|
|
11
|
+
* reads it. What this adds is the identity, which is the only part the specification does
|
|
12
|
+
* not supply.
|
|
13
|
+
*
|
|
14
|
+
* The vendor's own app compares the advertised name for exact equality, ignoring case, so
|
|
15
|
+
* that is what these matchers do. The duo control and the Fusion are not here: those speak a
|
|
16
|
+
* protocol of their own on a private service, and so does the ECG.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
const BPU_26 = "BPU26";
|
|
20
|
+
const BPW_26 = "BPW26";
|
|
21
|
+
const verovalCompactMonitor = (advertisedName, params) => standardBloodPressureDevice({
|
|
22
|
+
id: params.id,
|
|
23
|
+
nameMatch: params.nameMatch ?? new RegExp(`^${advertisedName}$`, "i"),
|
|
24
|
+
...(params.stuckDataTimeoutMs === undefined ? {} : {
|
|
25
|
+
stuckDataTimeoutMs: params.stuckDataTimeoutMs
|
|
26
|
+
})
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
/** BPU 26, the Veroval compact+ upper-arm monitor. */
|
|
30
|
+
const bpu26Monitor = params => verovalCompactMonitor(BPU_26, params);
|
|
31
|
+
|
|
32
|
+
/** BPW 26, the Veroval compact+ wrist monitor. */
|
|
33
|
+
const bpw26Monitor = params => verovalCompactMonitor(BPW_26, params);
|
|
34
|
+
|
|
35
|
+
/** The names these monitors advertise. */
|
|
36
|
+
const VEROVAL_BP_MODEL_NAMES = [BPU_26, BPW_26];
|
|
37
|
+
export { bpu26Monitor, bpw26Monitor, VEROVAL_BP_MODEL_NAMES, verovalCompactMonitor };
|
|
38
|
+
//# sourceMappingURL=veroval.bp-monitors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["standardBloodPressureDevice","BPU_26","BPW_26","verovalCompactMonitor","advertisedName","params","id","nameMatch","RegExp","stuckDataTimeoutMs","undefined","bpu26Monitor","bpw26Monitor","VEROVAL_BP_MODEL_NAMES"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/veroval/veroval.bp-monitors.ts"],"mappings":";;AACA,SAASA,2BAA2B,QAAQ,2CAAwC;;AAEpF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,MAAMC,MAAM,GAAG,OAAO;AACtB,MAAMC,MAAM,GAAG,OAAO;AActB,MAAMC,qBAAqB,GAAGA,CAC5BC,cAAsB,EACtBC,MAAuB,KAEvBL,2BAA2B,CAAC;EAC1BM,EAAE,EAAED,MAAM,CAACC,EAAE;EACbC,SAAS,EAAEF,MAAM,CAACE,SAAS,IAAI,IAAIC,MAAM,CAAC,IAAIJ,cAAc,GAAG,EAAE,GAAG,CAAC;EACrE,IAAIC,MAAM,CAACI,kBAAkB,KAAKC,SAAS,GACvC,CAAC,CAAC,GACF;IAAED,kBAAkB,EAAEJ,MAAM,CAACI;EAAmB,CAAC;AACvD,CAAC,CAAC;;AAEJ;AACA,MAAME,YAAY,GAAIN,MAAuB,IAC3CF,qBAAqB,CAACF,MAAM,EAAEI,MAAM,CAAC;;AAEvC;AACA,MAAMO,YAAY,GAAIP,MAAuB,IAC3CF,qBAAqB,CAACD,MAAM,EAAEG,MAAM,CAAC;;AAEvC;AACA,MAAMQ,sBAAyC,GAAG,CAACZ,MAAM,EAAEC,MAAM,CAAC;AAElE,SACES,YAAY,EACZC,YAAY,EACZC,sBAAsB,EACtBV,qBAAqB","ignoreList":[]}
|