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>
| Parameter | Type | Details |
|---|---|---|
device | Device | — |
__1 | CreateDeviceParams<T> | — |
Returns: BTManagedDevice<T>.
Public members
| Member | Type | Details |
|---|---|---|
id | string | — |
deviceData | DeviceData | — |
onError | (error: BleError | Error | string) => void | Optional. — |
onDeviceStatusChanged | (status: DeviceStatus, measurementTypeKey?: MeasurementTypeKey) => void | Optional. — |
onResult | (data: MeasurementWithCaseType<MeasurementTypeForDevices<[ T ]>>) => void | Optional. — |
onDeviceDisconnected | () => void | Optional. — |
onConnectionEvent | (data: DeviceConnectionEvent) => void | Optional. — |
device | Device | — |
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.