[BT] Force Active Scan when same interval as as Passive Scan (#1654)
This commit is contained in:
1 parent
7df72f6983
commit
88fc5643e8
1 file changed
+1
-1
+1
-1
@@ -764,7 +764,7 @@ void BLEscan() {
|
|||||||
BLEScan* pBLEScan = BLEDevice::getScan();
|
BLEScan* pBLEScan = BLEDevice::getScan();
|
||||||
MyAdvertisedDeviceCallbacks myCallbacks;
|
MyAdvertisedDeviceCallbacks myCallbacks;
|
||||||
pBLEScan->setAdvertisedDeviceCallbacks(&myCallbacks);
|
pBLEScan->setAdvertisedDeviceCallbacks(&myCallbacks);
|
||||||
if (millis() > (timeBetweenActive + BTConfig.intervalActiveScan)) {
|
if (millis() > (timeBetweenActive + BTConfig.intervalActiveScan) || BTConfig.intervalActiveScan == BTConfig.BLEinterval) {
|
||||||
pBLEScan->setActiveScan(true);
|
pBLEScan->setActiveScan(true);
|
||||||
timeBetweenActive = millis();
|
timeBetweenActive = millis();
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in new issue
Block a user