Safety switch? (automation)

Hi,

When i look on my phone i sometimes notice that my automation rules are switched off. I think i did that accidentally (while swiping on the phone in the GUI).

I want to make one master switch which has to be flipped before another switch can be flipped. Can someone give me an hint how to do this?

Thnx!

If you’re using the old UI there is a custom-ui solution that does the same thing.

Why don’t you just hide the automations?

are you using lovelace or original UI?
if lovelace, you can hide your automations if an input_boolean is off


see an example from my config
      - type: conditional
        conditions:
          - entity: input_boolean.xmas
            state: "on"
        card:
          type: entities
          title: Xmas Lights
          entities:
            - entity: switch.lwrf_socket_xmas
              secondary_info: last-changed
            - entity: light.bauble_1
              secondary_info: last-changed
            - entity: light.bauble_2
              secondary_info: last-changed
            - entity: light.bauble_3
              secondary_info: last-changed

If using the original UI, you can set an automation to make the group group.all_automations hidden with the following action

    - service: group.set_visibility
      entity_id: group.all_automations
      data:
        visible: no

by default the group.all_automations is hidden so you’ll have to unhide it in the customisation part of your config:

group.all_automations:
  hidden: false

The “toggle-lock-entity-row” custom card might be useful for this, as another user mentioned. It makes elements require a tap to unlock them, then they can be toggled.

1 Like

Hello Silicon_Avatar,

Where do i put:

resources:

  • url: /local/toggle-lock-entity-row.js
    type: js

views:

  • title: My view
    cards:
  • type: entities
    entities:
    - entity: light.my_lamp
    name: A lamp
    type: custom:toggle-lock-entity-row

?

ps: i downloaded toggle-lock-entity-row.js to the local-folder,

At the bottom of your ui-lovelace.yaml file, put this:

resources:
  - url: /local/toggle-lock-entity-row.js
    type: js

And make sure you have the toggle-lock-entity-row.js file in the WWW folder (/workspace/config/www)

Then, back in your ui-lovelace.yaml file, you can make a new card with the following config:

 - type: entities
      entities:
        - entity: light.my_lamp
          name: A lamp
          type: custom:toggle-lock-entity-row

Where the light.my_lamp is whatever entity you want to use the locked slider.

Thnx Silicon-Avatar, i didn’t get it to work but it forced me to:

-“take controle” in the GUI
-discovered the power of lovelace (views/cards/editors)

Thnx man!

1 Like