logo elektroda
logo elektroda
X
logo elektroda

Cozylife DS-1211AN 3Gang Touch Switch: 1MB BL602L10 [XT-BL12][DT-BL12] - Images, Firmware & Boot

divadiow 3699 119
ADVERTISEMENT
  • #61 21438596
    divadiow
    Level 35  
    indeed. excellent work!

    Added after 6 [minutes]:

    I wonder how many drivers we can get enabled. CHT83xx seems to be the most obvious one to include with a couple of posts now for devices with it in.
  • ADVERTISEMENT
  • #62 21438613
    maxim2002
    Level 13  
    FW partition @miegapele PT is 860kB wide.
    Last build File: OpenBL602_dev_20250213_222946.bin
    Size: 793444 Blocks: 1552 IO Block: 4096 regular file
    So we have 85.15kB ?
  • #64 21439705
    p.kaczmarek2
    Moderator Smart Home
    Can we integrate both 1MB and 2MB builds together into Github builds?
    Helpful post? Buy me a coffee.
  • ADVERTISEMENT
  • Helpful post
    #65 21439754
    maxim2002
    Level 13  
    >>21439639 looking good
    Firmware options for OpenBL602 with various configuration file paths and settings.
    Startup
    Code: Text
    Log in, to see the code

    (...)
    Code: Text
    Log in, to see the code

    Also app seems fine.
    OpenBL602 device screen with Not found message
    Screenshot of the OpenBL602 device user interface with status information.
    That basic one is fine, "Launch Web Appliction" link is blank page.
    Not much time today, my missis demans attention ;)
  • #66 21439890
    p.kaczmarek2
    Moderator Smart Home
    Thank you for testing!

    Don't worry about blank page - Web App is a Javascript addon fetched from Github, it's open source obviously, but it won't fetch if you don't have Internet connection.
    Helpful post? Buy me a coffee.
  • #67 21439908
    maxim2002
    Level 13  
    Yah, bell rang just couple of minutes after I've wrote that. Missus sleeps, gonna test some drivers.

    Added after 48 [minutes]:

    We might be doing rw's in incorrect region. When configured with AP credentials, it throws this warning
    [ 7285][WARN : bl_mtd.c: 205] addr@0x230a28cc is xip flash, size 8
    Have a look:
    Code: Text
    Log in, to see the code

    After that, it basically cycles with this:
    Code: Text
    Log in, to see the code

    Tested those creds with my mob, they fine.
  • #68 21439979
    chemik_16
    Level 26  
    cant find toml you guys using ;)

    wrote it with default one, but no response
    
    [00:36:58.248] - Erase flash from 0xe000 to 0xe0a3
    [00:36:58.268] - erase pending
    [00:36:58.378] - Erase time cost(ms): 130.1845703125
    [00:36:58.397] - Load 164/164 {"progress":100}
    [00:36:58.397] - Load 164/164 {"progress":100}
    [00:36:58.397] - Write check
    [00:36:58.415] - Flash load time cost(ms): 19.885498046875
    [00:36:58.416] - Finished
    [00:36:58.417] - Sha caled by host: c88b2a83541a724172d14a153d613705803436a54b93e75d55325bb8659df0da
    [00:36:58.417] - xip mode Verify
    [00:36:58.418] - Read Sha256/164
    [00:36:58.419] - Flash xip readsha time cost(ms): 1.999755859375
    [00:36:58.420] - Finished
    [00:36:58.420] - Sha caled by dev: c88b2a83541a724172d14a153d613705803436a54b93e75d55325bb8659df0da
    [00:36:58.421] - Verify success
    [00:36:58.440] - Dealing Index 2
    [00:36:58.440] - ========= programming chips\bl602\partition\partition.bin to 0x0000F000
    [00:36:58.444] - ========= flash load =========
    [00:36:58.446] - ========= flash erase =========
    [00:36:58.446] - Erase flash from 0xf000 to 0xf0a3
    [00:36:58.464] - erase pending
    [00:36:58.583] - Erase time cost(ms): 136.458251953125
    [00:36:58.601] - Load 164/164 {"progress":100}
    [00:36:58.601] - Load 164/164 {"progress":100}
    [00:36:58.602] - Write check
    [00:36:58.620] - Flash load time cost(ms): 20.178466796875
    [00:36:58.620] - Finished
    [00:36:58.621] - Sha caled by host: c88b2a83541a724172d14a153d613705803436a54b93e75d55325bb8659df0da
    [00:36:58.622] - xip mode Verify
    [00:36:58.623] - Read Sha256/164
    [00:36:58.623] - Flash xip readsha time cost(ms): 1.01123046875
    [00:36:58.623] - Finished
    [00:36:58.624] - Sha caled by dev: c88b2a83541a724172d14a153d613705803436a54b93e75d55325bb8659df0da
    [00:36:58.624] - Verify success
    [00:36:58.645] - Dealing Index 3
    [00:36:58.645] - ========= programming C:\Users\kenavru\Documents\BouffaloLabDevCube-v1.9.0\chips\bl602\img_create_iot\whole_img.bin to 0x00010000
    [00:36:58.650] - ========= flash load =========
    [00:36:58.651] - ========= flash erase =========
    [00:36:58.651] - Erase flash from 0x10000 to 0xd101f
    [00:36:58.669] - erase pending
    [00:36:59.436] - erase pending
    
    ...
    
    [00:37:12.168] - Load 422460/422460 {"progress":100}
    [00:37:12.168] - Write check
    [00:37:12.200] - Flash load time cost(ms): 4641.61669921875
    [00:37:12.200] - Finished
    [00:37:12.206] - Sha caled by host: 7e0443646a348c1091752123402cf8dbb40ab670180b9fe6664156751adeee7f
    [00:37:12.207] - xip mode Verify
    [00:37:12.422] - Read Sha256/790560
    [00:37:12.423] - Flash xip readsha time cost(ms): 215.037353515625
    [00:37:12.423] - Finished
    [00:37:12.424] - Sha caled by dev: 7e0443646a348c1091752123402cf8dbb40ab670180b9fe6664156751adeee7f
    [00:37:12.424] - Verify success
    [00:37:12.441] - Dealing Index 4
    [00:37:12.441] - ========= programming chips\bl602\device_tree\ro_params.dtb to 0x000FB000
    [00:37:12.445] - ========= flash load =========
    [00:37:12.446] - ========= flash erase =========
    [00:37:12.447] - Erase flash from 0xfb000 to 0xfc75d
    [00:37:12.463] - erase pending
    [00:37:12.531] - erase pending
    [00:37:12.649] - Erase time cost(ms): 201.883056640625
    [00:37:12.667] - decompress write rx timeout: 12.288
    [00:37:12.688] - decompress flash load 1584
    [00:37:12.697] - Load 1584/1584 {"progress":100}
    [00:37:12.698] - Load 1584/1584 {"progress":100}
    [00:37:12.701] - Write check
    [00:37:12.741] - Flash load time cost(ms): 73.89404296875
    [00:37:12.742] - Finished
    [00:37:12.743] - Sha caled by host: 2030ce2a98174d1e1bc02905472a5c55ff0df9d7274c49efd787982af2430e58
    [00:37:12.743] - xip mode Verify
    [00:37:12.746] - Read Sha256/5982
    [00:37:12.746] - Flash xip readsha time cost(ms): 2.005859375
    [00:37:12.747] - Finished
    [00:37:12.748] - Sha caled by dev: 2030ce2a98174d1e1bc02905472a5c55ff0df9d7274c49efd787982af2430e58
    [00:37:12.748] - Verify success
    [00:37:12.766] - Program Finished
    [00:37:12.767] - All time cost(ms): 18943.44140625
    [00:37:12.870] - close interface
    [00:37:12.871] - [All Success]


    plus - mine looks like have Boot mode all the time, i shorted io8 to 3v3 just once, since then any power-off-on is still in boot mode - fw doesnt load.

    also no logs
    [00:44:21.262] - Flash load shake hand
    [00:44:21.303] - default set DTR high
    [00:44:21.406] - clean buf
    [00:44:21.440] - send sync
    [00:44:21.654] - ack is 4f4b
    [00:44:25.732] - Not ack OK
    [00:44:25.732] - FL
    [00:44:25.734] - Read log
    [00:44:25.735] - Read Fail
  • ADVERTISEMENT
  • #69 21440030
    miegapele
    Level 15  
    >>21439705
    Yes of couse, but this is based on new sdk, so that needs to be merged first

    Added after 3 [minutes]:

    >>21439908
    I would try different wifi device, different protection settings, different MPF settings, also try simple password with only letters, somebody had issues with some symbols somewhere.

    Added after 2 [minutes]:

    >>21439979
    Toml file is posted in post #20 in this thread. Not sure if it's really required.
    But it it boots to bootloader I would look for short with multimeter first.
  • #70 21440257
    chemik_16
    Level 26  
    >>21440030
    got 133ohm to the ground from that pin. Had 8k earlier if i remember correctly. maybe connecting 3v3 directly burned pullup.
  • #71 21440260
    divadiow
    Level 35  
    10k resistor should be between 3.3v and IO8 for uart download mode
  • Helpful post
    #72 21440301
    p.kaczmarek2
    Moderator Smart Home
    I have this board, NodeMCU-series Ai-WB-12F-Kit R237.
    
    The module is equipped with BL602 chip as the core processor and supports Wi-Fi 802.11b/ g/n protocol and BLE 5.0 protocol. 
    

    The BURN button seems to be connected on one side directly to one of pins (IO8?) and second side is connected to VDD via 4.7k resistance. From IO8 to ground, I have 32k.

    I am not sure about that resistor requirement but it seems to be obeyed on the proto board I have. I don't even remember if I respected the resistance requirement in the past.... but I didn't brick any BL602 as far as I know. Or at least... I didn't brick them that way.
    Helpful post? Buy me a coffee.
  • #74 21440354
    chemik_16
    Level 26  
    >>21440260
    then mine is bricked, got 3.1V there when powered on, when off as said 133om to ground.

    just shortened it to the ground for test, now i got 540ohm and no longer im in download mode (0.001V now), now i have to pull 3v3 to flash it.
    Anyway, cant see it booting, is there any log on serial ? what boundrate ? its silent for me.
    just opening com, powercycle, nothing.

    Software interface for microcontroller flashing with settings and logs.
  • #75 21440420
    p.kaczmarek2
    Moderator Smart Home
    Do anyone know if it will actually output anything if wrong binary is flashed?
    Helpful post? Buy me a coffee.
  • #76 21440513
    maxim2002
    Level 13  
    Yes, if bootloader with debug selected you should see at least this
    Code: Text
    Log in, to see the code


    Added after 10 [minutes]:

    Ok, so I've configured AP with pretty much basic settings. Nothing fancy...
    Code: Text
    Log in, to see the code

    Scan finds the network
    Code: Text
    Log in, to see the code

    Config save and reboot:
    Code: Text
    Log in, to see the code

    Wifi init and connect attempt:
    Code: Text
    Log in, to see the code

    Obviously it loops with that.
    AP radio debug log shows this:
    Code: Text
    Log in, to see the code

    Will try open network next.

    Added after 10 [minutes]:

    With open network it doesn't even tries to connect.
    Code: Text
    Log in, to see the code

    AP wifi log remains quiet.

    Added after 3 [minutes]:

    >>21440260 Not really, found that even without that 10k it still enters download mode and successfully flashes.

    Added after 11 [minutes]:

    Attached toml I'm using, on standard 1M one it has issues.
    Code: Text
    Log in, to see the code

    After reboot:
    Code: Text
    Log in, to see the code
  • ADVERTISEMENT
  • #77 21440834
    miegapele
    Level 15  
    >>21440513
    Yes, Open wifi is not working I tested that while porting, I think it might be possible to make it work, but did not try.

    While porting I had to set some PMF setting on the connect call to make connection reliable. Maybe you can try changing PMF on your router if It has such ability:
    It worked I think with all options for me.

    Wireless network security configuration on a router.

    Also try maybe WPA1 or WPA3.

    I tried to flash build from github form 1mb devices on my 2mb module and it works just fine:
    
    ÿcustom 0x0
    flash init 0
    Boot2 start:Jan 17 2024,10:46:48
    Group=1,CPU Count=1
    ver:6.6.1
    user_fw 
    Active PT:0,Age 0
    MFG not found
    entry ID 0 found
    pass param addr 42049c00,len 4
    pass param addr 42049c04,len 164
    pass param addr 42049ca8,len 92
    Boot start
    Media boot main
    R header from 10000
    Cal hash addr 0x11000,len 789440
    Hash Success
    ps_mode 0,efuse hbn_check_sign 0
    group[0] offset 11000 ,core[0] offset 0 bootentry 23000000
    Counter value=87
    Starting bl602 now....
    Booting BL602 Chip...
    ██████╗ â–ˆâ–ˆâ•—      â–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ•—  â–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ•— â–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ•—
    
    ██╔══██╗██║     â–ˆâ–ˆâ•”════╝ â–ˆâ–ˆâ•”═████╗╚════██╗
    
    ██████╔╝██║     â–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ•— â–ˆâ–ˆâ•‘██╔██║ â–ˆâ–ˆâ–ˆâ–ˆâ–ˆâ•”╝
    
    ██╔══██╗██║     â–ˆâ–ˆâ•”═══██╗████╔╝██║██╔═══╝
    
    ██████╔╝███████╗╚██████╔╝╚██████╔╝███████╗
    
    ╚═════╝ â•šâ•â•â•â•â•â•â• â•šâ•â•â•â•â•â•  â•šâ•â•â•â•â•â• â•šâ•â•â•â•â•â•â•
    
    
    
    ------------------------------------------------------------
    RISC-V Core Feature:RV32-ACFIMX
    Build Version: release_bl_iot_sdk_1.6.39-238-gf5ba0a7ee
    Build Date: Feb 14 2025
    Build Time: 18:04:22
    ------------------------------------------------------------
    
    blog init set power on level 2, 2, 2.
    [IRQ] Clearing and Disable all the pending IRQ...
    [         0][INFO: hal_boot2.c: 282] [HAL] [BOOT2] Active Partition[0] consumed 596 Bytes
    [         0][INFO: hal_boot2.c:  82] ======= PtTable_Config @0x4200f2c0=======
    [         0][INFO: hal_boot2.c:  83] magicCode 0x54504642; version 0x0000; entryCnt 4; age 0; crc32 0x944BE888
    [         0][INFO: hal_boot2.c:  89] idx  type device activeIndex     name   Address[0]  Address[1]  Length[0]   Length[1]   age
    [         0][INFO: hal_boot2.c:  91] [00]  00     0         0            FW  0x00010000  0x00000000  0x000d7000  0x00000000  0
    [         0][INFO: hal_boot2.c:  91] [01]  03     0         0         media  0x001e7000  0x00000000  0x00002000  0x00000000  0
    [         0][INFO: hal_boot2.c:  91] [02]  04     0         0           PSM  0x000e9000  0x00000000  0x00008000  0x00000000  0
    [         0][INFO: hal_boot2.c:  91] [03]  07     0         0       factory  0x000f1000  0x00000000  0x00007000  0x00000000  0
    [         0][INFO: bl_flash.c: 391] ======= FlashCfg magiccode @0x42049c18=======
    [         0][INFO: bl_flash.c: 392] mid       0xEF
    [         0][INFO: bl_flash.c: 393] clkDelay    0x1
    [         0][INFO: bl_flash.c: 394] clkInvert    0x1
    [         0][INFO: bl_flash.c: 395] sector size   4KBytes
    [         0][INFO: bl_flash.c: 396] page size   256Bytes
    [         0][INFO: bl_flash.c: 397] ---------------------------------------------------------------
    [         0][INFO: hal_board.c:1249] [MAIN] [BOARD] [FLASH] addr from partition is 000f1000, ret is 0
    [         0][INFO: hal_board.c:1257] [MAIN] [BOARD] [XIP] addr from partition is 230e0000, ret is 0
    [         0][INFO: hal_board.c: 208] MAC address mode length 3
    [         0][INFO: hal_board.c: 212] MAC address mode is MBF
    Read slot:0
    [         0][INFO: hal_board.c: 187] Set MAC addrress 18:B9:05:C3:20:ED
    [         0][INFO: hal_board.c: 955] country_code : 86
    [         0][INFO: hal_board.c: 342] xtal_mode is MF
    Read slot:0
    [         0][INFO: hal_board.c: 374] get xtal from M ready 29 29 1 60 60
    [         0][INFO: hal_board.c: 846] pwr_table_11b :20 20 20 18
    [         0][INFO: hal_board.c: 860] pwr_table_11g :18 18 18 18 18 18 14 14
    [         0][INFO: hal_board.c: 878] pwr_table_11n :18 18 18 18 18 16 14 14
    No written slot found
    [         0][BUF: hal_board.c: 606]   0   0   0   0   0   0   0   0   0   0   0   0   0   0 
    [         0][INFO: hal_board.c: 902] set pwr_table_ble = 13 in dts
    [         0][INFO: hal_board.c: 687] ap_ssid string[0] = bl_test_005, ap_ssid_len = 11
    [         0][INFO: hal_board.c: 698] ap_psk string[0] = 12345678, ap_psk_len = 8
    [         0][INFO: hal_board.c: 707] ap_channel = 11
    [         0][INFO: hal_board.c: 635] [STA] ap_ssid string[0] = yourssid, ap_ssid_len = 8
    [         0][INFO: hal_board.c: 646] [STA] ap_psk string[0] = yourapssword, ap_psk_len = 12
    [         0][INFO: hal_board.c: 654] auto_connect_enable = 0
    [         0][INFO: hal_board.c: 749] Troom_os = -1, lentmp = 4
    [         0][INFO: hal_board.c: 758] linear_or_follow = 1, lentmp = 4
    [         0][INFO: hal_board.c: 767] Tchannels:2412,2427,2442,2457,2472,
    [         0][INFO: hal_board.c: 781] Tchannel_os:180,168,163,160,157,
    [         0][INFO: hal_board.c: 795] Tchannel_os_low:199,186,170,165,160,
    [         0][INFO: hal_board.c: 808] en_tcal = 0, lentmp = 4
    [OS] Starting aos_loop_proc task...
    [OS] Starting OS Scheduler...
    [MTD] >>>>>> Hanlde info Dump >>>>>>
          name PSM
          id 0
          offset 0x000e9000(954368)
          size 0x00008000(32Kbytes)
          xip_addr 0x230d8000
    [MTD] <<<<<< Hanlde info End <<<<<<
    [EF] Found Valid PSM partition, XIP Addr 230d8000, flash addr 000e9000, size 32768
    ENV AREA SIZE 32768, SECTOR NUM 8
    *default_env_size = 0x00000001
    ENV start address is 0x00000000, size is 32768 bytes.
    EasyFlash V4.0.99 is initialize success.
    You can get the latest version on https://github.com/armink/EasyFlash .
    [MTD] >>>>>> Hanlde info Dump >>>>>>
          name media
          id 0
          offset 0x001e7000(1994752)
          size 0x00002000(8Kbytes)
          xip_addr 0x231d6000
    [MTD] <<<<<< Hanlde info End <<<<<<
    [        53][ERROR : bl_romfs.c: 158] romfs magic is NOT correct
    [       214][INFO  : hosal_adc.c: 459] offset = 2210
    [       214][INFO  : hosal_adc.c: 233] ADC freq: 284Hz. div:6
    [OS] Starting proc_mian_entry task...
    [OS] Starting TCP/IP Stack...
    -------------------->>>>>>>> LWIP tcp_port 61886
    [MTD] >>>>>> Hanlde info Dump >>>>>>
          name PSM
          id 0
          offset 0x000e9000(954368)
          size 0x00008000(32Kbytes)
          xip_addr 0x230d8000
    [MTD] <<<<<< Hanlde info End <<<<<<
    [EF] Found Valid PSM partition, XIP Addr 230d8000, flash addr 000e9000, size 32768
    ENV AREA SIZE 32768, SECTOR NUM 8
    *default_env_size = 0x00000001
    EasyFlash V4.0.99 is initialize success.
    You can get the latest version on https://github.com/armink/EasyFlash .
    Start Wi-Fi fw @254ms
    1th channel,lo_vco_freq_cw=160
    2th channel,lo_vco_freq_cw=159
    3th channel,lo_vco_freq_cw=157
    4th channel,lo_vco_freq_cw=156
    5th channel,lo_vco_freq_cw=155
    6th channel,lo_vco_freq_cw=153
    7th channel,lo_vco_freq_cw=152
    8th channel,lo_vco_freq_cw=151
    9th channel,lo_vco_freq_cw=149
    10th channel,lo_vco_freq_cw=148
    11th channel,lo_vco_freq_cw=147
    12th channel,lo_vco_freq_cw=146
    13th channel,lo_vco_freq_cw=144
    14th channel,lo_vco_freq_cw=143
    15th channel,lo_vco_freq_cw=142
    16h channel,lo_vco_freq_cw=140
    17h channel,lo_vco_freq_cw=139
    18th channel,lo_vco_freq_cw=138
    19th channel,lo_vco_freq_cw=136
    20th channel,lo_vco_freq_cw=135
    21th channel,lo_vco_freq_cw=134
    0th channel,vco_idac_cw=12
    1th channel,vco_idac_cw=12
    2th channel,vco_idac_cw=11
    3th channel,vco_idac_cw=11
    4th channel,vco_idac_cw=11
    5th channel,vco_idac_cw=11
    6th channel,vco_idac_cw=11
    7th channel,vco_idac_cw=11
    8th channel,vco_idac_cw=11
    9th channel,vco_idac_cw=11
    10th channel,vco_idac_cw=11
    11th channel,vco_idac_cw=11
    12th channel,vco_idac_cw=11
    13th channel,vco_idac_cw=11
    14th channel,vco_idac_cw=10
    15th channel,vco_idac_cw=10
    16th channel,vco_idac_cw=10
    17th channel,vco_idac_cw=10
    18th channel,vco_idac_cw=10
    19th channel,vco_idac_cw=10
    20th channel,vco_idac_cw=10
    LO locked 9 149
    rosdac_i_gc3=31
    rosdac_i_gc2=31
    rosdac_i_gc1=31
    rosdac_i_gc0=31
    rosdac_q_gc3=26
    rosdac_q_gc2=26
    rosdac_q_gc1=26
    rosdac_q_gc0=26
    rbb_cap1_fc_i=24,rbb_cap2_fc_i=24,rbb_cap1_fc_q=26,rbb_cap2_fc_q=26
    new rbb_cap1_fc_i=48,rbb_cap2_fc_i=48,rbb_cap1_fc_q=48,rbb_cap2_fc_q=48
    LO locked 9 149
    amp=128,step=32,adc_mean_i=127
    tmx_cs=0, tmxcs_pwr_avg=42725, tmxcs_pwr_avg>>10=41
    tmx_cs=1, tmxcs_pwr_avg=51300, tmxcs_pwr_avg>>10=50
    tmx_cs=2, tmxcs_pwr_avg=62433, tmxcs_pwr_avg>>10=60
    tmx_cs=3, tmxcs_pwr_avg=78488, tmxcs_pwr_avg>>10=76
    tmx_cs=4, tmxcs_pwr_avg=100050, tmxcs_pwr_avg>>10=97
    tmx_cs=5, tmxcs_pwr_avg=130471, tmxcs_pwr_avg>>10=127
    tmx_cs=6, tmxcs_pwr_avg=168201, tmxcs_pwr_avg>>10=164
    tmx_cs=7, tmxcs_pwr_avg=204732, tmxcs_pwr_avg>>10=199
    tmx_cs_max=7, tmxcs_pwr_max=204732, tmxcs_pwr_max>>10=199
    amp=256,step=64,adc_mean_i=511
    amp=192,step=32,adc_mean_i=485
    amp=160,step=16,adc_mean_i=321
    amp=144,step=8,adc_mean_i=232
    tosdac_i=21,tosdac_q=42,tx_iq_gain_comp=1036,tx_iq_phase_comp=-3
    tosdac_i=19,tosdac_q=44,tx_iq_gain_comp=1035,tx_iq_phase_comp=0
    tosdac_i=23,tosdac_q=45,tx_iq_gain_comp=1046,tx_iq_phase_comp=7
    tosdac_i=24,tosdac_q=42,tx_iq_gain_comp=1034,tx_iq_phase_comp=3
    tosdac_i=24,tosdac_q=43,tx_iq_gain_comp=1032,tx_iq_phase_comp=-1
    tosdac_i=21,tosdac_q=42,tx_iq_gain_comp=1020,tx_iq_phase_comp=-8
    tosdac_i=23,tosdac_q=48,tx_iq_gain_comp=1026,tx_iq_phase_comp=0
    tosdac_i=22,tosdac_q=48,tx_iq_gain_comp=1026,tx_iq_phase_comp=6
    [WF] [KEY] [CFG] nVAP is 2, endidx 12, startidx 8
    td_init
    td_reset idx=0
    td_reset idx=1
    Start Wi-Fi fw is Done @328ms
    [APP] [EVT] INIT DONE 293
    
    
    [BL] Initi Wi-Fi with MAC #### 18:B9:05:C3:20:ED ####
         hostname: OpenBL602_05c320ed
    [WF] country code CN used, num of channel 13
    -----------------------------------------------------
    [IPC] [TX] Low level size 204, driver size 100, total size 304
    Enable BMX IRQ
    [WF] [KEY] [CFG] nVAP is 2, endidx 12, startidx 8
    td_init
    td_reset idx=0
    td_reset idx=1
    [version] lmac 5.4.0.0
    [version] version_machw_1 000055FB
    [version] version_machw_2 000001B3
    [version] version_phy_1 00822111
    [version] version_phy_2 00000000
    [version] features 001089DF
    [ME] HT supp 1, VHT supp 0
    [WF][SM] reload tsen 
    [WF][SM] Exiting ifaceDown state
    [WF][SM] State Action ###ifaceDown### --->>> ###idle###
    [WF][SM] Entering idle state
    [APP] [EVT] MGMR DONE 306, now 342ms
    Entering initLog()...
    Commands registered!
    initLog() done!
    [MTD] >>>>>> Hanlde info Dump >>>>>>
          name PSM
          id 0
          offset 0x000e9000(954368)
          size 0x00008000(32Kbytes)
          xip_addr 0x230d8000
    [MTD] <<<<<< Hanlde info End <<<<<<
    [EF] Found Valid PSM partition, XIP Addr 230d8000, flash addr 000e9000, size 32768
    ENV AREA SIZE 32768, SECTOR NUM 8
    *default_env_size = 0x00000001
    EasyFlash V4.0.99 is initialize success.
    You can get the latest version on https://github.com/armink/EasyFlash .
    [       857][WARN  : bl_mtd.c: 205] addr@0x230a1d58 is xip flash, size 8
    [MTD] >>>>>> Hanlde info Dump >>>>>>
          name media
          id 0
          offset 0x001e7000(1994752)
          size 0x00002000(8Kbytes)
          xip_addr 0x231d6000
    [MTD] <<<<<< Hanlde info End <<<<<<
    
    Main_Init_Before_Delay done
    
    Main_Init_Delay
    
    Main_Init_Delay done
    Info:MAIN:Main_Init_Before_Delay
    Warn:CFG:CFG_InitAndLoad: Correct config has been loaded with 2 changes count.
    Error:CMD:lfs is absent
    Info:GEN:PIN_SetupPins pins have been set up.
    Info:MAIN:Main_Init_Before_Delay done
    Info:MAIN:Main_Init_Delay
    Info:MAIN:Main_Init_Delay done
    Info:MAIN:Main_Init_After_Delay
    Info:MAIN:Using SSID [OpenWrt]
    Info:MAIN:Using Pass [labasrytas<>__]
    Info:MQTT:MQTT_RegisterCallback called for bT obl05C320ED/ subT obl05C320ED/+/set
    Info:MQTT:MQTT_RegisterCallback called for bT bl602s/ subT bl602s/+/set
    Info:MQTT:MQTT_RegisterCallback called for bT cmnd/obl05C320ED/ subT cmnd/obl05C320ED/+
    Info:MQTT:MQTT_RegisterCallback called for bT cmnd/bl602s/ subT cmnd/bl602s/+
    Info:MQTT:MQTT_RegisterCallback called for bT obl05C320ED/ subT obl05C320ED/+/get
    Info:CMD:CMD_StartScript: started @startup at the beginning
    Error:CMD:LFS_ReadFile: lfs is absent
    Info:CMD:CMD_StartScript: failed to get file autoexec.bat
    Info:MAIN:Main_Init_After_Delay done
    Info:MAIN:Time 1, idle 0/s, free 113928, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    Info:MAIN:Time 2, idle 0/s, free 113928, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    Info:MAIN:Time 3, idle 0/s, free 113928, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    Info:MAIN:Time 4, idle 0/s, free 113928, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    ---------STA enable
    [lwip] netif status callback
      IP: 0.0.0.0
      MK: 0.0.0.0
      GW: 0.0.0.0
    [WF][SM] currentState is idle
    [WF] MM_ADD_IF_REQ Sending: STA
    td_start idx=0
    [WF] MM_ADD_IF_REQ Done
    [WF] vif_index from LAMC is 0
    [WF][SM] Exiting idle state
    [WF][SM] Action Connect
       ssid OpenWrt
       ssid len 7
       passphr xxx
       passphr len 14
       psk yyy
       psk len 64
       band 0
       freq 0
       bssid 00:00:00:00:00:00
       dhcp status: true
       flags: 512
    [WF][PF] Adding and Using profile, idx is @0
    [WF][SM] State Action ###idle### --->>> ###connecting###
    connecting using vif_idx 0
    ===start sm_get_bss_params===
    bssid[0] = 0xffff
    bssid[1] = 0xffff
    bssid[2] = 0xffff
    search ssid = OpenWrt
    result ssid index = -1
    ===end sm_get_bss_params===
    [WF][SM] Entering connecting state
    Info:MAIN:Time 5, idle 0/s, free 113928, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    Info:MAIN:Registered for wifi c[APP] [EVT] Connecting 6399
    [APP] [EVT] Connecting 6399
    hanges
    Info:MAIN:Connecting to SSID [OpenWrt]
    Info:MAIN:Main_OnWiFiStatusChange - WIFI_STA_CONNECTING - 1
    [      7403][WARN  : bl_mtd.c: 205] addr@0x230a1d58 is xip flash, size 8
    Info:MAIN:Time 6, idle 0/s, free 111768, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    Info:MAIN:Boot complete time reached (5 seconds)
    Info:MAIN:Time 7, idle 0/s, free 111768, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    ===start sm_get_bss_params===
    bssid[0] = 0xffff
    bssid[1] = 0xffff
    bssid[2] = 0xffff
    search ssid = OpenWrt
    result ssid index = 0
    ===end sm_get_bss_params===
    --- OPT rxu_mgmt_ind is detected
    Info:MAIN:Time 8, idle 0/s, free 112752, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    ind ix 0x42027d94, chan_ctxt is 0x4201915c
    [RX] Connection Status
    [RX]   status_code 0
    [RX]   reason_code 0
    [RX]   connect result: sm connect ind ok
    [RX]   MAC 10:7B:44:EC:5D:98
    [RX]   vif_idx 0
    [RX]   ap_idx 0
    [RX]   ch_idx 0
    [RX]   qos 1
    [RX]   acm 0
    [RX]   assoc_req_ie_len 78
    [RX]   assoc_rsp_ie_len 98
    [RX]   aid 0
    [RX]   band 0
    [RX]   center_freq 2412
    [RX]   width 0
    [RX]   center_freq1 2412
    [RX]   center_freq2 0
    [RX]   tlv_ptr first 0x00000000
    [WF][SM] Exiting connecting state
    [WF][SM] State Action ###connecting### --->>> ###wifiConnected_ipObtaining###
    [WF][PF] Getting profile by index, idx is @0
    [WF][SM] Entering wifiConnected_ipObtaining state
    [WF][SM] DHCP Starting...0x4201b53c
    [SYS] Memory left is 113792 Bytes
    [APP] [EVT] connected 9480
    [APP] [EVT] connected 9481
    Info:MAIN:Time 9, idle 0/s, free 113792, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    -----------------> AABA Request:
        A-MSDU: Permitted
        Block Ack Policy: Immediate Block Ack
        TID: 7
        Number of Buffers: 64
    -----------------> AABA Response:
        A-MSDU: Not Permitted
        Block Ack Policy: Immediate Block Ack
        TID: 7
        Number of Buffers: 8
        ssn: 0
        timeout: 0
        tid 7
     IP:192.168.1.242
     MASK: 255.255.255.0
     Gateway: 192.168.1.1
    Info:MAIN:Time 10, idle 0/s, free 113792, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21 
    [lwip] netif status callback
      IP: 192.168.1.242
      MK: 255.255.255.0
      GW: 192.168.1.1
    [WF][SM] Exiting wifiConnected_ipObtaining state
    [WF][SM] State Action ###wifiConnected_ipObtaining### --->>> ###wifiConnected_IPOK###
    [WF][SM] Entering wifiConnected_IPOK state
    [APP] [EVT] GOT IP 12220
    [SYS] Memory left is 113888 Bytes
    [APP] [EVT] GOT IP 12220
    [SYS] Memory left is 113888 Bytes
    Info:MAIN:Main_OnWiFiStatusChange - WIFI_STA_CONNECTED - 4
    


    Added after 4 [hours] 58 [minutes]:

    I did a invastigation of standard 1mb toml layout and it's not suitable for this firmware. It only has PSM partition of 8kb, and that is not enough to handle big config of 3600b, so config updates does not work. You need more.
  • #78 21441712
    divadiow
    Level 35  
    miegapele wrote:
    I did a invastigation of standard 1mb toml layout and it's not suitable for this firmware. It only has PSM partition of 8kb, and that is not enough to handle big config of 3600b, so config updates does not work. You need more.

    so your revised custom toml should be considered the required de-facto toml for 1mb devices?
  • #79 21441931
    maxim2002
    Level 13  
    Idk what changed but it connected today. Doesn't matter what 802.11w MFP setting is on AP (Optional on mine).
    Wifi SNR is pretty good.
    Wi-Fi signal parameters: signal strength -53/-95 dBm, speeds 6.0 Mbit/s and 72.2 Mbit/s at 20 MHz band, MCS 7, Short GI.

    It doesn't feel stable tho. Requests are often timing out. Sometimes responses are incomplete. Can't create autoexec, gpio finder loaded properly only once and it basically kills it with loads of /api/pins requests ... after maybe 5 it stops responding. It is slightly faster after fresh reboot.

    Configuration page for the OpenBL602_FD438A7F module with several configuration options.

    Network loading time statistics

    Screenshot of browser developer tools showing network details for http://192.168.0.166/api/lfs/autoexec.bat.

    Screen area with the text drop file(s) or .tar here and file saving messages.

    Screenshot of the Network tab in browser developer tools showing various HTTP requests to IP 192.168.0.166.

    Notice that after Time 550 it stops managing memory ?
    Code: Text
    Log in, to see the code

    After this it goes dark, you have to reboot it to access it again.
    While writing this post and after it went dark, uart log recorded this:
    Code: Text
    Log in, to see the code
  • #80 21442160
    miegapele
    Level 15  
    My development module has the same problem. If connected to computer wifi is very slow/unusable. However, if
    I power it from separate usb charger, it works fine. Not sure why that is. I thought it was caused by my router upgrade, but probably not. Try connecting module to separate usb charger.

    Added after 56 [minutes]:

    >>21441712
    No, not really. That is something I've made for testing.
    This would be more proper one, I has:
    • 64kb for boot loader/partition table
    • 912kb for firmware
    • 0kb for media partition, (required so that it currently does not crash)
    • 32kb for PSM partition (that's there config, energy stats and boot count is stored)
    • 16kb for factory partition (that's there dts file is stored)

    Some of this could be reduced/removed if somebody wants, for example to implement update.
    
    [pt_table]
    #partition table is 4K in size
    address0 = 0xE000
    address1 = 0xF000
    
    [[pt_entry]]
    type = 0
    name = "FW"
    device = 0
    address0 = 0x010000
    size0 = 0xE4000
    address1 = 0x000
    size1 = 0x000
    # compressed image must set len,normal image can left it to 0
    len = 0
    
    [[pt_entry]]
    type = 3
    name = "media"
    device = 0
    address0 = 0x0F4000
    size0 = 0x0000
    address1 = 0
    size1 = 0
    # compressed image must set len,normal image can left it to 0
    len = 0
    
    [[pt_entry]]
    type = 4
    name = "PSM"
    device = 0
    address0 = 0x0F4000
    size0 = 0x8000
    address1 = 0
    size1 = 0
    # compressed image must set len,normal image can left it to 0
    len = 0
    
    [[pt_entry]]
    type = 7
    name = "factory"
    device = 0
    address0 = 0x0FC000
    size0 = 0x4000
    address1 = 0
    size1 = 0
    # compressed image must set len,normal image can left it to 0
    len = 0
    
    
  • #81 21442277
    maxim2002
    Level 13  
    I'm on kinna external psu already. Pretty sure it's stable.
    Programmable DC power supply connected to an electronic circuit on a desk.
  • #82 21442289
    miegapele
    Level 15  
    >>21442277
    That's nothing to do with any PSU issues, any computer can power such module. Much more likely it has something to do with noise coupled from the computer. You cannot avoid that unless you don't connect to a computer :) Also you might want to move the module away from the computer too for testing
  • #83 21442311
    p.kaczmarek2
    Moderator Smart Home
    I wonder how much such a filter could help?
    Diagram of a capacitor input filter or Pi filter.
    Helpful post? Buy me a coffee.
  • #84 21442328
    maxim2002
    Level 13  
    Powered it from fresh batteries and disconnected from everything. Stopped registering on ap. Tried a couple of times.
  • #85 21443050
    maxim2002
    Level 13  
    Batteries hold at 3.37V. Reflashed with updated partition table. Disabled 802.11w MFP on AP. Put closer to AP (the only emf it gets comes from AP). Connected after 3rd attempt. Same behavior, gpio finder kills it. Wireshark tells what we already know.
    Screenshot of Wireshark showing TCP packets between IP addresses.

    Does the webserver api is complete in your port? I'm getting 404s on /api/lfs
    Screenshot of a developer tool showing headers for a failed HTTP request.

    Lmk if you have any suggestions what else could be checked.
  • #86 21444306
    Zhekos555
    Level 10  
    Tried everything above with one of my XT-BL02 chips. It's booting up with OpenBL602_1532_merge_d11ce44f3af6.bin but WIFI won't connect whatever I tried. Voltages 3.2-3.4 short/long cables. On saving wifi settings just resets. It does boot with standard 1M.toml and with partition_cfg_1M_miegapele.toml. With this *.toml from @miegapele it boots but infinite reboots.
    [pt_table]
    #partition table is 4K in size
    address0 = 0xE000
    address1 = 0xF000

    [[pt_entry]]
    type = 0
    name = "FW"
    device = 0
    address0 = 0x010000
    size0 = 0xE4000
    address1 = 0x000
    size1 = 0x000
    # compressed image must set len,normal image can left it to 0
    len = 0

    [[pt_entry]]
    type = 3
    name = "media"
    device = 0
    address0 = 0x0F4000
    size0 = 0x0000
    address1 = 0
    size1 = 0
    # compressed image must set len,normal image can left it to 0
    len = 0

    [[pt_entry]]
    type = 4
    name = "PSM"
    device = 0
    address0 = 0x0F4000
    size0 = 0x8000
    address1 = 0
    size1 = 0
    # compressed image must set len,normal image can left it to 0
    len = 0

    [[pt_entry]]
    type = 7
    name = "factory"
    device = 0
    address0 = 0x0FC000
    size0 = 0x4000
    address1 = 0
    size1 = 0
    # compressed image must set len,normal image can left it to 0
    len = 0
  • #88 21445554
    Zhekos555
    Level 10  
    Can you please post comiled binary here?
  • Helpful post
    #89 21456497
    niterian
    Level 9  
    This is amazing, I'm happy I stumbled into this topic, because even some recent posts gave no hope for BL602L10.

    I have: https://pl.aliexpress.com/item/1005005989938860.html
    Inside it looks exactly like: https://www.elektroda.com/rtvforum/topic4039283.html, but it has BL602L10 inside. Same pinout works for UART and flashing. Even has the same PCB text: XLD-QFLWP-YT2.1. No need to desolder the module.

    It flashed fine, connects to WiFi and saves to Flash with:
    * this TOML: https://www.elektroda.com/rtvforum/topic4086736.html#21432034 (partition_cfg_1M_miegapele.toml on the screenshot)
    * this build file: https://github.com/openshwprojects/OpenBK7231...ions/runs/13334744916/job/37247362962?pr=1534, direct link: https://github.com/openshwprojects/OpenBK7231...actions/runs/13334744916/artifacts/2594275994

    Settings in Buffalo Lab Dev Cube 1.9.0 (I did flash erase on that chip in the past, it's not selected here):

    Microcontroller management program interface.

    Flashing log:
    
    
    [04:20:10.856] - serial type is general
    [04:20:10.892] - Open /dev/ttyUSB0 Success
    [04:20:17.897] - Close /dev/ttyUSB0 Success
    [04:20:17.913] - ========= Interface is Uart =========
    [04:20:17.927] - eflash loader bin is eflash_loader_40m.bin
    [04:20:17.932] - ========= chip flash id: ef4015 =========
    [04:20:17.943] - create partition.bin, pt_new is True
    [04:20:17.958] - fw_boot_head_gen xtal: 40M
    [04:20:17.960] - Create bootheader using /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini
    [04:20:17.960] - Updating data according to </home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini[BOOTHEADER_CFG]>
    [04:20:17.963] - Created file len:176
    [04:20:17.968] - Create efuse using /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini
    [04:20:17.969] - Updating data according to </home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini[EFUSE_CFG]>
    [04:20:17.971] - Created file len:128
    [04:20:17.975] - ========= sp image create =========
    [04:20:17.977] - Image hash is b'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'
    [04:20:17.977] - Hash ignored
    [04:20:17.977] - Header crc ignored
    [04:20:17.977] - Write flash img
    [04:20:17.978] - Encrypt efuse data
    [04:20:17.982] - fw_boot_head_gen xtal: 40M
    [04:20:17.984] - Create bootheader using /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini
    [04:20:17.984] - Updating data according to </home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini[BOOTHEADER_CFG]>
    [04:20:17.986] - Created file len:176
    [04:20:17.988] - Create efuse using /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini
    [04:20:17.990] - Updating data according to </home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini[EFUSE_CFG]>
    [04:20:17.992] - Created file len:128
    [04:20:17.997] - ========= sp image create =========
    [04:20:17.998] - Image hash is b'83891c0734583b9209e28aeaba717f85657b94747f6c4f2cc1c71e7fd874b4e8'
    [04:20:17.998] - Hash ignored
    [04:20:17.999] - Header crc ignored
    [04:20:17.999] - Write flash img
    [04:20:18.001] - Encrypt efuse data
    [04:20:18.008] - fw_boot_head_gen xtal: 40M
    [04:20:18.010] - Create bootheader using /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini
    [04:20:18.011] - Updating data according to </home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini[BOOTHEADER_CFG]>
    [04:20:18.013] - Created file len:176
    [04:20:18.017] - Create efuse using /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini
    [04:20:18.018] - Updating data according to </home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/efuse_bootheader_cfg.ini[EFUSE_CFG]>
    [04:20:18.021] - Created file len:128
    [04:20:18.027] - ========= sp image create =========
    [04:20:18.030] - Image hash is b'8ab35b9dea87649e9aeff932c70812a20dfed7721101afaaba7ebfb739952199'
    [04:20:18.030] - Header crc: b'c3145cb8'
    [04:20:18.030] - Write flash img
    [04:20:18.035] - Encrypt efuse data
    [04:20:18.036] - FW Header is 176, 3920 still needed
    [04:20:18.038] - FW OTA bin header is Done. Len is 4096
    [04:20:18.108] - BL60X_OTA_Ver1.0
    [04:20:18.179] - FW OTA bin is Done. Len is 793536
    [04:20:18.417] - OTA XZ file len = 438776
    [04:20:18.418] - Partiton len = 0
    [04:20:18.418] - Warn: fw1 xz bin size is overflow with partition table, don't create ota bin
    [04:20:18.418] - Warning: remove OTA files
    [04:20:18.419] - FW OTA xz is Done
    [04:20:18.420] - ========= eflash loader config =========
    [04:20:18.420] - Image offset = 8192
    [04:20:18.465] - =========/home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/device_tree/bl_factory_params_IoTKitA_40M.dts ——> /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/device_tree/ro_params.dtb=========
    [04:20:18.530] - True
    [04:20:18.535] - Version: eflash_loader_v2.5.1
    [04:20:18.535] - Program Start
    [04:20:18.535] - ========= eflash loader cmd arguments =========
    [04:20:18.535] - Config file: /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/eflash_loader/eflash_loader_cfg.ini
    [04:20:18.537] - serial port is /dev/ttyUSB0
    [04:20:18.537] - cpu_reset=False
    [04:20:18.537] - chiptype: bl602
    [04:20:18.537] - ========= Interface is uart =========
    [04:20:18.537] - com speed: 2000000
    [04:20:18.537] - Eflash load helper file: /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/eflash_loader/eflash_loader_40m.bin
    [04:20:18.539] - ========= load eflash_loader.bin =========
    [04:20:18.540] - Load eflash_loader.bin via uart
    [04:20:18.540] - ========= image load =========
    [04:20:18.743] - Not ack OK
    [04:20:18.744] - FL
    [04:20:18.745] - result: FL
    [04:20:19.019] - tx rx and power off, press the machine!
    [04:20:19.019] - cutoff time is 0.1
    [04:20:19.120] - power on tx and rx
    [04:20:19.844] - reset cnt: 0, reset hold: 0.005, shake hand delay: 0.1
    [04:20:19.846] - clean buf
    [04:20:19.847] - send sync
    [04:20:20.049] - ack is 4f4b
    [04:20:20.080] - shake hand success
    [04:20:20.093] - get_boot_info
    [04:20:20.097] - data read is b'010000000000000003000400a75073fdd7c41400'
    [04:20:20.097] - ========= chipid: c4d7fd7350a7 =========
    [04:20:20.098] - last boot info: None
    [04:20:20.098] - sign is 0 encrypt is 0
    [04:20:20.099] - segcnt is 1
    [04:20:20.108] - segdata_len is 38592
    [04:20:20.193] - 4080/38592
    [04:20:20.278] - 8160/38592
    [04:20:20.363] - 12240/38592
    [04:20:20.447] - 16320/38592
    [04:20:20.532] - 20400/38592
    [04:20:20.618] - 24480/38592
    [04:20:20.704] - 28560/38592
    [04:20:20.790] - 32640/38592
    [04:20:20.876] - 36720/38592
    [04:20:20.917] - 38592/38592
    [04:20:20.921] - Run img
    [04:20:21.025] - Load helper bin time cost(ms): 2484.660888671875
    [04:20:21.127] - Flash load shake hand
    [04:20:21.176] - default set DTR high
    [04:20:21.277] - clean buf
    [04:20:21.278] - send sync
    [04:20:21.486] - ack is 4f4b
    [04:20:21.517] - Read mac addr
    [04:20:21.520] - macaddr: a75073fdd7c4
    [04:20:21.521] - flash set para
    [04:20:21.522] - ========= flash read jedec ID =========
    [04:20:21.524] - Read flash jedec ID
    [04:20:21.525] - flash jedec id: c2201480
    [04:20:21.525] - Finished
    [04:20:21.531] - get flash size: 0x00100000
    [04:20:21.532] - Program operation
    [04:20:21.532] - Dealing Index 0
    [04:20:21.533] - ========= programming /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/whole_img_boot2.bin to 0x00000000
    [04:20:21.545] - ========= flash load =========
    [04:20:21.545] - ========= flash erase =========
    [04:20:21.546] - Erase flash from 0x0 to 0xbabf
    [04:20:21.548] - erase pending
    [04:20:21.883] - erase pending
    [04:20:21.947] - erase pending
    [04:20:22.010] - erase pending
    [04:20:22.073] - erase pending
    [04:20:22.160] - Erase time cost(ms): 614.2568359375
    [04:20:22.163] - decompress write rx timeout: 12.288
    [04:20:22.212] - decompress flash load 24060
    [04:20:22.232] - Load 2048/24060 {"progress":8}
    [04:20:22.261] - Load 4096/24060 {"progress":17}
    [04:20:22.279] - Load 6144/24060 {"progress":25}
    [04:20:22.299] - Load 8192/24060 {"progress":34}
    [04:20:22.319] - Load 10240/24060 {"progress":42}
    [04:20:22.340] - Load 12288/24060 {"progress":51}
    [04:20:22.356] - Load 14336/24060 {"progress":59}
    [04:20:22.376] - Load 16384/24060 {"progress":68}
    [04:20:22.396] - Load 18432/24060 {"progress":76}
    [04:20:22.416] - Load 20480/24060 {"progress":85}
    [04:20:22.436] - Load 22528/24060 {"progress":93}
    [04:20:22.449] - Load 24060/24060 {"progress":100}
    [04:20:22.450] - Load 24060/24060 {"progress":100}
    [04:20:22.451] - Write check
    [04:20:22.476] - Flash load time cost(ms): 313.7158203125
    [04:20:22.477] - Finished
    [04:20:22.478] - Sha caled by host: 2f44f91873a18ff35cf93ab5a35dcde41ab8f075e21af450e904699bdabb0c01
    [04:20:22.478] - xip mode Verify
    [04:20:22.496] - Read Sha256/47808
    [04:20:22.497] - Flash xip readsha time cost(ms): 16.4189453125
    [04:20:22.497] - Finished
    [04:20:22.500] - Sha caled by dev: 2f44f91873a18ff35cf93ab5a35dcde41ab8f075e21af450e904699bdabb0c01
    [04:20:22.500] - Verify success
    [04:20:22.501] - Dealing Index 1
    [04:20:22.501] - ========= programming chips/bl602/partition/partition.bin to 0x0000E000
    [04:20:22.510] - ========= flash load =========
    [04:20:22.511] - ========= flash erase =========
    [04:20:22.511] - Erase flash from 0xe000 to 0xe0a3
    [04:20:22.515] - erase pending
    [04:20:22.593] - Erase time cost(ms): 82.110595703125
    [04:20:22.598] - Load 164/164 {"progress":100}
    [04:20:22.598] - Load 164/164 {"progress":100}
    [04:20:22.599] - Write check
    [04:20:22.604] - Flash load time cost(ms): 9.484619140625
    [04:20:22.604] - Finished
    [04:20:22.605] - Sha caled by host: 439c9bf16a27c6fdc62c57ec66b454793f14fb495587ee44764d067d0fd79e56
    [04:20:22.605] - xip mode Verify
    [04:20:22.612] - Read Sha256/164
    [04:20:22.613] - Flash xip readsha time cost(ms): 4.6552734375
    [04:20:22.613] - Finished
    [04:20:22.616] - Sha caled by dev: 439c9bf16a27c6fdc62c57ec66b454793f14fb495587ee44764d067d0fd79e56
    [04:20:22.616] - Verify success
    [04:20:22.623] - Dealing Index 2
    [04:20:22.623] - ========= programming chips/bl602/partition/partition.bin to 0x0000F000
    [04:20:22.636] - ========= flash load =========
    [04:20:22.637] - ========= flash erase =========
    [04:20:22.637] - Erase flash from 0xf000 to 0xf0a3
    [04:20:22.640] - erase pending
    [04:20:22.724] - Erase time cost(ms): 86.76123046875
    [04:20:22.729] - Load 164/164 {"progress":100}
    [04:20:22.730] - Load 164/164 {"progress":100}
    [04:20:22.730] - Write check
    [04:20:22.733] - Flash load time cost(ms): 8.04736328125
    [04:20:22.734] - Finished
    [04:20:22.735] - Sha caled by host: 439c9bf16a27c6fdc62c57ec66b454793f14fb495587ee44764d067d0fd79e56
    [04:20:22.736] - xip mode Verify
    [04:20:22.746] - Read Sha256/164
    [04:20:22.747] - Flash xip readsha time cost(ms): 6.9384765625
    [04:20:22.748] - Finished
    [04:20:22.751] - Sha caled by dev: 439c9bf16a27c6fdc62c57ec66b454793f14fb495587ee44764d067d0fd79e56
    [04:20:22.752] - Verify success
    [04:20:22.754] - Dealing Index 3
    [04:20:22.756] - ========= programming /home/niteria/Dropbox/backups/tuya/BL602/chips/bl602/img_create_iot/whole_img.bin to 0x00010000
    [04:20:22.775] - ========= flash load =========
    [04:20:22.777] - ========= flash erase =========
    [04:20:22.777] - Erase flash from 0x10000 to 0xd1bbf
    [04:20:22.780] - erase pending
    [04:20:23.439] - erase pending
    [04:20:24.085] - erase pending
    [04:20:24.714] - erase pending
    [04:20:25.336] - erase pending
    [04:20:25.943] - erase pending
    [04:20:26.545] - erase pending
    [04:20:27.127] - erase pending
    [04:20:27.760] - erase pending
    [04:20:28.390] - erase pending
    [04:20:29.001] - erase pending
    [04:20:29.595] - erase pending
    [04:20:30.168] - erase pending
    [04:20:30.219] - erase pending
    [04:20:30.289] - Erase time cost(ms): 7511.48779296875
    [04:20:30.290] - decompress write rx timeout: 12.288
    [04:20:30.470] - decompress flash load 438776
    [04:20:30.486] - Load 2048/438776 {"progress":0}
    [04:20:30.511] - Load 4096/438776 {"progress":0}
    [04:20:30.528] - Load 6144/438776 {"progress":1}
    [04:20:30.548] - Load 8192/438776 {"progress":1}
    [04:20:30.568] - Load 10240/438776 {"progress":2}
    [04:20:30.588] - Load 12288/438776 {"progress":2}
    [04:20:30.604] - Load 14336/438776 {"progress":3}
    [04:20:30.624] - Load 16384/438776 {"progress":3}
    [04:20:30.644] - Load 18432/438776 {"progress":4}
    [04:20:30.664] - Load 20480/438776 {"progress":4}
    [04:20:30.685] - Load 22528/438776 {"progress":5}
    [04:20:30.705] - Load 24576/438776 {"progress":5}
    [04:20:30.725] - Load 26624/438776 {"progress":6}
    [04:20:30.746] - Load 28672/438776 {"progress":6}
    [04:20:30.766] - Load 30720/438776 {"progress":7}
    [04:20:30.786] - Load 32768/438776 {"progress":7}
    [04:20:30.806] - Load 34816/438776 {"progress":7}
    [04:20:30.822] - Load 36864/438776 {"progress":8}
    [04:20:30.842] - Load 38912/438776 {"progress":8}
    [04:20:30.862] - Load 40960/438776 {"progress":9}
    [04:20:30.882] - Load 43008/438776 {"progress":9}
    [04:20:30.898] - Load 45056/438776 {"progress":10}
    [04:20:30.918] - Load 47104/438776 {"progress":10}
    [04:20:30.938] - Load 49152/438776 {"progress":11}
    [04:20:30.958] - Load 51200/438776 {"progress":11}
    [04:20:30.978] - Load 53248/438776 {"progress":12}
    [04:20:30.994] - Load 55296/438776 {"progress":12}
    [04:20:31.015] - Load 57344/438776 {"progress":13}
    [04:20:31.035] - Load 59392/438776 {"progress":13}
    [04:20:31.055] - Load 61440/438776 {"progress":14}
    [04:20:31.075] - Load 63488/438776 {"progress":14}
    [04:20:31.091] - Load 65536/438776 {"progress":14}
    [04:20:31.111] - Load 67584/438776 {"progress":15}
    [04:20:31.131] - Load 69632/438776 {"progress":15}
    [04:20:31.151] - Load 71680/438776 {"progress":16}
    [04:20:31.171] - Load 73728/438776 {"progress":16}
    [04:20:31.191] - Load 75776/438776 {"progress":17}
    [04:20:31.212] - Load 77824/438776 {"progress":17}
    [04:20:31.232] - Load 79872/438776 {"progress":18}
    [04:20:31.248] - Load 81920/438776 {"progress":18}
    [04:20:31.268] - Load 83968/438776 {"progress":19}
    [04:20:31.288] - Load 86016/438776 {"progress":19}
    [04:20:31.308] - Load 88064/438776 {"progress":20}
    [04:20:31.328] - Load 90112/438776 {"progress":20}
    [04:20:31.348] - Load 92160/438776 {"progress":21}
    [04:20:31.368] - Load 94208/438776 {"progress":21}
    [04:20:31.389] - Load 96256/438776 {"progress":21}
    [04:20:31.409] - Load 98304/438776 {"progress":22}
    [04:20:31.430] - Load 100352/438776 {"progress":22}
    [04:20:31.450] - Load 102400/438776 {"progress":23}
    [04:20:31.470] - Load 104448/438776 {"progress":23}
    [04:20:31.490] - Load 106496/438776 {"progress":24}
    [04:20:31.510] - Load 108544/438776 {"progress":24}
    [04:20:31.530] - Load 110592/438776 {"progress":25}
    [04:20:31.551] - Load 112640/438776 {"progress":25}
    [04:20:31.570] - Load 114688/438776 {"progress":26}
    [04:20:31.586] - Load 116736/438776 {"progress":26}
    [04:20:31.606] - Load 118784/438776 {"progress":27}
    [04:20:31.626] - Load 120832/438776 {"progress":27}
    [04:20:31.646] - Load 122880/438776 {"progress":28}
    [04:20:31.663] - Load 124928/438776 {"progress":28}
    [04:20:31.683] - Load 126976/438776 {"progress":28}
    [04:20:31.703] - Load 129024/438776 {"progress":29}
    [04:20:31.723] - Load 131072/438776 {"progress":29}
    [04:20:31.744] - Load 133120/438776 {"progress":30}
    [04:20:31.764] - Load 135168/438776 {"progress":30}
    [04:20:31.784] - Load 137216/438776 {"progress":31}
    [04:20:31.804] - Load 139264/438776 {"progress":31}
    [04:20:31.822] - Load 141312/438776 {"progress":32}
    [04:20:31.842] - Load 143360/438776 {"progress":32}
    [04:20:31.862] - Load 145408/438776 {"progress":33}
    [04:20:31.882] - Load 147456/438776 {"progress":33}
    [04:20:31.902] - Load 149504/438776 {"progress":34}
    [04:20:31.922] - Load 151552/438776 {"progress":34}
    [04:20:31.939] - Load 153600/438776 {"progress":35}
    [04:20:31.959] - Load 155648/438776 {"progress":35}
    [04:20:31.979] - Load 157696/438776 {"progress":35}
    [04:20:31.999] - Load 159744/438776 {"progress":36}
    [04:20:32.019] - Load 161792/438776 {"progress":36}
    [04:20:32.035] - Load 163840/438776 {"progress":37}
    [04:20:32.055] - Load 165888/438776 {"progress":37}
    [04:20:32.075] - Load 167936/438776 {"progress":38}
    [04:20:32.095] - Load 169984/438776 {"progress":38}
    [04:20:32.115] - Load 172032/438776 {"progress":39}
    [04:20:32.131] - Load 174080/438776 {"progress":39}
    [04:20:32.152] - Load 176128/438776 {"progress":40}
    [04:20:32.172] - Load 178176/438776 {"progress":40}
    [04:20:32.192] - Load 180224/438776 {"progress":41}
    [04:20:32.212] - Load 182272/438776 {"progress":41}
    [04:20:32.228] - Load 184320/438776 {"progress":42}
    [04:20:32.248] - Load 186368/438776 {"progress":42}
    [04:20:32.268] - Load 188416/438776 {"progress":42}
    [04:20:32.288] - Load 190464/438776 {"progress":43}
    [04:20:32.305] - Load 192512/438776 {"progress":43}
    [04:20:32.325] - Load 194560/438776 {"progress":44}
    [04:20:32.345] - Load 196608/438776 {"progress":44}
    [04:20:32.365] - Load 198656/438776 {"progress":45}
    [04:20:32.384] - Load 200704/438776 {"progress":45}
    [04:20:32.404] - Load 202752/438776 {"progress":46}
    [04:20:32.424] - Load 204800/438776 {"progress":46}
    [04:20:32.444] - Load 206848/438776 {"progress":47}
    [04:20:32.464] - Load 208896/438776 {"progress":47}
    [04:20:32.484] - Load 210944/438776 {"progress":48}
    [04:20:32.504] - Load 212992/438776 {"progress":48}
    [04:20:32.524] - Load 215040/438776 {"progress":49}
    [04:20:32.544] - Load 217088/438776 {"progress":49}
    [04:20:32.564] - Load 219136/438776 {"progress":49}
    [04:20:32.584] - Load 221184/438776 {"progress":50}
    [04:20:32.601] - Load 223232/438776 {"progress":50}
    [04:20:32.621] - Load 225280/438776 {"progress":51}
    [04:20:32.641] - Load 227328/438776 {"progress":51}
    [04:20:32.661] - Load 229376/438776 {"progress":52}
    [04:20:32.681] - Load 231424/438776 {"progress":52}
    [04:20:32.701] - Load 233472/438776 {"progress":53}
    [04:20:32.717] - Load 235520/438776 {"progress":53}
    [04:20:32.737] - Load 237568/438776 {"progress":54}
    [04:20:32.757] - Load 239616/438776 {"progress":54}
    [04:20:32.777] - Load 241664/438776 {"progress":55}
    [04:20:32.797] - Load 243712/438776 {"progress":55}
    [04:20:32.814] - Load 245760/438776 {"progress":56}
    [04:20:32.836] - Load 247808/438776 {"progress":56}
    [04:20:32.855] - Load 249856/438776 {"progress":56}
    [04:20:32.874] - Load 251904/438776 {"progress":57}
    [04:20:32.893] - Load 253952/438776 {"progress":57}
    [04:20:32.913] - Load 256000/438776 {"progress":58}
    [04:20:32.933] - Load 258048/438776 {"progress":58}
    [04:20:32.953] - Load 260096/438776 {"progress":59}
    [04:20:32.970] - Load 262144/438776 {"progress":59}
    [04:20:32.990] - Load 264192/438776 {"progress":60}
    [04:20:33.010] - Load 266240/438776 {"progress":60}
    [04:20:33.030] - Load 268288/438776 {"progress":61}
    [04:20:33.050] - Load 270336/438776 {"progress":61}
    [04:20:33.070] - Load 272384/438776 {"progress":62}
    [04:20:33.091] - Load 274432/438776 {"progress":62}
    [04:20:33.111] - Load 276480/438776 {"progress":63}
    [04:20:33.131] - Load 278528/438776 {"progress":63}
    [04:20:33.154] - Load 280576/438776 {"progress":63}
    [04:20:33.173] - Load 282624/438776 {"progress":64}
    [04:20:33.193] - Load 284672/438776 {"progress":64}
    [04:20:33.210] - Load 286720/438776 {"progress":65}
    [04:20:33.230] - Load 288768/438776 {"progress":65}
    [04:20:33.250] - Load 290816/438776 {"progress":66}
    [04:20:33.271] - Load 292864/438776 {"progress":66}
    [04:20:33.291] - Load 294912/438776 {"progress":67}
    [04:20:33.310] - Load 296960/438776 {"progress":67}
    [04:20:33.330] - Load 299008/438776 {"progress":68}
    [04:20:33.350] - Load 301056/438776 {"progress":68}
    [04:20:33.370] - Load 303104/438776 {"progress":69}
    [04:20:33.388] - Load 305152/438776 {"progress":69}
    [04:20:33.408] - Load 307200/438776 {"progress":70}
    [04:20:33.428] - Load 309248/438776 {"progress":70}
    [04:20:33.448] - Load 311296/438776 {"progress":70}
    [04:20:33.468] - Load 313344/438776 {"progress":71}
    [04:20:33.484] - Load 315392/438776 {"progress":71}
    [04:20:33.504] - Load 317440/438776 {"progress":72}
    [04:20:33.524] - Load 319488/438776 {"progress":72}
    [04:20:33.544] - Load 321536/438776 {"progress":73}
    [04:20:33.565] - Load 323584/438776 {"progress":73}
    [04:20:33.581] - Load 325632/438776 {"progress":74}
    [04:20:33.601] - Load 327680/438776 {"progress":74}
    [04:20:33.622] - Load 329728/438776 {"progress":75}
    [04:20:33.642] - Load 331776/438776 {"progress":75}
    [04:20:33.658] - Load 333824/438776 {"progress":76}
    [04:20:33.678] - Load 335872/438776 {"progress":76}
    [04:20:33.698] - Load 337920/438776 {"progress":77}
    [04:20:33.719] - Load 339968/438776 {"progress":77}
    [04:20:33.739] - Load 342016/438776 {"progress":77}
    [04:20:33.759] - Load 344064/438776 {"progress":78}
    [04:20:33.778] - Load 346112/438776 {"progress":78}
    [04:20:33.795] - Load 348160/438776 {"progress":79}
    [04:20:33.815] - Load 350208/438776 {"progress":79}
    [04:20:33.835] - Load 352256/438776 {"progress":80}
    [04:20:33.855] - Load 354304/438776 {"progress":80}
    [04:20:33.872] - Load 356352/438776 {"progress":81}
    [04:20:33.893] - Load 358400/438776 {"progress":81}
    [04:20:33.915] - Load 360448/438776 {"progress":82}
    [04:20:33.934] - Load 362496/438776 {"progress":82}
    [04:20:33.956] - Load 364544/438776 {"progress":83}
    [04:20:33.977] - Load 366592/438776 {"progress":83}
    [04:20:33.997] - Load 368640/438776 {"progress":84}
    [04:20:34.017] - Load 370688/438776 {"progress":84}
    [04:20:34.037] - Load 372736/438776 {"progress":84}
    [04:20:34.057] - Load 374784/438776 {"progress":85}
    [04:20:34.073] - Load 376832/438776 {"progress":85}
    [04:20:34.093] - Load 378880/438776 {"progress":86}
    [04:20:34.113] - Load 380928/438776 {"progress":86}
    [04:20:34.133] - Load 382976/438776 {"progress":87}
    [04:20:34.150] - Load 385024/438776 {"progress":87}
    [04:20:34.170] - Load 387072/438776 {"progress":88}
    [04:20:34.190] - Load 389120/438776 {"progress":88}
    [04:20:34.225] - Load 391168/438776 {"progress":89}
    [04:20:34.259] - Load 393216/438776 {"progress":89}
    [04:20:34.280] - Load 395264/438776 {"progress":90}
    [04:20:34.314] - Load 397312/438776 {"progress":90}
    [04:20:34.335] - Load 399360/438776 {"progress":91}
    [04:20:34.369] - Load 401408/438776 {"progress":91}
    [04:20:34.390] - Load 403456/438776 {"progress":91}
    [04:20:34.423] - Load 405504/438776 {"progress":92}
    [04:20:34.444] - Load 407552/438776 {"progress":92}
    [04:20:34.465] - Load 409600/438776 {"progress":93}
    [04:20:34.499] - Load 411648/438776 {"progress":93}
    [04:20:34.520] - Load 413696/438776 {"progress":94}
    [04:20:34.554] - Load 415744/438776 {"progress":94}
    [04:20:34.574] - Load 417792/438776 {"progress":95}
    [04:20:34.609] - Load 419840/438776 {"progress":95}
    [04:20:34.630] - Load 421888/438776 {"progress":96}
    [04:20:34.664] - Load 423936/438776 {"progress":96}
    [04:20:34.698] - Load 425984/438776 {"progress":97}
    [04:20:34.719] - Load 428032/438776 {"progress":97}
    [04:20:34.740] - Load 430080/438776 {"progress":98}
    [04:20:34.774] - Load 432128/438776 {"progress":98}
    [04:20:34.809] - Load 434176/438776 {"progress":98}
    [04:20:34.830] - Load 436224/438776 {"progress":99}
    [04:20:34.849] - Load 438272/438776 {"progress":99}
    [04:20:34.883] - Load 438776/438776 {"progress":100}
    [04:20:34.884] - Load 438776/438776 {"progress":100}
    [04:20:34.884] - Write check
    [04:20:34.895] - Flash load time cost(ms): 4604.290771484375
    [04:20:34.896] - Finished
    [04:20:34.903] - Sha caled by host: 8c9d52f4b076bee53f64217ec1942569402674466c4fdc8f4775c79df62d1b31
    [04:20:34.903] - xip mode Verify
    [04:20:35.124] - Read Sha256/793536
    [04:20:35.126] - Flash xip readsha time cost(ms): 219.52099609375
    [04:20:35.127] - Finished
    [04:20:35.130] - Sha caled by dev: 8c9d52f4b076bee53f64217ec1942569402674466c4fdc8f4775c79df62d1b31
    [04:20:35.131] - Verify success
    [04:20:35.132] - Dealing Index 4
    [04:20:35.133] - ========= programming chips/bl602/device_tree/ro_params.dtb to 0x000F1000
    [04:20:35.161] - ========= flash load =========
    [04:20:35.163] - ========= flash erase =========
    [04:20:35.164] - Erase flash from 0xf1000 to 0xf275d
    [04:20:35.167] - erase pending
    [04:20:35.231] - erase pending
    [04:20:35.304] - Erase time cost(ms): 139.348388671875
    [04:20:35.304] - decompress write rx timeout: 12.288
    [04:20:35.316] - decompress flash load 1584
    [04:20:35.332] - Load 1584/1584 {"progress":100}
    [04:20:35.334] - Load 1584/1584 {"progress":100}
    [04:20:35.335] - Write check
    [04:20:35.357] - Flash load time cost(ms): 52.94140625
    [04:20:35.358] - Finished
    [04:20:35.360] - Sha caled by host: 2030ce2a98174d1e1bc02905472a5c55ff0df9d7274c49efd787982af2430e58
    [04:20:35.360] - xip mode Verify
    [04:20:35.369] - Read Sha256/5982
    [04:20:35.370] - Flash xip readsha time cost(ms): 5.438232421875
    [04:20:35.371] - Finished
    [04:20:35.374] - Sha caled by dev: 2030ce2a98174d1e1bc02905472a5c55ff0df9d7274c49efd787982af2430e58
    [04:20:35.375] - Verify success
    [04:20:35.376] - Program Finished
    [04:20:35.376] - All time cost(ms): 16841.05322265625
    [04:20:35.478] - close interface
    [04:20:35.478] - [All Success]
    


    This is my second BL602, I had way easier time with this one:
    * soldered jump wires
    * breadboard I trust
    * power supply backed by AMS1117 https://botland.store/power-modules/1482-supp...ontact-plates-mb102-33v-5v-5904422300739.html
    * CH340G usb2uart

    EDIT: exactly the same config from https://www.elektroda.com/rtvforum/topic4039283.html works

    OpenBL602 user interface with LED settings and device information.
  • Helpful post
    #90 21470955
    niterian
    Level 9  
    >>21456497

    I got another 2 bulbs with exactly the same hardware (BL602L10), from two different sellers.

    I've dumped the flash for both. Flashed one with OpenBK. There are some differences in two address ranges: 0x000f8000-0x000f8690 and 0x000f9000-0x000f9980

Topic summary

The discussion focuses on the Cozylife DS-1211AN 3-gang touch wall switch featuring a 1MB BL602L10 Wi-Fi and BLE module, manufactured by Shenzhen Dianling Intelligent Technology Co Ltd. The main challenge is adapting OpenBeken/OpenBL602 firmware, which typically targets 2MB flash BL602 chips, to the 1MB flash variant, as standard builds and tools like OpenBeken do not natively support 1MB BL602L10 devices. Key technical issues include flash memory partitioning, bootloader compatibility, EasyFlash storage initialization, and power supply stability affecting boot loops and Wi-Fi connectivity.

Significant progress was made by creating and testing custom partition table (TOML) files tailored for 1MB flash layouts, notably the partition_cfg_1M_miegapele.toml, which allocates appropriate sizes for firmware, media, PSM, and factory partitions. Firmware builds with specific SDK configurations (e.g., CONFIG_BL602_USE_1M_FLASH and CONFIG_BL602_USE_ROM_DRIVER enabled) successfully boot and run on the 1MB BL602L10, including OpenBK7231T_App builds from GitHub pull requests #1532 and #1534.

Power supply quality and wiring (shorter VCC and ground cables, decoupling capacitors) were critical for stable operation, as the module exhibited boot looping and Wi-Fi instability when powered inadequately or with noisy sources. The GPIO17 pin usage and UART download mode resistor requirements were also discussed for module replacement or debugging.

Wi-Fi connection issues were partially resolved by adjusting router PMF (Protected Management Frames) settings and using simpler passwords. The firmware supports AP mode and basic Wi-Fi functions, though some web API endpoints (e.g., /api/lfs) may be incomplete. The community shared detailed boot logs, flash memory dumps, and PCB images to aid development and testing.

Overall, the topic demonstrates successful adaptation of OpenBL602 firmware to the 1MB BL602L10 module in the Cozylife DS-1211AN switch, with custom partitioning, SDK flags, and power considerations enabling stable boot and Wi-Fi operation, while highlighting ongoing challenges in full feature support and stability.
Summary generated by the language model.
ADVERTISEMENT