slsys / Gateway

Web site
https://slsys.github.io/Gateway/
245 stars 107 forks source link

TS0042: send actions for every button separatelly #92

Closed re3lex closed 3 years ago

re3lex commented 3 years ago

Hi,

TS0042 is Lonsonho Wireless switch with 2 buttons.

I see three issues with it:

  1. MQTT messages appears within 2-3 seconds on MQTT server's topic after clicking on switch button. There are no issues with my other devices: in that case messages appears instantly.
  2. SLS is sending 3 MQTT messages on 1st key click, where first two do not contain action info and only 3rd has it. Here is example of these MQTT messages:
    
    18.01.2021 20:12:41 
    {"action":"1_single","battery":100,"linkquality":86,"voltage":3}

18.01.2021 20:12:39(-2.03 seconds) {"battery":100,"linkquality":84,"voltage":3}

18.01.2021 20:12:38(-1 seconds) {"battery":100,"linkquality":70,"voltage":3}

3. SLS duplicates MQTT message when 2nd key is pressed though there is no issue with 1st button. This is definitely not switch issue: there are no duplicated messages when it is connected to MQTT server via Zigbee2mqtt and cc2538 dongle. Here is example of these MQTT messages:

18.01.2021 20:14:44 {"action":"2_single","battery":100,"linkquality":94,"voltage":3}

18.01.2021 20:14:43(-0.97 seconds) {"action":"2_single","battery":100,"linkquality":94,"voltage":3}



**Update:**
I just got another double key switch from another factory but it is determined as TS0042 as well in SLS gateway.
Unlike the switch I mentioned earlier SLS is generating duplicated MQTT messages for both keys for this switch.
Avenitos commented 3 years ago

this will be fixed in the new version 2021.01.24d1