logo elektroda
logo elektroda
X
logo elektroda

[BK7231N - CBU] Avatto - 2 Gang Wi-Fi Switch Module

Weafyr 1974 1

TL;DR LABEL_AI_GENERATED

  • Avatto WSM16-2 2 Gang Wi‑Fi Switch module uses a BK7231N chip on a CBU board.
  • The teardown exposes the internal pin mapping, including WifiLED_n, Btn_Tgl_All, TglChanOnTgl for both channels, and relay outputs.
  • The profile lists model WSM16-2, chip BK7231N, board CBU, and pins 6, 8, 14, 16, 17, and 20.
  • Flashing succeeded with BK7231GUIFlashTool and pinout diagrams from the referenced thread.
  • One device was burned by accident, but the internals of both units were identical.
AI summary based on the discussion. May contain errors.
ADVERTISEMENT
Listen:
  • Hi there,
    I present you teardown and profile for this switch module

    [BK7231N - CBU] Avatto - 2 Gang Wi-Fi Switch Module

    Brand: Avatto
    Name: 2 Gang Wi-Fi Switch module
    Model: WSM16-2
    Chip: BK7231N
    Board: CBU

    This is the listing where I bought it:
    AliExpress - AVATTO Online Store
    AliExpress - AVATTO Official Store
    Yes, I bought 2 devices, but then I have burned one of them by accident, however, the internals are identical.

    Teardown photos:
    [BK7231N - CBU] Avatto - 2 Gang Wi-Fi Switch Module [BK7231N - CBU] Avatto - 2 Gang Wi-Fi Switch Module
    [BK7231N - CBU] Avatto - 2 Gang Wi-Fi Switch Module [BK7231N - CBU] Avatto - 2 Gang Wi-Fi Switch Module [BK7231N - CBU] Avatto - 2 Gang Wi-Fi Switch Module

    Flashing successful using BK7231GUIFlashTool and pin out diagrams from this thread.

    Profile export:
    
    {
      "vendor": "Avatto (Tuya)",
      "bDetailed": "0",
      "name": "2 Gang Wi-Fi Switch module",
      "model": "WSM16-2",
      "chip": "BK7231N",
      "board": "CBU",
      "flags": "1024",
      "keywords": [
        "TODO",
        "TODO",
        "TODO"
      ],
      "pins": {
        "6": "WifiLED_n;0",
        "8": "Btn_Tgl_All;0",
        "14": "TglChanOnTgl;1",
        "16": "TglChanOnTgl;2",
        "17": "Rel;2",
        "20": "Rel;1"
      },
      "command": "",
      "image": "https://obrazki.elektroda.pl/7874363900_1685534454.png",
      "wiki": "https://www.elektroda.com/rtvforum/viewtopic.php?p=20601089"
    }
    

    Cool? Ranking DIY
    About Author
    Weafyr
    Level 4  
    Offline 
    Weafyr wrote 6 posts with rating 2, helped 1 times. Live in city Brandýs nad Labem. Been with us since 2023 year.
  • ADVERTISEMENT
  • #2 20603483
    Weafyr
    Level 4  
    Posts: 6
    Help: 1
    Rate: 2
    Sorry for using wrong forum, @p.kaczmarek2 can you please move this thread in to Teardown forum?
Listen:

FAQ LABEL_AI_GENERATED

TL;DR: 6 configured pins and “Flashing successful” make this FAQ useful for Avatto WSM16-2 owners who need the BK7231N CBU OpenBeken profile, relay mapping, and teardown references without guessing GPIO roles. [#20601089] Why it matters: The posted profile maps both relays, both toggle inputs, one all-toggle button, and the Wi-Fi LED for a 2-gang Tuya-based Avatto module.

Option Thread-specific value
Avatto Online Store One AliExpress listing used for purchase
Avatto Official Store Second AliExpress listing used for purchase
Hardware result The two purchased devices had identical internals

Key insight: The Avatto WSM16-2 profile is usable because the teardown identifies the exact chip as BK7231N and the board as CBU. The critical mapping is relay 1 on pin 20 and relay 2 on pin 17.

Quick Facts

  • Brand and device: Avatto 2 Gang Wi-Fi Switch Module, model WSM16-2, shown with teardown photos. [#20601089]
  • Core platform: BK7231N chip on a CBU board, matching the profile export. [#20601089]
  • OpenBeken pin map includes 6 entries: pins 6, 8, 14, 16, 17, and 20. [#20601089]
  • Output mapping: relay channel 1 uses pin 20, while relay channel 2 uses pin 17. [#20601089]
  • Flashing was reported successful with BK7231GUIFlashTool and pinout diagrams from a referenced thread. [#20601089]

How do I flash an Avatto WSM16-2 2 Gang Wi-Fi Switch Module with a BK7231N CBU board using BK7231GUIFlashTool?

Flash it with BK7231GUIFlashTool using the BK7231N CBU pinout diagrams referenced in the thread.
  1. Open the module and identify the CBU board.
  2. Use BK7231GUIFlashTool with the referenced pinout diagrams.
  3. Apply the exported profile after flashing. The author reported “Flashing successful” for the Avatto WSM16-2 on 2023-05-31. [#20601089]

What is the correct OpenBeken pin configuration for the Avatto WSM16-2 2 Gang Wi-Fi Switch Module?

Use the posted 6-pin OpenBeken profile for the Avatto WSM16-2. Configure pin 6 as WifiLED_n channel 0, pin 8 as Btn_Tgl_All channel 0, pin 14 as TglChanOnTgl channel 1, pin 16 as TglChanOnTgl channel 2, pin 17 as Rel channel 2, and pin 20 as Rel channel 1. The profile also lists flags value 1024. [#20601089]

What is the BK7231N chip used in the Avatto 2 Gang Wi-Fi Switch Module?

The BK7231N is the chip identified inside the Avatto WSM16-2 2 Gang Wi-Fi Switch Module. "BK7231N is the wireless microcontroller chip that runs the switch module firmware, identified in this teardown as the device chip on a CBU board." The thread’s profile export lists chip “BK7231N” and board “CBU” for model WSM16-2. [#20601089]

What is a CBU board in Tuya-based Wi-Fi switch modules?

The CBU board is the board type found in this Avatto WSM16-2 module. "CBU is a Tuya-style module board that carries the BK7231N platform, used here as the Wi-Fi switch module’s main control board." The teardown lists board “CBU” and chip “BK7231N” as separate hardware identifiers. [#20601089]

Which GPIO pins control the relays, buttons, and Wi-Fi LED on the Avatto WSM16-2 BK7231N module?

Pins 20 and 17 control the two relays, while pins 8, 14, and 16 handle switch inputs. Pin 20 is Rel channel 1, and pin 17 is Rel channel 2. Pin 8 is Btn_Tgl_All channel 0. Pin 14 is TglChanOnTgl channel 1, and pin 16 is TglChanOnTgl channel 2. Pin 6 is WifiLED_n channel 0. [#20601089]

Where can I find teardown photos and internal details for the Avatto WSM16-2 2 Gang Wi-Fi Switch Module?

Find the teardown photos and internal details in the Elektroda post dated 2023-05-31. The post shows multiple teardown images and identifies the brand as Avatto, model as WSM16-2, chip as BK7231N, and board as CBU. It also includes the profile export and image URL for the module. [#20601089]

What does the OpenBeken role Btn_Tgl_All mean in a two-gang Wi-Fi switch configuration?

Btn_Tgl_All is assigned to pin 8 with channel 0 in this two-gang profile. "Btn_Tgl_All is an OpenBeken button role that toggles all configured channels together, rather than addressing only relay channel 1 or channel 2." In this WSM16-2 mapping, it sits alongside two individual TglChanOnTgl inputs. [#20601089]

How should TglChanOnTgl be configured for two external wall switch inputs on an Avatto WSM16-2?

Configure TglChanOnTgl on pin 14 for channel 1 and pin 16 for channel 2. "TglChanOnTgl is an OpenBeken input role that toggles a selected channel when the input toggles, making it suitable for external wall switch contacts." This profile uses exactly 2 TglChanOnTgl entries for the 2-gang module. [#20601089]

What is BK7231GUIFlashTool and how is it used for Tuya BK7231N devices?

BK7231GUIFlashTool is the flashing tool the author used successfully on this BK7231N CBU device. "BK7231GUIFlashTool is a graphical flashing utility for BK7231 devices that writes compatible firmware when the correct pinout is used." The thread specifically names BK7231GUIFlashTool and references external pinout diagrams for the flashing step. [#20601089]

What is OpenBeken and why is it used on BK7231N smart switch modules?

OpenBeken is the firmware profile target implied by the exported BK7231N pin-role configuration. "OpenBeken is alternative firmware for BK7231-based smart devices that maps hardware pins to roles such as relays, buttons, and LEDs." In this case, the profile defines 6 pins for a 2-gang Avatto WSM16-2 module. [#20601089]

Avatto Online Store vs Avatto Official Store on AliExpress: which listing should I use for the WSM16-2 module?

Use either listing only after confirming the product matches Avatto WSM16-2 with BK7231N and CBU. The author bought 2 devices through Avatto Online Store and Avatto Official Store links. The internals were identical, even though one device was accidentally burned during handling. [#20601089]

What precautions help avoid burning or damaging an Avatto WSM16-2 module during teardown or flashing?

Avoid wiring mistakes and verify the BK7231N CBU pinout before flashing. The thread reports one of 2 purchased devices was accidentally burned, while the other was flashed successfully. Treat that as the main failure case. Confirm the board, chip, and pinout diagrams before connecting any flashing tool. [#20601089]

How can I identify whether my Avatto 2 Gang Wi-Fi Switch Module uses BK7231N rather than another Tuya chip?

Open the module and compare the internal board and chip markings with the teardown details. The posted device is Avatto WSM16-2, with chip “BK7231N” and board “CBU.” The profile export repeats both values, so the hardware identification and firmware profile agree on 2 separate fields. [#20601089]

What should I check when flashing succeeds but the relays or buttons do not work on a BK7231N CBU switch module?

Check the 6-pin role map first, especially relay pins 20 and 17. A successful flash still needs the correct profile. Set pin 20 to Rel channel 1, pin 17 to Rel channel 2, pin 14 to TglChanOnTgl channel 1, pin 16 to TglChanOnTgl channel 2, pin 8 to Btn_Tgl_All channel 0, and pin 6 to WifiLED_n channel 0. [#20601089]

How do I move or request moving an Elektroda forum post to the Teardown forum when it was posted in the wrong section?

Ask a forum moderator to move the thread to the Teardown forum. On 2023-06-02, the author apologized for using the wrong forum and requested moving the thread into the Teardown forum. The post names the requested destination as “Teardown forum” and asks a moderator directly. [#20603483]
AI summary based on the discussion. May contain errors.
ADVERTISEMENT