From 357e8d71b75f5a1f16bbfe0ca9b6b461f5568927 Mon Sep 17 00:00:00 2001 From: gemu2015 Date: Mon, 27 Apr 2020 07:20:17 +0200 Subject: [PATCH] fix sml transmit timer --- tasmota/xsns_53_sml.ino | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tasmota/xsns_53_sml.ino b/tasmota/xsns_53_sml.ino index c5f2d3cc2..71b205e6e 100755 --- a/tasmota/xsns_53_sml.ino +++ b/tasmota/xsns_53_sml.ino @@ -2206,7 +2206,10 @@ void SML_Check_Send(void) { char *cp; for (uint32_t cnt=sml_desc_cnt; cnt=0 && script_meter_desc[cnt].txmem) { - if ((sml_100ms_cnt%script_meter_desc[cnt].tsecs)==0) { + //AddLog_P2(LOG_LEVEL_INFO, PSTR("100 ms>> %d - %s - %d"),sml_desc_cnt,script_meter_desc[cnt].txmem,script_meter_desc[cnt].tsecs); + if ((sml_100ms_cnt>=script_meter_desc[cnt].tsecs)) { + sml_100ms_cnt=0; + //AddLog_P2(LOG_LEVEL_INFO, PSTR("100 ms>> 2"),cp); if (script_meter_desc[cnt].max_index>1) { script_meter_desc[cnt].index++; if (script_meter_desc[cnt].index>=script_meter_desc[cnt].max_index) {