Methods
(async) discover(serviceFilteropt, timeoutopt) → {Array.<BleAdvertisement>}
Discovers BLE peripherals for a certain time
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
serviceFilter |
Array.<string>
|
<optional> |
List of required serviceUuids the peripheral should expose |
|
timeout |
number
|
<optional> |
10000 |
Time in ms to search for Ble peripherals (max 30 seconds) |
Returns:
- Type:
-
Array.<BleAdvertisement>
(async) find(peripheralUuid, timeoutopt) → {BleAdvertisement}
Finds a Ble peripheral with a given peripheralUuid
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
peripheralUuid |
string
|
The uuid of the peripheral to find |
||
timeout |
number
|
<optional> |
10000 |
Time in ms to search for the Ble peripheral (max 30 seconds) |
Returns:
- Type:
-
BleAdvertisement