@ovok/native 0.4.7 → 0.4.9
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 +44 -0
- package/lib/commonjs/modules/bt-management/index.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/bt-manager.js +15 -13
- package/lib/commonjs/modules/bt-management/services/bt-manager.js.map +1 -1
- 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 +8 -2
- 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/device-creator.js +12 -2
- package/lib/commonjs/modules/bt-management/services/device-creator.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bc01/bc01-command-sequencer.js +184 -0
- package/lib/commonjs/modules/bt-management/services/devices/bc01/bc01-command-sequencer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/bc01/bc01-frame-parser.js +114 -0
- package/lib/commonjs/modules/bt-management/services/devices/bc01/bc01-frame-parser.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/bc01/bc01.device.js +113 -51
- package/lib/commonjs/modules/bt-management/services/devices/bc01/bc01.device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bc01/bc01.main-services.js +41 -77
- package/lib/commonjs/modules/bt-management/services/devices/bc01/bc01.main-services.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-command-writer.js +15 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-command-writer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js +20 -1
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom.device.js +30 -44
- 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/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 +27 -53
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js.map +1 -1
- 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/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/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/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/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 +4 -0
- package/lib/module/modules/bt-management/index.js.map +1 -1
- package/lib/module/modules/bt-management/services/bt-manager.js +15 -13
- package/lib/module/modules/bt-management/services/bt-manager.js.map +1 -1
- 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 +8 -2
- 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/device-creator.js +12 -2
- package/lib/module/modules/bt-management/services/device-creator.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bc01/bc01-command-sequencer.js +180 -0
- package/lib/module/modules/bt-management/services/devices/bc01/bc01-command-sequencer.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/bc01/bc01-frame-parser.js +110 -0
- package/lib/module/modules/bt-management/services/devices/bc01/bc01-frame-parser.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/bc01/bc01.device.js +113 -51
- package/lib/module/modules/bt-management/services/devices/bc01/bc01.device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bc01/bc01.main-services.js +41 -77
- package/lib/module/modules/bt-management/services/devices/bc01/bc01.main-services.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-command-writer.js +15 -1
- package/lib/module/modules/bt-management/services/devices/bt-command-writer.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js +20 -1
- package/lib/module/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/custom/custom.device.js +31 -45
- 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/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 +19 -45
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js.map +1 -1
- 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/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/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/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/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 +4 -0
- package/lib/typescript/commonjs/src/modules/bt-management/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/bt-manager.d.ts +0 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/bt-manager.d.ts.map +1 -1
- 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/device-creator.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bc01/bc01-command-sequencer.d.ts +53 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bc01/bc01-command-sequencer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bc01/bc01-frame-parser.d.ts +53 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bc01/bc01-frame-parser.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bc01/bc01.device.d.ts +33 -13
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bc01/bc01.device.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bc01/bc01.main-services.d.ts +11 -17
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bc01/bc01.main-services.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-command-writer.d.ts +7 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-command-writer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts +11 -2
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom.device.d.ts +10 -13
- 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/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 +22 -13
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.d.ts.map +1 -1
- 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/types/custom-case-spec.d.ts +30 -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-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/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 +9 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-command.d.ts.map +1 -1
- 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/parsing-case.d.ts +8 -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/create-custom-field-parser.d.ts.map +1 -1
- 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/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 +4 -0
- package/lib/typescript/module/src/modules/bt-management/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/bt-manager.d.ts +0 -1
- package/lib/typescript/module/src/modules/bt-management/services/bt-manager.d.ts.map +1 -1
- 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/device-creator.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bc01/bc01-command-sequencer.d.ts +53 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bc01/bc01-command-sequencer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bc01/bc01-frame-parser.d.ts +53 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bc01/bc01-frame-parser.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bc01/bc01.device.d.ts +33 -13
- package/lib/typescript/module/src/modules/bt-management/services/devices/bc01/bc01.device.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bc01/bc01.main-services.d.ts +11 -17
- package/lib/typescript/module/src/modules/bt-management/services/devices/bc01/bc01.main-services.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-command-writer.d.ts +7 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-command-writer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts +11 -2
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom.device.d.ts +10 -13
- 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/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 +22 -13
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.d.ts.map +1 -1
- 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/types/custom-case-spec.d.ts +30 -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-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/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 +9 -0
- package/lib/typescript/module/src/modules/bt-management/types/device-command.d.ts.map +1 -1
- 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/parsing-case.d.ts +8 -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/create-custom-field-parser.d.ts.map +1 -1
- 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/package.json +1 -1
package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-command-writer.d.ts
CHANGED
|
@@ -48,6 +48,13 @@ export declare class BTCommandWriter {
|
|
|
48
48
|
* for - worse than sending nothing, because it would be answered.
|
|
49
49
|
*/
|
|
50
50
|
private writeCommand;
|
|
51
|
+
/**
|
|
52
|
+
* Writes one chunk the way the characteristic accepts writes.
|
|
53
|
+
*
|
|
54
|
+
* A with-response write to a characteristic that only supports write-without-response
|
|
55
|
+
* fails outright, so the command says which it is rather than the transport guessing.
|
|
56
|
+
*/
|
|
57
|
+
private writeTo;
|
|
51
58
|
/**
|
|
52
59
|
* Splits a frame into writes the link will carry whole.
|
|
53
60
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bt-command-writer.d.ts","sourceRoot":"","sources":["../../../../../../../../src/modules/bt-management/services/devices/bt-command-writer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAIxD,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAW3D;;;;;;;;GAQG;AACH,qBAAa,eAAe;IAKxB,OAAO,CAAC,QAAQ,CAAC,MAAM;IACvB,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC;IAL3B,OAAO,CAAC,aAAa,CAAoC;IACzD,OAAO,CAAC,GAAG,CAAmB;gBAGX,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,GAAE,CAAC,KAAK,EAAE,QAAQ,GAAG,KAAK,KAAK,IAAI,aAAA;IAG9D;;;;;;OAMG;IACI,gBAAgB,GAAI,MAAM,MAAM,KAAG,IAAI,CAI5C;IAEF,kEAAkE;IAC3D,KAAK,QAAO,IAAI,CAErB;IAEF;;;;;;;OAOG;IACI,IAAI,GAAI,UAAU,SAAS,aAAa,EAAE,KAAG,OAAO,CAAC,IAAI,CAAC,CAQ/D;IAEF,OAAO,CAAC,YAAY,CAMlB;IAEF;;;;;;;;;;;OAWG;IACH,OAAO,CAAC,YAAY,CAQlB;IAEF;;;;;OAKG;IACH,OAAO,CAAC,QAAQ,CASd;IAEF;;;;;;OAMG;IACH,OAAO,CAAC,UAAU,
|
|
1
|
+
{"version":3,"file":"bt-command-writer.d.ts","sourceRoot":"","sources":["../../../../../../../../src/modules/bt-management/services/devices/bt-command-writer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAIxD,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAW3D;;;;;;;;GAQG;AACH,qBAAa,eAAe;IAKxB,OAAO,CAAC,QAAQ,CAAC,MAAM;IACvB,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC;IAL3B,OAAO,CAAC,aAAa,CAAoC;IACzD,OAAO,CAAC,GAAG,CAAmB;gBAGX,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,GAAE,CAAC,KAAK,EAAE,QAAQ,GAAG,KAAK,KAAK,IAAI,aAAA;IAG9D;;;;;;OAMG;IACI,gBAAgB,GAAI,MAAM,MAAM,KAAG,IAAI,CAI5C;IAEF,kEAAkE;IAC3D,KAAK,QAAO,IAAI,CAErB;IAEF;;;;;;;OAOG;IACI,IAAI,GAAI,UAAU,SAAS,aAAa,EAAE,KAAG,OAAO,CAAC,IAAI,CAAC,CAQ/D;IAEF,OAAO,CAAC,YAAY,CAMlB;IAEF;;;;;;;;;;;OAWG;IACH,OAAO,CAAC,YAAY,CAQlB;IAEF;;;;;OAKG;IACH,OAAO,CAAC,OAAO,CAmBb;IAEF;;;;;OAKG;IACH,OAAO,CAAC,QAAQ,CASd;IAEF;;;;;;OAMG;IACH,OAAO,CAAC,UAAU,CA8BhB;CACH"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { CommandSequencer } from "../../../types/command-sequencer";
|
|
2
2
|
import { CustomLepuSpec } from "../../../types/custom-lepu-spec";
|
|
3
|
+
import { DeviceData } from "../../../types/device-data";
|
|
3
4
|
import { LepuDeviceInfo } from "../lepu/lepu.device-info";
|
|
4
5
|
interface IdentityReport {
|
|
5
6
|
onIdentified: (info: LepuDeviceInfo) => void;
|
|
@@ -16,6 +17,14 @@ interface IdentityReport {
|
|
|
16
17
|
* answers on the one it is addressed with, so the list matters for reading and its head for
|
|
17
18
|
* writing.
|
|
18
19
|
*/
|
|
19
|
-
|
|
20
|
-
|
|
20
|
+
/**
|
|
21
|
+
* Records what the device said it was.
|
|
22
|
+
*
|
|
23
|
+
* The model number is logged because it is the only place one exists: the vendor's SDK
|
|
24
|
+
* never reads the field back, so a declaration written without it is completed by
|
|
25
|
+
* connecting once and reading this line.
|
|
26
|
+
*/
|
|
27
|
+
declare const recordLepuIdentity: (deviceData: DeviceData, info: LepuDeviceInfo) => void;
|
|
28
|
+
declare const createLepuSequencer: (lepu: CustomLepuSpec, report: IdentityReport) => CommandSequencer;
|
|
29
|
+
export { createLepuSequencer, recordLepuIdentity };
|
|
21
30
|
//# sourceMappingURL=custom-lepu-sequencer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"custom-lepu-sequencer.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"custom-lepu-sequencer.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAExD,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAM1D,UAAU,cAAc;IACtB,YAAY,EAAE,CAAC,IAAI,EAAE,cAAc,KAAK,IAAI,CAAC;IAC7C,SAAS,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC;AAED;;;;;;;;;;GAUG;AACH;;;;;;GAMG;AACH,QAAA,MAAM,kBAAkB,GACtB,YAAY,UAAU,EACtB,MAAM,cAAc,KACnB,IAUF,CAAC;AAEF,QAAA,MAAM,mBAAmB,GACvB,MAAM,cAAc,EACpB,QAAQ,cAAc,KACrB,gBAWC,CAAC;AAEL,OAAO,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,CAAC"}
|
package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom.device.d.ts
CHANGED
|
@@ -31,18 +31,7 @@ export declare class CustomDevice extends BTManagedDevice<CustomDeviceId> {
|
|
|
31
31
|
* gate would poll hardware it had not identified, which is the case the gate exists for.
|
|
32
32
|
*/
|
|
33
33
|
private declareLepuProtocol;
|
|
34
|
-
/**
|
|
35
|
-
* Records what the device said it was.
|
|
36
|
-
*
|
|
37
|
-
* The model number is logged because it is the only place one exists: the vendor's SDK
|
|
38
|
-
* never reads the field back, so a declaration written without it is completed by
|
|
39
|
-
* connecting once and reading this line.
|
|
40
|
-
*/
|
|
41
34
|
private onIdentified;
|
|
42
|
-
/**
|
|
43
|
-
* Nothing is sent to a device that could not be identified, because the same opcode means
|
|
44
|
-
* different things on different models in this family.
|
|
45
|
-
*/
|
|
46
35
|
private onIdentityRefused;
|
|
47
36
|
protected validatePackage: (pkg: string[], uuid: string) => boolean;
|
|
48
37
|
/**
|
|
@@ -56,6 +45,15 @@ export declare class CustomDevice extends BTManagedDevice<CustomDeviceId> {
|
|
|
56
45
|
* readings themselves are reported from handleDependentResult, so there is nothing to do.
|
|
57
46
|
*/
|
|
58
47
|
protected handleSuccessResult(): void | boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Reports what the frame carried, which may be more than one reading.
|
|
50
|
+
*
|
|
51
|
+
* A device handing over its stored history answers one request with every record it
|
|
52
|
+
* holds, back to back. Those were taken at different times and are separate readings, so
|
|
53
|
+
* each record is decoded and reported on its own. A trailing part-record is ignored: half
|
|
54
|
+
* a record is not a reading.
|
|
55
|
+
*/
|
|
56
|
+
private reportFrame;
|
|
59
57
|
/**
|
|
60
58
|
* Reports every reading the frame carried.
|
|
61
59
|
*
|
|
@@ -68,9 +66,8 @@ export declare class CustomDevice extends BTManagedDevice<CustomDeviceId> {
|
|
|
68
66
|
* not take is no reason to withhold the heart rate in the same frame.
|
|
69
67
|
*/
|
|
70
68
|
private report;
|
|
69
|
+
private discard;
|
|
71
70
|
private reportMeasurement;
|
|
72
|
-
private reject;
|
|
73
|
-
private fail;
|
|
74
71
|
}
|
|
75
72
|
export {};
|
|
76
73
|
//# sourceMappingURL=custom.device.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"custom.device.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/custom/custom.device.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"custom.device.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/custom/custom.device.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAG9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,qCAAqC,CAAC;AACzE,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AACjF,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAE,4BAA4B,EAAE,MAAM,gDAAgD,CAAC;AAC9F,OAAO,EAAE,yBAAyB,EAAE,MAAM,uCAAuC,CAAC;AAIlF,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AAOvD,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AASvD,KAAK,mBAAmB,GAAG,yBAAyB,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC;AAGvE;;;;;;;;GAQG;AACH,qBAAa,YAAa,SAAQ,eAAe,CAAC,cAAc,CAAC;IAC/D,SAAS,CAAC,YAAY,EAAE,QAAQ,EAAE,CAAC;IACnC,SAAS,CAAC,gBAAgB,EAAE,MAAM,CAAC;IACnC,SAAS,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,CAAC;IAEnD,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAyB;IACpD,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAiD;gBAG1E,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,kBAAkB,CAAC,cAAc,CAAC,EAC1C,UAAU,EAAE,sBAAsB;IAmBpC;;;;;;OAMG;IACH,OAAO,CAAC,mBAAmB;IAgB3B,OAAO,CAAC,YAAY,CACwB;IAE5C,OAAO,CAAC,iBAAiB,CAMvB;IAEF,SAAS,CAAC,eAAe,GAAI,KAAK,MAAM,EAAE,EAAE,MAAM,MAAM,KAAG,OAAO,CAQhE;IAEF;;;;OAIG;IACH,SAAS,CAAC,qBAAqB,GAC7B,MAAM,4BAA4B,CAAC,mBAAmB,CAAC,KACtD,4BAA4B,CAAC,mBAAmB,CAAC,CAWlD;IAEF;;;OAGG;IACH,SAAS,CAAC,mBAAmB,IAAI,IAAI,GAAG,OAAO;IAI/C;;;;;;;OAOG;IACH,OAAO,CAAC,WAAW;IAyBnB;;;;;;;;;;OAUG;IACH,OAAO,CAAC,MAAM;IAcd,OAAO,CAAC,OAAO;IAIf,OAAO,CAAC,iBAAiB;CAiC1B"}
|
package/lib/typescript/commonjs/src/modules/bt-management/services/devices/frame-parser.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"frame-parser.d.ts","sourceRoot":"","sources":["../../../../../../../../src/modules/bt-management/services/devices/frame-parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAE,4BAA4B,EAAE,MAAM,6CAA6C,CAAC;AAC3F,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAK9D;;;;;;;GAOG;AACH,qBAAa,WAAW,CAAC,CAAC,SAAS,WAAW;IAChC,OAAO,CAAC,QAAQ,CAAC,YAAY;gBAAZ,YAAY,EAAE,cAAc,CAAC,aAAa,CAAC;IAEjE,KAAK,CACV,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,MAAM,EAAE,GACd,4BAA4B,CAAC,CAAC,CAAC,GAAG,SAAS;
|
|
1
|
+
{"version":3,"file":"frame-parser.d.ts","sourceRoot":"","sources":["../../../../../../../../src/modules/bt-management/services/devices/frame-parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAE,4BAA4B,EAAE,MAAM,6CAA6C,CAAC;AAC3F,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAK9D;;;;;;;GAOG;AACH,qBAAa,WAAW,CAAC,CAAC,SAAS,WAAW;IAChC,OAAO,CAAC,QAAQ,CAAC,YAAY;gBAAZ,YAAY,EAAE,cAAc,CAAC,aAAa,CAAC;IAEjE,KAAK,CACV,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,MAAM,EAAE,GACd,4BAA4B,CAAC,CAAC,CAAC,GAAG,SAAS;IA+B9C,OAAO,CAAC,gBAAgB;IAcxB,OAAO,CAAC,aAAa;CAMtB"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { FrameReadResult } from "../../types/frame-read-result";
|
|
2
|
+
import { FrameReader } from "../../types/frame-reader";
|
|
3
|
+
interface SentinelFrameSpec {
|
|
4
|
+
/** Byte that ends a reply. Excluded from the frame, being framing rather than payload. */
|
|
5
|
+
terminator: string;
|
|
6
|
+
/** Byte that begins one, when the device sends one. Also excluded. */
|
|
7
|
+
start?: string;
|
|
8
|
+
/**
|
|
9
|
+
* Longest reply worth waiting for.
|
|
10
|
+
*
|
|
11
|
+
* A sentinel protocol has no length field, so a lost terminator is indistinguishable from
|
|
12
|
+
* a reply that has not finished arriving - the buffer would grow for as long as the link
|
|
13
|
+
* stayed up. Past this the buffer is dropped and reported, which resynchronises on the
|
|
14
|
+
* next reply instead of holding a partial one for ever.
|
|
15
|
+
*/
|
|
16
|
+
maxFrameBytes: number;
|
|
17
|
+
/**
|
|
18
|
+
* Bytes that are a whole reply on their own, carrying no delimiters at all.
|
|
19
|
+
*
|
|
20
|
+
* Serial protocols answer with a bare acknowledgement as often as with a payload, and a
|
|
21
|
+
* reader that only knows delimited replies would wait for a terminator that is never
|
|
22
|
+
* coming. Only the first byte of the buffer is tested, which is the one place a reply can
|
|
23
|
+
* begin - so a control code inside a payload is still payload.
|
|
24
|
+
*/
|
|
25
|
+
standaloneBytes?: readonly string[];
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Reads a reply that ends on a sentinel byte rather than declaring its length.
|
|
29
|
+
*
|
|
30
|
+
* The Veroval duo control answers this way, as serial protocols generally do: a request is
|
|
31
|
+
* answered across as many notifications as it takes and the end is marked, not counted. The
|
|
32
|
+
* reader therefore cannot know how much is coming and holds the buffer until the terminator
|
|
33
|
+
* lands - which is why the cap exists.
|
|
34
|
+
*
|
|
35
|
+
* There is no integrity check to make. A sentinel protocol carries no checksum, so a frame
|
|
36
|
+
* that reaches a parser here has been delimited, not verified, and whatever decodes it is
|
|
37
|
+
* the only thing standing between a corrupted reply and a reported reading. Declare a range
|
|
38
|
+
* for every field.
|
|
39
|
+
*/
|
|
40
|
+
export declare class SentinelFrameReader implements FrameReader {
|
|
41
|
+
private readonly spec;
|
|
42
|
+
constructor(spec: SentinelFrameSpec);
|
|
43
|
+
readFrame(buffer: readonly string[]): FrameReadResult;
|
|
44
|
+
/**
|
|
45
|
+
* Where the payload begins: after the start byte when one is declared, and at zero when
|
|
46
|
+
* none is. A declared start byte that has not arrived means the reply has not begun.
|
|
47
|
+
*/
|
|
48
|
+
private frameStart;
|
|
49
|
+
private incompleteOrOverlong;
|
|
50
|
+
}
|
|
51
|
+
export {};
|
|
52
|
+
//# sourceMappingURL=sentinel-frame-reader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sentinel-frame-reader.d.ts","sourceRoot":"","sources":["../../../../../../../../src/modules/bt-management/services/devices/sentinel-frame-reader.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,+BAA+B,CAAC;AAEhE,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,UAAU,iBAAiB;IAEzB,0FAA0F;IAC1F,UAAU,EAAE,MAAM,CAAC;IAEnB,sEAAsE;IACtE,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;;;;;OAOG;IACH,aAAa,EAAE,MAAM,CAAC;IAEtB;;;;;;;OAOG;IACH,eAAe,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CACrC;AAID;;;;;;;;;;;;GAYG;AACH,qBAAa,mBAAoB,YAAW,WAAW;IAClC,OAAO,CAAC,QAAQ,CAAC,IAAI;gBAAJ,IAAI,EAAE,iBAAiB;IAEpD,SAAS,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,GAAG,eAAe;IAoC5D;;;OAGG;IACH,OAAO,CAAC,UAAU;IAUlB,OAAO,CAAC,oBAAoB;CAU7B"}
|
|
@@ -1,20 +1,29 @@
|
|
|
1
1
|
import { CustomDeviceDefinition } from "../../../types/custom-device-definition";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
2
|
+
import { StandardDeviceParams } from "./standard-gatt.profile";
|
|
3
|
+
/**
|
|
4
|
+
* Declarations for the Bluetooth SIG vital-signs profiles.
|
|
5
|
+
*
|
|
6
|
+
* These are the profiles a compliant patient device implements, and their layouts come from
|
|
7
|
+
* the public specification rather than from reading a vendor's app, so they can be written
|
|
8
|
+
* down exactly instead of inferred.
|
|
9
|
+
*
|
|
10
|
+
* The advertised name stays the caller's, because the SDK matches a scan result by name and
|
|
11
|
+
* every vendor names its hardware differently. A product declares the profile and supplies
|
|
12
|
+
* the name its own hardware advertises.
|
|
13
|
+
*
|
|
14
|
+
* Values are little-endian, as the specification requires. Only the layouts using each
|
|
15
|
+
* catalog's canonical unit are declared: a device reporting kPa, Fahrenheit or pounds needs
|
|
16
|
+
* a conversion a declaration cannot express, and leaving those flag values undeclared means
|
|
17
|
+
* such a device yields no reading rather than one that is quietly wrong.
|
|
18
|
+
*/
|
|
10
19
|
/**
|
|
11
20
|
* Blood Pressure Service 0x1810, Blood Pressure Measurement 0x2A35.
|
|
12
21
|
*
|
|
13
|
-
* The
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
22
|
+
* The pressures sit at bytes 1-4 whatever the flags say. The pulse rate sits behind two of
|
|
23
|
+
* them: bit 1 puts a seven-byte timestamp in front of it and bit 2 says whether it is there
|
|
24
|
+
* at all, so it is read at byte 7 in one shape and byte 14 in the other, and each shape
|
|
25
|
+
* declares the length it needs. A device that reports no pulse still decodes, because the
|
|
26
|
+
* flags value it sends selects a case that never looks for one.
|
|
18
27
|
*/
|
|
19
28
|
declare const standardBloodPressureDevice: (params: StandardDeviceParams) => CustomDeviceDefinition;
|
|
20
29
|
/** Health Thermometer Service 0x1809, Temperature Measurement 0x2A1C. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"standard-gatt.devices.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;
|
|
1
|
+
{"version":3,"file":"standard-gatt.devices.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AAEjF,OAAO,EAGL,oBAAoB,EACrB,MAAM,yBAAyB,CAAC;AAEjC;;;;;;;;;;;;;;;GAeG;AAEH;;;;;;;;GAQG;AACH,QAAA,MAAM,2BAA2B,GAC/B,QAAQ,oBAAoB,KAC3B,sBA0BC,CAAC;AAEL,yEAAyE;AACzE,QAAA,MAAM,yBAAyB,GAC7B,QAAQ,oBAAoB,KAC3B,sBAUC,CAAC;AAKL;;;;GAIG;AACH,QAAA,MAAM,yBAAyB,GAC7B,QAAQ,oBAAoB,KAC3B,sBAgBC,CAAC;AAEL;;;;;GAKG;AACH,QAAA,MAAM,2BAA2B,GAC/B,QAAQ,oBAAoB,KAC3B,sBAWC,CAAC;AAEL;;;;;;GAMG;AACH,QAAA,MAAM,uBAAuB,GAC3B,QAAQ,oBAAoB,KAC3B,sBAUC,CAAC;AAEL,OAAO,EACL,2BAA2B,EAC3B,uBAAuB,EACvB,2BAA2B,EAC3B,yBAAyB,EACzB,yBAAyB,GAC1B,CAAC"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { MeasurementTypeKey } from "@ovok/core";
|
|
2
|
+
import { CustomDeviceDefinition } from "../../../types/custom-device-definition";
|
|
3
|
+
import { CustomFieldSpec } from "../../../types/custom-field-spec";
|
|
4
|
+
interface StandardDeviceParams {
|
|
5
|
+
/** Reported back as deviceData.name, and must not collide with a built-in device. */
|
|
6
|
+
id: string;
|
|
7
|
+
/** The name the hardware advertises. */
|
|
8
|
+
nameMatch: string | RegExp;
|
|
9
|
+
/** Overrides the default settle time, for hardware slower than most. */
|
|
10
|
+
stuckDataTimeoutMs?: number;
|
|
11
|
+
}
|
|
12
|
+
interface ProfileSpec {
|
|
13
|
+
service: string;
|
|
14
|
+
characteristic: string;
|
|
15
|
+
/** Shortest frame the profile guarantees, which bounds every field a case may read. */
|
|
16
|
+
minLengthBytes: number;
|
|
17
|
+
measurementTypeKey: MeasurementTypeKey;
|
|
18
|
+
/** Flags-byte values whose layout matches `fields`, in canonical units. */
|
|
19
|
+
selectors: readonly string[];
|
|
20
|
+
/** Read by every declared case, so only fields that keep their offset across all of them. */
|
|
21
|
+
fields: readonly CustomFieldSpec[];
|
|
22
|
+
/**
|
|
23
|
+
* Fields only some flag combinations carry, keyed by the selector that carries them.
|
|
24
|
+
*
|
|
25
|
+
* The flags byte decides which optional fields are present and therefore where the later
|
|
26
|
+
* ones sit, so a field behind a flag has a different offset in each shape - and a longer
|
|
27
|
+
* frame to go with it.
|
|
28
|
+
*/
|
|
29
|
+
optionalFields?: Readonly<Record<string, {
|
|
30
|
+
fields: CustomFieldSpec[];
|
|
31
|
+
minLengthBytes: number;
|
|
32
|
+
}>>;
|
|
33
|
+
}
|
|
34
|
+
declare const sigUuid: (assigned: string) => string;
|
|
35
|
+
/**
|
|
36
|
+
* The flags byte selects the case, because it decides which optional fields are present and
|
|
37
|
+
* therefore where the later ones sit. Fields common to every shape are declared once; a
|
|
38
|
+
* field a flag adds is declared against the selector that carries it, at the offset that
|
|
39
|
+
* flag combination puts it and with the frame length that shape guarantees.
|
|
40
|
+
*/
|
|
41
|
+
declare const declareProfile: (params: StandardDeviceParams, profile: ProfileSpec) => CustomDeviceDefinition;
|
|
42
|
+
declare const littleEndian: (name: string, byteIndexes: number[], unit: string, encoding: CustomFieldSpec["encoding"]) => CustomFieldSpec;
|
|
43
|
+
export { declareProfile, littleEndian, sigUuid };
|
|
44
|
+
export type { ProfileSpec, StandardDeviceParams };
|
|
45
|
+
//# sourceMappingURL=standard-gatt.profile.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"standard-gatt.profile.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAEhD,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AACjF,OAAO,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AAMnE,UAAU,oBAAoB;IAE5B,qFAAqF;IACrF,EAAE,EAAE,MAAM,CAAC;IAEX,wCAAwC;IACxC,SAAS,EAAE,MAAM,GAAG,MAAM,CAAC;IAE3B,wEAAwE;IACxE,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED,UAAU,WAAW;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,cAAc,EAAE,MAAM,CAAC;IAEvB,uFAAuF;IACvF,cAAc,EAAE,MAAM,CAAC;IAEvB,kBAAkB,EAAE,kBAAkB,CAAC;IAEvC,2EAA2E;IAC3E,SAAS,EAAE,SAAS,MAAM,EAAE,CAAC;IAE7B,6FAA6F;IAC7F,MAAM,EAAE,SAAS,eAAe,EAAE,CAAC;IAEnC;;;;;;OAMG;IACH,cAAc,CAAC,EAAE,QAAQ,CACvB,MAAM,CAAC,MAAM,EAAE;QAAE,MAAM,EAAE,eAAe,EAAE,CAAC;QAAC,cAAc,EAAE,MAAM,CAAA;KAAE,CAAC,CACtE,CAAC;CACH;AAED,QAAA,MAAM,OAAO,GAAI,UAAU,MAAM,KAAG,MACW,CAAC;AAEhD;;;;;GAKG;AACH,QAAA,MAAM,cAAc,GAClB,QAAQ,oBAAoB,EAC5B,SAAS,WAAW,KACnB,sBA8BC,CAAC;AAEL,QAAA,MAAM,YAAY,GAChB,MAAM,MAAM,EACZ,aAAa,MAAM,EAAE,EACrB,MAAM,MAAM,EACZ,UAAU,eAAe,CAAC,UAAU,CAAC,KACpC,eAMD,CAAC;AAEH,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,OAAO,EAAE,CAAC;AACjD,YAAY,EAAE,WAAW,EAAE,oBAAoB,EAAE,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { CustomDeviceDefinition } from "../../../types/custom-device-definition";
|
|
2
|
+
interface VerovalBpParams {
|
|
3
|
+
/** Reported back as deviceData.name, and must not collide with a built-in device. */
|
|
4
|
+
id: string;
|
|
5
|
+
/** Overrides the exact-name matcher, for firmware that advertises something else. */
|
|
6
|
+
nameMatch?: string | RegExp;
|
|
7
|
+
/** Overrides the default settle time, for hardware slower than most. */
|
|
8
|
+
stuckDataTimeoutMs?: number;
|
|
9
|
+
}
|
|
10
|
+
declare const verovalCompactMonitor: (advertisedName: string, params: VerovalBpParams) => CustomDeviceDefinition;
|
|
11
|
+
/** BPU 26, the Veroval compact+ upper-arm monitor. */
|
|
12
|
+
declare const bpu26Monitor: (params: VerovalBpParams) => CustomDeviceDefinition;
|
|
13
|
+
/** BPW 26, the Veroval compact+ wrist monitor. */
|
|
14
|
+
declare const bpw26Monitor: (params: VerovalBpParams) => CustomDeviceDefinition;
|
|
15
|
+
/** The names these monitors advertise. */
|
|
16
|
+
declare const VEROVAL_BP_MODEL_NAMES: readonly string[];
|
|
17
|
+
export { bpu26Monitor, bpw26Monitor, VEROVAL_BP_MODEL_NAMES, verovalCompactMonitor, };
|
|
18
|
+
//# sourceMappingURL=veroval.bp-monitors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"veroval.bp-monitors.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/veroval/veroval.bp-monitors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AAoBjF,UAAU,eAAe;IAEvB,qFAAqF;IACrF,EAAE,EAAE,MAAM,CAAC;IAEX,qFAAqF;IACrF,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAE5B,wEAAwE;IACxE,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED,QAAA,MAAM,qBAAqB,GACzB,gBAAgB,MAAM,EACtB,QAAQ,eAAe,KACtB,sBAOC,CAAC;AAEL,sDAAsD;AACtD,QAAA,MAAM,YAAY,GAAI,QAAQ,eAAe,KAAG,sBACT,CAAC;AAExC,kDAAkD;AAClD,QAAA,MAAM,YAAY,GAAI,QAAQ,eAAe,KAAG,sBACT,CAAC;AAExC,0CAA0C;AAC1C,QAAA,MAAM,sBAAsB,EAAE,SAAS,MAAM,EAAqB,CAAC;AAEnE,OAAO,EACL,YAAY,EACZ,YAAY,EACZ,sBAAsB,EACtB,qBAAqB,GACtB,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Device } from "react-native-ble-plx";
|
|
2
|
+
import { CreateDeviceParams } from "../../../types/create-device-params";
|
|
3
|
+
import { CustomDeviceId } from "../../../types/custom-device-id";
|
|
4
|
+
import { CustomDevice } from "../custom/custom.device";
|
|
5
|
+
/**
|
|
6
|
+
* The Veroval duo control.
|
|
7
|
+
*
|
|
8
|
+
* A device class rather than a declaration, because reading it is a conversation: the two
|
|
9
|
+
* user memories are asked in turn, and the device answers with bare control bytes as often
|
|
10
|
+
* as with payload. The decoding is still declared - the class supplies the framing and the
|
|
11
|
+
* walk, and nothing else.
|
|
12
|
+
*
|
|
13
|
+
* Readings are stored measurements, not live ones. The device hands over its history when
|
|
14
|
+
* asked, so what arrives was taken before the connection and may be days old.
|
|
15
|
+
*/
|
|
16
|
+
export declare class VerovalDuoControlDevice extends CustomDevice {
|
|
17
|
+
constructor(device: Device, params: CreateDeviceParams<CustomDeviceId>);
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=veroval.duo-control-device.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"veroval.duo-control-device.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/veroval/veroval.duo-control-device.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAE9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,qCAAqC,CAAC;AACzE,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAEjE,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAoFvD;;;;;;;;;;GAUG;AACH,qBAAa,uBAAwB,SAAQ,YAAY;gBAErD,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,kBAAkB,CAAC,cAAc,CAAC;CAkB7C"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { CommandSequencer } from "../../../types/command-sequencer";
|
|
2
|
+
import { DeviceCommand } from "../../../types/device-command";
|
|
3
|
+
interface DuoControlSequencerParams {
|
|
4
|
+
/** The characteristic commands are written to. It acknowledges nothing. */
|
|
5
|
+
write: Omit<DeviceCommand, "frame">;
|
|
6
|
+
/** Called with why the exchange stopped early. Required, so a refusal is not lost. */
|
|
7
|
+
onRefused: (reason: string) => void;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Walks the Veroval duo control through its stored history.
|
|
11
|
+
*
|
|
12
|
+
* The device answers one request at a time and holds two user memories, so the exchange is
|
|
13
|
+
* a fixed walk: ask user one how many records it has, read them, then user two. A memory
|
|
14
|
+
* that reports none is skipped rather than read.
|
|
15
|
+
*
|
|
16
|
+
* Two of its replies are not payload at all. A bare `ACK` means the device has more to send
|
|
17
|
+
* and is waiting to be asked, which is what `ENQ` does - so an acknowledgement provokes an
|
|
18
|
+
* enquiry rather than advancing the walk. A bare `NAK` is a refusal and ends it.
|
|
19
|
+
*
|
|
20
|
+
* Everything here is derived from HARTMANN's own application. The one part that is an
|
|
21
|
+
* inference rather than a reading is `ENQ` as flow control: the app writes it on receiving
|
|
22
|
+
* `ACK`, which is what that pair means in the serial protocol this is descended from, but
|
|
23
|
+
* the pacing was not observed on hardware.
|
|
24
|
+
*/
|
|
25
|
+
export declare class VerovalDuoControlSequencer implements CommandSequencer {
|
|
26
|
+
private readonly params;
|
|
27
|
+
private step;
|
|
28
|
+
private isDone;
|
|
29
|
+
constructor(params: DuoControlSequencerParams);
|
|
30
|
+
initialCommands: () => readonly DeviceCommand[];
|
|
31
|
+
nextCommand: (frame: readonly string[]) => readonly DeviceCommand[] | undefined;
|
|
32
|
+
private answerControlByte;
|
|
33
|
+
/**
|
|
34
|
+
* A memory reporting no records is skipped. Asking for the data of an empty memory is a
|
|
35
|
+
* request the device answers with nothing, which would stall the walk on its own reply.
|
|
36
|
+
*/
|
|
37
|
+
private answerCount;
|
|
38
|
+
/** Past this memory's data command, to the next memory's count. */
|
|
39
|
+
private skipMemory;
|
|
40
|
+
private advance;
|
|
41
|
+
private stop;
|
|
42
|
+
private commandFor;
|
|
43
|
+
}
|
|
44
|
+
export {};
|
|
45
|
+
//# sourceMappingURL=veroval.duo-control-sequencer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"veroval.duo-control-sequencer.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/veroval/veroval.duo-control-sequencer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAyC9D,UAAU,yBAAyB;IAEjC,2EAA2E;IAC3E,KAAK,EAAE,IAAI,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;IAEpC,sFAAsF;IACtF,SAAS,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC;AAaD;;;;;;;;;;;;;;;GAeG;AACH,qBAAa,0BAA2B,YAAW,gBAAgB;IAI9C,OAAO,CAAC,QAAQ,CAAC,MAAM;IAH1C,OAAO,CAAC,IAAI,CAAK;IACjB,OAAO,CAAC,MAAM,CAAS;gBAEa,MAAM,EAAE,yBAAyB;IAE9D,eAAe,QAAO,SAAS,aAAa,EAAE,CAAyB;IAEvE,WAAW,GAChB,OAAO,SAAS,MAAM,EAAE,KACvB,SAAS,aAAa,EAAE,GAAG,SAAS,CAgBrC;IAEF,OAAO,CAAC,iBAAiB,CAYvB;IAEF;;;OAGG;IACH,OAAO,CAAC,WAAW,CAUjB;IAEF,mEAAmE;IACnE,OAAO,CAAC,UAAU,CAIhB;IAEF,OAAO,CAAC,OAAO,CAUb;IAEF,OAAO,CAAC,IAAI,CAKV;IAEF,OAAO,CAAC,UAAU,CACmC;CACtD"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Device } from "react-native-ble-plx";
|
|
2
|
+
import { CreateDeviceParams } from "../../../types/create-device-params";
|
|
3
|
+
import { IntegratedDevices } from "../../../types/integrated-devices";
|
|
4
|
+
import { IService } from "../../../types/service.type";
|
|
5
|
+
import { BTManagedDevice } from "../bt-managed-device";
|
|
6
|
+
import { VerovalEcgTransfer } from "./veroval.ecg-transfer";
|
|
7
|
+
/**
|
|
8
|
+
* The Veroval ECG.
|
|
9
|
+
*
|
|
10
|
+
* Reading it is a download rather than a decode, so the whole recording is assembled before
|
|
11
|
+
* anything is reported: thirty-four seconds of samples at 128 Hz, two bytes each, converted
|
|
12
|
+
* to millivolts with the device's own calibration.
|
|
13
|
+
*
|
|
14
|
+
* The vendor's app plots a thirty-second window of this with a baseline-wander filter
|
|
15
|
+
* applied. That is a display transform, not calibration, so it is deliberately not
|
|
16
|
+
* reproduced here - what is reported is what the device recorded.
|
|
17
|
+
*/
|
|
18
|
+
export declare class VerovalEcgDevice extends BTManagedDevice<IntegratedDevices.VEROVAL_ECG> {
|
|
19
|
+
protected stuckDataTimeout: number;
|
|
20
|
+
protected preferredMtu: number;
|
|
21
|
+
protected onStreamStart: undefined;
|
|
22
|
+
protected mainServices: IService[];
|
|
23
|
+
protected validatePackage: () => boolean;
|
|
24
|
+
protected createCommandSequencer: () => VerovalEcgTransfer;
|
|
25
|
+
constructor(device: Device, params: CreateDeviceParams<IntegratedDevices.VEROVAL_ECG>);
|
|
26
|
+
/** Nothing is reported per packet; the transfer reports the recording when it is whole. */
|
|
27
|
+
protected handleSuccessResult(): void;
|
|
28
|
+
private reportRecording;
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=veroval.ecg-device.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"veroval.ecg-device.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/veroval/veroval.ecg-device.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAG9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,qCAAqC,CAAC;AACzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AACtE,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AACvD,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAMvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAgC5D;;;;;;;;;;GAUG;AACH,qBAAa,gBAAiB,SAAQ,eAAe,CAAC,iBAAiB,CAAC,WAAW,CAAC;IAClF,SAAS,CAAC,gBAAgB,SAAoB;IAC9C,UAAmB,YAAY,SAAiB;IAChD,SAAS,CAAC,aAAa,YAAa;IAEpC,SAAS,CAAC,YAAY,EAAE,QAAQ,EAAE,CAKhC;IAEF,UAAmB,eAAe,QAAO,OAAO,CAAS;IAEzD,UAAmB,sBAAsB,2BAIpC;gBAGH,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,kBAAkB,CAAC,iBAAiB,CAAC,WAAW,CAAC;IAK3D,2FAA2F;IAC3F,SAAS,CAAC,mBAAmB,IAAI,IAAI;IAIrC,OAAO,CAAC,eAAe,CAerB;CACH"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* How fast the device samples.
|
|
3
|
+
*
|
|
4
|
+
* Not taken on trust: the vendor's own plotting step works out to two two-hundred-and-fifty
|
|
5
|
+
* sixths of a second, and its transfer is thirty-four segments of sixteen packets of sixteen
|
|
6
|
+
* bytes - which is 256 bytes, 128 samples, one second per segment. Both say 128 Hz.
|
|
7
|
+
*/
|
|
8
|
+
declare const VEROVAL_ECG_SAMPLE_RATE_HZ = 128;
|
|
9
|
+
/**
|
|
10
|
+
* The calibration the recording is read with.
|
|
11
|
+
*
|
|
12
|
+
* This is the EDF convention - a linear map from counts onto a physical range - and the
|
|
13
|
+
* device states its own in the header it sends before the curve. These are the values the
|
|
14
|
+
* vendor's app falls back to, and are what the SDK uses until a header supplies otherwise:
|
|
15
|
+
* the full signed sixteen-bit range spans plus or minus 27.68 mV.
|
|
16
|
+
*/
|
|
17
|
+
declare const DEFAULT_CALIBRATION: {
|
|
18
|
+
readonly physicalMinimumMicrovolts: -27680;
|
|
19
|
+
readonly physicalMaximumMicrovolts: 27680;
|
|
20
|
+
readonly digitalMinimum: -32768;
|
|
21
|
+
readonly digitalMaximum: 32767;
|
|
22
|
+
};
|
|
23
|
+
interface EcgCalibration {
|
|
24
|
+
physicalMinimumMicrovolts: number;
|
|
25
|
+
physicalMaximumMicrovolts: number;
|
|
26
|
+
digitalMinimum: number;
|
|
27
|
+
digitalMaximum: number;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Turns the bytes of a recording into millivolts.
|
|
31
|
+
*
|
|
32
|
+
* A trailing odd byte is ignored: half a sample is not a sample. The conversion is the
|
|
33
|
+
* device's own, applied as it states it rather than reduced to a single factor, so a header
|
|
34
|
+
* that reports a different range still decodes correctly.
|
|
35
|
+
*/
|
|
36
|
+
declare const decodeVerovalEcgSamples: (bytes: readonly string[], calibration?: EcgCalibration) => number[];
|
|
37
|
+
export { decodeVerovalEcgSamples, DEFAULT_CALIBRATION, VEROVAL_ECG_SAMPLE_RATE_HZ, };
|
|
38
|
+
export type { EcgCalibration };
|
|
39
|
+
//# sourceMappingURL=veroval.ecg-samples.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"veroval.ecg-samples.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/veroval/veroval.ecg-samples.ts"],"names":[],"mappings":"AAOA;;;;;;GAMG;AACH,QAAA,MAAM,0BAA0B,MAAM,CAAC;AAEvC;;;;;;;GAOG;AACH,QAAA,MAAM,mBAAmB;;;;;CAKf,CAAC;AAIX,UAAU,cAAc;IACtB,yBAAyB,EAAE,MAAM,CAAC;IAClC,yBAAyB,EAAE,MAAM,CAAC;IAClC,cAAc,EAAE,MAAM,CAAC;IACvB,cAAc,EAAE,MAAM,CAAC;CACxB;AAWD;;;;;;GAMG;AACH,QAAA,MAAM,uBAAuB,GAC3B,OAAO,SAAS,MAAM,EAAE,EACxB,cAAa,cAAoC,KAChD,MAAM,EAsBR,CAAC;AAEF,OAAO,EACL,uBAAuB,EACvB,mBAAmB,EACnB,0BAA0B,GAC3B,CAAC;AACF,YAAY,EAAE,cAAc,EAAE,CAAC"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { CommandSequencer } from "../../../types/command-sequencer";
|
|
2
|
+
import { DeviceCommand } from "../../../types/device-command";
|
|
3
|
+
interface EcgTransferParams {
|
|
4
|
+
/** The characteristic requests are written to. */
|
|
5
|
+
write: Omit<DeviceCommand, "frame">;
|
|
6
|
+
/** Called once, with the recording's bytes, when every segment has arrived. */
|
|
7
|
+
onRecording: (bytes: readonly string[]) => void;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Downloads a recording from the Veroval ECG.
|
|
11
|
+
*
|
|
12
|
+
* The exchange is a fixed walk rather than a conversation: ask for the download mode, then
|
|
13
|
+
* the header, then each second of the recording in turn. The device answers each request
|
|
14
|
+
* with a known number of twenty-byte packets, sixteen payload bytes each, so the transfer is
|
|
15
|
+
* paced by counting them - which is how the vendor's own app paces it, and is the only thing
|
|
16
|
+
* that distinguishes one phase's packets from another's.
|
|
17
|
+
*
|
|
18
|
+
* A recording is thirty-four seconds at 128 Hz. Nothing is reported until all of it has
|
|
19
|
+
* arrived: a partial ECG that looked whole would be worse than none, and the count is what
|
|
20
|
+
* says it is whole.
|
|
21
|
+
*/
|
|
22
|
+
export declare class VerovalEcgTransfer implements CommandSequencer {
|
|
23
|
+
private readonly params;
|
|
24
|
+
private phase;
|
|
25
|
+
private packets;
|
|
26
|
+
private segment;
|
|
27
|
+
private recording;
|
|
28
|
+
constructor(params: EcgTransferParams);
|
|
29
|
+
initialCommands: () => readonly DeviceCommand[];
|
|
30
|
+
nextCommand: (frame: readonly string[]) => readonly DeviceCommand[] | undefined;
|
|
31
|
+
private finishSegment;
|
|
32
|
+
private requestSegment;
|
|
33
|
+
}
|
|
34
|
+
export {};
|
|
35
|
+
//# sourceMappingURL=veroval.ecg-transfer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"veroval.ecg-transfer.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/modules/bt-management/services/devices/veroval/veroval.ecg-transfer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACpE,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAgD9D,UAAU,iBAAiB;IAEzB,kDAAkD;IAClD,KAAK,EAAE,IAAI,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;IAEpC,+EAA+E;IAC/E,WAAW,EAAE,CAAC,KAAK,EAAE,SAAS,MAAM,EAAE,KAAK,IAAI,CAAC;CACjD;AAID;;;;;;;;;;;;GAYG;AACH,qBAAa,kBAAmB,YAAW,gBAAgB;IAMtC,OAAO,CAAC,QAAQ,CAAC,MAAM;IAL1C,OAAO,CAAC,KAAK,CAAiB;IAC9B,OAAO,CAAC,OAAO,CAAK;IACpB,OAAO,CAAC,OAAO,CAAK;IACpB,OAAO,CAAC,SAAS,CAAgB;gBAEG,MAAM,EAAE,iBAAiB;IAEtD,eAAe,QAAO,SAAS,aAAa,EAAE,CAEnD;IAEK,WAAW,GAChB,OAAO,SAAS,MAAM,EAAE,KACvB,SAAS,aAAa,EAAE,GAAG,SAAS,CAyBrC;IAEF,OAAO,CAAC,aAAa,CAWnB;IAEF,OAAO,CAAC,cAAc,CAQpB;CACH"}
|
|
@@ -14,6 +14,36 @@ export interface CustomCaseSpec {
|
|
|
14
14
|
measurementTypeKey?: MeasurementTypeKey;
|
|
15
15
|
/** Required and non-empty for a "result" case, forbidden otherwise. */
|
|
16
16
|
fields?: CustomFieldSpec[];
|
|
17
|
+
/**
|
|
18
|
+
* The frame is a run of fixed-width records, each decoded the same way.
|
|
19
|
+
*
|
|
20
|
+
* A device that hands over its stored history answers one request with every record it
|
|
21
|
+
* holds, back to back. Those are separate readings taken at separate times, so each is
|
|
22
|
+
* reported on its own rather than merged.
|
|
23
|
+
*
|
|
24
|
+
* **Byte indexes are relative to a record, not to the frame**, and are bounds-checked
|
|
25
|
+
* against `recordBytes`. A trailing part-record is ignored: a whole number of records is
|
|
26
|
+
* what the device sends, and half of one is not a reading.
|
|
27
|
+
*/
|
|
28
|
+
repeatedRecords?: {
|
|
29
|
+
/** Width of one record. */
|
|
30
|
+
recordBytes: number;
|
|
31
|
+
/** Byte the first record starts at. Defaults to 0. */
|
|
32
|
+
from?: number;
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* Shortest frame of this shape, when it is longer than the characteristic's minimum.
|
|
36
|
+
*
|
|
37
|
+
* A selector byte often decides how long the frame is: the Bluetooth blood-pressure
|
|
38
|
+
* profile puts a timestamp and a pulse rate behind flag bits, so one shape is seven bytes
|
|
39
|
+
* and another is sixteen. Without this, every case is bounded by the shortest of them and
|
|
40
|
+
* the later fields cannot be declared at all - which is how a pulse rate gets dropped from
|
|
41
|
+
* a device that reports one.
|
|
42
|
+
*
|
|
43
|
+
* Must be at least the characteristic's `frame.minLengthBytes`. A frame that arrives
|
|
44
|
+
* shorter than the case it selected decodes nothing and is reported, not guessed at.
|
|
45
|
+
*/
|
|
46
|
+
minLengthBytes?: number;
|
|
17
47
|
/**
|
|
18
48
|
* Further readings the same frame carries.
|
|
19
49
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"custom-case-spec.d.ts","sourceRoot":"","sources":["../../../../../../../src/modules/bt-management/types/custom-case-spec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAEhD,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAElE,uFAAuF;AACvF,MAAM,WAAW,cAAc;IAE7B;;;OAGG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB,IAAI,EAAE,cAAc,CAAC;IAErB,qFAAqF;IACrF,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;IAExC,uEAAuE;IACvE,MAAM,CAAC,EAAE,eAAe,EAAE,CAAC;IAE3B;;;;;;;;;;OAUG;IACH,sBAAsB,CAAC,EAAE,qBAAqB,EAAE,CAAC;IAEjD,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB"}
|
|
1
|
+
{"version":3,"file":"custom-case-spec.d.ts","sourceRoot":"","sources":["../../../../../../../src/modules/bt-management/types/custom-case-spec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAEhD,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAElE,uFAAuF;AACvF,MAAM,WAAW,cAAc;IAE7B;;;OAGG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB,IAAI,EAAE,cAAc,CAAC;IAErB,qFAAqF;IACrF,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;IAExC,uEAAuE;IACvE,MAAM,CAAC,EAAE,eAAe,EAAE,CAAC;IAE3B;;;;;;;;;;OAUG;IACH,eAAe,CAAC,EAAE;QAEhB,2BAA2B;QAC3B,WAAW,EAAE,MAAM,CAAC;QAEpB,sDAAsD;QACtD,IAAI,CAAC,EAAE,MAAM,CAAC;KACf,CAAC;IAEF;;;;;;;;;;;OAWG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;;;;;;;;OAUG;IACH,sBAAsB,CAAC,EAAE,qBAAqB,EAAE,CAAC;IAEjD,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB"}
|
|
@@ -5,6 +5,12 @@
|
|
|
5
5
|
* - "int" two's complement signed integer, 1-6 bytes
|
|
6
6
|
* - "sfloat" IEEE-11073 16-bit SFLOAT, exactly 2 bytes (standard GATT vitals)
|
|
7
7
|
* - "float" IEEE-11073 32-bit FLOAT, exactly 4 bytes (standard GATT thermometer)
|
|
8
|
+
* - "ascii" decimal digits written as text, one digit per byte
|
|
9
|
+
*
|
|
10
|
+
* "ascii" is not a numeric encoding at all: the bytes are characters, so `"120"` arrives as
|
|
11
|
+
* 0x31 0x32 0x30. Serial-derived devices report whole records this way. Digits read
|
|
12
|
+
* left to right, so the field may not be declared little-endian - reversing them would
|
|
13
|
+
* turn 120 into 21.
|
|
8
14
|
*/
|
|
9
|
-
export type CustomFieldEncoding = "uint" | "int" | "sfloat" | "float";
|
|
15
|
+
export type CustomFieldEncoding = "uint" | "int" | "sfloat" | "float" | "ascii";
|
|
10
16
|
//# sourceMappingURL=custom-field-encoding.d.ts.map
|
package/lib/typescript/commonjs/src/modules/bt-management/types/custom-field-encoding.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"custom-field-encoding.d.ts","sourceRoot":"","sources":["../../../../../../../src/modules/bt-management/types/custom-field-encoding.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"custom-field-encoding.d.ts","sourceRoot":"","sources":["../../../../../../../src/modules/bt-management/types/custom-field-encoding.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,mBAAmB,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,GAAG,OAAO,GAAG,OAAO,CAAC"}
|
package/lib/typescript/commonjs/src/modules/bt-management/types/dependent-result-handler-params.d.ts
CHANGED
|
@@ -5,5 +5,12 @@ export interface DependentResultHandlerParams<T extends Measurement = Measuremen
|
|
|
5
5
|
parsingCase: ParsingCase;
|
|
6
6
|
measurementTypeKey: MeasurementTypeKey | undefined;
|
|
7
7
|
parsedData: MeasurementWithCaseType<T>;
|
|
8
|
+
/**
|
|
9
|
+
* The verified frame the reading was decoded from, for a case that repeats a record.
|
|
10
|
+
*
|
|
11
|
+
* Optional because a device class builds these params itself and decodes its own frames;
|
|
12
|
+
* only the declarative path needs to go back to the bytes.
|
|
13
|
+
*/
|
|
14
|
+
frame?: string[];
|
|
8
15
|
}
|
|
9
16
|
//# sourceMappingURL=dependent-result-handler-params.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dependent-result-handler-params.d.ts","sourceRoot":"","sources":["../../../../../../../src/modules/bt-management/types/dependent-result-handler-params.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAE7D,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AACvE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,MAAM,WAAW,4BAA4B,CAC3C,CAAC,SAAS,WAAW,GAAG,WAAW;IAEnC,WAAW,EAAE,WAAW,CAAC;IACzB,kBAAkB,EAAE,kBAAkB,GAAG,SAAS,CAAC;IACnD,UAAU,EAAE,uBAAuB,CAAC,CAAC,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"dependent-result-handler-params.d.ts","sourceRoot":"","sources":["../../../../../../../src/modules/bt-management/types/dependent-result-handler-params.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAE7D,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AACvE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,MAAM,WAAW,4BAA4B,CAC3C,CAAC,SAAS,WAAW,GAAG,WAAW;IAEnC,WAAW,EAAE,WAAW,CAAC;IACzB,kBAAkB,EAAE,kBAAkB,GAAG,SAAS,CAAC;IACnD,UAAU,EAAE,uBAAuB,CAAC,CAAC,CAAC,CAAC;IAEvC;;;;;OAKG;IACH,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;CAClB"}
|
|
@@ -14,5 +14,14 @@ export interface DeviceCommand {
|
|
|
14
14
|
serviceUuid: string;
|
|
15
15
|
characteristicUuid: string;
|
|
16
16
|
frame: readonly string[];
|
|
17
|
+
/**
|
|
18
|
+
* Write without waiting for the device to acknowledge it.
|
|
19
|
+
*
|
|
20
|
+
* Some devices expose a write-without-response characteristic and nothing else, and a
|
|
21
|
+
* with-response write to one of those fails rather than degrading - the property simply
|
|
22
|
+
* is not there. It is the characteristic that decides this, not a preference, so it is
|
|
23
|
+
* declared alongside the one being written to.
|
|
24
|
+
*/
|
|
25
|
+
withoutResponse?: boolean;
|
|
17
26
|
}
|
|
18
27
|
//# sourceMappingURL=device-command.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"device-command.d.ts","sourceRoot":"","sources":["../../../../../../../src/modules/bt-management/types/device-command.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,MAAM,WAAW,aAAa;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"device-command.d.ts","sourceRoot":"","sources":["../../../../../../../src/modules/bt-management/types/device-command.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,MAAM,WAAW,aAAa;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;IAEzB;;;;;;;OAOG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B"}
|