We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Greetings;
I just came upon your momentary switch and have installed and configured it. However, I am not clear on how I actually make the switch trigger things.
My current setup is using various command lines in switches, but inclusion in momentary throws error messages.
For example, from my configuration.yaml:
- platform: momentary name: Increase + mode: on toggle_for: milliseconds: 500 command_on: !secret arizer_increase command_off: !secret arizer_light_off value_template: "{{ value | regex_search('ACTIVE', ignorecase=True) }}"
produces the following error:
Invalid config for [switch.momentary]: [command_on] is an invalid option for [switch.momentary]. Check: switch.momentary->command_on. (See ?, line ?).
The text was updated successfully, but these errors were encountered:
There is no command_on or command_off option for the momentary switch, it's just a switch.
command_on
command_off
I you want to run commands you have to monitor the switch from an automation. See Configuration -> Automations -> Add on the GUI.
Configuration -> Automations -> Add
Set up your trigger to act on a state change on the momentary switch and then run your actions. There are more docs here on automation.
Sorry, something went wrong.
Ok thanks. I'll try to figure something out along those lines.
There is no command_on or command_off option for the momentary switch, it's just a switch. I you want to run commands you have to monitor the switch from an automation. See Configuration -> Automations -> Add on the GUI. Set up your trigger to act on a state change on the momentary switch and then run your actions. There are more docs here on automation.
What's a pity, I was also exactly in this case .... why not extend with "command: True" as option ?
No branches or pull requests
Greetings;
I just came upon your momentary switch and have installed and configured it. However, I am not clear on how I actually make the switch trigger things.
My current setup is using various command lines in switches, but inclusion in momentary throws error messages.
For example, from my configuration.yaml:
- platform: momentary name: Increase + mode: on toggle_for: milliseconds: 500 command_on: !secret arizer_increase command_off: !secret arizer_light_off value_template: "{{ value | regex_search('ACTIVE', ignorecase=True) }}"
produces the following error:
Invalid config for [switch.momentary]: [command_on] is an invalid option for [switch.momentary]. Check: switch.momentary->command_on. (See ?, line ?).
The text was updated successfully, but these errors were encountered: