Enable/Disable Automation with KNX Switch?

Hi there,

how can I enable and disable an HA automation with a KNX switch?

I need to link the automation to the KNX bus and created a address and state address in ETS and also added this to knx.yaml, but I am not sure how to combine both…

What is my aim?
I have an automation that is controlling the light in our living room during the night with some zigbee lights and is activated by an KNX motion sensor.

We have some friends sleeping in our living room from time to time and we thus want to deactivate the automation so no light turns on while they are moving…

Thanks and meery xmas to all of you!

Hi :wave:!

If you have a switch entity, you can create an automation that toggles the automation.

Or you just add a condition to the automation.

Hi John, the proper way to do this is to create a helper and use that as a condition for running that automation (or not).
Although you can (de-)activate automations, it’s not meant for the use you are aiming.