logo elektroda
logo elektroda
X
logo elektroda

[Solved] OpenBeken Light Switch: Cannot Temporarily Disable Physical Switches with Flag 41 (Child Lock)

zakdma 825 13
Best answers LABEL_AI_GENERATED

How can I temporarily disable a physical `dinput_n` switch in OpenBeken without unbinding it from the module configuration?

Yes—`Flag 41` can now block `dinput_n` switch events, but you need a firmware build that includes the child-lock update for dinput. Initially, this flag was described as working by design for buttons and not for `dinput`, so the switch still followed the relay on older builds [#21853787] A fix was added in PR `#2037`, and the flag can also be set via MQTT if you want Home Assistant to lock and unlock it on a schedule [#21866967] The updated binary was tested successfully: `Flag 41` blocked `dInput_n` as expected, and removing the flag restored normal switch-follow behavior [#21867013][#21867465] The PR was then accepted and merged [#21867486][#21868030]
AI summary based on the discussion. May contain errors.
ADVERTISEMENT
  • Request for a flag to temporarily disable physical switches

    #1 21852790
    zakdma
    Level 3  
    Posts: 27
    Hi there!

    OpenBeken light switch, latest firmware OpenBK7231N_1.18.268.rbl.
    All switches are configured as dinput_n, so the relay follows the physical switch.
    I sometimes need to lock the physical switch to prevent children from switching on the light.
    I tried to use:
    Flag 41 - [BTN] Ignore all button events (aka child lock).
    But, looks like it does not work. Relay still follows the physical switch.
    Is there any fast flag to disable physical switches temporarily without unbinding them in the module configuration?

    Thanks!
  • ADVERTISEMENT
  • Child lock should also support dInput

    #2 21853787
    p.kaczmarek2
    Moderator Smart Home
    Posts: 14770
    Help: 659
    Rate: 12913
    Well... this is by design. I think you should rather use "Toggle channel on toggle" role, so you have remote control as well, and can toggle relay via WiFi. I am somewhat suprised, why are you using dInput? dInput + Relay effectively makes OBK act like old style switch with no remote control.

    If you want, I can make child lock also work for dinput, I see nothing against that, but still, it's suprising.
    Helpful post? Buy me a coffee.
  • Request for MQTT-controlled child lock on dinput_n

    #3 21853795
    zakdma
    Level 3  
    Posts: 27
    >>21853787

    Hi! Thank you for the reply.
    I need that config with dinput_n because I need the relay to follow the physical switch. So, if the switch is on, then the relay is on, and if the switch is off, then the relay is also off. But the same time I can switch the light on/off by automation (HA).
    In case I used a toggle, then after the light is off by automation, the light will be off when the switch is on, and vice versa. It's very inconvenient for me.
    It would be great if you implemented a child lock for dinput_n.

    Thank you!

    P.S. It would be useful also if this flag could be set by an MQTT message, so HA could lock the switch, let's say, by the time trigger.
  • #4 21859476
    zakdma
    Level 3  
    Posts: 27
    p.kaczmarek2 wrote:
    If you want, I can make child lock also work for dinput, I see nothing against that, but still, it's suprising.


    Hi! Are there any updates about that?
  • ADVERTISEMENT
  • #5 21866932
    zakdma
    Level 3  
    Posts: 27
    Hi @p.kaczmarek2
    Are there any updates about that?
  • #6 21866967
    p.kaczmarek2
    Moderator Smart Home
    Posts: 14770
    Help: 659
    Rate: 12913
    Flags can be already set with MQTT message if you need it.

    I tried to add childlock for dinput in this PR, can you check, get binary and flash?
    https://github.com/openshwprojects/OpenBK7231T_App/pull/2037
    Helpful post? Buy me a coffee.
  • #7 21866988
    zakdma
    Level 3  
    Posts: 27
    >>21866967

    @p.kaczmarek2 how can I get binary?
  • #8 21867000
    p.kaczmarek2
    Moderator Smart Home
    Posts: 14770
    Help: 659
    Rate: 12913
    Check this out tutorial to learn how to get online binaries for OBK pull requests:
    https://www.elektroda.com/rtvforum/topic4033833.html
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #9 21867013
    zakdma
    Level 3  
    Posts: 27
    Thank you, @p.kaczmarek2 !

    It's working fine for me now.
  • ADVERTISEMENT
  • #10 21867080
    p.kaczmarek2
    Moderator Smart Home
    Posts: 14770
    Help: 659
    Rate: 12913
    So do you think we can merge it?
    Helpful post? Buy me a coffee.
  • #11 21867465
    zakdma
    Level 3  
    Posts: 27
    @p.kaczmarek2 yes, it's working fine for me. Flag 41 now blocks dInput_n as expected. If flag 41 is removed, it starts to follow the switch again, also as expected. I assume we are good to merge.
  • Helpful post
    #12 21867486
    p.kaczmarek2
    Moderator Smart Home
    Posts: 14770
    Help: 659
    Rate: 12913
    Very well, I'll merge it now. Is there anything else we may add for you?
    Helpful post? Buy me a coffee.
  • #13 21867495
    zakdma
    Level 3  
    Posts: 27
    @p.kaczmarek2 thank you, that's all for now. Very much appreciate your help!

Topic summary

LABEL_AI_GENERATED
OpenBeken light switch firmware did not initially apply Flag 41 (child lock / ignore button events) to dinput_n inputs, so the relay still followed the physical switch. The user needed dinput_n behavior to keep relay state synchronized with the wall switch while still allowing Home Assistant automation control, and requested a temporary lock that could also be toggled via MQTT. A firmware change was proposed and tested in a pull request, adding child lock support for dinput; after flashing the updated binary, Flag 41 correctly blocked dinput_n events and restored normal switch-following behavior when removed. The fix was then merged into OpenBK7231T_App PR #2037.
AI summary based on the discussion. May contain errors.
ADVERTISEMENT