Publish SYStoMQTT scan count (#896)

This commit is contained in:
Florian authored and GitHub committed 2021-03-14 15:05:09 -05:00
1 parent 8afb1c5223
commit 625f7f358b
3 files changed
+2 -2

No files matched your search

-2
View File
@@ -90,8 +90,6 @@ static bool oneWhite = false;
int minRssi = abs(MinimumRSSI); //minimum rssi value
unsigned int scanCount = 0;
void pubBTMainCore(JsonObject& data, bool haPresenceEnabled = true) {
if (abs((int)data["rssi"] | 0) < minRssi) {
String mac_address = data["id"].as<const char*>();
+1
View File
@@ -78,6 +78,7 @@ bool bleConnect = AttemptBLECOnnect;
unsigned int BLEinterval = TimeBtwRead; //time between 2 scans
unsigned int BLEscanBeforeConnect = ScanBeforeConnect; //Number of BLE scans between connection cycles
unsigned long scanCount = 0;
bool publishOnlySensors = PublishOnlySensors;
#ifndef pubKnownBLEServiceData
+1
View File
@@ -1358,6 +1358,7 @@ void stateMeasures() {
# endif
SYSdata["interval"] = BLEinterval;
SYSdata["scanbcnct"] = BLEscanBeforeConnect;
SYSdata["scnct"] = scanCount;
# endif
# ifdef ZboardM5STACK
M5.Power.begin();