# Logic between two light switch

**URL:** <https://community.homey.app/t/logic-between-two-light-switch/26722>\
**Category:** Questions & Help\
**Created:** [March 4, 2020, 7:38am UTC](https://community.homey.app/t/logic-between-two-light-switch/26722 "2020-03-04T07:38:52Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Magic](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/magic/32/12395_2.png) [@Magic](https://community.homey.app/u/Magic)\
**Post date:** [March 4, 2020, 7:38am UTC](https://community.homey.app/t/logic-between-two-light-switch/26722/1 "2020-03-04T07:38:52Z")

</div>

Hi, i buy 2 Sonoff 3 button light switch. Each has wired connect light on 1 and 3 button. I want set middle button as

1. switch off all light connected to both switches
2. switch off all light connected to second switch

i need, that when any light on 1 switch is ON, on the 2 switch turn ON middle button (for future switch OFF light on 1 switch), when all light on switch 1 is off middle button on 2 switch OFF too. this should work crosswise on both.

I hope it’s at least a bit understandable. Thank you
