Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Controlling LED strip with WB3L chip not possible #1509

Open
xTreame opened this issue Jan 13, 2025 · 11 comments
Open

Controlling LED strip with WB3L chip not possible #1509

xTreame opened this issue Jan 13, 2025 · 11 comments

Comments

@xTreame
Copy link

xTreame commented Jan 13, 2025

i'm not sure if this is the right place for this

Yesterday I flashed OpenBeken on my WB3L (https://docs.libretiny.eu/boards/wb3l/#usage) chip. The chip is in a Meko LED Driver (MKP006C0160BLTG)
An LED strip is connected to it (RGBWC)
I have tried several configurations in Openbeken, including the GPIO Doctor. But the LED strip does not respond. It hangs on the same color that was set with the old/original firmware.
An important info! There is another chip installed on the back. This is probably for the 2.4GHz remote control.
Do you have any experience with this? Do I have to set the config in OpenBeken to control the other chip? I just don't know how.

Thank you!

@xTreame
Copy link
Author

xTreame commented Jan 13, 2025

image
image
image

@xTreame
Copy link
Author

xTreame commented Jan 13, 2025

@ataa
Copy link
Contributor

ataa commented Jan 13, 2025

What is the App name? In case it's a Tuya device, you can dump the firmware and read the device configuration using GUIFlasher or ltchiptool. I am not familiar with the Telink chip but if it's a Tuya device, you might be able to communicate with it using TuyaMCU of OpenBeken.

If you flashed the Openbeken firmware without dumping the factory firmware first, search the forum for the same device, and post the teardown photos there, you'll get help faster.

@xTreame
Copy link
Author

xTreame commented Jan 13, 2025

Thanks for your answer. I dumped the firmware before. But the tool was not able to extract some config (see Screenshot)
image

I will attach the dump
readResult_BK7231T_QIO_2025-12-1-18-32-00.zip

@ataa
Copy link
Contributor

ataa commented Jan 13, 2025

It's a TuyaMCU, I managed to download it's Schema from Tuya using ltchiptool, There are Chinese chars. in the mode names:

{
    "tokenResponse": {
        "expire_time": 300,
        "region": "EU",
        "secret": "63xR",
        "token": "HQolHjv8"
    },
    "deviceApi": "http://a.tuyaeu.com/d.json",
    "activeRequest": {
        "token": "HQolHjv8",
        "productKey": "brvmbe8zlxo0r58x",
        "softVer": "1.1.80",
        "protocolVer": "2.2",
        "baselineVer": "40.00",
        "cadVer": "1.0.2",
        "cdVer": "1.0.0",
        "options": "{\"isFK\":false}",
        "t": 1736773681
    },
    "activeResponse": {
        "capability": 1,
        "devId": "bf995c6e1f62a3ad46y1gi",
        "dstIntervals": [],
        "localKey": "c~9SP06tz:M<k2)=",
        "resetFactory": false,
        "schema": [
            {
                "mode": "rw",
                "property": {
                    "type": "bool"
                },
                "id": 1,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "range": [
                        "white",
                        "colour",
                        "scene",
                        "scene_1",
                        "scene_2",
                        "scene_3",
                        "scene_4"
                    ],
                    "type": "enum"
                },
                "id": 2,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "min": 12,
                    "max": 255,
                    "scale": 0,
                    "step": 1,
                    "type": "value"
                },
                "id": 3,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "min": 0,
                    "max": 255,
                    "scale": 0,
                    "step": 1,
                    "type": "value"
                },
                "id": 4,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "type": "string",
                    "maxlen": 255
                },
                "id": 5,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "type": "string",
                    "maxlen": 255
                },
                "id": 6,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "type": "string",
                    "maxlen": 255
                },
                "id": 7,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "type": "string",
                    "maxlen": 255
                },
                "id": 8,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "type": "string",
                    "maxlen": 255
                },
                "id": 9,
                "type": "obj"
            },
            {
                "mode": "rw",
                "property": {
                    "type": "string",
                    "maxlen": 255
                },
                "id": 10,
                "type": "obj"
            }
        ],
        "schemaId": "0000002sy5",
        "secKey": "YkCy+/#xa=dz^Ui;",
        "stdTimeZone": "+04:00",
        "timeZone": "+04:00"
    },
    "checkResponse": {
        "error_devices": [],
        "success_devices": [
            {
                "id": "bf995c6e1f62a3ad46y1gi",
                "ip": "2a06:98c0:3600::103",
                "lat": "",
                "lon": "",
                "name": "EBL 6W R120 RGB+CCT RC",
                "online": false,
                "product_id": "brvmbe8zlxo0r58x",
                "uuid": "abc6f37189f2872f"
            }
        ]
    },
    "modelResponse": {
        "model": {
            "modelId": "0000002sy5",
            "services": [
                {
                    "actions": [],
                    "code": "",
                    "description": "",
                    "events": [],
                    "name": "\u9ed8\u8ba4\u670d\u52a1",
                    "properties": [
                        {
                            "abilityId": 1,
                            "accessMode": "rw",
                            "code": "led_switch",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_power2"
                            },
                            "name": "\u5f00\u5173",
                            "typeSpec": {
                                "type": "bool"
                            }
                        },
                        {
                            "abilityId": 2,
                            "accessMode": "rw",
                            "code": "work_mode",
                            "description": "white\uff1a\u767d\u5149\u6a21\u5f0f\uff1bcolour\uff1a\u5f69\u5149\u6a21\u5f0f\uff1bscene\uff1a\u573a\u666f\u6a21\u5f0f\uff1bscene1-4:\u4e0d\u540c\u573a\u666f\u6a21\u5f0f\u5207\u6362\uff1b\u53ef\u6839\u636e\u4ea7\u54c1\u5b9e\u9645\u529f\u80fd\u66f4\u6539\u3002",
                            "extensions": {
                                "iconName": "icon-dp_mode"
                            },
                            "name": "\u6a21\u5f0f",
                            "typeSpec": {
                                "type": "enum",
                                "range": [
                                    "white",
                                    "colour",
                                    "scene",
                                    "scene_1",
                                    "scene_2",
                                    "scene_3",
                                    "scene_4"
                                ]
                            }
                        },
                        {
                            "abilityId": 3,
                            "accessMode": "rw",
                            "code": "bright_value",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_light"
                            },
                            "name": "\u4eae\u5ea6",
                            "typeSpec": {
                                "type": "value",
                                "max": 255,
                                "min": 12,
                                "scale": 0,
                                "step": 1,
                                "unit": ""
                            }
                        },
                        {
                            "abilityId": 4,
                            "accessMode": "rw",
                            "code": "temp_value",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_sun"
                            },
                            "name": "\u51b7\u6696",
                            "typeSpec": {
                                "type": "value",
                                "max": 255,
                                "min": 0,
                                "scale": 0,
                                "step": 1,
                                "unit": ""
                            }
                        },
                        {
                            "abilityId": 5,
                            "accessMode": "rw",
                            "code": "colour_data",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_light2"
                            },
                            "name": "\u5f69\u5149\u6a21\u5f0f\u6570",
                            "typeSpec": {
                                "type": "string",
                                "maxlen": 255
                            }
                        },
                        {
                            "abilityId": 6,
                            "accessMode": "rw",
                            "code": "scene_data",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_direction"
                            },
                            "name": "\u60c5\u666f\u6a21\u5f0f\u6570",
                            "typeSpec": {
                                "type": "string",
                                "maxlen": 255
                            }
                        },
                        {
                            "abilityId": 7,
                            "accessMode": "rw",
                            "code": "flash_scene_1",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_flower"
                            },
                            "name": "\u67d4\u5149\u6a21\u5f0f",
                            "typeSpec": {
                                "type": "string",
                                "maxlen": 255
                            }
                        },
                        {
                            "abilityId": 8,
                            "accessMode": "rw",
                            "code": "flash_scene_2",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_dust"
                            },
                            "name": "\u7f24\u7eb7\u6a21\u5f0f",
                            "typeSpec": {
                                "type": "string",
                                "maxlen": 255
                            }
                        },
                        {
                            "abilityId": 9,
                            "accessMode": "rw",
                            "code": "flash_scene_3",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_puzzle"
                            },
                            "name": "\u70ab\u5f69\u6a21\u5f0f",
                            "typeSpec": {
                                "type": "string",
                                "maxlen": 255
                            }
                        },
                        {
                            "abilityId": 10,
                            "accessMode": "rw",
                            "code": "flash_scene_4",
                            "description": "",
                            "extensions": {
                                "iconName": "icon-dp_smile"
                            },
                            "name": "\u6591\u6593\u6a21\u5f0f",
                            "typeSpec": {
                                "type": "string",
                                "maxlen": 255
                            }
                        }
                    ]
                }
            ]
        }
    },
    "errors": [],
    "detailsResponse": {
        "active_time": 1736773682,
        "category": "dj",
        "category_name": "Light Source",
        "gateway_id": "",
        "icon": "smart/icon/ay1553779747140i6L1V/26ccdf3746f00ce82feeb7b6f19a4bb3.jpg",
        "id": "bf995c6e1f62a3ad46y1gi",
        "ip": "2a06:98c0:3600::103",
        "lat": "",
        "local_key": "c~9SP06tz:M<k2)=",
        "lon": "",
        "model": "309302TF,309306TF",
        "name": "EBL 6W R120 RGB+CCT RC",
        "online": false,
        "owner_id": "219857651",
        "product_id": "brvmbe8zlxo0r58x",
        "sub": false,
        "time_zone": "+04:00",
        "uuid": "abc6f37189f2872f"
    },
    "updateResponse": [
        {
            "channel": 0,
            "control_type": 0,
            "current_version": "1.1.80",
            "dev_type": 0,
            "last_upgrade_time": 0,
            "timeout": 0,
            "type": 0,
            "type_desc": "Main Module",
            "upgrade_status": 0
        }
    ],
    "deleteResponse": true,
    "cachedAt": 1736773685193,
    "cacheKey": "brvmbe8zlxo0r58x"
}

@ataa
Copy link
Contributor

ataa commented Jan 13, 2025

tuya

uart:
  rx_pin: RX1
  tx_pin: TX1
  baud_rate: 9600

tuya:
  # DPIDs processed from schema model: 0000002sy5

switch:
  - platform: tuya
    switch_datapoint: 1
    name: (Unconfirmed) Led Switch

select:
  - platform: tuya
    enum_datapoint: 2
    name: (Unconfirmed) Work Mode
    optimistic: true
    options:
      0: White
      1: Colour
      2: Scene
      3: Scene_1
      4: Scene_2
      5: Scene_3
      6: Scene_4

number:
  - platform: tuya
    number_datapoint: 3
    name: (Unconfirmed) Bright Value
    min_value: 12
    max_value: 255
    step: 1
  - platform: tuya
    number_datapoint: 4
    name: (Unconfirmed) Temp Value
    min_value: 0
    max_value: 255
    step: 1

@xTreame
Copy link
Author

xTreame commented Jan 13, 2025

Thanks!

I asked ChatGPT to translate the chinese symbols

开关 - Switch (On/Off)
模式 - Mode
亮度值 - Brightness value
冷暖 - Cool/Warm (Color temperature)
彩光模式数据 - Color light mode data
情景模式数据 - Scene data
炫彩模式 1 - Flash scene 1 (or: Colorful mode 1)
炫彩模式 2 - Flash scene 2 (or: Colorful mode 2)
炫彩模式 3 - Flash scene 3 (or: Colorful mode 3)
炫彩模式 4 - Flash scene 4 (or: Colorful mode 4)

@ataa
Copy link
Contributor

ataa commented Jan 13, 2025

@xTreame
Copy link
Author

xTreame commented Jan 13, 2025

For the first test i added the autoexec.bat with this configuration

startDriver TuyaMCU
setChannelType 1 toggle
linkTuyaMCUOutputToChannel 1 1 1

I'm now able to turn LED strip on/off

@divadiow
Copy link
Contributor

Please consider posting your findings to a new thread on Elektroda.

@openshwprojects
Copy link
Owner

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants