@ovok/native 1.16.1-rc.3 → 1.16.1-rc.5
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-management/components/android-bluetooth-foreground-service.js +3 -1
- package/lib/commonjs/modules/bt-management/components/android-bluetooth-foreground-service.js.map +1 -1
- package/lib/commonjs/modules/bt-management/components/bluetooth-device-picker.js +9 -141
- package/lib/commonjs/modules/bt-management/components/bluetooth-device-picker.js.map +1 -1
- package/lib/commonjs/modules/bt-management/components/bt-provider-child-wrapper.js +1 -0
- package/lib/commonjs/modules/bt-management/components/bt-provider-child-wrapper.js.map +1 -1
- package/lib/commonjs/modules/bt-management/components/device-picker-sheet.js +160 -0
- package/lib/commonjs/modules/bt-management/components/device-picker-sheet.js.map +1 -0
- package/lib/commonjs/modules/bt-management/hooks/runtime-context.js.map +1 -1
- package/lib/commonjs/modules/bt-management/hooks/use-bluetooth-permission.js +2 -1
- package/lib/commonjs/modules/bt-management/hooks/use-bluetooth-permission.js.map +1 -1
- package/lib/commonjs/modules/bt-management/hooks/use-measurements.js +1 -1
- package/lib/commonjs/modules/bt-management/hooks/use-measurements.js.map +1 -1
- package/lib/commonjs/modules/bt-management/index.js +12 -0
- package/lib/commonjs/modules/bt-management/index.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/bt-manager.js +50 -0
- package/lib/commonjs/modules/bt-management/services/bt-manager.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/custom/define-custom-device.js +3 -0
- package/lib/commonjs/modules/bt-management/services/custom/define-custom-device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-command-writer.js +4 -2
- package/lib/commonjs/modules/bt-management/services/devices/bt-command-writer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-connection-handler.js +97 -28
- package/lib/commonjs/modules/bt-management/services/devices/bt-connection-handler.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-current-time.js +59 -0
- package/lib/commonjs/modules/bt-management/services/devices/bt-current-time.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/bt-device-information.js +18 -37
- package/lib/commonjs/modules/bt-management/services/devices/bt-device-information.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-managed-device.js +31 -3
- package/lib/commonjs/modules/bt-management/services/devices/bt-managed-device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-notification-readiness.js +68 -0
- package/lib/commonjs/modules/bt-management/services/devices/bt-notification-readiness.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/bt-pairing-retry.js +70 -0
- package/lib/commonjs/modules/bt-management/services/devices/bt-pairing-retry.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom.device.js +14 -0
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom.device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.blood-pressure-status.js +4 -7
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.blood-pressure-status.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.decorators.js +106 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.decorators.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js +38 -31
- 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.frame.js +41 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.frame.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-details.js +77 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-details.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-frame.js +49 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-frame.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-racp.js +89 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-racp.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.js +35 -42
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js +22 -24
- package/lib/commonjs/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/record-cursor.js +70 -0
- package/lib/commonjs/modules/bt-management/services/record-cursor.js.map +1 -0
- package/lib/commonjs/modules/bt-management/testing/fake-ble-manager.js +8 -0
- package/lib/commonjs/modules/bt-management/testing/fake-ble-manager.js.map +1 -1
- package/lib/commonjs/modules/bt-management/types/glucose-record-details.js +2 -0
- package/lib/commonjs/modules/bt-management/types/glucose-record-details.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/bluetooth-permission-list.js +19 -0
- package/lib/commonjs/modules/bt-management/utils/bluetooth-permission-list.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/device-user.js +22 -0
- package/lib/commonjs/modules/bt-management/utils/device-user.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/kpa-to-mmhg.js +9 -0
- package/lib/commonjs/modules/bt-management/utils/kpa-to-mmhg.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/result-identity.js +26 -35
- package/lib/commonjs/modules/bt-management/utils/result-identity.js.map +1 -1
- package/lib/commonjs/modules/bt-management/utils/rr-interval.js +16 -0
- package/lib/commonjs/modules/bt-management/utils/rr-interval.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/temperature-type.js +15 -0
- package/lib/commonjs/modules/bt-management/utils/temperature-type.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/wait.js +10 -0
- package/lib/commonjs/modules/bt-management/utils/wait.js.map +1 -0
- package/lib/commonjs/modules/next/background-sync/index.js +28 -0
- package/lib/commonjs/modules/next/background-sync/index.js.map +1 -0
- package/lib/commonjs/modules/next/background-sync/offline-measurement-background-sync.js +63 -0
- package/lib/commonjs/modules/next/background-sync/offline-measurement-background-sync.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/auto-connect.js +32 -0
- package/lib/commonjs/modules/next/bluetooth/auto-connect.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/ble-errors.js +33 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/ble-errors.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/ble-link.js +162 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/ble-link.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/ble-peripheral.js +35 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/ble-peripheral.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/ble-scanner.js +48 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/ble-scanner.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/built-in-devices.js +34 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/built-in-devices.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/legacy-driver.js +67 -0
- package/lib/commonjs/modules/next/bluetooth/ble-plx/legacy-driver.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/connections.js +114 -0
- package/lib/commonjs/modules/next/bluetooth/connections.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/daily-total-day.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/devices.js +41 -0
- package/lib/commonjs/modules/next/bluetooth/devices.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/driver.js +30 -20
- package/lib/commonjs/modules/next/bluetooth/driver.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/errors.js +26 -0
- package/lib/commonjs/modules/next/bluetooth/errors.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/index.js +122 -11
- package/lib/commonjs/modules/next/bluetooth/index.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/link.js +0 -103
- package/lib/commonjs/modules/next/bluetooth/link.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/paired.js +50 -0
- package/lib/commonjs/modules/next/bluetooth/paired.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/permissions.js +2 -0
- package/lib/commonjs/modules/next/bluetooth/permissions.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/react/bluetooth-device-picker.js +44 -0
- package/lib/commonjs/modules/next/bluetooth/react/bluetooth-device-picker.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/react/context.js +54 -0
- package/lib/commonjs/modules/next/bluetooth/react/context.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/react/hooks.js +86 -0
- package/lib/commonjs/modules/next/bluetooth/react/hooks.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/react-native/create-bluetooth-runtime.js +28 -0
- package/lib/commonjs/modules/next/bluetooth/react-native/create-bluetooth-runtime.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/react-native/os-permissions.js +32 -0
- package/lib/commonjs/modules/next/bluetooth/react-native/os-permissions.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/react-native/ovok-sink.js +43 -0
- package/lib/commonjs/modules/next/bluetooth/react-native/ovok-sink.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/readings.js +93 -0
- package/lib/commonjs/modules/next/bluetooth/readings.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/result-policy.js +15 -2
- package/lib/commonjs/modules/next/bluetooth/result-policy.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/runtime.js +223 -0
- package/lib/commonjs/modules/next/bluetooth/runtime.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/scan-loop.js +82 -0
- package/lib/commonjs/modules/next/bluetooth/scan-loop.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/sig-profiles.js +46 -13
- package/lib/commonjs/modules/next/bluetooth/sig-profiles.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/sink.js +6 -0
- package/lib/commonjs/modules/next/bluetooth/sink.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/snapshot.js +6 -0
- package/lib/commonjs/modules/next/bluetooth/snapshot.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/stable-hash.js +42 -0
- package/lib/commonjs/modules/next/bluetooth/stable-hash.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/store.js +61 -0
- package/lib/commonjs/modules/next/bluetooth/store.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/transport.js +6 -0
- package/lib/commonjs/modules/next/bluetooth/transport.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/create-web-bluetooth-runtime.js +28 -0
- package/lib/commonjs/modules/next/bluetooth/web/create-web-bluetooth-runtime.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/index.js +208 -0
- package/lib/commonjs/modules/next/bluetooth/web/index.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-ble-device.js +143 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-ble-device.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-ble-shapes.js +43 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-ble-shapes.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth-permissions.js +21 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth-permissions.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth-scanner.js +133 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth-scanner.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth-services.js +28 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth-services.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth-values.js +37 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth-values.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth.types.js +2 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-bluetooth.types.js.map +1 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-gatt.js +83 -0
- package/lib/commonjs/modules/next/bluetooth/web/web-gatt.js.map +1 -0
- package/lib/commonjs/modules/next/breathing-exercise/index.js +17 -0
- package/lib/commonjs/modules/next/breathing-exercise/index.js.map +1 -0
- package/lib/commonjs/modules/next/cms/index.js +17 -0
- package/lib/commonjs/modules/next/cms/index.js.map +1 -0
- package/lib/commonjs/modules/next/content/index.js +17 -0
- package/lib/commonjs/modules/next/content/index.js.map +1 -0
- package/lib/commonjs/modules/next/data-sync/index.js +17 -0
- package/lib/commonjs/modules/next/data-sync/index.js.map +1 -0
- package/lib/commonjs/modules/next/diary/index.js +17 -0
- package/lib/commonjs/modules/next/diary/index.js.map +1 -0
- package/lib/commonjs/modules/next/image/index.js +17 -0
- package/lib/commonjs/modules/next/image/index.js.map +1 -0
- package/lib/commonjs/modules/next/journal/index.js +17 -0
- package/lib/commonjs/modules/next/journal/index.js.map +1 -0
- package/lib/commonjs/modules/next/language-switcher/index.js +17 -0
- package/lib/commonjs/modules/next/language-switcher/index.js.map +1 -0
- package/lib/commonjs/modules/next/measurement/index.js +17 -0
- package/lib/commonjs/modules/next/measurement/index.js.map +1 -0
- package/lib/commonjs/modules/next/observation-detail/index.js +17 -0
- package/lib/commonjs/modules/next/observation-detail/index.js.map +1 -0
- package/lib/commonjs/modules/next/patient/index.js +17 -0
- package/lib/commonjs/modules/next/patient/index.js.map +1 -0
- package/lib/commonjs/modules/next/pdf/index.js +17 -0
- package/lib/commonjs/modules/next/pdf/index.js.map +1 -0
- package/lib/commonjs/modules/next/picker-sheet/index.js +17 -0
- package/lib/commonjs/modules/next/picker-sheet/index.js.map +1 -0
- package/lib/commonjs/modules/next/progress-bar/index.js +17 -0
- package/lib/commonjs/modules/next/progress-bar/index.js.map +1 -0
- package/lib/commonjs/modules/next/progress-ring/index.js +17 -0
- package/lib/commonjs/modules/next/progress-ring/index.js.map +1 -0
- package/lib/commonjs/modules/next/setting/index.js +17 -0
- package/lib/commonjs/modules/next/setting/index.js.map +1 -0
- package/lib/commonjs/modules/next/tab/index.js +17 -0
- package/lib/commonjs/modules/next/tab/index.js.map +1 -0
- package/lib/commonjs/modules/next/theme/index.js +17 -0
- package/lib/commonjs/modules/next/theme/index.js.map +1 -0
- package/lib/commonjs/modules/next/tile/index.js +17 -0
- package/lib/commonjs/modules/next/tile/index.js.map +1 -0
- package/lib/commonjs/modules/next/ui/index.js +17 -0
- package/lib/commonjs/modules/next/ui/index.js.map +1 -0
- package/lib/module/modules/bt-management/components/android-bluetooth-foreground-service.js +3 -1
- package/lib/module/modules/bt-management/components/android-bluetooth-foreground-service.js.map +1 -1
- package/lib/module/modules/bt-management/components/bluetooth-device-picker.js +9 -141
- package/lib/module/modules/bt-management/components/bluetooth-device-picker.js.map +1 -1
- package/lib/module/modules/bt-management/components/bt-provider-child-wrapper.js +1 -0
- package/lib/module/modules/bt-management/components/bt-provider-child-wrapper.js.map +1 -1
- package/lib/module/modules/bt-management/components/device-picker-sheet.js +154 -0
- package/lib/module/modules/bt-management/components/device-picker-sheet.js.map +1 -0
- package/lib/module/modules/bt-management/hooks/runtime-context.js.map +1 -1
- package/lib/module/modules/bt-management/hooks/use-bluetooth-permission.js +4 -3
- package/lib/module/modules/bt-management/hooks/use-bluetooth-permission.js.map +1 -1
- package/lib/module/modules/bt-management/hooks/use-measurements.js +1 -1
- package/lib/module/modules/bt-management/hooks/use-measurements.js.map +1 -1
- package/lib/module/modules/bt-management/index.js +1 -0
- package/lib/module/modules/bt-management/index.js.map +1 -1
- package/lib/module/modules/bt-management/services/bt-manager.js +50 -0
- package/lib/module/modules/bt-management/services/bt-manager.js.map +1 -1
- package/lib/module/modules/bt-management/services/custom/define-custom-device.js +3 -0
- package/lib/module/modules/bt-management/services/custom/define-custom-device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-command-writer.js +4 -2
- package/lib/module/modules/bt-management/services/devices/bt-command-writer.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-connection-handler.js +97 -28
- package/lib/module/modules/bt-management/services/devices/bt-connection-handler.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-current-time.js +55 -0
- package/lib/module/modules/bt-management/services/devices/bt-current-time.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/bt-device-information.js +18 -37
- package/lib/module/modules/bt-management/services/devices/bt-device-information.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-managed-device.js +33 -5
- package/lib/module/modules/bt-management/services/devices/bt-managed-device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-notification-readiness.js +65 -0
- package/lib/module/modules/bt-management/services/devices/bt-notification-readiness.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/bt-pairing-retry.js +65 -0
- package/lib/module/modules/bt-management/services/devices/bt-pairing-retry.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/custom/custom.device.js +14 -0
- package/lib/module/modules/bt-management/services/devices/custom/custom.device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.blood-pressure-status.js +1 -4
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.blood-pressure-status.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.decorators.js +99 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.decorators.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.js +38 -31
- 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.frame.js +35 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.frame.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-details.js +72 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-details.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-frame.js +40 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-frame.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-racp.js +85 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-racp.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.js +25 -32
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js +18 -20
- package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js.map +1 -1
- package/lib/module/modules/bt-management/services/record-cursor.js +66 -0
- package/lib/module/modules/bt-management/services/record-cursor.js.map +1 -0
- package/lib/module/modules/bt-management/testing/fake-ble-manager.js +8 -0
- package/lib/module/modules/bt-management/testing/fake-ble-manager.js.map +1 -1
- package/lib/module/modules/bt-management/types/custom-device-definition.js +4 -0
- package/lib/module/modules/bt-management/types/custom-device-definition.js.map +1 -1
- package/lib/module/modules/bt-management/types/glucose-record-details.js +2 -0
- package/lib/module/modules/bt-management/types/glucose-record-details.js.map +1 -0
- package/lib/module/modules/bt-management/utils/bluetooth-permission-list.js +14 -0
- package/lib/module/modules/bt-management/utils/bluetooth-permission-list.js.map +1 -0
- package/lib/module/modules/bt-management/utils/device-user.js +17 -0
- package/lib/module/modules/bt-management/utils/device-user.js.map +1 -0
- package/lib/module/modules/bt-management/utils/kpa-to-mmhg.js +6 -0
- package/lib/module/modules/bt-management/utils/kpa-to-mmhg.js.map +1 -0
- package/lib/module/modules/bt-management/utils/result-identity.js +23 -33
- package/lib/module/modules/bt-management/utils/result-identity.js.map +1 -1
- package/lib/module/modules/bt-management/utils/rr-interval.js +12 -0
- package/lib/module/modules/bt-management/utils/rr-interval.js.map +1 -0
- package/lib/module/modules/bt-management/utils/temperature-type.js +11 -0
- package/lib/module/modules/bt-management/utils/temperature-type.js.map +1 -0
- package/lib/module/modules/bt-management/utils/wait.js +5 -0
- package/lib/module/modules/bt-management/utils/wait.js.map +1 -0
- package/lib/module/modules/next/background-sync/index.js +12 -0
- package/lib/module/modules/next/background-sync/index.js.map +1 -0
- package/lib/module/modules/next/background-sync/offline-measurement-background-sync.js +55 -0
- package/lib/module/modules/next/background-sync/offline-measurement-background-sync.js.map +1 -0
- package/lib/module/modules/next/bluetooth/auto-connect.js +28 -0
- package/lib/module/modules/next/bluetooth/auto-connect.js.map +1 -0
- package/lib/module/modules/next/bluetooth/ble-plx/ble-errors.js +28 -0
- package/lib/module/modules/next/bluetooth/ble-plx/ble-errors.js.map +1 -0
- package/lib/module/modules/next/bluetooth/ble-plx/ble-link.js +159 -0
- package/lib/module/modules/next/bluetooth/ble-plx/ble-link.js.map +1 -0
- package/lib/module/modules/next/bluetooth/ble-plx/ble-peripheral.js +30 -0
- package/lib/module/modules/next/bluetooth/ble-plx/ble-peripheral.js.map +1 -0
- package/lib/module/modules/next/bluetooth/ble-plx/ble-scanner.js +44 -0
- package/lib/module/modules/next/bluetooth/ble-plx/ble-scanner.js.map +1 -0
- package/lib/module/modules/next/bluetooth/ble-plx/built-in-devices.js +31 -0
- package/lib/module/modules/next/bluetooth/ble-plx/built-in-devices.js.map +1 -0
- package/lib/module/modules/next/bluetooth/ble-plx/legacy-driver.js +63 -0
- package/lib/module/modules/next/bluetooth/ble-plx/legacy-driver.js.map +1 -0
- package/lib/module/modules/next/bluetooth/connections.js +110 -0
- package/lib/module/modules/next/bluetooth/connections.js.map +1 -0
- package/lib/module/modules/next/bluetooth/daily-total-day.js.map +1 -0
- package/lib/module/modules/next/bluetooth/devices.js +37 -0
- package/lib/module/modules/next/bluetooth/devices.js.map +1 -0
- package/lib/module/modules/next/bluetooth/driver.js +29 -20
- package/lib/module/modules/next/bluetooth/driver.js.map +1 -1
- package/lib/module/modules/next/bluetooth/errors.js +21 -0
- package/lib/module/modules/next/bluetooth/errors.js.map +1 -0
- package/lib/module/modules/next/bluetooth/index.js +22 -4
- package/lib/module/modules/next/bluetooth/index.js.map +1 -1
- package/lib/module/modules/next/bluetooth/link.js +0 -101
- package/lib/module/modules/next/bluetooth/link.js.map +1 -1
- package/lib/module/modules/next/bluetooth/paired.js +46 -0
- package/lib/module/modules/next/bluetooth/paired.js.map +1 -0
- package/lib/module/modules/next/bluetooth/permissions.js +2 -0
- package/lib/module/modules/next/bluetooth/permissions.js.map +1 -0
- package/lib/module/modules/next/bluetooth/react/bluetooth-device-picker.js +39 -0
- package/lib/module/modules/next/bluetooth/react/bluetooth-device-picker.js.map +1 -0
- package/lib/module/modules/next/bluetooth/react/context.js +48 -0
- package/lib/module/modules/next/bluetooth/react/context.js.map +1 -0
- package/lib/module/modules/next/bluetooth/react/hooks.js +76 -0
- package/lib/module/modules/next/bluetooth/react/hooks.js.map +1 -0
- package/lib/module/modules/next/bluetooth/react-native/create-bluetooth-runtime.js +25 -0
- package/lib/module/modules/next/bluetooth/react-native/create-bluetooth-runtime.js.map +1 -0
- package/lib/module/modules/next/bluetooth/react-native/os-permissions.js +28 -0
- package/lib/module/modules/next/bluetooth/react-native/os-permissions.js.map +1 -0
- package/lib/module/modules/next/bluetooth/react-native/ovok-sink.js +39 -0
- package/lib/module/modules/next/bluetooth/react-native/ovok-sink.js.map +1 -0
- package/lib/module/modules/next/bluetooth/readings.js +89 -0
- package/lib/module/modules/next/bluetooth/readings.js.map +1 -0
- package/lib/module/modules/next/bluetooth/result-policy.js +14 -2
- package/lib/module/modules/next/bluetooth/result-policy.js.map +1 -1
- package/lib/module/modules/next/bluetooth/runtime.js +220 -0
- package/lib/module/modules/next/bluetooth/runtime.js.map +1 -0
- package/lib/module/modules/next/bluetooth/scan-loop.js +78 -0
- package/lib/module/modules/next/bluetooth/scan-loop.js.map +1 -0
- package/lib/module/modules/next/bluetooth/sig-profiles.js +44 -11
- package/lib/module/modules/next/bluetooth/sig-profiles.js.map +1 -1
- package/lib/module/modules/next/bluetooth/sink.js +4 -0
- package/lib/module/modules/next/bluetooth/sink.js.map +1 -0
- package/lib/module/modules/next/bluetooth/snapshot.js +4 -0
- package/lib/module/modules/next/bluetooth/snapshot.js.map +1 -0
- package/lib/module/modules/next/bluetooth/stable-hash.js +37 -0
- package/lib/module/modules/next/bluetooth/stable-hash.js.map +1 -0
- package/lib/module/modules/next/bluetooth/store.js +57 -0
- package/lib/module/modules/next/bluetooth/store.js.map +1 -0
- package/lib/module/modules/next/bluetooth/transport.js +4 -0
- package/lib/module/modules/next/bluetooth/transport.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/create-web-bluetooth-runtime.js +25 -0
- package/lib/module/modules/next/bluetooth/web/create-web-bluetooth-runtime.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/index.js +28 -0
- package/lib/module/modules/next/bluetooth/web/index.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/web-ble-device.js +140 -0
- package/lib/module/modules/next/bluetooth/web/web-ble-device.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/web-ble-shapes.js +39 -0
- package/lib/module/modules/next/bluetooth/web/web-ble-shapes.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth-permissions.js +18 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth-permissions.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth-scanner.js +128 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth-scanner.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth-services.js +25 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth-services.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth-values.js +29 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth-values.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth.types.js +2 -0
- package/lib/module/modules/next/bluetooth/web/web-bluetooth.types.js.map +1 -0
- package/lib/module/modules/next/bluetooth/web/web-gatt.js +79 -0
- package/lib/module/modules/next/bluetooth/web/web-gatt.js.map +1 -0
- package/lib/module/modules/next/breathing-exercise/index.js +5 -0
- package/lib/module/modules/next/breathing-exercise/index.js.map +1 -0
- package/lib/module/modules/next/cms/index.js +5 -0
- package/lib/module/modules/next/cms/index.js.map +1 -0
- package/lib/module/modules/next/content/index.js +5 -0
- package/lib/module/modules/next/content/index.js.map +1 -0
- package/lib/module/modules/next/data-sync/index.js +11 -0
- package/lib/module/modules/next/data-sync/index.js.map +1 -0
- package/lib/module/modules/next/diary/index.js +5 -0
- package/lib/module/modules/next/diary/index.js.map +1 -0
- package/lib/module/modules/next/image/index.js +5 -0
- package/lib/module/modules/next/image/index.js.map +1 -0
- package/lib/module/modules/next/journal/index.js +5 -0
- package/lib/module/modules/next/journal/index.js.map +1 -0
- package/lib/module/modules/next/language-switcher/index.js +5 -0
- package/lib/module/modules/next/language-switcher/index.js.map +1 -0
- package/lib/module/modules/next/measurement/index.js +5 -0
- package/lib/module/modules/next/measurement/index.js.map +1 -0
- package/lib/module/modules/next/observation-detail/index.js +5 -0
- package/lib/module/modules/next/observation-detail/index.js.map +1 -0
- package/lib/module/modules/next/patient/index.js +5 -0
- package/lib/module/modules/next/patient/index.js.map +1 -0
- package/lib/module/modules/next/pdf/index.js +5 -0
- package/lib/module/modules/next/pdf/index.js.map +1 -0
- package/lib/module/modules/next/picker-sheet/index.js +5 -0
- package/lib/module/modules/next/picker-sheet/index.js.map +1 -0
- package/lib/module/modules/next/progress-bar/index.js +5 -0
- package/lib/module/modules/next/progress-bar/index.js.map +1 -0
- package/lib/module/modules/next/progress-ring/index.js +5 -0
- package/lib/module/modules/next/progress-ring/index.js.map +1 -0
- package/lib/module/modules/next/setting/index.js +5 -0
- package/lib/module/modules/next/setting/index.js.map +1 -0
- package/lib/module/modules/next/tab/index.js +5 -0
- package/lib/module/modules/next/tab/index.js.map +1 -0
- package/lib/module/modules/next/theme/index.js +5 -0
- package/lib/module/modules/next/theme/index.js.map +1 -0
- package/lib/module/modules/next/tile/index.js +5 -0
- package/lib/module/modules/next/tile/index.js.map +1 -0
- package/lib/module/modules/next/ui/index.js +5 -0
- package/lib/module/modules/next/ui/index.js.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/hooks/use-sign-in.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/components/android-bluetooth-foreground-service.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/components/bluetooth-device-picker.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/components/bluetooth-device-picker.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/components/bt-provider-child-wrapper.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/components/device-picker-sheet.d.ts +25 -0
- package/lib/typescript/commonjs/src/modules/bt-management/components/device-picker-sheet.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/runtime-context.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/runtime-context.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/use-bluetooth-permission.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/use-measurements.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/index.d.ts +1 -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 +20 -0
- 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/define-custom-device.d.ts +2 -1
- 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/devices/bt-command-writer.d.ts +3 -1
- 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/bt-connection-handler.d.ts +14 -1
- 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-current-time.d.ts +11 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-current-time.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-device-information.d.ts +2 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-device-information.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-managed-device.d.ts +11 -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/bt-notification-readiness.d.ts +15 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-notification-readiness.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-pairing-retry.d.ts +21 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-pairing-retry.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom.device.d.ts +2 -0
- 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/standard-gatt/standard-gatt.blood-pressure-status.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.decorators.d.ts +11 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.decorators.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.d.ts +5 -2
- 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.frame.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.frame.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-details.d.ts +7 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-details.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-frame.d.ts +16 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-frame.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-racp.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-racp.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.d.ts +2 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/record-cursor.d.ts +21 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/record-cursor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/testing/fake-ble-manager.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/command-sequencer.d.ts +6 -2
- package/lib/typescript/commonjs/src/modules/bt-management/types/command-sequencer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/create-device-params.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/create-device-params.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-device-definition.d.ts +14 -1
- 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/glucose-record-details.d.ts +33 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/glucose-record-details.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/result-callback.d.ts +2 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/result-callback.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/result-policy.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/result-policy.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/bluetooth-permission-list.d.ts +4 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/bluetooth-permission-list.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/device-user.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/device-user.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/kpa-to-mmhg.d.ts +4 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/kpa-to-mmhg.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/result-identity.d.ts +5 -4
- package/lib/typescript/commonjs/src/modules/bt-management/utils/result-identity.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/rr-interval.d.ts +4 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/rr-interval.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/temperature-type.d.ts +7 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/temperature-type.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/wait.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/wait.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/services/managers/sync-progress-manager.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/next/background-sync/index.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/next/background-sync/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/background-sync/offline-measurement-background-sync.d.ts +22 -0
- package/lib/typescript/commonjs/src/modules/next/background-sync/offline-measurement-background-sync.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/auto-connect.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/auto-connect.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/ble-errors.d.ts +4 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/ble-errors.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/ble-link.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/ble-link.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/ble-peripheral.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/ble-peripheral.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/ble-scanner.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/ble-scanner.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/built-in-devices.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/built-in-devices.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/legacy-driver.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/legacy-driver.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/connections.d.ts +25 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/connections.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/daily-total-day.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/devices.d.ts +30 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/devices.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/driver.d.ts +27 -20
- package/lib/typescript/commonjs/src/modules/next/bluetooth/driver.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/errors.d.ts +17 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/errors.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/index.d.ts +34 -5
- package/lib/typescript/commonjs/src/modules/next/bluetooth/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/link.d.ts +14 -5
- package/lib/typescript/commonjs/src/modules/next/bluetooth/link.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/paired.d.ts +18 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/paired.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/permissions.d.ts +13 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/permissions.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react/bluetooth-device-picker.d.ts +35 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react/bluetooth-device-picker.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react/context.d.ts +30 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react/context.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react/hooks.d.ts +47 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react/hooks.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react-native/create-bluetooth-runtime.d.ts +21 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react-native/create-bluetooth-runtime.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react-native/os-permissions.d.ts +5 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react-native/os-permissions.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react-native/ovok-sink.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/react-native/ovok-sink.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/readings.d.ts +21 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/readings.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/result-policy.d.ts +9 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/result-policy.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/runtime.d.ts +87 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/runtime.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/scan-loop.d.ts +23 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/scan-loop.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/sig-profiles.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/sink.d.ts +20 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/sink.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/snapshot.d.ts +72 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/snapshot.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/stable-hash.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/stable-hash.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/store.d.ts +16 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/store.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/transport.d.ts +31 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/transport.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/create-web-bluetooth-runtime.d.ts +23 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/create-web-bluetooth-runtime.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/index.d.ts +41 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-ble-device.d.ts +53 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-ble-device.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-ble-shapes.d.ts +27 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-ble-shapes.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth-permissions.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth-permissions.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth-scanner.d.ts +29 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth-scanner.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth-services.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth-services.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth-values.d.ts +9 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth-values.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth.types.d.ts +56 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-bluetooth.types.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-gatt.d.ts +27 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/web-gatt.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/breathing-exercise/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/breathing-exercise/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/cms/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/cms/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/content/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/content/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/data-sync/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/modules/next/data-sync/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/diary/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/diary/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/image/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/image/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/journal/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/journal/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/language-switcher/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/language-switcher/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/measurement/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/measurement/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/observation-detail/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/observation-detail/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/patient/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/patient/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/pdf/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/pdf/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/picker-sheet/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/picker-sheet/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/progress-bar/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/progress-bar/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/progress-ring/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/progress-ring/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/setting/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/setting/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/tab/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/tab/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/theme/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/theme/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/tile/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/tile/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/next/ui/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/next/ui/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/hooks/use-sign-in.d.ts +1 -1
- package/lib/typescript/module/src/modules/bt-management/components/android-bluetooth-foreground-service.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/components/bluetooth-device-picker.d.ts +1 -1
- package/lib/typescript/module/src/modules/bt-management/components/bluetooth-device-picker.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/components/bt-provider-child-wrapper.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/components/device-picker-sheet.d.ts +25 -0
- package/lib/typescript/module/src/modules/bt-management/components/device-picker-sheet.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/hooks/runtime-context.d.ts +1 -1
- package/lib/typescript/module/src/modules/bt-management/hooks/runtime-context.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/hooks/use-bluetooth-permission.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/hooks/use-measurements.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/index.d.ts +1 -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 +20 -0
- 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/define-custom-device.d.ts +2 -1
- 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/devices/bt-command-writer.d.ts +3 -1
- 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/bt-connection-handler.d.ts +14 -1
- 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-current-time.d.ts +11 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-current-time.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-device-information.d.ts +2 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-device-information.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-managed-device.d.ts +11 -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/bt-notification-readiness.d.ts +15 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-notification-readiness.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-pairing-retry.d.ts +21 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-pairing-retry.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom.device.d.ts +2 -0
- 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/standard-gatt/standard-gatt.blood-pressure-status.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.decorators.d.ts +11 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.decorators.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.devices.d.ts +5 -2
- 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.frame.d.ts +10 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.frame.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-details.d.ts +7 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-details.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-frame.d.ts +16 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-frame.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-racp.d.ts +8 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose-racp.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.d.ts +2 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/record-cursor.d.ts +21 -0
- package/lib/typescript/module/src/modules/bt-management/services/record-cursor.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/testing/fake-ble-manager.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/command-sequencer.d.ts +6 -2
- package/lib/typescript/module/src/modules/bt-management/types/command-sequencer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/create-device-params.d.ts +3 -0
- package/lib/typescript/module/src/modules/bt-management/types/create-device-params.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/custom-device-definition.d.ts +14 -1
- 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/glucose-record-details.d.ts +33 -0
- package/lib/typescript/module/src/modules/bt-management/types/glucose-record-details.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/types/result-callback.d.ts +2 -0
- package/lib/typescript/module/src/modules/bt-management/types/result-callback.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/result-policy.d.ts +6 -0
- package/lib/typescript/module/src/modules/bt-management/types/result-policy.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/bluetooth-permission-list.d.ts +4 -0
- package/lib/typescript/module/src/modules/bt-management/utils/bluetooth-permission-list.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/device-user.d.ts +6 -0
- package/lib/typescript/module/src/modules/bt-management/utils/device-user.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/kpa-to-mmhg.d.ts +4 -0
- package/lib/typescript/module/src/modules/bt-management/utils/kpa-to-mmhg.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/result-identity.d.ts +5 -4
- package/lib/typescript/module/src/modules/bt-management/utils/result-identity.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/rr-interval.d.ts +4 -0
- package/lib/typescript/module/src/modules/bt-management/utils/rr-interval.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/temperature-type.d.ts +7 -0
- package/lib/typescript/module/src/modules/bt-management/utils/temperature-type.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/wait.d.ts +3 -0
- package/lib/typescript/module/src/modules/bt-management/utils/wait.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/data-sync/services/managers/sync-progress-manager.d.ts +1 -1
- package/lib/typescript/module/src/modules/next/background-sync/index.d.ts +10 -0
- package/lib/typescript/module/src/modules/next/background-sync/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/background-sync/offline-measurement-background-sync.d.ts +22 -0
- package/lib/typescript/module/src/modules/next/background-sync/offline-measurement-background-sync.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/auto-connect.d.ts +10 -0
- package/lib/typescript/module/src/modules/next/bluetooth/auto-connect.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/ble-errors.d.ts +4 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/ble-errors.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/ble-link.d.ts +6 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/ble-link.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/ble-peripheral.d.ts +8 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/ble-peripheral.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/ble-scanner.d.ts +6 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/ble-scanner.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/built-in-devices.d.ts +6 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/built-in-devices.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/legacy-driver.d.ts +8 -0
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/legacy-driver.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/connections.d.ts +25 -0
- package/lib/typescript/module/src/modules/next/bluetooth/connections.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/daily-total-day.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/devices.d.ts +30 -0
- package/lib/typescript/module/src/modules/next/bluetooth/devices.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/driver.d.ts +27 -20
- package/lib/typescript/module/src/modules/next/bluetooth/driver.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/errors.d.ts +17 -0
- package/lib/typescript/module/src/modules/next/bluetooth/errors.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/index.d.ts +34 -5
- package/lib/typescript/module/src/modules/next/bluetooth/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/link.d.ts +14 -5
- package/lib/typescript/module/src/modules/next/bluetooth/link.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/paired.d.ts +18 -0
- package/lib/typescript/module/src/modules/next/bluetooth/paired.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/permissions.d.ts +13 -0
- package/lib/typescript/module/src/modules/next/bluetooth/permissions.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react/bluetooth-device-picker.d.ts +35 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react/bluetooth-device-picker.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react/context.d.ts +30 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react/context.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react/hooks.d.ts +47 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react/hooks.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react-native/create-bluetooth-runtime.d.ts +21 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react-native/create-bluetooth-runtime.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react-native/os-permissions.d.ts +5 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react-native/os-permissions.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react-native/ovok-sink.d.ts +6 -0
- package/lib/typescript/module/src/modules/next/bluetooth/react-native/ovok-sink.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/readings.d.ts +21 -0
- package/lib/typescript/module/src/modules/next/bluetooth/readings.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/result-policy.d.ts +9 -1
- package/lib/typescript/module/src/modules/next/bluetooth/result-policy.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/runtime.d.ts +87 -0
- package/lib/typescript/module/src/modules/next/bluetooth/runtime.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/scan-loop.d.ts +23 -0
- package/lib/typescript/module/src/modules/next/bluetooth/scan-loop.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/sig-profiles.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/sink.d.ts +20 -0
- package/lib/typescript/module/src/modules/next/bluetooth/sink.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/snapshot.d.ts +72 -0
- package/lib/typescript/module/src/modules/next/bluetooth/snapshot.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/stable-hash.d.ts +6 -0
- package/lib/typescript/module/src/modules/next/bluetooth/stable-hash.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/store.d.ts +16 -0
- package/lib/typescript/module/src/modules/next/bluetooth/store.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/transport.d.ts +31 -0
- package/lib/typescript/module/src/modules/next/bluetooth/transport.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/create-web-bluetooth-runtime.d.ts +23 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/create-web-bluetooth-runtime.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/index.d.ts +41 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-ble-device.d.ts +53 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-ble-device.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-ble-shapes.d.ts +27 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-ble-shapes.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth-permissions.d.ts +8 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth-permissions.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth-scanner.d.ts +29 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth-scanner.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth-services.d.ts +10 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth-services.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth-values.d.ts +9 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth-values.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth.types.d.ts +56 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-bluetooth.types.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-gatt.d.ts +27 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/web-gatt.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/breathing-exercise/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/breathing-exercise/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/cms/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/cms/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/content/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/content/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/data-sync/index.d.ts +9 -0
- package/lib/typescript/module/src/modules/next/data-sync/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/diary/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/diary/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/image/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/image/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/journal/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/journal/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/language-switcher/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/language-switcher/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/measurement/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/measurement/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/observation-detail/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/observation-detail/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/patient/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/patient/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/pdf/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/pdf/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/picker-sheet/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/picker-sheet/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/progress-bar/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/progress-bar/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/progress-ring/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/progress-ring/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/setting/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/setting/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/tab/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/tab/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/theme/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/theme/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/tile/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/tile/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/next/ui/index.d.ts +3 -0
- package/lib/typescript/module/src/modules/next/ui/index.d.ts.map +1 -0
- package/package.json +12 -2
- package/lib/commonjs/modules/bt-management/utils/daily-total-day.js.map +0 -1
- package/lib/commonjs/modules/next/bluetooth/drivers.js +0 -20
- package/lib/commonjs/modules/next/bluetooth/drivers.js.map +0 -1
- package/lib/commonjs/modules/next/bluetooth/legacy-driver.js +0 -55
- package/lib/commonjs/modules/next/bluetooth/legacy-driver.js.map +0 -1
- package/lib/module/modules/bt-management/utils/daily-total-day.js.map +0 -1
- package/lib/module/modules/next/bluetooth/drivers.js +0 -17
- package/lib/module/modules/next/bluetooth/drivers.js.map +0 -1
- package/lib/module/modules/next/bluetooth/legacy-driver.js +0 -51
- package/lib/module/modules/next/bluetooth/legacy-driver.js.map +0 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/daily-total-day.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/drivers.d.ts +0 -7
- package/lib/typescript/commonjs/src/modules/next/bluetooth/drivers.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/legacy-driver.d.ts +0 -8
- package/lib/typescript/commonjs/src/modules/next/bluetooth/legacy-driver.d.ts.map +0 -1
- package/lib/typescript/module/src/modules/bt-management/utils/daily-total-day.d.ts.map +0 -1
- package/lib/typescript/module/src/modules/next/bluetooth/drivers.d.ts +0 -7
- package/lib/typescript/module/src/modules/next/bluetooth/drivers.d.ts.map +0 -1
- package/lib/typescript/module/src/modules/next/bluetooth/legacy-driver.d.ts +0 -8
- package/lib/typescript/module/src/modules/next/bluetooth/legacy-driver.d.ts.map +0 -1
- /package/lib/commonjs/modules/{bt-management/utils → next/bluetooth}/daily-total-day.js +0 -0
- /package/lib/module/modules/{bt-management/utils → next/bluetooth}/daily-total-day.js +0 -0
- /package/lib/typescript/commonjs/src/modules/{bt-management/utils → next/bluetooth}/daily-total-day.d.ts +0 -0
- /package/lib/typescript/module/src/modules/{bt-management/utils → next/bluetooth}/daily-total-day.d.ts +0 -0
package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.js
CHANGED
|
@@ -2,8 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
import { MeasurementTypeKey } from "@ovok/core/next";
|
|
4
4
|
import { byteToHex } from "../../../utils/bytes-to-hex.js";
|
|
5
|
-
import { sigUuid } from "../../../utils/sig-uuid.js";
|
|
6
5
|
import { defineCustomDevice } from "../../custom/define-custom-device.js";
|
|
6
|
+
import { glucoseRecordDetails, hasUnusableSensorStatus } from "./standard-gatt.glucose-details.js";
|
|
7
|
+
import { BASE_TIME_INDEX, byte, concentrationIndex, FLAG_CONCENTRATION, FLAG_MOL_PER_L, FLAG_TIME_OFFSET, TIME_OFFSET_INDEX, typeAndLocationFromGlucoseFrame } from "./standard-gatt.glucose-frame.js";
|
|
8
|
+
import { createGlucoseSequencer, GLUCOSE_MEASUREMENT_UUID, GLUCOSE_SERVICE_UUID, RECORD_ACCESS_CONTROL_POINT_UUID } from "./standard-gatt.glucose-racp.js";
|
|
7
9
|
import { littleEndian } from "./standard-gatt.profile.js";
|
|
8
10
|
|
|
9
11
|
/**
|
|
@@ -11,10 +13,11 @@ import { littleEndian } from "./standard-gatt.profile.js";
|
|
|
11
13
|
* 0x2A52.
|
|
12
14
|
*
|
|
13
15
|
* A glucose meter does not push its readings. The collector enables indications on the
|
|
14
|
-
* control point
|
|
15
|
-
*
|
|
16
|
-
* (`
|
|
17
|
-
*
|
|
16
|
+
* control point and writes a request for the stored records: those after the newest one it
|
|
17
|
+
* has read (`01 03 01 nn nn`) when the manager has a `recordCursorStorage`, otherwise all of
|
|
18
|
+
* them (`01 01`). The meter answers with one Glucose Measurement per record followed by a
|
|
19
|
+
* control-point response (`06 00 01 xx`). The SDK's stable result identity, which covers the
|
|
20
|
+
* record's sequence number, keeps a record seen twice from becoming a second reading.
|
|
18
21
|
*
|
|
19
22
|
* Glucose Measurement layout: flags, sequence number (2), base time (7), time offset (2,
|
|
20
23
|
* flag bit 0), concentration SFLOAT (2) and type/sample-location (1) (bit 1), sensor status
|
|
@@ -24,17 +27,13 @@ const MG_PER_DL_PER_KG_PER_L = 100_000;
|
|
|
24
27
|
|
|
25
28
|
/** One mol/L of glucose (180.16 g/mol) is 18,016 mg/dL. */
|
|
26
29
|
const MG_PER_DL_PER_MOL_PER_L = 18_016;
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
const
|
|
30
|
-
const BASE_TIME_INDEX = 3;
|
|
31
|
-
const TIME_OFFSET_INDEX = 10;
|
|
30
|
+
|
|
31
|
+
/** One decimal reads a mmol/L result (0.1 mmol/L is 1.8 mg/dL) back as the meter showed it. */
|
|
32
|
+
const MG_PER_DL_DECIMALS = 1;
|
|
32
33
|
|
|
33
34
|
/** Type 0xA and sample location 0x4 both mean a control-solution test, not a patient sample. */
|
|
34
35
|
const CONTROL_SOLUTION_TYPE = 0x0a;
|
|
35
36
|
const CONTROL_SOLUTION_LOCATION = 0x04;
|
|
36
|
-
const REPORT_ALL_STORED_RECORDS = "0101";
|
|
37
|
-
const concentrationIndex = flags => flags & FLAG_TIME_OFFSET ? TIME_OFFSET_INDEX + 2 : TIME_OFFSET_INDEX;
|
|
38
37
|
|
|
39
38
|
/** Bits 5-7 are reserved; a meter that sets one still sends a readable record. */
|
|
40
39
|
const ALL_FLAGS = Array.from({
|
|
@@ -45,13 +44,9 @@ const glucoseField = flags => {
|
|
|
45
44
|
return {
|
|
46
45
|
...littleEndian("bloodGlucose", [index, index + 1], "mg/dL", "sfloat"),
|
|
47
46
|
scale: flags & FLAG_MOL_PER_L ? MG_PER_DL_PER_MOL_PER_L : MG_PER_DL_PER_KG_PER_L,
|
|
48
|
-
decimals:
|
|
47
|
+
decimals: MG_PER_DL_DECIMALS
|
|
49
48
|
};
|
|
50
49
|
};
|
|
51
|
-
const byte = (frame, index) => {
|
|
52
|
-
const value = Number.parseInt(frame[index] ?? "", 16);
|
|
53
|
-
return Number.isInteger(value) ? value : undefined;
|
|
54
|
-
};
|
|
55
50
|
|
|
56
51
|
/** The record's own time: the base time plus its offset in minutes, read as phone-local. */
|
|
57
52
|
const recordedAtFromGlucoseFrame = frame => {
|
|
@@ -82,8 +77,7 @@ const recordedAtFromGlucoseFrame = frame => {
|
|
|
82
77
|
return recordedAt;
|
|
83
78
|
};
|
|
84
79
|
const isControlSolution = frame => {
|
|
85
|
-
const
|
|
86
|
-
const typeAndLocation = byte(frame, concentrationIndex(flags) + 2);
|
|
80
|
+
const typeAndLocation = typeAndLocationFromGlucoseFrame(frame);
|
|
87
81
|
return typeAndLocation !== undefined && ((typeAndLocation & 0x0f) === CONTROL_SOLUTION_TYPE || typeAndLocation >> 4 === CONTROL_SOLUTION_LOCATION);
|
|
88
82
|
};
|
|
89
83
|
|
|
@@ -95,9 +89,9 @@ const standardGlucoseDevice = params => defineCustomDevice({
|
|
|
95
89
|
oneReadingPerConnection: params.oneReadingPerConnection,
|
|
96
90
|
stuckDataTimeoutMs: params.stuckDataTimeoutMs ?? 60_000,
|
|
97
91
|
services: [{
|
|
98
|
-
uuid:
|
|
92
|
+
uuid: GLUCOSE_SERVICE_UUID,
|
|
99
93
|
monitor: [{
|
|
100
|
-
uuid:
|
|
94
|
+
uuid: GLUCOSE_MEASUREMENT_UUID,
|
|
101
95
|
frame: {
|
|
102
96
|
minLengthBytes: TIME_OFFSET_INDEX
|
|
103
97
|
},
|
|
@@ -114,7 +108,7 @@ const standardGlucoseDevice = params => defineCustomDevice({
|
|
|
114
108
|
description: "A record without a concentration"
|
|
115
109
|
})
|
|
116
110
|
}, {
|
|
117
|
-
uuid:
|
|
111
|
+
uuid: RECORD_ACCESS_CONTROL_POINT_UUID,
|
|
118
112
|
frame: {
|
|
119
113
|
minLengthBytes: 2
|
|
120
114
|
},
|
|
@@ -128,23 +122,22 @@ const standardGlucoseDevice = params => defineCustomDevice({
|
|
|
128
122
|
kind: "idle",
|
|
129
123
|
description: "Record access response"
|
|
130
124
|
}]
|
|
131
|
-
}]
|
|
132
|
-
write: {
|
|
133
|
-
uuid: sigUuid("2a52"),
|
|
134
|
-
commandHex: REPORT_ALL_STORED_RECORDS,
|
|
135
|
-
when: "connect"
|
|
136
|
-
}
|
|
125
|
+
}]
|
|
137
126
|
}]
|
|
138
127
|
}, {
|
|
128
|
+
createCommandSequencer: createGlucoseSequencer,
|
|
139
129
|
decorateReading: (reading, frame, recordOffset) => {
|
|
140
|
-
if (frame && isControlSolution(frame)) {
|
|
130
|
+
if (frame && (isControlSolution(frame) || hasUnusableSensorStatus(frame))) {
|
|
141
131
|
return null;
|
|
142
132
|
}
|
|
143
133
|
const recordedAt = frame ? recordedAtFromGlucoseFrame(frame) : undefined;
|
|
144
|
-
const decorated =
|
|
134
|
+
const decorated = {
|
|
145
135
|
...reading,
|
|
146
|
-
|
|
147
|
-
|
|
136
|
+
...(frame && glucoseRecordDetails(frame)),
|
|
137
|
+
...(recordedAt && {
|
|
138
|
+
recordedAt
|
|
139
|
+
})
|
|
140
|
+
};
|
|
148
141
|
return params.decorateReading ? params.decorateReading(decorated, frame, recordOffset) : decorated;
|
|
149
142
|
}
|
|
150
143
|
});
|
package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["MeasurementTypeKey","byteToHex","
|
|
1
|
+
{"version":3,"names":["MeasurementTypeKey","byteToHex","defineCustomDevice","glucoseRecordDetails","hasUnusableSensorStatus","BASE_TIME_INDEX","byte","concentrationIndex","FLAG_CONCENTRATION","FLAG_MOL_PER_L","FLAG_TIME_OFFSET","TIME_OFFSET_INDEX","typeAndLocationFromGlucoseFrame","createGlucoseSequencer","GLUCOSE_MEASUREMENT_UUID","GLUCOSE_SERVICE_UUID","RECORD_ACCESS_CONTROL_POINT_UUID","littleEndian","MG_PER_DL_PER_KG_PER_L","MG_PER_DL_PER_MOL_PER_L","MG_PER_DL_DECIMALS","CONTROL_SOLUTION_TYPE","CONTROL_SOLUTION_LOCATION","ALL_FLAGS","Array","from","length","_","flags","glucoseField","index","scale","decimals","recordedAtFromGlucoseFrame","frame","parts","i","undefined","some","part","yearLow","yearHigh","month","day","hour","minute","second","year","recordedAt","Date","getFullYear","getMonth","getDate","getHours","getMinutes","getSeconds","low","high","offsetMinutes","setMinutes","isControlSolution","typeAndLocation","standardGlucoseDevice","params","id","bloodGlucose","nameMatch","matchByService","oneReadingPerConnection","stuckDataTimeoutMs","services","uuid","monitor","minLengthBytes","caseSelectorBytes","cases","map","selector","kind","measurementTypeKey","fields","description","createCommandSequencer","decorateReading","reading","recordOffset","decorated"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/standard-gatt/standard-gatt.glucose.ts"],"mappings":";;AAAA,SAASA,kBAAkB,QAAQ,iBAAiB;AAIpD,SAASC,SAAS,QAAQ,gCAA6B;AACvD,SAASC,kBAAkB,QAAQ,sCAAmC;AAEtE,SACEC,oBAAoB,EACpBC,uBAAuB,QAClB,oCAAiC;AACxC,SACEC,eAAe,EACfC,IAAI,EACJC,kBAAkB,EAClBC,kBAAkB,EAClBC,cAAc,EACdC,gBAAgB,EAChBC,iBAAiB,EACjBC,+BAA+B,QAC1B,kCAA+B;AACtC,SACEC,sBAAsB,EACtBC,wBAAwB,EACxBC,oBAAoB,EACpBC,gCAAgC,QAC3B,iCAA8B;AACrC,SAASC,YAAY,QAA8B,4BAAyB;;AAE5E;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,sBAAsB,GAAG,OAAO;;AAEtC;AACA,MAAMC,uBAAuB,GAAG,MAAM;;AAEtC;AACA,MAAMC,kBAAkB,GAAG,CAAC;;AAE5B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AI,EAAE,MAAe;QAAEG,WAAW,EAAE;MAAyB,CAAC;IAEpF,CAAC;EAEL,CAAC;AAEL,CAAC,EACD;EACEC,sBAAsB,EAAErE,sBAAsB;EAC9CsE,eAAe,EAAEA,CAACC,OAAO,EAAElD,KAAK,EAAEmD,YAAY,KAAK;IACjD,IAAInD,KAAK,KAAK0B,iBAAiB,CAAC1B,KAAK,CAAC,IAAI9B,uBAAuB,CAAC8B,KAAK,CAAC,CAAC,EAAE;MACzE,OAAO,IAAI;IACb;IAEA,MAAMc,UAAU,GAAGd,KAAK,GAAGD,0BAA0B,CAACC,KAAK,CAAC,GAAGG,SAAS;IAExE,MAAMiD,SAAS,GAAG;MAChB,GAAGF,OAAO;MACV,IAAIlD,KAAK,IAAI/B,oBAAoB,CAAC+B,KAAK,CAAC,CAAC;MACzC,IAAIc,UAAU,IAAI;QAAEA;MAAW,CAAC;IAClC,CAAC;IAED,OAAOe,MAAM,CAACoB,eAAe,GACzBpB,MAAM,CAACoB,eAAe,CAACG,SAAS,EAAEpD,KAAK,EAAEmD,YAAY,CAAC,GACtDC,SAAS;EACf;AACF,CACF,CAAC;AAEH,SAASrD,0BAA0B,EAAE6B,qBAAqB","ignoreList":[]}
|
package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js
CHANGED
|
@@ -1,12 +1,25 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
import { BloodPressureStates } from "../../../types/blood-pressure-states.js";
|
|
4
|
+
import { memorySlotForDeviceUser } from "../../../utils/device-user.js";
|
|
4
5
|
import { sigUuid } from "../../../utils/sig-uuid.js";
|
|
5
6
|
import { defineCustomDevice } from "../../custom/define-custom-device.js";
|
|
6
7
|
import { bloodPressureStatusFromFrame } from "./standard-gatt.blood-pressure-status.js";
|
|
8
|
+
import { byteAt, dateTimeAt } from "./standard-gatt.frame.js";
|
|
7
9
|
|
|
8
10
|
/** Milliseconds a spot-check device may take to produce its reading. */
|
|
9
11
|
const SPOT_CHECK_TIMEOUT_MS = 60_000;
|
|
12
|
+
/** Runs `first`, then `second` on what it returns; either may withhold the reading. */
|
|
13
|
+
const chainDecorators = (first, second) => {
|
|
14
|
+
if (!first || !second) {
|
|
15
|
+
return first ?? second;
|
|
16
|
+
}
|
|
17
|
+
return (reading, frame, recordOffset) => {
|
|
18
|
+
const decorated = first(reading, frame, recordOffset);
|
|
19
|
+
return decorated && second(decorated, frame, recordOffset);
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
|
|
10
23
|
/**
|
|
11
24
|
* The flags byte selects the case, because it decides which optional fields are present and
|
|
12
25
|
* therefore where the later ones sit. Fields common to every shape are declared once; a
|
|
@@ -43,7 +56,7 @@ const declareProfile = (params, profile) => defineCustomDevice({
|
|
|
43
56
|
}]
|
|
44
57
|
}]
|
|
45
58
|
}, {
|
|
46
|
-
decorateReading: params.decorateReading
|
|
59
|
+
decorateReading: chainDecorators(profile.decorateReading, params.decorateReading)
|
|
47
60
|
});
|
|
48
61
|
const littleEndian = (name, byteIndexes, unit, encoding) => ({
|
|
49
62
|
name,
|
|
@@ -52,27 +65,11 @@ const littleEndian = (name, byteIndexes, unit, encoding) => ({
|
|
|
52
65
|
encoding,
|
|
53
66
|
unit
|
|
54
67
|
});
|
|
55
|
-
const byteAt = (frame, index, offset) => {
|
|
56
|
-
const value = Number.parseInt(frame[index + offset] ?? "", 16);
|
|
57
|
-
return Number.isInteger(value) && value >= 0 && value <= 0xff ? value : undefined;
|
|
58
|
-
};
|
|
59
68
|
|
|
60
69
|
/** Reads the SIG blood-pressure timestamp as a phone-local date. */
|
|
61
70
|
const recordedAtFromBloodPressureFrame = (frame, offset = 0) => {
|
|
62
71
|
const flags = byteAt(frame, 0, offset);
|
|
63
|
-
|
|
64
|
-
const yearHigh = byteAt(frame, 8, offset);
|
|
65
|
-
const month = byteAt(frame, 9, offset);
|
|
66
|
-
const day = byteAt(frame, 10, offset);
|
|
67
|
-
const hour = byteAt(frame, 11, offset);
|
|
68
|
-
const minute = byteAt(frame, 12, offset);
|
|
69
|
-
const second = byteAt(frame, 13, offset);
|
|
70
|
-
if (flags === undefined || (flags & 0x02) === 0 || yearLow === undefined || yearHigh === undefined || month === undefined || day === undefined || hour === undefined || minute === undefined || second === undefined) {
|
|
71
|
-
return undefined;
|
|
72
|
-
}
|
|
73
|
-
const year = yearLow | yearHigh << 8;
|
|
74
|
-
const recordedAt = new Date(year, month - 1, day, hour, minute, second);
|
|
75
|
-
return recordedAt.getFullYear() === year && recordedAt.getMonth() === month - 1 && recordedAt.getDate() === day && recordedAt.getHours() === hour && recordedAt.getMinutes() === minute && recordedAt.getSeconds() === second ? recordedAt : undefined;
|
|
72
|
+
return flags !== undefined && (flags & 0x02) !== 0 ? dateTimeAt(frame, 7, offset) : undefined;
|
|
76
73
|
};
|
|
77
74
|
const decorateBloodPressureReading = (reading, frame, recordOffset) => {
|
|
78
75
|
if (!frame) {
|
|
@@ -99,8 +96,9 @@ const decorateBloodPressureReading = (reading, frame, recordOffset) => {
|
|
|
99
96
|
} : {};
|
|
100
97
|
if ((flags & 0x08) !== 0) {
|
|
101
98
|
const userId = byteAt(frame, cursor, offset);
|
|
102
|
-
|
|
103
|
-
|
|
99
|
+
const memorySlot = userId === undefined ? undefined : memorySlotForDeviceUser(userId);
|
|
100
|
+
if (memorySlot !== undefined) {
|
|
101
|
+
metadata.memorySlot = memorySlot;
|
|
104
102
|
}
|
|
105
103
|
cursor += 1;
|
|
106
104
|
}
|
package/lib/module/modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BloodPressureStates","sigUuid","defineCustomDevice","bloodPressureStatusFromFrame","SPOT_CHECK_TIMEOUT_MS","declareProfile","params","profile","id","measurementTypeKey","nameMatch","matchByService","undefined","oneReadingPerConnection","stuckDataTimeoutMs","services","uuid","service","monitor","characteristic","
|
|
1
|
+
{"version":3,"names":["BloodPressureStates","memorySlotForDeviceUser","sigUuid","defineCustomDevice","bloodPressureStatusFromFrame","byteAt","dateTimeAt","SPOT_CHECK_TIMEOUT_MS","chainDecorators","first","second","reading","frame","recordOffset","decorated","declareProfile","params","profile","id","measurementTypeKey","nameMatch","matchByService","undefined","oneReadingPerConnection","stuckDataTimeoutMs","services","uuid","service","monitor","characteristic","minLengthBytes","caseSelectorBytes","cases","selectors","map","selector","optional","optionalFields","fields","fieldsBySelector","kind","decorateReading","littleEndian","name","byteIndexes","unit","encoding","byteOrder","recordedAtFromBloodPressureFrame","offset","flags","decorateBloodPressureReading","recordedAt","cursor","metadata","userId","memorySlot","status","DISTURB_DETECTED","LOOSE_SLEEVE","REGULAR","irregularHeartbeat","Object","keys","length"],"sourceRoot":"../../../../../../../src","sources":["modules/bt-management/services/devices/standard-gatt/standard-gatt.profile.ts"],"mappings":";;AAEA,SAASA,mBAAmB,QAAQ,yCAAsC;AAM1E,SAASC,uBAAuB,QAAQ,+BAA4B;AACpE,SAASC,OAAO,QAAQ,4BAAyB;AACjD,SAASC,kBAAkB,QAAQ,sCAAmC;AAEtE,SAASC,4BAA4B,QAAQ,0CAAuC;AACpF,SAASC,MAAM,EAAEC,UAAU,QAAQ,0BAAuB;;AAE1D;AACA,MAAMC,qBAAqB,GAAG,MAAM;AAqDpC;AACA,MAAMC,eAAe,GAAGA,CACtBC,KAAyC,EACzCC,MAA0C,KACH;EACvC,IAAI,CAACD,KAAK,IAAI,CAACC,MAAM,EAAE;IACrB,OAAOD,KAAK,IAAIC,MAAM;EACxB;EAEA,OAAO,CAACC,OAAO,EAAEC,KAAK,EAAEC,YAAY,KAAK;IACvC,MAAMC,SAAS,GAAGL,KAAK,CAACE,OAAO,EAAEC,KAAK,EAAEC,YAAY,CAAC;IAErD,OAAOC,SAAS,IAAIJ,MAAM,CAACI,SAAS,EAAEF,KAAK,EAAEC,YAAY,CAAC;EAC5D,CAAC;AACH,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;AACA,MAAME,cAAc,GAAGA,CACrBC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
+
import { toBluetoothError } from "../types/bluetooth-error.js";
|
|
5
|
+
const parseCursor = stored => {
|
|
6
|
+
const parsed = Number.parseInt(stored ?? "", 10);
|
|
7
|
+
return Number.isSafeInteger(parsed) && parsed >= 0 ? parsed : undefined;
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* The number of the newest stored record read from one device, kept in `storage` so the next
|
|
12
|
+
* connection asks the device for newer records only. Without storage it forgets on disconnect.
|
|
13
|
+
*/
|
|
14
|
+
class RecordCursor {
|
|
15
|
+
writing = false;
|
|
16
|
+
changedWhileWriting = false;
|
|
17
|
+
constructor(storage, key) {
|
|
18
|
+
this.storage = storage;
|
|
19
|
+
this.key = key;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/** What an earlier connection stored; nothing, an unreadable value or a failing store gives `undefined`. */
|
|
23
|
+
load = async () => {
|
|
24
|
+
try {
|
|
25
|
+
this.newest = parseCursor(await this.storage?.getItem(this.key));
|
|
26
|
+
} catch (error) {
|
|
27
|
+
sentryLogger("error", "RECORD_CURSOR: Could not read the stored cursor", {
|
|
28
|
+
errorCode: toBluetoothError(error).code
|
|
29
|
+
});
|
|
30
|
+
this.newest = undefined;
|
|
31
|
+
}
|
|
32
|
+
return this.newest;
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
/** Remembers a record number that is newer than any seen; writes to the store are coalesced. */
|
|
36
|
+
advance = recordNumber => {
|
|
37
|
+
if (this.newest !== undefined && recordNumber <= this.newest) {
|
|
38
|
+
return;
|
|
39
|
+
}
|
|
40
|
+
this.newest = recordNumber;
|
|
41
|
+
void this.persist();
|
|
42
|
+
};
|
|
43
|
+
persist = async () => {
|
|
44
|
+
if (this.writing) {
|
|
45
|
+
this.changedWhileWriting = true;
|
|
46
|
+
return;
|
|
47
|
+
}
|
|
48
|
+
this.writing = true;
|
|
49
|
+
do {
|
|
50
|
+
this.changedWhileWriting = false;
|
|
51
|
+
await this.store();
|
|
52
|
+
} while (this.changedWhileWriting);
|
|
53
|
+
this.writing = false;
|
|
54
|
+
};
|
|
55
|
+
store = async () => {
|
|
56
|
+
try {
|
|
57
|
+
await this.storage?.setItem(this.key, String(this.newest));
|
|
58
|
+
} catch (error) {
|
|
59
|
+
sentryLogger("error", "RECORD_CURSOR: Could not store the cursor", {
|
|
60
|
+
errorCode: toBluetoothError(error).code
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
export { RecordCursor };
|
|
66
|
+
//# sourceMappingURL=record-cursor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["sentryLogger","toBluetoothError","parseCursor","stored","parsed","Number","parseInt","isSafeInteger","undefined","RecordCursor","writing","changedWhileWriting","constructor","storage","key","load","newest","getItem","error","errorCode","code","advance","recordNumber","persist","store","setItem","String"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/services/record-cursor.ts"],"mappings":";;AAAA,SAASA,YAAY,QAAQ,sCAAmC;AAEhE,SAASC,gBAAgB,QAAQ,6BAA0B;AAE3D,MAAMC,WAAW,GAAIC,MAAiC,IAAyB;EAC7E,MAAMC,MAAM,GAAGC,MAAM,CAACC,QAAQ,CAACH,MAAM,IAAI,EAAE,EAAE,EAAE,CAAC;EAEhD,OAAOE,MAAM,CAACE,aAAa,CAACH,MAAM,CAAC,IAAIA,MAAM,IAAI,CAAC,GAAGA,MAAM,GAAGI,SAAS;AACzE,CAAC;;AAED;AACA;AACA;AACA;AACA,MAAMC,YAAY,CAAC;EAETC,OAAO,GAAG,KAAK;EACfC,mBAAmB,GAAG,KAAK;EAE5BC,WAAWA,CACCC,OAA0C,EAC1CC,GAAW,EAC5B;IAAA,KAFiBD,OAA0C,GAA1CA,OAA0C;IAAA,KAC1CC,GAAW,GAAXA,GAAW;EAC3B;;EAEH;EACOC,IAAI,GAAG,MAAAA,CAAA,KAAyC;IACrD,IAAI;MACF,IAAI,CAACC,MAAM,GAAGd,WAAW,CAAC,MAAM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H;AAEA,SAASX,YAAY","ignoreList":[]}
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
/* eslint-disable import/group-exports */
|
|
4
4
|
|
|
5
|
+
import { Buffer } from "buffer";
|
|
5
6
|
import { State } from "react-native-ble-plx";
|
|
6
7
|
|
|
7
8
|
/** Options for `createFakeBleDevice`. */
|
|
@@ -13,6 +14,8 @@ import { State } from "react-native-ble-plx";
|
|
|
13
14
|
/** A deterministic BLE manager for hook and scan integration tests. No hardware is used. */
|
|
14
15
|
|
|
15
16
|
const characteristicKey = (serviceUuid, characteristicUuid) => `${serviceUuid}/${characteristicUuid}`;
|
|
17
|
+
const NOTIFICATIONS_ENABLED = Buffer.from([0x01, 0x00]).toString("base64");
|
|
18
|
+
const NOTIFICATIONS_DISABLED = Buffer.from([0x00, 0x00]).toString("base64");
|
|
16
19
|
|
|
17
20
|
/** Creates a GATT-capable fake device for connection and notification tests. */
|
|
18
21
|
export const createFakeBleDevice = ({
|
|
@@ -27,6 +30,7 @@ export const createFakeBleDevice = ({
|
|
|
27
30
|
let connected = false;
|
|
28
31
|
let currentMtu = mtu;
|
|
29
32
|
const values = new Map(Object.entries(characteristics));
|
|
33
|
+
const monitoredKeys = new Set();
|
|
30
34
|
const disconnectedCallbacks = new Set();
|
|
31
35
|
const notificationCallbacks = new Map();
|
|
32
36
|
const fake = {
|
|
@@ -62,8 +66,12 @@ export const createFakeBleDevice = ({
|
|
|
62
66
|
readCharacteristicForService: async (serviceUuid, characteristicUuid) => ({
|
|
63
67
|
value: values.get(characteristicKey(serviceUuid, characteristicUuid)) ?? null
|
|
64
68
|
}),
|
|
69
|
+
readDescriptorForService: async (serviceUuid, characteristicUuid) => ({
|
|
70
|
+
value: monitoredKeys.has(characteristicKey(serviceUuid, characteristicUuid)) ? NOTIFICATIONS_ENABLED : NOTIFICATIONS_DISABLED
|
|
71
|
+
}),
|
|
65
72
|
monitorCharacteristicForService: (serviceUuid, characteristicUuid, callback) => {
|
|
66
73
|
const key = characteristicKey(serviceUuid, characteristicUuid);
|
|
74
|
+
monitoredKeys.add(key);
|
|
67
75
|
const callbacks = notificationCallbacks.get(key) ?? new Set();
|
|
68
76
|
callbacks.add(callback);
|
|
69
77
|
notificationCallbacks.set(key, callbacks);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["State","characteristicKey","serviceUuid","characteristicUuid","createFakeBleDevice","id","name","localName","manufacturerData","serviceUUIDs","mtu","characteristics","connected","currentMtu","values","Map","Object","entries","
|
|
1
|
+
{"version":3,"names":["Buffer","State","characteristicKey","serviceUuid","characteristicUuid","NOTIFICATIONS_ENABLED","from","toString","NOTIFICATIONS_DISABLED","createFakeBleDevice","id","name","localName","manufacturerData","serviceUUIDs","mtu","characteristics","connected","currentMtu","values","Map","Object","entries","monitoredKeys","Set","disconnectedCallbacks","notificationCallbacks","fake","isConnected","connect","cancelConnection","forEach","callback","discoverAllServicesAndCharacteristics","onDisconnected","add","remove","delete","requestMTU","requestedMtu","readCharacteristicForService","value","get","readDescriptorForService","has","monitorCharacteristicForService","key","callbacks","set","writeCharacteristicWithResponseForService","writeCharacteristicWithoutResponseForService","device","emitCharacteristic","characteristic","uuid","disconnect","createFakeBleManager","state","PoweredOn","devices","currentState","scanCallback","stateCallbacks","scannedServiceUUIDs","manager","onStateChange","emitCurrentState","startDeviceScan","_options","stopDeviceScan","undefined","createDevice","emitDevice","emitError","error","setState","nextState","getScannedServiceUUIDs"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/testing/fake-ble-manager.ts"],"mappings":";;AAAA;;AAEA,SAASA,MAAM,QAAQ,QAAQ;AAE/B,SAA6BC,KAAK,QAAsB,sBAAsB;;AAE9E;;AAyBA;;AAiBA;;AAUA;;AAyBA,MAAMC,iBAAiB,GAAGA,CAACC,WAAmB,EAAEC,kBAA0B,KACxE,GAAGD,WAAW,IAAIC,kBAAkB,EAAE;AAExC,MAAMC,qBAAqB,GAAGL,MAAM,CAACM,IAAI,CAAC,CAA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AACL,QAAQ;MAC9C,CAAC;IACH,CAAC;IACDmC,eAAe,EAAEA,CACfrD,YAAsC,EACtCsD,QAAiB,EACjBpC,QAAsD,KACnD;MACH+B,mBAAmB,GAAGjD,YAAY;MAClC+C,YAAY,GAAG7B,QAAQ;MACvB2B,OAAO,CAAC5B,OAAO,CAAEoB,MAAM,IAAKnB,QAAQ,CAAC,IAAI,EAAEmB,MAAM,CAAC,CAAC;IACrD,CAAC;IACDkB,cAAc,EAAEA,CAAA,KAAM;MACpBR,YAAY,GAAGS,SAAS;IAC1B;EACF,CAA0B;EAE1B,OAAO;IACLN,OAAO;IACPO,YAAY,EAAE9D,mBAAmB;IACjC+D,UAAU,EAAGrB,MAAM,IAAKU,YAAY,GAAG,IAAI,EAAEV,MAAM,CAAC;IACpDsB,SAAS,EAAGC,KAAK,IACfb,YAAY,GAAGa,KAAK,EAAW,IAAI,CAAC;IACtCC,QAAQ,EAAGC,SAAS,IAAK;MACvBhB,YAAY,GAAGgB,SAAS;MACxBd,cAAc,CAAC/B,OAAO,CAAEC,QAAQ,IAAKA,QAAQ,CAAC4C,SAAS,CAAC,CAAC;IAC3D,CAAC;IACDC,sBAAsB,EAAEA,CAAA,KAAMd,mBAAmB;IACjDM,cAAc,EAAEA,CAAA,KAAML,OAAO,CAACK,cAAc,CAAC;EAC/C,CAAC;AACH,CAAC","ignoreList":[]}
|
|
@@ -8,6 +8,10 @@ import { CUSTOM_DEVICE_BRAND } from "../constants/custom-device-brand.js";
|
|
|
8
8
|
|
|
9
9
|
/** Creates the per-device `CustomFrameHandler`. */
|
|
10
10
|
|
|
11
|
+
/** What a declaration's command sequencer is told about the device it is about to drive. */
|
|
12
|
+
|
|
13
|
+
/** Creates the command sequencer of one connection, for a declaration whose commands depend on the device or on stored state. */
|
|
14
|
+
|
|
11
15
|
/**
|
|
12
16
|
* A validated, ready-to-run custom device. Only defineCustomDevice produces one.
|
|
13
17
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["CUSTOM_DEVICE_BRAND"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/types/custom-device-definition.ts"],"mappings":";;AAEA,SAASA,mBAAmB,QAAQ,qCAAkC;;
|
|
1
|
+
{"version":3,"names":["CUSTOM_DEVICE_BRAND"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/types/custom-device-definition.ts"],"mappings":";;AAEA,SAASA,mBAAmB,QAAQ,qCAAkC;;AAiBtE;;AAeA;;AAGA;;AAGA;;AAUA;;AAGA;AACA;AACA","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../../../src","sources":["modules/bt-management/types/glucose-record-details.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { Platform } from "react-native";
|
|
4
|
+
import { PERMISSIONS } from "react-native-permissions";
|
|
5
|
+
const ANDROID_12_API_LEVEL = 31;
|
|
6
|
+
|
|
7
|
+
/** The OS permissions Bluetooth scanning and connecting need on this platform. */
|
|
8
|
+
export const bluetoothPermissionList = () => {
|
|
9
|
+
if (Platform.OS === "android") {
|
|
10
|
+
return Number(Platform.Version) >= ANDROID_12_API_LEVEL ? [PERMISSIONS.ANDROID.BLUETOOTH_CONNECT, PERMISSIONS.ANDROID.BLUETOOTH_SCAN] : [PERMISSIONS.ANDROID.ACCESS_FINE_LOCATION];
|
|
11
|
+
}
|
|
12
|
+
return Platform.OS === "ios" ? [PERMISSIONS.IOS.BLUETOOTH] : [];
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=bluetooth-permission-list.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["Platform","PERMISSIONS","ANDROID_12_API_LEVEL","bluetoothPermissionList","OS","Number","Version","ANDROID","BLUETOOTH_CONNECT","BLUETOOTH_SCAN","ACCESS_FINE_LOCATION","IOS","BLUETOOTH"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/utils/bluetooth-permission-list.ts"],"mappings":";;AAAA,SAASA,QAAQ,QAAQ,cAAc;AACvC,SAAqBC,WAAW,QAAQ,0BAA0B;AAElE,MAAMC,oBAAoB,GAAG,EAAE;;AAE/B;AACA,OAAO,MAAMC,uBAAuB,GAAGA,CAAA,KAAoB;EACzD,IAAIH,QAAQ,CAACI,EAAE,KAAK,SAAS,EAAE;IAC7B,OAAOC,MAAM,CAACL,QAAQ,CAACM,OAAO,CAAC,IAAIJ,oBAAoB,GACnD,CAACD,WAAW,CAACM,OAAO,CAACC,iBAAiB,EAAEP,WAAW,CAACM,OAAO,CAACE,cAAc,CAAC,GAC3E,CAACR,WAAW,CAACM,OAAO,CAACG,oBAAoB,CAAC;EAChD;EAEA,OAAOV,QAAQ,CAACI,EAAE,KAAK,KAAK,GAAG,CAACH,WAAW,CAACU,GAAG,CAACC,SAAS,CAAC,GAAG,EAAE;AACjE,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
/** The Bluetooth SIG User Index that means the device does not know whose reading it is. */
|
|
4
|
+
const UNKNOWN_DEVICE_USER = 0xff;
|
|
5
|
+
|
|
6
|
+
/** The memory slot of a SIG device user: users count from 0, slots from 1; the unknown user has none. */
|
|
7
|
+
const memorySlotForDeviceUser = userId => userId === UNKNOWN_DEVICE_USER ? undefined : userId + 1;
|
|
8
|
+
|
|
9
|
+
/** Whether a reading is from one of the device users `slots`; a reading that names no device user is kept. */
|
|
10
|
+
const isFromAcceptedMemorySlot = (reading, slots) => {
|
|
11
|
+
const {
|
|
12
|
+
memorySlot
|
|
13
|
+
} = reading;
|
|
14
|
+
return typeof memorySlot !== "number" || slots.includes(memorySlot);
|
|
15
|
+
};
|
|
16
|
+
export { isFromAcceptedMemorySlot, memorySlotForDeviceUser };
|
|
17
|
+
//# sourceMappingURL=device-user.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["UNKNOWN_DEVICE_USER","memorySlotForDeviceUser","userId","undefined","isFromAcceptedMemorySlot","reading","slots","memorySlot","includes"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/utils/device-user.ts"],"mappings":";;AAAA;AACA,MAAMA,mBAAmB,GAAG,IAAI;;AAEhC;AACA,MAAMC,uBAAuB,GAAIC,MAAc,IAC7CA,MAAM,KAAKF,mBAAmB,GAAGG,SAAS,GAAGD,MAAM,GAAG,CAAC;;AAEzD;AACA,MAAME,wBAAwB,GAAGA,CAC/BC,OAAe,EACfC,KAAwB,KACZ;EACZ,MAAM;IAAEC;EAAW,CAAC,GAAGF,OAAmC;EAE1D,OAAO,OAAOE,UAAU,KAAK,QAAQ,IAAID,KAAK,CAACE,QAAQ,CAACD,UAAU,CAAC;AACrE,CAAC;AAED,SAASH,wBAAwB,EAAEH,uBAAuB","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["KPA_TO_MMHG"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/utils/kpa-to-mmhg.ts"],"mappings":";;AAAA;AACA,MAAMA,WAAW,GAAG,OAAO;AAE3B,SAASA,WAAW","ignoreList":[]}
|
|
@@ -2,42 +2,32 @@
|
|
|
2
2
|
|
|
3
3
|
/* eslint-disable import/group-exports */
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}
|
|
12
|
-
if (value && typeof value === "object") {
|
|
13
|
-
return Object.fromEntries(Object.entries(value).sort(([left], [right]) => left.localeCompare(right)).map(([key, nested]) => [key, canonicalize(nested)]));
|
|
14
|
-
}
|
|
15
|
-
return value;
|
|
16
|
-
};
|
|
17
|
-
const hash = value => {
|
|
18
|
-
let first = 0x811c9dc5;
|
|
19
|
-
let second = 0x01000193;
|
|
20
|
-
for (let index = 0; index < value.length; index += 1) {
|
|
21
|
-
const code = value.charCodeAt(index);
|
|
22
|
-
first = Math.imul(first ^ code, 0x01000193);
|
|
23
|
-
second = Math.imul(second ^ code + index, 0x811c9dc5);
|
|
24
|
-
}
|
|
25
|
-
return `${(first >>> 0).toString(16).padStart(8, "0")}${(second >>> 0).toString(16).padStart(8, "0")}`;
|
|
26
|
-
};
|
|
5
|
+
import { isTimestamped } from "../../next/bluetooth/driver.js";
|
|
6
|
+
import { instantStableHash, stableHash } from "../../next/bluetooth/stable-hash.js";
|
|
7
|
+
/** Reading properties added after result ids were first issued; leaving them out keeps every earlier id. */
|
|
8
|
+
const ADDED_READING_PROPERTIES = new Set(["sequenceNumber", "specimen", "sampleLocation", "sensorStatus", "outOfRange", "meal", "reportedUnit", "temperatureType", "rrIntervals"]);
|
|
9
|
+
const identifyingData = data => Object.fromEntries(Object.entries(data).filter(([key]) => !ADDED_READING_PROPERTIES.has(key)));
|
|
10
|
+
const deviceIdentityOf = deviceData => deviceData.sn || deviceData.manufacturerData || deviceData.model || deviceData.name || deviceData.id;
|
|
27
11
|
|
|
28
12
|
/**
|
|
29
|
-
* Creates an identity that is stable when a device sends its stored history again.
|
|
30
|
-
*
|
|
31
|
-
* delivery metadata is deliberately not part of the key.
|
|
13
|
+
* Creates an identity that is stable when a device sends its stored history again, in any time zone. A reading
|
|
14
|
+
* without a time of its own is a new measurement each time, so it is told apart by when it arrived.
|
|
32
15
|
*/
|
|
33
|
-
export const createStableResultId = (deviceData, data) => {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
})
|
|
40
|
-
}
|
|
16
|
+
export const createStableResultId = (deviceData, data, receivedAt = new Date()) => `ovok:${stableHash({
|
|
17
|
+
device: deviceIdentityOf(deviceData),
|
|
18
|
+
name: deviceData.name,
|
|
19
|
+
data: identifyingData(data),
|
|
20
|
+
...(isTimestamped(data) ? {} : {
|
|
21
|
+
receivedAt: receivedAt.toISOString()
|
|
22
|
+
})
|
|
23
|
+
})}`;
|
|
24
|
+
|
|
25
|
+
/** The id SDKs before 1.16.1 gave the same reading, to find what they saved. */
|
|
26
|
+
export const createLegacyResultId = (deviceData, data) => `ovok:${instantStableHash({
|
|
27
|
+
device: deviceIdentityOf(deviceData),
|
|
28
|
+
name: deviceData.name,
|
|
29
|
+
data: identifyingData(data)
|
|
30
|
+
})}`;
|
|
41
31
|
|
|
42
32
|
/** Converts the ISO date strings of `recordedAt`, `start` and `end` fields back to `Date`s, recursively. */
|
|
43
33
|
export const reviveResultDates = value => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["isTimestamped","instantStableHash","stableHash","ADDED_READING_PROPERTIES","Set","identifyingData","data","Object","fromEntries","entries","filter","key","has","deviceIdentityOf","deviceData","sn","manufacturerData","model","name","id","createStableResultId","receivedAt","Date","device","toISOString","createLegacyResultId","reviveResultDates","value","revive","current","includes","date","Number","isNaN","getTime","Array","isArray","map","item","childKey","childValue"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/utils/result-identity.ts"],"mappings":";;AAAA;;AAIA,SAASA,aAAa,QAAQ,gCAA6B;AAC3D,SAASC,iBAAiB,EAAEC,UAAU,QAAQ,qCAAkC;AAGhF;AACA,MAAMC,wBAAwB,GAAG,IAAIC,GAAG,CAAC,CACvC,gBAAgB,EAChB,UAAU,EACV,gBAAgB,EAChB,cAAc,EACd,YAAY,EACZ,MAAM,EACN,cAAc,EACd,iBAAiB,EACjB,aAAa,CACd,CAAC;AAEF,MAAMC,eAAe,GAAIC,IAAiB,IACxCC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAACH,IAAI,CAAC,CAACI,MAAM,CAAC,CAAC,CAACC,GAAG,CAAC,KAAK,CAACR,wBAAwB,CAACS,GAAG,CAACD,GAAG,CAAC,CAAC,CAAC;AAEhG,MAAME,gBAAgB,GAAIC,UAAsB,IAC9CA,UAAU,CAACC,EAAE,IACbD,UAAU,CAACE,gBAAgB,IAC3BF,UAAU,CAACG,KAAK,I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AAG,CAAEC,IAAI,IAAKV,MAAM,CAACU,IAAI,CAAC,CAAC;IAC5C;IAEA,IAAIT,OAAO,IAAI,OAAOA,OAAO,KAAK,QAAQ,EAAE;MAC1C,OAAOtB,MAAM,CAACC,WAAW,CACvBD,MAAM,CAACE,OAAO,CAACoB,OAAO,CAAC,CAACQ,GAAG,CAAC,CAAC,CAACE,QAAQ,EAAEC,UAAU,CAAC,KAAK,CACtDD,QAAQ,EACRX,MAAM,CAACY,UAAU,EAAED,QAAQ,CAAC,CAC7B,CACH,CAAC;IACH;IAEA,OAAOV,OAAO;EAChB,CAAC;EAED,OAAOD,MAAM,CAACD,KAAK,CAAC;AACtB,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
const MILLISECONDS_PER_SECOND = 1000;
|
|
4
|
+
|
|
5
|
+
/** The Bluetooth SIG heart-rate RR-Interval resolution: counts of 1/1024 s. */
|
|
6
|
+
const RR_COUNTS_PER_SECOND = 1024;
|
|
7
|
+
const RR_DECIMALS = 2;
|
|
8
|
+
|
|
9
|
+
/** An RR-Interval count from a Heart Rate Measurement, in milliseconds. */
|
|
10
|
+
const rrIntervalMilliseconds = counts => Number((counts * MILLISECONDS_PER_SECOND / RR_COUNTS_PER_SECOND).toFixed(RR_DECIMALS));
|
|
11
|
+
export { rrIntervalMilliseconds };
|
|
12
|
+
//# sourceMappingURL=rr-interval.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["MILLISECONDS_PER_SECOND","RR_COUNTS_PER_SECOND","RR_DECIMALS","rrIntervalMilliseconds","counts","Number","toFixed"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/utils/rr-interval.ts"],"mappings":";;AAAA,MAAMA,uBAAuB,GAAG,IAAI;;AAEpC;AACA,MAAMC,oBAAoB,GAAG,IAAI;AAEjC,MAAMC,WAAW,GAAG,CAAC;;AAErB;AACA,MAAMC,sBAAsB,GAAIC,MAAc,IAC5CC,MAAM,CACJ,CAAED,MAAM,GAAGJ,uBAAuB,GAAIC,oBAAoB,EAAEK,OAAO,CACjEJ,WACF,CACF,CAAC;AAEH,SAASC,sBAAsB","ignoreList":[]}
|