Skip to main content

BTManagedDevice

No behavioral description is attached to this declaration. The public signature, parameter and return types, and source location below document its published contract.

Kind: Class
Package: @ovok/native

Import​

import { BTManagedDevice } from '@ovok/native/bt-management';

TypeScript signatures​

<T extends DeviceKey = IntegratedDevices.BP2>(device: Device, { deviceName, onError: onErrorCallback, onDeviceStatusChanged: onDeviceStatusChangedCallback, onResult: onResultCallback, onConnectionEvent: onConnectionEventCallback, onDeviceDisconnected: onDeviceDisconnectedCallback, oneReadingPerConnection, resultPolicy, }: CreateDeviceParams<T>): BTManagedDevice<T>
ParameterTypeDetails
deviceDevice—
__1CreateDeviceParams<T>—

Returns: BTManagedDevice<T>.

Public members​

MemberTypeDetails
idstring—
deviceDataDeviceData—
onError(error: BleError | Error | string) => voidOptional. —
onDeviceStatusChanged(status: DeviceStatus, measurementTypeKey?: MeasurementTypeKey) => voidOptional. —
onResult(data: MeasurementWithCaseType<MeasurementTypeForDevices<[ T ]>>) => voidOptional. —
onDeviceDisconnected() => voidOptional. —
onConnectionEvent(data: DeviceConnectionEvent) => voidOptional. —
deviceDevice—
destroy(): void—
disconnect(): Promise<void>Stops this device's subscriptions and closes its BLE connection.
connect(): Promise<void>—

Learn the workflow​

Continue with Bluetooth for the workflow context and examples.

Source​

View the declaration in the SDK source.