I've flashed and partially configured a Smart Life Switch but I'm struggling with triggering scripts or backlog commands in the event of a button click. I'm familiar with Tasmota but have never used OpenBeken before.
Here's the unit with the front panel removed:
Current configuration is Open btn, Open LED, Open Relay all on Ch 1, Stop btn & Stop LED on Ch 2, Close btn, Close LED and Close Relay all on Ch 3. No Channel Types have been set. I have an autoexec.bat file to label the buttons on the GUI and close the window.
But the Event Handler doesn't work when I click the Stop btn!
ATM I'd like it to behave like it did with the Tuya firmware.
On Open btn click, it should ensure the Close Relay is not on, then turn on the Open Relay and Open LED for 10 seconds then turn both off, then it should turn on the Stop LED for 3 seconds. The Close btn should do the opposite. The Stop btn should turn both relays off (Either one could be on) then turn on the Stop LED for 3 seconds.
So I just need a bit of help linking the btn clicks to some action. Also, should I use different channels for the buttons away from the relays/LEDs to stop any automatic linkage. I don't want both relays on at the same time as that could blow up the actual opener itself!
I will be writing this up as a project and new device in the repository when I'm done.
Thanks in advance.
Here's the unit with the front panel removed:

Current configuration is Open btn, Open LED, Open Relay all on Ch 1, Stop btn & Stop LED on Ch 2, Close btn, Close LED and Close Relay all on Ch 3. No Channel Types have been set. I have an autoexec.bat file to label the buttons on the GUI and close the window.
// Add names to the buttons
setChannelLabel 1 Open 1
setChannelLabel 2 Stop 1
setChannelLabel 3 Close 1
// Close window
setChannel 1 0
setChannel 2 0
setChannel 3 1
delay_s 10
setChannel 3 0
setChannel 2 1
delay_s 3
setChannel 2 0
addEventHandler OnChannelChange 2 backlog setchannel 1 0; setchannel 2 1; setchannel 3 0; delay_s 3; setchannel 2 0
But the Event Handler doesn't work when I click the Stop btn!
ATM I'd like it to behave like it did with the Tuya firmware.
On Open btn click, it should ensure the Close Relay is not on, then turn on the Open Relay and Open LED for 10 seconds then turn both off, then it should turn on the Stop LED for 3 seconds. The Close btn should do the opposite. The Stop btn should turn both relays off (Either one could be on) then turn on the Stop LED for 3 seconds.
So I just need a bit of help linking the btn clicks to some action. Also, should I use different channels for the buttons away from the relays/LEDs to stop any automatic linkage. I don't want both relays on at the same time as that could blow up the actual opener itself!
I will be writing this up as a project and new device in the repository when I'm done.
Thanks in advance.