From f6b527d189ab87815cf464a5300d6ea965f7bf81 Mon Sep 17 00:00:00 2001 From: gemu2015 Date: Mon, 19 Jul 2021 09:55:43 +0200 Subject: [PATCH] fix =d mode --- tasmota/xsns_53_sml.ino | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tasmota/xsns_53_sml.ino b/tasmota/xsns_53_sml.ino index cb7fa9497..184261771 100755 --- a/tasmota/xsns_53_sml.ino +++ b/tasmota/xsns_53_sml.ino @@ -456,7 +456,7 @@ const uint8_t meter[]= //0x77,0x07,0x01,0x00,0x01,0x08,0x01,0xff "1,77070101010801ff@1000," D_TPWRIN1 ",kWh," DJ_TPWRIN1 ",2|" // Verbrauch T1 //0x77,0x07,0x01,0x00,0x01,0x07,0x00,0xff -"1,77070100010700ff@1," D_TPWRCURR ",W," DJ_TPWRCURR ",0|" // Strom Gesamt +"1,77070100010700ff@1," D_TPWRCURR ",W," DJ_TPWRCURR ",0|" // Strom Gesamt //0x77,0x07,0x01,0x00,0x01,0x07,0x00,0xff "1,77070100150700ff@1," D_TPWRCURR1 ",W," DJ_TPWRCURR1 ",0|" // Strom L1 //0x77,0x07,0x01,0x00,0x01,0x07,0x00,0xff @@ -1438,6 +1438,13 @@ void SML_Decode(uint8_t index) { continue; } + // =d must handle dindex + if (*mp == '=' && *(mp + 1) == 'd') { + if (index != mindex) { + dindex++; + } + } + if (index!=mindex) goto nextsect; // start of serial source buffer