Bluetooth LE (BLE)
BleScanParams
The BleScanParams structure specifies the settings for scanning on a central device.
// PROTOTYPE
uint16_t version;
uint16_t size;
uint16_t interval;
uint16_t window;
uint16_t timeout; uint8_t active;
uint8_t filter_policy;
// EXAMPLE
BleScanParams scanParams;
scanParams.version = BLE_API_VERSION;
scanParams.size = sizeof(BleScanParams);
int res = BLE.getScanParameters(&scanParams);
version
Always set toBLE_API_VERSION
.size
Always set tosizeof(BleScanParams)
.interval
Advertising interval in 0.625 ms units. Default is 160.window
Scanning window in 0.625 ms units. Default is 80.timeout
Scan timeout in 10 ms units. Default value is 500.active
Boolean value, typically 1.filter_policy
Default is 0.