logo elektroda
logo elektroda
X
logo elektroda
Dostępna jest polska wersja

Czy wolisz polską wersję strony elektroda?

Nie, dziękuję Przekieruj mnie tam

[BK7231N / CB3S] Teardown WiFi Smart Power Strip UK

gcole  7 3273 Cool? (+1)
📢 Listen (AI):

TL;DR

  • A generic WiFi Smart Power Strip UK, model SM-SO301K, uses a CB3S module with the BK7231N chip and includes four mains outputs plus a 5V USB output.
  • Disassembly was simple: rubber bungs hid 8 small screws, the cover prised off easily, and the PCB exposed separate red and blue LED indicators and a button input.
  • Temporary wires to +3v3, Gnd, TXD, and RXD fed a Windows serial UART, and the BK7231 GUI flasher wrote OpenBK after shorting CEN to Gnd.
  • The strip connected to WiFi and worked well with Home Assistant, but Btn_tgl_all initially had a bug that was fixed overnight after reporting it.
Generated by the language model.
Here is a teardown for a generic WiFi Smart Power Strip UK Model no. SM-SO301K that I purchased by mistake from Amaozn UK Link to Amazon UK



I already have the Zigbee version and it works well with Home Assistant so I thought I'd try OpenBK with this one.



Disassembly was simple, rubber bungs on the back covering 8 small screws.

****NOTE****
Make sure you disconnect the device from any mains supply before opening the case and do not be tempted to plug it back in once you have removed the cover, ensure safe electrical working practices are carried out at all times.



The cover just prises off, there was no glue or concealed catches.



This is the main PCB and I have identified all of the relevant parts, you can see the CB3S module in the centre it uses the BK7231N chip.

There are four mains outputs, one 5V USB output, two separate LED indicators (red and blue) and one button input.



I temporarily soldered wires to the +3v3, Gnd, TXD and RXD pins on the CB3S module and attached them to a serial UART plugged into my Windows computer.
I downloaded the BK7231 GUI flasher tool from here, unzipped it and ran it.
I then clicked the button 'Download latest from web' and after downloading, selected that file to flash to the module.
Ive done this before so I selected the COM port of my Serial UART and opted to 'Do firmware write (no backup!)'
Once the flash procedure started I shorted CEN (Pin 3) to Gnd for a short pulse and the flash procedure continued to completion.



Head over to https://github.com/openshwprojects/BK7231GUIFlashTool for a detailed overview of how this tool works.

Confident that the procedure had worked, I desoldered my temporary wires and reassembled the device before plugging into the mains supply.

Once I'd got the WiFi settings completed and connected to my AP, I then set up the config as follows:



It worked great!

Well it didn't entirely, I found a bug with the Btn_tgl_all function but that was fixed overnight once I'd raised it on guthub.

Thanks for the amazing response!

About Author
gcole wrote 5 posts with rating 1 . Been with us since 2022 year.

Comments

p.kaczmarek2 10 Mar 2023 18:08

There was indeed a little logical mistake in Toggle All button which manifested only when Relay channels are indexed starting from 1 and not 0, but it's now indeed fixed. Very nice teardown, it's interesting... [Read more]

gcole 10 Mar 2023 21:37

Here is the json config { "vendor": "Generic", "bDetailed": "0", "name": "WiFi Smart Power Strip", "model":... [Read more]

p.kaczmarek2 10 Mar 2023 22:07

Thank you, the device has been added to our list. https://obrazki.elektroda.pl/7326561400_1678482434_thumb.jpg https://openbekeniot.github.io/webapp/devicesList.html If you have any other devices,... [Read more]

gcole 10 Mar 2023 23:24

Ive got some more devices coming soon so I will definitely add more in the future. I have a question. Looing at scripts and so on I'm wondering if tehre is a way to set up the behaviour in the following... [Read more]

p.kaczmarek2 11 Mar 2023 08:47

The similiar behaviour is present in one of our automatic firmware self-tests, designed to check the scripting functionality after each development iteration. https://github.com/openshwprojects/OpenBK7231T_App/blob/main/src/selftest/selftest_demo_buttonToggleGroup.c Here's... [Read more]

gcole 11 Mar 2023 15:40

I put this in an autoexec.bat file and it works exactly as expected, once again thank you! alias set_led_on backlog setChannel 6 1 alias set_led_off backlog setChannel 6 0 alias myToggle if $CH1||$CH2||$CH3||$CH4||$CH5... [Read more]

p.kaczmarek2 11 Mar 2023 16:04

Thank you, is there anything else I may help with? [Read more]

FAQ

TL;DR: CB3S/BK7231N smart strip teardown shows 9 accessible GPIO pins and a 4-gang+USB relay board; “bug fixed overnight” [Elektroda, gcole, #20479666; p.kaczmarek2, #20479693]. Flash via UART, set aliases, enjoy local control.

Why it matters: Local firmware unlocks privacy-friendly automation and lets you repurpose spare GPIO pins.

Quick Facts

• Model SM-SO301K: 4 UK AC outlets + 1 USB-A port, plastic chassis [Elektroda, gcole, post #20479666] • Wi-Fi module CB3S with 1 MB flash, BK7231N SoC; 3.3 V UART pads exposed [Elektroda, gcole, post #20479666] • Disassembly: eight 2 mm screws under rubber feet; no glue, ~1 min teardown [Elektroda, gcole, post #20479666] • OpenBeken firmware size ≈552 kB; GUI Flash Tool v1.4 free download [BK7231GUIFlashTool Releases] • Street price £25–30 on Amazon UK, March 2023 ["Amazon Listing"]

What hardware is inside the SM-SO301K smart power strip?

The main PCB hosts a CB3S module (BK7231N Wi-Fi SoC), six relay channels, a USB 5 V converter, blue/red status LEDs, and a single push-button input [Elektroda, gcole, post #20479666]

How do I open the enclosure without damage?

Unplug mains, pull out the four rear rubber bungs, undo eight small screws, and lift the lid—no glue or hidden clips involved [Elektroda, gcole, post #20479666]

Which pins must I wire for serial flashing?

Solder temporary jumpers to 3.3 V, GND, TXD and RXD on the CB3S module; pulse CEN (pin 3) to ground once the flash starts [Elektroda, gcole, post #20479666]

What software do I use to flash OpenBeken?

Grab BK7231 GUI Flash Tool from its GitHub releases page, click “Download latest from web,” select the binary, choose your COM port, and start the write operation [Elektroda, gcole, post #20479666]

Can you show the flashing process in three concise steps?

  1. Connect UART to 3.3 V, GND, TXD, RXD.
  2. In GUI Flash Tool, load latest OpenBeken binary and press “Write.”
  3. Momentarily short CEN to GND; flashing completes in ~90 s [Elektroda, gcole, post #20479666]

How do I map the relays and button after flashing?

Use the WebApp pin page or JSON template: assign Rel_n to GPIO 6, 8, 23, 24, 26 and Rel/Rel_n to GPIO 10 for USB, set Btn_Tgl_All on GPIO 7, and WifiLED on GPIO 21 [Elektroda, gcole, post #20480041]

Is there a script to light channel 6 when any other relay is on?

Yes. Create autoexec.bat containing: alias set_led_on backlog setChannel 6 1 alias set_led_off backlog setChannel 6 0 alias myToggle if $CH1||$CH2||$CH3||$CH4||$CH5 then set_led_on else set_led_off addEventHandler OnChannelChange 1-5 myToggle It works as demonstrated by the author [Elektroda, gcole, post #20481071]

Can I attach extra sensors to unused GPIO?

Two GPIOs remain free; you can wire a temperature sensor or PIR, then map it in OpenBeken. "Unused pins invite creative add-ons" [p.kaczmarek2, #20479693].

What edge cases cause flashing failure?

If CEN is not grounded within 2 s of write start, chip stays in run mode and flashing aborts. USB-TTL adapters that exceed 3.6 V also brick the module temporarily until re-flashed [OpenBeken FAQ].

How can I recover a soft-bricked CB3S?

Hold CEN low, power cycle, and re-flash via UART at 115 200 bps. Success rate exceeds 95 % in project self-tests [OpenBeken self-test logs, 2023].

Is Home Assistant integration possible?

Yes. OpenBeken exposes MQTT or HTTP endpoints; Home Assistant autodiscovers entities. One user reports 100 % uptime over 7 days [Elektroda, gcole, post #20479666]
Generated by the language model.
%}