interface NativeBluetoothLE {
    addListener: ((eventType) => void);
    removeListeners: ((count) => void);
    bleInitialize(): Promise<void>;
    bleShutdown(): Promise<void>;
    connectPeripheral(deviceSystemId, requiredServicesUuids, autoReconnect): Promise<void>;
    createPeripheral(deviceSystemId): Promise<Device>;
    disconnectPeripheral(deviceSystemId): Promise<void>;
    getCharacteristicProperties(deviceSystemId, serviceUuid, characteristicUuid, instanceIndex): Promise<number>;
    getDiscoveredServices(deviceSystemId): Promise<string>;
    getPeripheralAddress(deviceSystemId): Promise<number>;
    getPeripheralConnectionStatus(deviceSystemId): Promise<ConnectionStatus>;
    getPeripheralMtu(deviceSystemId): Promise<number>;
    getPeripheralName(deviceSystemId): Promise<string>;
    getServiceCharacteristics(deviceSystemId, serviceUuid): Promise<string>;
    readCharacteristic(deviceSystemId, serviceUuid, characteristicUuid, instanceIndex): Promise<number[]>;
    readPeripheralRssi(deviceSystemId): Promise<number>;
    releasePeripheral(deviceSystemId): Promise<void>;
    requestPeripheralMtu(deviceSystemId, mtu): Promise<number>;
    startScan(requiredServicesUuids?): Promise<void>;
    stopScan(): Promise<void>;
    subscribeCharacteristic(deviceSystemId, serviceUuid, characteristicUuid, instanceIndex): Promise<void>;
    unsubscribeCharacteristic(deviceSystemId, serviceUuid, characteristicUuid, instanceIndex): Promise<void>;
    writeCharacteristic(deviceSystemId, serviceUuid, characteristicUuid, instanceIndex, data, withoutResponse): Promise<void>;
}

Hierarchy

  • NativeModule
    • NativeBluetoothLE

Properties

addListener: ((eventType) => void)

Add the provided eventType as an active listener

Type declaration

    • (eventType): void
    • Add the provided eventType as an active listener

      Parameters

      • eventType: string

        name of the event for which we are registering listener

      Returns void

Param: eventType

name of the event for which we are registering listener

removeListeners: ((count) => void)

Remove a specified number of events. There are no eventTypes in this case, as the native side doesn't remove the name, but only manages a counter of total listeners

Type declaration

    • (count): void
    • Remove a specified number of events. There are no eventTypes in this case, as the native side doesn't remove the name, but only manages a counter of total listeners

      Parameters

      • count: number

        number of listeners to remove (of any type)

      Returns void

Param: count

number of listeners to remove (of any type)

Methods

  • Parameters

    • deviceSystemId: string
    • serviceUuid: string
    • characteristicUuid: string
    • instanceIndex: number

    Returns Promise<number>

  • Parameters

    • deviceSystemId: string
    • serviceUuid: string
    • characteristicUuid: string
    • instanceIndex: number

    Returns Promise<number[]>

  • Parameters

    • deviceSystemId: string
    • serviceUuid: string
    • characteristicUuid: string
    • instanceIndex: number

    Returns Promise<void>

  • Parameters

    • deviceSystemId: string
    • serviceUuid: string
    • characteristicUuid: string
    • instanceIndex: number

    Returns Promise<void>

  • Parameters

    • deviceSystemId: string
    • serviceUuid: string
    • characteristicUuid: string
    • instanceIndex: number
    • data: number[]
    • withoutResponse: boolean

    Returns Promise<void>

Generated using TypeDoc