Button for closing blinds not working

G’day

I did create an automation to close the blinds. The idea is to have a button in dashboard that I can close all blinds.

In the automation if i click “run” in the menu the blinds are closing, but if I use the enable or disable button nothing happens.

What do I need to change that the button I later want to use in the dashboard is working too?

The code looks like this:

“Code start”
alias: Storen einfahren
description: “”
trigger:

  • platform: state
    entity_id:
    • input_boolean.storen_offnen_oder_schliessen
      condition:
      action:
  • device_id: 5712194a1d4ff77c9ca87439b3058fcb
    domain: cover
    entity_id: 9a00423179d3b29c69cf62da5e861194
    type: close
  • device_id: c74aa55aaf3ad316839ce33c2de7ff8b
    domain: cover
    entity_id: 42093d05bac38bc6a6d3dea75c4ea54f
    type: close
  • device_id: b8200aef6dfdb58045cdfee7a4eb2264
    domain: cover
    entity_id: 878f5e51b6321a786c88996580e0a6d1
    type: close
  • device_id: ddae6566e0f4a55215174cf6be2cda0e
    domain: cover
    entity_id: d8ed27d032890fcc1bb095a76c22368e
    type: close
    mode: single
    “Code end”

Many thanks
Chris

Enable or disable does exactly what is says.
It enables or disables the automation.

If you want to trigger your automation you need to manipulate the input_boolean.storen_offnen_oder_schliessen.

But it will not function the way you expect.

Please post the automation as code using the </> symbol so that we can read and edit it.

Or is your idea to only be able to close the blinds?
If so then you could just make a script instead of an automation.
Automations are meant to trigger and work by themselves but scripts are for manual triggering

Yes the idea is just to be able to close the blinds.
If this is not possbile via an automation, then I need further information how to create this script which then triggers a button which then close the blinds.

Just go to scripts and add the same code there.

image

I did now try with a script, but the script does not run.
What do I wrong? I’m not familiar with scripts.

Thank you

“Code start”
alias: Storen einfahren
sequence:

  • service: switch.turn_on
    metadata: {}
    data: {}
  • device_id: 5712194a1d4ff77c9ca87439b3058fcb
    domain: cover
    entity_id: 9a00423179d3b29c69cf62da5e861194
    type: close
  • device_id: c74aa55aaf3ad316839ce33c2de7ff8b
    domain: cover
    entity_id: 42093d05bac38bc6a6d3dea75c4ea54f
    type: close
  • device_id: b8200aef6dfdb58045cdfee7a4eb2264
    domain: cover
    entity_id: 878f5e51b6321a786c88996580e0a6d1
    type: close
  • device_id: ddae6566e0f4a55215174cf6be2cda0e
    domain: cover
    entity_id: d8ed27d032890fcc1bb095a76c22368e
    type: close
    description: “”
    “Code end”

The script is running now, I just used the wrong service.

“Code start”
alias: Storen einfahren
sequence:

  • service: script.storen_einfahren
    data: {}
  • device_id: 5712194a1d4ff77c9ca87439b3058fcb
    domain: cover
    entity_id: 9a00423179d3b29c69cf62da5e861194
    type: close
  • device_id: c74aa55aaf3ad316839ce33c2de7ff8b
    domain: cover
    entity_id: 42093d05bac38bc6a6d3dea75c4ea54f
    type: close
  • device_id: b8200aef6dfdb58045cdfee7a4eb2264
    domain: cover
    entity_id: 878f5e51b6321a786c88996580e0a6d1
    type: close
  • device_id: ddae6566e0f4a55215174cf6be2cda0e
    domain: cover
    entity_id: d8ed27d032890fcc1bb095a76c22368e
    type: close
    description: “”
    “Code end”

It is very hard to troubleshoot code when the format and indents / spacing is not legible.

It would help us help you of you could format the code as per the FAQ.
How to help us help you - or How to ask a good question.

I guess you need to remove the first action in your script.
It seems to call itself, that is not a good idea. This could cause an endless loop.
But as said before, it’s hard to read your post when it’s not formatted correctly