Entity to entity automation with condition state not working

Hi All, i have two sonoff T2 wall switches and i want a button on the on switch to trigger a button on the other to both on and off state, at the moment i can switch switch.sonoff_1000b9de1e_1 (passage switch no.1) ON using switch.sonoff_10009f75f4_2 (bathroom switch no.2)

But cannot switch it off ? based on below two automatons on and off are configured the same but only on is functioning.

Any input will be much appreciated
PS. Ist there any way to convert the sonoff entities to devices ?

Cheers
G

- id: '1603190083349'
  alias: Our Bathroom c2 on
  description: ''
  trigger:
  - platform: state
    entity_id: switch.sonoff_10009f75f4_2
    to: 'on'
  condition: []
  action:
  - condition: state
    state: 'on'
    entity_id: switch.sonoff_1000b9de1e_1
  mode: single
  max: 10
- id: '1603190237257'
  alias: Our Bathroom c2 off
  description: ''
  trigger:
  - platform: state
    entity_id: switch.sonoff_10009f75f4_2
    to: 'off'
  condition: []
  action:
  - condition: state
    state: 'off'
    entity_id: switch.sonoff_1000b9de1e_1
  mode: single
  max: 10

You don’t have any services in your actions, only conditions. Those automations don’t do anything.

just saw now :frowning: i had a old scene in ewelink that caused it to turn on . (feeling a bit stupid now) … just changed it to call a service as you said, will test tonight

- id: '1603190083349'
  alias: Our Bathroom c2 on
  description: ''
  trigger:
  - platform: state
    entity_id: switch.sonoff_10009f75f4_2
    to: 'on'
  condition: []
  action:
  - service: switch.turn_on
    data:
      entity_id: switch.sonoff_1000b9de1e_1
  mode: single
  max: 10
- id: '1603190237257'
  alias: Our Bathroom c2 off
  description: ''
  trigger:
  - platform: state
    entity_id: switch.sonoff_10009f75f4_2
    to: 'off'
  condition: []
  action:
  - service: switch.turn_off
    data:
      entity_id: switch.sonoff_1000b9de1e_1
  mode: single
  max: 10
1 Like