[BLE] Add dynamic active scan runtime setting (#1360)
This commit add the capability to set passive scanning during runtime, versus buildtime before, so as to improve energy consumption of sensors when they don't require active scanning
This commit is contained in:
1 parent
807c668489
commit
8dde777fb7
4 files changed
+28
-1
No files matched your search
@@ -146,6 +146,7 @@ unsigned long scanCount = 0;
|
||||
/*----------------CONFIGURABLE PARAMETERS-----------------*/
|
||||
struct BTConfig_s {
|
||||
bool bleConnect; // Attempt a BLE connection to sensors with ESP32
|
||||
bool activeScan;
|
||||
unsigned int BLEinterval; // Time between 2 scans
|
||||
unsigned int BLEscanBeforeConnect; // Number of BLE scans between connection cycles
|
||||
bool pubOnlySensors; // Publish only the identified sensors (like temperature sensors)
|
||||
|
||||
Reference in new issue
Block a user