React-native-ble-plx: Get list of connected / known BLE devices

Created on 21 Nov 2016  路  7Comments  路  Source: Polidea/react-native-ble-plx

Can I get the connected Bluetooth device informations without any parameters ,and the device is connected manually in system setting.

easy enhancement

Most helpful comment

Hi, @Cierpliwy !

Is it possible to interact with paired (via OS, only android interesting for me) device through the package?

async devices(deviceIdentifiers: Array<DeviceId>): Promise<Array<Device>>

and other your example get required argument, but I don't know of devics UUID or something else...

Looks like I should know information about device earlier then use this package

All 7 comments

If you mean normal Bluetooth devices I think it is currently impossible to do.

@Cierpliwy what about a BLE device that is paired within the system bluetooth settings? Possibly attain a list of paired devices?

Thanks for the great library.

There is possibility to add functions:

  • function knownDevices(): Promise<Array<Device>>
  • function connectedDevices(): Promise<Array<Device>>

There are native counterparts on iOS side. On Android we could use internal caches for that purpose.

async devices(deviceIdentifiers: Array<DeviceId>): Promise<Array<Device>> 

and

async connectedDevices(serviceUUIDs: Array<UUID>): Promise<Array<Device>>

were added in version 0.9

Hi,

Error: knownDevices is not a function.

Are you sure this is the best?
Can you write an example?

Thank you,
bhenav

Hi, @Cierpliwy !

Is it possible to interact with paired (via OS, only android interesting for me) device through the package?

async devices(deviceIdentifiers: Array<DeviceId>): Promise<Array<Device>>

and other your example get required argument, but I don't know of devics UUID or something else...

Looks like I should know information about device earlier then use this package

i also would like to interact with paired device (connected via Bluetooth System Settings).
is this possible with this package?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

alfacommunication-alessandro picture alfacommunication-alessandro  路  4Comments

BlackCod3 picture BlackCod3  路  3Comments

paddlefish picture paddlefish  路  4Comments

biks152207 picture biks152207  路  3Comments

brycejacobs picture brycejacobs  路  5Comments