Sonoff switch with Tasmota 8.1 get always a payload OFF from somewhere

Hey All,

May you met with this problem already. I have some sonoff basic, which I use to enable air condition fans.
I think I set everything well and Im using hassio 0.103.0 and tasmota 8.1.
What I experience is that when I sent the cmnd/tasmotaname/POWER payload ON after some mins the switch got an OFF… In my configuration only the timer.finished can trigger this, but the timer is not finish yet in this time.

I can see well the logs in the sonoff device (that’s why I know there is a turn off command from somewhere), but I can not see why, and what is sending this to there…

My logging: is this:

logger:
  default: critical
  logs:
    # log level for HA core
    homeassistant.core: warning

    # log level for MQTT integration
    homeassistant.components.mqtt: debug

Do you know why is this happen or how can I see what and when send the payload OFF from my hassio? :s

Thanks

Thanks!

Ohh I just realized I can not see the log under the log page only if I click for the full log from file :slight_smile:

So in random times I got an off to every of my switch :S
2020-01-05 17:47:57 DEBUG (MainThread) [homeassistant.components.mqtt] Transmitting message on cmnd/sonoffbasic1/POWER: OFF
2020-01-05 17:47:57 DEBUG (MainThread) [homeassistant.components.mqtt] Transmitting message on cmnd/sonoffbasic2/POWER: OFF
2020-01-05 17:47:57 DEBUG (MainThread) [homeassistant.components.mqtt] Transmitting message on cmnd/sonoffbasic3/POWER: OFF
2020-01-05 17:47:57 DEBUG (MainThread) [homeassistant.components.mqtt] Transmitting message on cmnd/sonoffbasic4/POWER: OFF

But I dont know why

So what I see sometimes all of my timers for the MQTT switches triggered :S
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.components.automation] Executing Bathroom air timer off
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.helpers.script] Script Bathroom air timer off: Running script
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.helpers.script] Script Bathroom air timer off: Executing step call service
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.components.automation] Executing Kitchen air timer - Finish
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.helpers.script] Script Kitchen air timer - Finish: Running script
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.helpers.script] Script Kitchen air timer - Finish: Executing step call service
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.components.automation] Executing HWR air timer off
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.helpers.script] Script HWR air timer off: Running script
2020-01-05 18:15:18 INFO (MainThread) [homeassistant.helpers.script] Script HWR air timer off: Executing step call service

This time the kitchen timer was still running…

I have this config for it:

- alias: 'Kitchen air timer - Finish'
  initial_state: 'on'
  trigger:
    - platform: event
      event_type: timer.finished
      event_data:
        event_id: timer.kitchen_air
  action:
    - service: switch.turn_off
      entity_id: switch.sonoff_basic_1

Finally I found the solution. There is a bug somewhere.
There was a Tasmota switch which was unavailable and a timer.finished event turn it off with the switch.turn_off.

This indicated a trigger which was not normal, because the trigger could fire a timer finished event, which timer was deleted before…
So somehow the unavailable switch sent POWER off messages to the MQTT… and all of my switches (maybe one not…) got it and they went off…

So if you have some anomaly then check the automations with not available switches.

Cheers