Admin USE_ENERGY_DUMMY

This commit is contained in:
Theo Arends 2021-04-06 12:08:07 +02:00
parent db4399d89b
commit f50c3f8f62
5 changed files with 8 additions and 5 deletions

View File

@ -67,6 +67,7 @@ m = minimal, l = lite, t = tasmota, k = knx, s = sensors, i = ir, d = display
| USE_ELECTRIQ_MOODL | - | - | x / - | x | x | - | x |
| | | | | | | | |
| USE_ENERGY_SENSOR | - | x | x / x | x | x | - | - |
| USE_ENERGY_DUMMY | - | x | x / x | x | x | - | - |
| USE_PZEM004T | - | - | x / x | x | x | - | - |
| USE_PZEM_AC | - | - | x / x | x | x | - | - |
| USE_PZEM_DC | - | - | x / x | x | x | - | - |

View File

@ -707,7 +707,7 @@
// -- Power monitoring sensors --------------------
#define USE_ENERGY_MARGIN_DETECTION // Add support for Energy Margin detection (+1k6 code)
#define USE_ENERGY_POWER_LIMIT // Add additional support for Energy Power Limit detection (+1k2 code)
#define USE_ENERGY_DUMMY // Add support for dummy Energy monitor allowing user values (+0k5 code)
#define USE_ENERGY_DUMMY // Add support for dummy Energy monitor allowing user values (+0k7 code)
#define USE_PZEM004T // Add support for PZEM004T Energy monitor (+2k code)
#define USE_PZEM_AC // Add support for PZEM014,016 Energy monitor (+1k1 code)
#define USE_PZEM_DC // Add support for PZEM003,017 Energy monitor (+1k1 code)

View File

@ -740,7 +740,9 @@ void ResponseAppendFeatures(void)
#ifdef USE_HALLEFFECT
feature8 |= 0x00000010; // xsns_87_esp32_halleffect.ino
#endif
// feature8 |= 0x00000020;
#if defined(USE_ENERGY_SENSOR) && defined(USE_ENERGY_DUMMY)
feature8 |= 0x00000020;
#endif
// feature8 |= 0x00000040;
// feature8 |= 0x00000080;

View File

@ -105,7 +105,7 @@ bool NrgDummyCommand(void) {
}
void NrgDummyDrvInit(void) {
if (TasmotaGlobal.gpio_optiona.dummy_energy) {
if (TasmotaGlobal.gpio_optiona.dummy_energy && TasmotaGlobal.devices_present) {
if (HLW_PREF_PULSE == Settings.energy_power_calibration) {
Settings.energy_frequency_calibration = NRG_DUMMY_FREF;
Settings.energy_voltage_calibration = NRG_DUMMY_UREF;

View File

@ -253,7 +253,7 @@ a_features = [[
"USE_TOF10120","USE_SDM72","USE_DISPLAY_TM1637","USE_PROJECTOR_CTRL"
],[
"USE_MPU6886","USE_TFMINIPLUS","USE_CSE7761","USE_BERRY",
"USE_HALLEFFECT","","","",
"USE_HALLEFFECT","USE_ENERGY_DUMMY","","",
"","","","",
"","","","",
"","","","",
@ -287,7 +287,7 @@ else:
obj = json.load(fp)
def StartDecode():
print ("\n*** decode-status.py v20210327 by Theo Arends and Jacek Ziolkowski ***")
print ("\n*** decode-status.py v20210406 by Theo Arends and Jacek Ziolkowski ***")
# print("Decoding\n{}".format(obj))