clear a few warnings

This commit is contained in:
Martijn Scheepers
2021-06-07 10:39:28 +02:00
parent e01861e3f3
commit c9762995d9
6 changed files with 10 additions and 8 deletions

2
README Normal file
View File

@@ -0,0 +1,2 @@
Clear eeprom in platformIO
pio run -t erase

View File

@@ -1,7 +1,7 @@
#ifndef H1602_WSEN_GLOBAL_H #ifndef H1602_WSEN_GLOBAL_H
#define H1602_WSEN_GLOBAL_H #define H1602_WSEN_GLOBAL_H
//#define DEBUG_MSG #define DEBUG_MSG
#define INPUT_CHANNELS 5 #define INPUT_CHANNELS 5

View File

@@ -426,7 +426,7 @@ void WifiScanGet(AsyncWebServerRequest *request)
//Scan not triggered //Scan not triggered
WiFi.scanNetworks(true, showHidden); WiFi.scanNetworks(true, showHidden);
} }
else if (n) else
{ {
for (int i = 0; i < n; ++i) for (int i = 0; i < n; ++i)
{ {

View File

@@ -148,7 +148,7 @@ void checkEeprom()
yield(); yield();
if (writeCheck == true) if (writeCheck)
{ {
EEPROM.put(EEPROMSTRUCT_OFFSET, eepromStruct); EEPROM.put(EEPROMSTRUCT_OFFSET, eepromStruct);
EEPROM.commit(); EEPROM.commit();

View File

@@ -183,16 +183,16 @@ void setup()
{ {
pinMode(inputTable[i], INPUT_PULLUP); pinMode(inputTable[i], INPUT_PULLUP);
inputValue[i] = !digitalRead(inputTable[i]); inputValue[i] = !digitalRead(inputTable[i]);
if (getEeprom()->apMode == false) if (!getEeprom()->apMode)
{ {
if (getEeprom()->channel[i].enable == true) if (getEeprom()->channel[i].enable)
{ {
attachInputInterrupt(i); attachInputInterrupt(i);
} }
} }
} }
if (getEeprom()->apMode == true) if (getEeprom()->apMode)
{ {
accessPointMode(); accessPointMode();
} }

View File

@@ -21,7 +21,7 @@ void prtgServerUpdate()
for (int i = 1; i < INPUT_CHANNELS; i++) for (int i = 1; i < INPUT_CHANNELS; i++)
{ {
if (getEepromChannel(i)->enable == true) if (getEepromChannel(i)->enable)
{ {
request += F("<result><channel>"); request += F("<result><channel>");
request += getEepromChannel(i)->channel; request += getEepromChannel(i)->channel;
@@ -45,7 +45,7 @@ void prtgServerUpdate()
Serial.println(url); Serial.println(url);
#endif #endif
if (http.begin(httpClient, url) == false) if (!http.begin(httpClient, url))
{ {
#ifdef DEBUG_MSG #ifdef DEBUG_MSG
Serial.println(F("http.begin failed")); Serial.println(F("http.begin failed"));