mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-23 18:56:38 +00:00
Add compile time interlock parameters
Add compile time interlock parameters (#8759)
This commit is contained in:
parent
c8e08d7f8a
commit
7c8b06ce16
@ -62,6 +62,7 @@ The following binary downloads have been compiled with ESP8266/Arduino library c
|
||||
- Change define USE_TASMOTA_SLAVE into USE_TASMOTA_CLIENT
|
||||
- Change commands ``SlaveSend`` and ``SlaveReset`` into ``ClientSend`` and ``ClientReset``
|
||||
- Fix escape of non-JSON received serial data (#8329)
|
||||
- Fix exception or watchdog on rule re-entry (#8757)
|
||||
- Add command ``Rule0`` to change global rule parameters
|
||||
- Add command ``Time 4`` to display timestamp using milliseconds (#8537)
|
||||
- Add command ``SetOption94 0/1`` to select MAX31855 or MAX6675 thermocouple support (#8616)
|
||||
@ -88,3 +89,4 @@ The following binary downloads have been compiled with ESP8266/Arduino library c
|
||||
- Add Library to be used for decoding Teleinfo (French Metering Smart Meter)
|
||||
- Add basic support for ESP32 ethernet adding commands ``Wifi 0/1`` and ``Ethernet 0/1`` both default ON
|
||||
- Add support for single wire LMT01 temperature Sensor by justifiably (#8713)
|
||||
- Add compile time interlock parameters (#8759)
|
||||
|
@ -6,6 +6,8 @@
|
||||
- Add support for Energy sensor (Denky) for French Smart Metering meter provided by global Energy Providers, need a adaptater. See dedicated full [blog](http://hallard.me/category/tinfo/) about French teleinformation stuff
|
||||
- Add library to be used for decoding Teleinfo (French Metering Smart Meter)
|
||||
- Add support for single wire LMT01 temperature Sensor by justifiably (#8713)
|
||||
- Add compile time interlock parameters (#8759)
|
||||
- Fix exception or watchdog on rule re-entry (#8757)
|
||||
- Change ESP32 USER GPIO template representation decreasing template message size
|
||||
- Change define USE_TASMOTA_SLAVE into USE_TASMOTA_CLIENT
|
||||
- Change commands ``SlaveSend`` and ``SlaveReset`` into ``ClientSend`` and ``ClientReset``
|
||||
|
@ -280,6 +280,12 @@
|
||||
#define APP_DISABLE_POWERCYCLE false // [SetOption65] Disable fast power cycle detection for device reset
|
||||
#define DEEPSLEEP_BOOTCOUNT false // [SetOption76] Enable incrementing bootcount when deepsleep is enabled
|
||||
|
||||
#define APP_INTERLOCK_MODE false // [Interlock] Relay interlock mode
|
||||
#define APP_INTERLOCK_GROUP_1 0xFF // [Interlock] Relay bitmask for interlock group 1 (0xFF if undef)
|
||||
//#define APP_INTERLOCK_GROUP_2 0x00 // [Interlock] Relay bitmask for interlock group 2 (0x00 if undef)
|
||||
//#define APP_INTERLOCK_GROUP_3 0x00 // [Interlock] Relay bitmask for interlock group 3 (0x00 if undef)
|
||||
//#define APP_INTERLOCK_GROUP_4 0x00 // [Interlock] Relay bitmask for interlock group 4 (0x00 if undef)
|
||||
|
||||
// -- Lights --------------------------------------
|
||||
#define WS2812_LEDS 30 // [Pixels] Number of WS2812 LEDs to start with (max is 512)
|
||||
#define LIGHT_MODE true // [SetOption15] Switch between commands PWM or COLOR/DIMMER/CT/CHANNEL
|
||||
|
@ -765,8 +765,11 @@ void SettingsDefaultSet2(void)
|
||||
}
|
||||
|
||||
// Module
|
||||
// flag.interlock |= 0;
|
||||
Settings.interlock[0] = 0xFF; // Legacy support using all relays in one interlock group
|
||||
flag.interlock |= APP_INTERLOCK_MODE;
|
||||
Settings.interlock[0] = APP_INTERLOCK_GROUP_1;
|
||||
Settings.interlock[1] = APP_INTERLOCK_GROUP_2;
|
||||
Settings.interlock[2] = APP_INTERLOCK_GROUP_3;
|
||||
Settings.interlock[3] = APP_INTERLOCK_GROUP_4;
|
||||
Settings.module = MODULE;
|
||||
Settings.fallback_module = FALLBACK_MODULE;
|
||||
ModuleDefault(WEMOS);
|
||||
@ -1188,8 +1191,11 @@ void SettingsDelta(void)
|
||||
Settings.param[P_MDNS_DELAYED_START] = 0;
|
||||
}
|
||||
if (Settings.version < 0x0604010B) {
|
||||
Settings.interlock[0] = 0xFF; // Legacy support using all relays in one interlock group
|
||||
for (uint32_t i = 1; i < MAX_INTERLOCKS; i++) { Settings.interlock[i] = 0; }
|
||||
Settings.flag.interlock = APP_INTERLOCK_MODE;
|
||||
Settings.interlock[0] = APP_INTERLOCK_GROUP_1;
|
||||
Settings.interlock[1] = APP_INTERLOCK_GROUP_2;
|
||||
Settings.interlock[2] = APP_INTERLOCK_GROUP_3;
|
||||
Settings.interlock[3] = APP_INTERLOCK_GROUP_4;
|
||||
}
|
||||
if (Settings.version < 0x0604010D) {
|
||||
Settings.param[P_BOOT_LOOP_OFFSET] = BOOT_LOOP_OFFSET; // SetOption36
|
||||
|
@ -1627,7 +1627,8 @@ void CmndInterlock(void)
|
||||
}
|
||||
ResponseAppend_P(PSTR("\"}"));
|
||||
} else {
|
||||
Settings.flag.interlock = 0; // CMND_INTERLOCK - Enable/disable interlock
|
||||
// never ever reset interlock mode inadvertently if we forced it upon compilation
|
||||
Settings.flag.interlock = APP_INTERLOCK_MODE; // CMND_INTERLOCK - Enable/disable interlock
|
||||
ResponseCmndStateText(Settings.flag.interlock);
|
||||
}
|
||||
}
|
||||
|
@ -88,6 +88,22 @@ String EthernetMacAddress(void);
|
||||
#undef USE_RF_FLASH // Disable RF firmware flash when Sonoff Rf is disabled
|
||||
#endif
|
||||
|
||||
#ifndef APP_INTERLOCK_MODE
|
||||
#define APP_INTERLOCK_MODE false // [Interlock] Relay interlock mode
|
||||
#endif
|
||||
#ifndef APP_INTERLOCK_GROUP_1
|
||||
#define APP_INTERLOCK_GROUP_1 0xFF // [Interlock] Relay bitmask for interlock group 1 - Legacy support using all relays in one interlock group
|
||||
#endif
|
||||
#ifndef APP_INTERLOCK_GROUP_2
|
||||
#define APP_INTERLOCK_GROUP_2 0x00 // [Interlock] Relay bitmask for interlock group 2
|
||||
#endif
|
||||
#ifndef APP_INTERLOCK_GROUP_3
|
||||
#define APP_INTERLOCK_GROUP_3 0x00 // [Interlock] Relay bitmask for interlock group 3
|
||||
#endif
|
||||
#ifndef APP_INTERLOCK_GROUP_4
|
||||
#define APP_INTERLOCK_GROUP_4 0x00 // [Interlock] Relay bitmask for interlock group 4
|
||||
#endif
|
||||
|
||||
#ifndef SWITCH_MODE
|
||||
#define SWITCH_MODE TOGGLE // TOGGLE, FOLLOW or FOLLOW_INV (the wall switch state)
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user