Hierarchy

  • BluetoothCommon
    • Bluetooth

Constructors

  • restoreIdentifier is optional and only used on iOS

    Parameters

    • Optional restoreIndentifierOrOptions: string | Partial<BluetoothOptions>

    Returns Bluetooth

Properties

centralManager: any
enabled: boolean

Property to determine if bluetooth is enabled.

events: any
UUIDKey: string
android?: {
    CallbackType: typeof CallbackType;
    MatchMode: typeof MatchMode;
    MatchNum: typeof MatchNum;
    ScanMode: typeof ScanMode;
}

Type declaration

bluetooth_status_event: string
characteristicUUIDKey: string
device_connected_event: string
device_disconnected_event: string
device_discovered_event: string
msg_cant_open_settings: string
msg_characteristic_cant_notify: string
msg_error_function_call: string
msg_invalid_value: string
msg_missing_parameter: string
msg_no_characteristic: string
msg_no_peripheral: string
msg_no_service: string
msg_not_enabled: string
msg_not_supported: string
msg_peripheral_disconnected: string
msg_peripheral_not_connected: string
peripheralUUIDKey: string
serviceUUIDKey: string

Methods

  • everything needed to clear on app close

    Returns any

  • Returns any

  • Parameters

    Returns Promise<any>

  • Parameters

    Returns Promise<any>

  • Parameters

    Returns Promise<{
        characteristics: Characteristic[];
        services: Service[];
    }>

  • Parameters

    Returns Promise<{
        services: Service[];
    }>

  • Android only. Will return false if the user denied turning Bluetooth on.

    Returns Promise<boolean>

  • Android only. Will reject if the user denied turning GPS on.

    Returns Promise<void>

  • Returns any

  • Parameters

    Returns any

  • Required for Android 6+ to be able to scan for peripherals in the background.

    Returns Promise<boolean>

  • Returns Promise<boolean>

  • Parameters

    Returns Promise<boolean>

  • Android only. check if GPS is enabled.

    Returns Promise<boolean>

  • open device bluetooth settings

    Parameters

    • Optional url: string

    Returns any

  • Parameters

    • args: ReadRSSIOptions

    Returns Promise<number>

  • Required for Android 6+ to be able to scan for peripherals in the background.

    Returns Promise<any>

  • Parameters

    Returns Promise<number>

  • Notify events by name and optionally pass data

    Parameters

    • eventName: string
    • Optional data: any
    • Optional msg: string

    Returns void

  • Parameters

    Returns Promise<any>

  • Parameters

    Returns Promise<void>

  • Returns any

  • Parameters

    Returns Promise<any>

  • Returns Promise<any>

  • Parameters

    Returns Promise<any>

  • Parameters

    Returns Promise<any>

Generated using TypeDoc