devices.esphome.io
Connect SmartHome Wi-Fi Plug with USB Ports (CSH-PLGUSB)
Connect SmartHome Wi-Fi Plug with USB Ports (CSH-PLGUSB)
Device Type: plugElectrical Standard: auBoard: bk72xx
General Notes
Connect SmartHome Wi-Fi Plug with USB Ports
      
  
        
This contains a Tuya Beken Chip WB2S which can be flashed with ESPHome and a USB to UART converter by soldering to the chip's RX, TX, VCC and GND pins.
It might be possible to flash (especially older units) OTA using tuya-convert. If you attempt to flash a current unit OTA, you should update this page specify if it's still possible or not.
Basic Configuration
esphome:  name: smart-plug  name_add_mac_suffix: true
wifi:  ssid: !secret wifi_ssid  password: !secret wifi_password  ap:    ssid: 'downlight'    password: 'ap_password'
# Enable logginglogger:
# Enable Home Assistant APIapi:  encryption:    key: !secret encryption_key
ota:  password: 'ota_password'
# Platformbk72xx:  board: wb2s
# Buttonbinary_sensor:  - platform: gpio    pin:      number: P10      inverted: true    name: 'Push Button'    on_press:      then:        - homeassistant.event:            event: esphome.button_pressed
# Switchswitch:  - platform: gpio    pin: P26    name: 'Switch'