mirror of
https://github.com/HASwitchPlate/openHASP.git
synced 2025-07-24 11:46:34 +00:00
Add Button
This commit is contained in:
parent
3dc9b89fd6
commit
af16164e41
@ -12,6 +12,8 @@
|
||||
#define HASP_USE_EEPROM 0
|
||||
#define HASP_USE_SDCARD 0
|
||||
|
||||
#define HASP_USE_BUTTON 1
|
||||
|
||||
#define HASP_USE_QRCODE 1
|
||||
#define HASP_USE_PNGDECODE 0
|
||||
|
||||
|
12
src/main.cpp
12
src/main.cpp
@ -39,6 +39,10 @@
|
||||
#include "hasp_mdns.h"
|
||||
#endif
|
||||
|
||||
#if HASP_USE_BUTTON
|
||||
#include "hasp_button.h"
|
||||
#endif
|
||||
|
||||
bool isConnected;
|
||||
|
||||
void setup()
|
||||
@ -83,6 +87,10 @@ void setup()
|
||||
httpSetup(settings[F("http")]);
|
||||
#endif
|
||||
|
||||
#if HASP_USE_BUTTON
|
||||
buttonSetup();
|
||||
#endif
|
||||
|
||||
// otaSetup(settings[F("ota")]);
|
||||
#endif
|
||||
}
|
||||
@ -123,6 +131,10 @@ void loop()
|
||||
mdnsLoop(isConnected);
|
||||
#endif
|
||||
|
||||
#if HASP_USE_BUTTON
|
||||
buttonLoop();
|
||||
#endif
|
||||
|
||||
// otaLoop(wifiIsConnected);
|
||||
#endif
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user