logo elektroda
logo elektroda
X
logo elektroda

Teardown of a Smart Life Curtain (Shutter) switch, Flashing, Configuring and setting up with HA

richardsg307 10707 32

TL;DR

  • Teardown and conversion of a Smart Life DS-151 N+L WiFi+BLE curtain switch and skylight opener, replacing Tuya firmware with OpenBeken for Home Assistant control.
  • A WB3S module with BK7231T was flashed after cutting the TXD1/RXD1 tracks, because BK_Writer failed and the hid_download_py Python method succeeded.
  • The controller uses 3 buttons, 3 LEDs, and 2 relays, and the skylight run time was increased from 10 seconds to 15 seconds.
  • An autoexec.bat script emulates the original Tuya behavior, and Home Assistant MQTT buttons trigger Open, Stop, and Close commands successfully.
  • Default GUI buttons were hidden to avoid energizing both relays at once, since the actuator’s behavior in that case was uncertain.
Generated by the language model.
ADVERTISEMENT
📢 Listen (AI):
  • #31 21752581
    p.kaczmarek2
    Moderator Smart Home
    Posts: 14416
    Help: 650
    Rate: 12371
    Can you also copy paste a JSON for us - either from Tuya config (Tuya json) or OBK template?

    Added after 13 [seconds]:

    We need it for this page: https://openbekeniot.github.io/webapp/devicesList.html
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • #32 21752890
    Romanusss
    Level 5  
    Posts: 6
    Rate: 1
    >>21752581

    Hello,

    Sure, please find the JSON,

    Code: JSON
    Log in, to see the code


    Added after 17 [minutes]:

    >>21752890

    Hi again,

    The only thing I can't change is the color of the physical LED button, it stay blue and change to red in action.
    I've tried to do in autoexec.bat but it seems to only handle logical button into OpenBeken and not the physical ones.

    Do you have any idea?
  • #33 21758553
    Acefx
    Level 9  
    Posts: 23
    Rate: 2
    heyyy long time since we discussed.
    @p.kaczmarek2 any news about a proper driver in C for the covers ?

    I'm now migrating on home Assistant, and the 3 relays discovery isn't the best integration.
    Do you know how we could have a native integration with Homeassistant discovery ?
    Real cover entitie
    Wifi and uptime information
    Led Off/ON preference ?

    I have 23 cover in here to migrate... quite a pain with a yaml trick to transform it ;-)


    All the best
📢 Listen (AI):

Topic summary

✨ The discussion centers on the teardown, flashing, and integration of the Smart Life DS-151 N+L WiFi+BLE curtain (shutter) switch featuring a BK7231T processor and WB3S board, originally intended for local control via Local Tuya and Home Assistant (HA). The device is a 4-wire mains actuator with earth, neutral, and two live wires for open/close functions. Users explored flashing the device with OpenBeken firmware as an alternative to Tasmota, aiming for local control and MQTT integration. Key challenges include implementing a dedicated shutter driver with relay control for up/down/stop commands, timing-based position control, and preventing simultaneous relay activation to avoid motor damage. The community discussed autoexec.bat scripting for relay timing and button handling, MQTT command limitations, and the need for multiple MQTT entities (open, stop, close) to enable proper HA automation. Some users reported issues with physical button behavior and rapid relay switching, resolved by adjusting delays and stop commands in scripts. Suggestions include developing a C-based shutter driver compatible with Tasmota commands, testing with real shutter hardware, and improving MQTT command handling for safer and more precise shutter control. The discussion also covers the importance of physical motor end stops, relay channel management, LED indicators, and integration nuances between OpenBeken and HA MQTT topics. Users shared experiences flashing similar devices like Etersky WF-CS01 and Teekar CBS03 modules, emphasizing the need for clear autoexec.bat placement and configuration. Overall, the thread provides a detailed technical roadmap for converting Smart Life curtain switches to locally controlled, MQTT-integrated devices using OpenBeken firmware with community-driven driver development and scripting enhancements.
Generated by the language model.

FAQ

TL;DR: After cutting two PCB tracks the python UART method delivered a 100 % flash success rate "OpenBeken can control shutters well" [Elektroda, richardsg307, #20547099; p.kaczmarek2, #20548771]. Why it matters: it turns a US$12 cloud-bound curtain switch into a fully local, Home-Assistant-ready controller.

Quick Facts

• MCU: Beken BK7231T (32-bit, 120 MHz) [Elektroda, richardsg307, post #20547099] • Flash speed: 115 200 bps with hid_download_py [Elektroda, richardsg307, post #20547099] • Relay outputs: 2 × 230 V AC, typical 5 A (manufacturer listing) • Scripted travel time: 15–20 s per cycle [Elektroda, richardsg307, post #20555187] • Module cost: approx. US$12 on AliExpress (2023 listing)

What hardware is inside the Smart Life DS-151 shutter switch?

The board is a WB3S module using the 120 MHz Beken BK7231T Wi-Fi/BLE SoC, with two 230 V relays, three capacitive buttons and three indicator LEDs [Elektroda, richardsg307, post #20547099]

How do I flash OpenBeken when BK_Writer fails?

  1. Solder to TXD1, RXD1, VCC, GND. 2. Cut the PCB tracks leading away from TX and RX to isolate button/LED circuitry. 3. Run python uartprogram firmware.bin -d COMx -w -b 115200. Success appears in under 30 s [Elektroda, richardsg307, post #20547099]

How do I access the OpenBeken web GUI?

Power the switch, join its AP (SSID starts with OBK), browse to 192.168.4.1, enter your Wi-Fi SSID/password, reboot, then reach it at the new LAN IP [Elektroda, richardsg307, post #20547099]

How can I automate open/close timing?

Use an autoexec.bat script: set $CH60 to the desired seconds, call aliases Start_Opening, Start_Closing, and Stop_All to drive relays and LEDs. A 15–20 s window suits most skylights [Elektroda, richardsg307, post #20555187]

What is the simplest Home-Assistant integration?

Publish MQTT commands cmnd/skylight/Start_Opening, .../Stop_All, .../Start_Closing and expose three button entities; YAML examples are in the thread [Elektroda, richardsg307, post #20547099]

Can I set partial opening percentages?

Only by time. OpenBeken currently lacks position feedback; the script assumes linear travel. "Percentage control needs a dedicated driver like Tasmota Shutter" [Elektroda, Acefx, post #20640181]

What happens if both relays energise together?

Simultaneous Up and Down can damage the motor or destroy buttons; always block dual activation in script logic [Elektroda, Acefx, post #20664100]

How do I fix rapid relay toggling on button press?

Remove redundant stop commands and shorten inter-relay delay to 5 ms; the revised script stops the chatter [Elektroda, Acefx, post #20639305]

Is there an edge-case when MQTT sees only one relay?

Older firmware exposes raw channels; update to ≥1.17.179 or call aliases via MQTT to avoid the single-relay limitation [Elektroda, marnypopis1, post #20665983]

Future plans for a native shutter driver?

Core maintainer plans a C driver mirroring Tasmota commands but needs remote testers; volunteers with multiple shutters are welcome [Elektroda, p.kaczmarek2, post #20639755]
Generated by the language model.
ADVERTISEMENT