mirror of https://github.com/arendst/Tasmota.git
v5.9.1h - Add switchmode 7
5.9.1h * Patch library I2Cdevlib-Core for esp8266-core 2.4.0-rc2 * Add option PUSHBUTTON_TOGGLE (SwitchMode 7) to allow toggling on any switch change (#1221) * Fix DHT sensor timeout recognition by distinguish "signal already there" from "timeout" (#1233)
This commit is contained in:
parent
53b100fdeb
commit
869aa4d6fb
|
@ -1,7 +1,7 @@
|
|||
## Sonoff-Tasmota
|
||||
Provide ESP8266 based Sonoff by [iTead Studio](https://www.itead.cc/) and ElectroDragon IoT Relay with Serial, Web and MQTT control allowing 'Over the Air' or OTA firmware updates using Arduino IDE.
|
||||
|
||||
Current version is **5.9.1g** - See [sonoff/_releasenotes.ino](https://github.com/arendst/Sonoff-Tasmota/blob/development/sonoff/_releasenotes.ino) for change information.
|
||||
Current version is **5.9.1h** - See [sonoff/_releasenotes.ino](https://github.com/arendst/Sonoff-Tasmota/blob/development/sonoff/_releasenotes.ino) for change information.
|
||||
|
||||
### ATTENTION All versions
|
||||
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
/* 5.9.1g
|
||||
/* 5.9.1h
|
||||
* Patch library I2Cdevlib-Core for esp8266-core 2.4.0-rc2
|
||||
* Add option PUSHBUTTON_TOGGLE (SwitchMode 7) to allow toggling on any switch change (#1221)
|
||||
* Fix DHT sensor timeout recognition by distinguish "signal already there" from "timeout" (#1233)
|
||||
*
|
||||
* 5.9.1g
|
||||
* Fix typo ALIRFRCV into ARIRFRCV
|
||||
* Add nicer clock support for larger hand widths
|
||||
* Add better clock support for different pixel counts (#1226)
|
||||
|
|
|
@ -111,7 +111,7 @@ enum LoggingLevels {LOG_LEVEL_NONE, LOG_LEVEL_ERROR, LOG_LEVEL_INFO, LOG_LEVEL_D
|
|||
|
||||
enum WifiConfigOptions {WIFI_RESTART, WIFI_SMARTCONFIG, WIFI_MANAGER, WIFI_WPSCONFIG, WIFI_RETRY, WIFI_WAIT, MAX_WIFI_OPTION};
|
||||
|
||||
enum SwitchModeOptions {TOGGLE, FOLLOW, FOLLOW_INV, PUSHBUTTON, PUSHBUTTON_INV, PUSHBUTTONHOLD, PUSHBUTTONHOLD_INV, MAX_SWITCH_OPTION};
|
||||
enum SwitchModeOptions {TOGGLE, FOLLOW, FOLLOW_INV, PUSHBUTTON, PUSHBUTTON_INV, PUSHBUTTONHOLD, PUSHBUTTONHOLD_INV, PUSHBUTTON_TOGGLE, MAX_SWITCH_OPTION};
|
||||
|
||||
enum LedStateOptions {LED_OFF, LED_POWER, LED_MQTTSUB, LED_POWER_MQTTSUB, LED_MQTTPUB, LED_POWER_MQTTPUB, LED_MQTT, LED_POWER_MQTT, MAX_LED_OPTION};
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
- Select IDE Tools - Flash Size: "1M (no SPIFFS)"
|
||||
====================================================*/
|
||||
|
||||
#define VERSION 0x05090107 // 5.9.1g
|
||||
#define VERSION 0x05090108 // 5.9.1h
|
||||
|
||||
// Location specific includes
|
||||
#include "sonoff.h" // Enumaration used in user_config.h
|
||||
|
@ -2083,6 +2083,11 @@ void SwitchHandler()
|
|||
switchflag = 2; // Toggle with releasing pushbutton from Gnd
|
||||
}
|
||||
break;
|
||||
case PUSHBUTTON_TOGGLE:
|
||||
if (button != lastwallswitch[i]) {
|
||||
switchflag = 2; // Toggle with any pushbutton change
|
||||
}
|
||||
break;
|
||||
case PUSHBUTTONHOLD:
|
||||
if ((PRESSED == button) && (NOT_PRESSED == lastwallswitch[i])) {
|
||||
holdwallswitch[i] = Settings.param[P_HOLD_TIME] * (STATES / 10);
|
||||
|
|
|
@ -151,7 +151,7 @@
|
|||
#define APP_SLEEP 0 // [Sleep] Sleep time to lower energy consumption (0 = Off, 1 - 250 mSec)
|
||||
|
||||
#define KEY_HOLD_TIME 40 // [SetOption32] Number of 0.1 seconds to hold Button or external Pushbutton before sending HOLD message
|
||||
#define SWITCH_MODE TOGGLE // [SwitchMode] TOGGLE, FOLLOW, FOLLOW_INV, PUSHBUTTON, PUSHBUTTON_INV, PUSHBUTTONHOLD or PUSHBUTTONHOLD_INV (the wall switch state)
|
||||
#define SWITCH_MODE TOGGLE // [SwitchMode] TOGGLE, FOLLOW, FOLLOW_INV, PUSHBUTTON, PUSHBUTTON_INV, PUSHBUTTONHOLD, PUSHBUTTONHOLD_INV or PUSHBUTTON_TOGGLE (the wall switch state)
|
||||
#define WS2812_LEDS 30 // [Pixels] Number of WS2812 LEDs to start with
|
||||
|
||||
#define TEMP_CONVERSION 0 // [SetOption8] Return temperature in (0 = Celsius or 1 = Fahrenheit)
|
||||
|
|
Loading…
Reference in New Issue