This commit is contained in:
Dmitry Borisenko
2020-10-04 23:54:41 +03:00
parent 1e4206f31d
commit 19bc027083
3 changed files with 6 additions and 3 deletions

View File

@@ -43,7 +43,7 @@
}, },
{ {
"type": "h4", "type": "h4",
"title": "LittleFS version: 248" "title": "LittleFS version: 249"
}, },
{ {
"type": "hr" "type": "hr"

View File

@@ -2,7 +2,7 @@
//=================Firmeare================= //=================Firmeare=================
#define FIRMWARE_NAME "esp8266-iotm" #define FIRMWARE_NAME "esp8266-iotm"
#define FIRMWARE_VERSION 248 #define FIRMWARE_VERSION 249
#define FLASH_4MB true #define FLASH_4MB true
//=================System=================== //=================System===================

View File

@@ -28,10 +28,13 @@ class ButtonInClass : public LineParsing {
buttons[switch_number].update(); buttons[switch_number].update();
if (buttons[switch_number].fell()) { if (buttons[switch_number].fell()) {
String key = jsonReadStr(configOptionJson, "switch_num_" + String(switch_number)); String key = jsonReadStr(configOptionJson, "switch_num_" + String(switch_number));
state = !state; state = 0;
switchChangeVirtual(key, String(state)); switchChangeVirtual(key, String(state));
} }
if (buttons[switch_number].rose()) { if (buttons[switch_number].rose()) {
String key = jsonReadStr(configOptionJson, "switch_num_" + String(switch_number));
state = 1;
switchChangeVirtual(key, String(state));
} }
} }
switch_number++; switch_number++;