logo elektroda
logo elektroda
X
logo elektroda

[BK7231N on board] Flashing Anko Sunset Lamp (I004055) RGB LED lamp controller

lyonzy 
Anko WiFi RGB Sunset Lamp with packaging and product features.
This is a lamp sold by Kmart in Australia. Seems to be made by Mirabella but exclusively for the Kmart Anko brand. It went a bit nuts on TikTok late last year.
User manual:
User manual for the ANKO Smart Wi-Fi Sunset Lamp. Mirabella Genio app setup screen for pairing Sunset Lamp with Wi-Fi network. Screenshots of the pairing process for the Kmart Anko lamp with the Mirabella Genio app. Wi-Fi RGB lamp connection instruction.

Good news is (1) it's a 5v device (powered by USB) and (2) it's running a BK7231N inside. Doesn't seem to be a SoC/ESP type chip, just the BK7231N directly on a circuit board. Even more good news is that most of the pins are exposed and labelled on the underside of the board.

Photos:
View of an RGB LED lamp circuit board with attached wires. Printed circuit board with wires and electronics on a white background. Electronic circuit board with visible connections and a button.
Pin roles:
- P20 - button
- P6 - PWM (red)
- P7 - PWM (green)
- P8 - PWM (blue)

I was able to flash using LTChipTool (remembering to connect CEN to GND when it starts) using TX1 and RX1. Was a bit hit and miss, sometimes it would freeze at 0 or low %, but I eventually read the data from the chip and uploaded binary.

The LED bulbs are all exposed as a single RGB PWM output from the controller (R=6 G=7 B=8). The button on the controller is pin 20, inverted, with pullup active.

OBK Config:
Code: YAML
Log in, to see the code

ESPHome config (snippet, add your own Wifi etc):

binary_sensor:
  - platform: gpio
    name: Button
    pin:
      number: P20
      mode:
        input: true
        pullup: true
      inverted: true


output:
- platform: ledc
  id: output_red
  pin: P6
- platform: ledc
  id: output_green
  pin: P7
- platform: ledc
  id: output_blue
  pin: P8

light:
- platform: rgb
  id: light_rgb
  name: Light
  red: output_red
  green: output_green
  blue: output_blue

About Author
lyonzy wrote 3 posts with rating 3 . Been with us since 2023 year.

Comments

sillychip 21 Jul 2024 08:00

Thanks for posting this! I've got two separate Anko sunset lights flashed now and they're working perfectly! Out of the two I flashed, one was an older revision with a WB3S inside (BK7231T) instead... [Read more]

piotrszulc1 21 Jul 2024 13:28

Hi, could you post the firmware dump here or by creating an issue on tuyacloudcutter repo - then it may be possible to flash this lamp via OTA in the future. [Read more]

sillychip 21 Jul 2024 13:38

Sure thing, is it fine if I hex edit out my WiFi credentials from the dump before uploading? I opened it up in HxD and confirmed I could see my credentials in there. [Read more]

piotrszulc1 21 Jul 2024 16:03

Not sure about this, as it might change the checksums and then the tools for creating cloudcutter profile might fail. But that's only my guess, go ahead and post it without the credentials and we'll see... [Read more]

sillychip 21 Jul 2024 16:15

Here's the file, hoping just replacing the SSID and password chars with bogus data should be fine. If it doesn't work let me know and I'll try get a fresh copy by flashing the original firmware back to... [Read more]

divadiow 21 Jul 2024 17:38

flashed fine for me to a WB3S. V:BK7231S_1.0.5 CPSR:000000D3 R0:1F6FFE41 R1:2223F356 R2:F9ABF3BE R3:7B3DEA2C R4:7F5E3AB8 R13:EFAE59FF R14(LR):07E73BEF ST:14968466 J 0x10000 prvHeapInit-start... [Read more]

sillychip 22 Jul 2024 04:18

Nice, thanks for checking that out! Although I just realised something: that light was behaving very oddly last night after I uploaded the dump, doing stuff like flickering and turning off. Could that... [Read more]

divadiow 22 Jul 2024 08:38

negative, this would not be possible. A coincidence. [Read more]

sillychip 22 Jul 2024 08:55

Thanks for confirming, I thought as much, but I just wanted to make sure. Edit: found the reason it was misbehaving, it was only because the USB extension cable it was plugged into wasn't making the... [Read more]

%}