logo elektroda
logo elektroda
X
logo elektroda

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

divadiow 6774 132
Best answers

How can I get OpenBK/OpenBL602 running on this Cozylife DS-1211AN with a 1 MB BL602L10 chip?

Yes — the thread ended up showing that OpenBK/OpenBL602 can run on the 1 MB BL602L10, but you need the 1 MB-aware SDK/build path and a matching partition layout [#21438533][#21439639] The key fix was enabling `CONFIG_BL602_USE_1M_FLASH := 1`; once that was set, the device booted and EasyFlash worked [#21438533][#21438595] A tester confirmed a 1 MB BL602L10 device flashed successfully, joined Wi‑Fi, and saved settings using the `partition_cfg_1M_miegapele.toml` partition file plus the PR 1534 build artifact [#21456497] The stock 1 MB layout was a problem because its PSM partition was only 8 KB, which was too small for this firmware and caused boot/init/config-save issues; the revised layout used a larger PSM and adjusted/removing other partitions as needed [#21431575][#21442160] Later replies also noted that the 1 MB build works on 2 MB devices too, and that the standard release was later reported to boot on 1 MB hardware as well [#21619453][#21798426]
Generated by the language model.
ADVERTISEMENT
  • ADVERTISEMENT
  • #122 21642558
    insmod
    Level 31  
    Posts: 1353
    Help: 160
    Rate: 425
    >>21642397
    If 1mb build works on 2mb, then just add CONFIG_BL602_USE_1M_FLASH define directly in sdk. One less job for workflow that way.
  • #123 21642574
    divadiow
    Level 38  
    Posts: 4850
    Help: 421
    Rate: 854
    Hmm yeh I guess. Will check when home. I think it works fine on 2mb from memory. I wonder what the ACTUAL difference is with CONFIG_BL602_USE_1M_FLASH and if it's use on 2mb+ has any downsides
  • #124 21642580
    insmod
    Level 31  
    Posts: 1353
    Help: 160
    Rate: 425
    >>21642574
    It compiles and uses some specific read/write/erase functions, instead of using ROM ones.
    Actually, there is no need to open a pull in SDK. Just add -DCONF_BL602_USE_1M_FLASH=1 define to CFLAGS in bouffalo.mk in app.
  • ADVERTISEMENT
  • #125 21642622
    divadiow
    Level 38  
    Posts: 4850
    Help: 421
    Rate: 854
    Oh very good. OK. Good
  • #127 21643058
    insmod
    Level 31  
    Posts: 1353
    Help: 160
    Rate: 425
    >>21643038
    Hmm, it seems that cflags are not exported to global level?
  • ADVERTISEMENT
  • #128 21643060
    divadiow
    Level 38  
    Posts: 4850
    Help: 421
    Rate: 854
    trying USER_ https://github.com/divadiow/OpenBK7231T_App/commit/d490f1dac9484f8f0e62228ec20a3a7c1415dae0

    but maybe you already know if this will make any difference

    Added after 3 [minutes]:

    nope. no effect

    Added after 2 [minutes]:

    trying
    Code: Text
    Log in, to see the code


    Added after 7 [minutes]:

    nope.

    could modify SDK I guess, but preference is to keep SDK pure so it can be updated in future without fear of losing changes?
  • ADVERTISEMENT
  • #129 21646003
    divadiow
    Level 38  
    Posts: 4850
    Help: 421
    Rate: 854
    insmod wrote:
    Enabled 1M config by default (it works fine on 4mb module).


    thanks.
    bl602_ir_9f263cba4454
    https://github.com/NonPIayerCharacter/OpenBK7231T_App/actions/runs/17263341611

    1mb module. miegapele 1mb toml

    first boot:
    Spoiler:
    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: Aug 27 2025
    Build Time: 09:54:04
    ------------------------------------------------------------

    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 @0x4200f524=======
    [ 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 0x000e7000 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 0xC2
    [ 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 C4:D7:FD:43:90:45
    [ 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.
    Warning: Sector header check failed. Format this sector (0x00000000).
    Warning: Sector header check failed. Format this sector (0x00001000).
    Warning: Sector header check failed. Format this sector (0x00002000).
    Warning: Sector header check failed. Format this sector (0x00003000).
    Warning: Sector header check failed. Format this sector (0x00004000).
    Warning: Sector header check failed. Format this sector (0x00005000).
    Warning: Sector header check failed. Format this sector (0x00006000).
    Warning: Sector header check failed. Format this sector (0x00007000).
    Warning: All sector header check failed. Set it to default.
    [ 890][WARN : bl_mtd.c: 205] addr@0x23097a20 is xip flash, size 10
    [ 890][WARN : bl_mtd.c: 205] addr@0x230b0bec is xip flash, size 1
    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 0x000e7000(946176)
    size 0x00002000(8Kbytes)
    xip_addr 0x230d6000
    [MTD] <<<<<< Hanlde info End <<<<<<
    [ 901][ERROR : bl_romfs.c: 158] romfs magic is NOT correct
    [ 903][INFO : hosal_adc.c: 459] offset = 2228
    [ 903][INFO : hosal_adc.c: 233] ADC freq: 284Hz. div:6
    [OS] Starting proc_mian_entry task...
    [OS] Starting TCP/IP Stack...
    [MTD] >>>>>> Hanlde info Dump >>>>>>
    name PSM
    id 0
    offset 0x000e9000(954368)
    size 0x00008000(32Kbytes)
    xip_addr 0x230d8000
    [MTD] <<<<<< H xip_addr 0x230d8000
    anlde 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 @966ms
    1th channel,lo_vco_freq_cw=135
    2th channel,lo_vco_freq_cw=134
    3th channel,lo_vco_freq_cw=133
    4th channel,lo_vco_freq_cw=132
    5th channel,lo_vco_freq_cw=131
    6th channel,lo_vco_freq_cw=130
    7th channel,lo_vco_freq_cw=128
    8th channel,lo_vco_freq_cw=127
    9th channel,lo_vco_freq_cw=126
    10th channel,lo_vco_freq_cw=125
    11th channel,lo_vco_freq_cw=124
    12th channel,lo_vco_freq_cw=123
    13th channel,lo_vco_freq_cw=122
    14th channel,lo_vco_freq_cw=121
    15th channel,lo_vco_freq_cw=119
    16th channel,lo_vco_freq_cw=118
    17th channel,lo_vco_freq_cw=117
    18th channel,lo_vco_freq_cw=116
    19th channel,lo_vco_freq_cw=115
    20th channel,lo_vco_freq_cw=114
    21th channel,lo_vco_freq_cw=113
    0th channel,vco_idac_cw=12
    1th channel,vco_idac_cw=11
    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=10
    9th channel,vco_idac_cw=10
    10th channel,vco_idac_cw=10
    11th channel,vco_idac_cw=10
    12th channel,vco_idac_cw=10
    13th channel,vco_idac_cw=10
    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 126
    rosdac_i_gc3=35
    rosdac_i_gc2=35
    rosdac_i_gc1=35
    rosdac_i_gc0=35
    rosdac_q_gc3=32
    rosdac_q_gc2=32
    rosdac_q_gc1=32
    rosdac_q_gc0=32
    rbb_cap1_fc_i=17,rbb_cap2_fc_i=17,rbb_cap1_fc_q=17,rbb_cap2_fc_q=17
    new rbb_cap1_fc_i=41,rbb_cap2_fc_i=41,rbb_cap1_fc_q=41,rbb_cap2_fc_q=41
    LO locked 9 126
    amp=128,step=32,adc_mean_i=29
    amp=160,step=16,adc_mean_i=48
    amp=176,step=8,adc_mean_i=59
    amp=184,step=4,adc_mean_i=65
    amp=188,step=2,adc_mean_i=67
    amp=190,step=1,adc_mean_i=69
    amp=191,step=0,adc_mean_i=70
    tmx_cs=0, tmxcs_pwr_avg=16484, tmxcs_pwr_avg>>10=16
    tmx_cs=1, tmxcs_pwr_avg=23045, tmxcs_pwr_avg>>10=22
    tmx_cs=2, tmxcs_pwr_avg=32777, tmxcs_pwr_avg>>10=32
    tmx_cs=3, tmxcs_pwr_avg=45828, tmxcs_pwr_avg>>10=44
    tmx_cs=4, tmxcs_pwr_avg=59836, tmxcs_pwr_avg>>10=58
    tmx_cs=5, tmxcs_pwr_avg=71258, tmxcs_pwr_avg>>10=69
    tmx_cs=6, tmxcs_pwr_avg=71602, tmxcs_pwr_avg>>10=69
    tmx_cs=7, tmxcs_pwr_avg=61015, tmxcs_pwr_avg>>10=59
    tmx_cs_max=6, tmxcs_pwr_max=71602, tmxcs_pwr_max>>10=69
    amp=256,step=64,adc_mean_i=-9
    amp=320,step=32,adc_mean_i=102
    amp=352,step=16,adc_mean_i=169
    amp=368,step=8,adc_mean_i=204
    tosdac_i=33,tosdac_q=33,tx_iq_gain_comp=1034,tx_iq_phase_comp=-11
    tosdac_i=33,tosdac_q=32,tx_iq_gain_comp=1038,tx_iq_phase_comp=-7
    tosdac_i=32,tosdac_q=32,tx_iq_gain_comp=1030,tx_iq_phase_comp=-10
    tosdac_i=33,tosdac_q=35,tx_iq_gain_comp=1028,tx_iq_phase_comp=-11
    tosdac_i=30,tosdac_q=38,tx_iq_gain_comp=1027,tx_iq_phase_comp=-11
    tosdac_i=33,tosdac_q=35,tx_iq_gain_comp=1031,tx_iq_phase_comp=-13
    tosdac_i=30,tosdac_q=30,tx_iq_gain_comp=1030,tx_iq_phase_comp=-8
    tosdac_i=29,tosdac_q=29,tx_iq_gain_comp=1020,tx_iq_phase_comp=-12
    [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 @1043ms
    [APP] [EVT] INIT DONE 986


    [BL] Initi Wi-Fi with MAC #### C4:D7:FD:43:90:45 ####
    hostname: OpenBL602_fd439045
    [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 1003, now 1062ms
    OpenBL602, version bl602_ir_9f263cba4454
    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 .
    [ 1493][WARN : bl_mtd.c: 205] addr@0x230a1f10 is xip flash, size 8
    [ 1509][WARN : bl_mtd.c: 205] addr@0x230a1dec is xip flash, size 7
    [MTD] >>>>>> Hanlde info Dump >>>>>>
    name media
    id 0
    offset 0x000e7000(946176)
    size 0x00002000(8Kbytes)
    xip_addr 0x230d6000
    [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: Config crc or ident mismatch. Default config will be loaded.
    Info:CFG:CFG_SetDefaultLEDCorrectionTable: setting defaults
    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 []
    Info:MAIN:Using Pass []
    Error:HTTP:Created HTTP SV thread with (stack=2048)
    Info:MQTT:MQTT_RegisterCallback called for bT oblFD439045/ subT oblFD439045/+/set
    Info:MQTT:MQTT_RegisterCallback called for bT bl602s/ subT bl602s/+/set
    Info:MQTT:MQTT_RegisterCallback called for bT cmnd/oblFD439045/ subT cmnd/oblFD439045/+
    Info:MQTT:MQTT_RegisterCallback called for bT cmnd/bl602s/ subT cmnd/bl602s/+
    Info:MQTT:MQTT_RegisterCallback called for bT oblFD439045/ subT oblFD439045/+/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
    [ 2552][WARN : bl_mtd.c: 205] addr@0x230a1dec is xip flash, size 7
    Info:MAIN:Time 1, idle 0/s, free 107952, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 2, idle 0/s, free 107952, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 3, idle 0/s, free 107952, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 4, idle 0/s, free 107952, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    [lwip] netif status callback
    IP: 192.168.11.1
    MK: 255.255.255.0
    GW: 0.0.0.0
    [WF] MM_ADD_IF_REQ Sending: AP
    td_start idx=0
    [WF] MM_ADD_IF_REQ Done
    [WF] vif_index from LAMC is 0
    [lwip] netif status callback
    IP: 192.168.4.1
    MK: 255.255.255.0
    GW: 0.0.0.0
    [DHCP] ip_start: [192.168.4.2]
    [DHCP] ip_start: [192.168.4.254]
    [WF][SM] start AP with ssid OpenBL602_FD439045;
    [WF][SM] pwd ;
    [WF][SM] channel 1;
    [WF] APM_START_REQ Sending with vif_index 0
    [WF] received APM Start apm_start_req_handler:74
    [WF] return with other handler
    [WF] APM_START_REQ Done
    [WF] status is 00
    [WF] vif_idx is 00
    [WF] ch_idx is 00
    [WF] bcmc_idx is 05
    [WF][SM] stateGlobalGuard_AP: AP iface has started!
    Info:MAIN:Time 5, idle 0/s, free 107952, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks [APP] [EVT] Unknown code 11, 6596
    2/21
    [ 7601][WARN : bl_mtd.c: 205] addr@0x230a1f10 is xip flash, size 8
    Info:MAIN:Time 6, idle 0/s, free 107640, 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 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 8, idle 0/s, free 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 9, idle 0/s, free 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 10, idle 0/s, free 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 11, idle 0/s, free 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 12, idle 0/s, free 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 13, idle 0/s, free 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 14, idle 0/s, free 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21
    Info:MAIN:Time 15, idle 0/s, free 107640, MQTT 0(0), bWifi 0, secondsWithNoPing -1, socks 2/21


    DS1820 and CHT8310 OK

    OpenBL602 web interface showing sensor temperature, humidity, and diagnostics
  • Helpful post
    #130 21726256
    divadiow
    Level 38  
    Posts: 4850
    Help: 421
    Rate: 854
    divadiow wrote:
    ffs 👿. lol. that's the end of that 1mb module now. tried old fake Prolific TTL that must been labelled wrong (I think I remember it killing something before - BINNED NOW) and now she's pulling an unhealthy load and burning hot. good excuse to order another CozyLife DS-1211AN


    yay but, cozylife-1 vs dead one = cozylife-3. hope it's 1mb still.

    PCB board with ESP8266 Wi-Fi module and various electronic components WiFi and Bluetooth communication module XT-BL12 on a green PCB Black rectangular touch panel with a centered circle, covered in protective film Green box with product label DS-1211AN-BLACK-01 and barcode
  • #131 21798424
    vinibali
    Level 8  
    Posts: 19
    Rate: 1
    Are we already using 1 MB as the default flash size? I couldn't figure out where can I find the latest binaries for BL602L10.
  • #132 21798426
    divadiow
    Level 38  
    Posts: 4850
    Help: 421
    Rate: 854
    the release for 2mb now works on 1mb too, so you should just be able to flash standard OpenBL602
  • #133 21798435
    vinibali
    Level 8  
    Posts: 19
    Rate: 1
    >>21798426 Thanks for the update!

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.
Generated by the language model.

FAQ

TL;DR: For people flashing OpenBL602 on 1MB BL602L10 modules, the breakthrough was a 1MB flash define plus a custom partition layout; one tester confirmed standard releases now work on 1MB, and another key finding was: "the release for 2mb now works on 1mb too." This solves the classic freeze at EasyFlash init and makes XT-BL12/DT-BL12 practical OpenBeken targets. [#21798426]

Why it matters: This thread turns 1MB BL602L10 devices from borderline unsupported hardware into flashable, usable OpenBL602 targets with known limits.

Option Flash size Status in thread Main limitation
Early stock 1MB BL602L10 1MB Boot freeze / EasyFlash failure Stuck at ENV init without 1MB support [#21431575]
1MB build + custom TOML 1MB Boots and saves settings Tight space, LFS/media/OTA trade-offs [#21438533]
Standard 2MB release 2MB Works normally None specific to flash size in thread [#21609804]
Later standard release on 1MB 1MB Reported working Still flash-layout dependent for advanced features [#21798426]

Key insight: The decisive fix was not firmware size alone. The real blocker was BL602 flash access on 1MB parts, solved by enabling CONFIG_BL602_USE_1M_FLASH and pairing it with a partition layout that gives PSM enough space to save config. [#21438533]

Quick Facts

  • The stock Cozylife DS-1211AN sample used a 1MB BL602L10 module, labelled XT-BL12 / DT-BL12, and originally could not run OpenBeken because earlier builds targeted larger flash layouts. [#21301826]
  • The successful 1MB fix used CONFIG_BL602_USE_1M_FLASH := 1 with a build based on BL IoT SDK 1.6.39, built on February 13, 2025. [#21438533]
  • The commonly reused working 1MB partition gave FW 0xD7000 (~860KB), PSM 0x8000 (32KB), media 0x2000 (8KB), and factory 0x7000 (28KB). The thread rejected the standard 1MB PSM because 8KB was too small for OpenBL602 config writes. [#21432034]
  • BL602 hardware proved power-sensitive on jumper wires: testers reported looping even around 3.5V–3.6V, then stable boot after shortening VCC or ground leads. [#21434069]
  • By January 4, 2026, a maintainer-level thread update stated that the normal 2MB OpenBL602 release also worked on 1MB BL602L10, removing the need for a separate end-user binary in many cases. [#21798426]

How do I flash OpenBL602 onto a 1MB BL602L10 module like the XT-BL12 or DT-BL12 using Bouffalo Lab Dev Cube and a custom TOML partition file?

Use Bouffalo Lab Dev Cube with UART download mode, a 1MB-aware OpenBL602 binary, and a custom partition TOML. 1. Put GPIO8 into download mode and connect UART. 2. In Dev Cube, load the working 1MB TOML and the OpenBL602 image, then flash at 2,000,000 baud if your adapter is stable. 3. Reboot, join the AP, and confirm the boot log shows a valid PSM partition and EasyFlash init. A proven setup used Dev Cube 1.9.0 with a custom 1MB TOML and flashed successfully on BL602L10 bulbs without desoldering the module. [#21456497]

Why did OpenBL602 originally freeze on 1MB BL602L10 at "ENV start address is 0x00000000" during EasyFlash init, and what change finally fixed it?

It froze because the BL602 SDK was reading 1MB flash parts with the wrong flash-access path during EasyFlash initialization. The visible symptom was boot stopping at ENV start address is 0x00000000, even when partition addresses looked correct. The fix was enabling CONFIG_BL602_USE_1M_FLASH := 1, then doing a clean rebuild so the new code path was actually compiled. After that, testers reported normal EasyFlash startup, sector formatting, and successful boot on 1MB parts. An expert summary from the thread was: "CONFIG_BL602_USE_1M_FLASH is what we where after." [#21438533]

What does CONFIG_BL602_USE_1M_FLASH do in the BL602 SDK, and why was it necessary for BL602L10 1MB flash support?

CONFIG_BL602_USE_1M_FLASH switches the SDK to 1MB-compatible flash read logic instead of the default ROM-driver path used on larger parts. The thread found a conditional in the SDK where 1MB builds call a different XIP_SFlash_Read...Ext path. That mattered because standard reads froze during PSM and EasyFlash access on BL602L10. Once enabled, the same firmware could boot on 1MB parts and still worked on at least one 2MB module, so the flag became the practical compatibility switch for BL602L10 support. [#21438486]

What is EasyFlash on BL602, and how does the PSM partition size affect whether OpenBL602 can save Wi-Fi settings and boot counts?

EasyFlash is the BL602 key-value storage layer that saves settings like Wi-Fi credentials, boot counters, and config data inside the PSM partition. "EasyFlash is a flash-resident configuration store that saves persistent key-value settings, using sector-based ENV records and garbage collection." When PSM was only 8KB, OpenBL602 could boot but failed to save larger config changes reliably. A 32KB PSM worked much better, and testers explicitly linked successful setting saves to the larger PSM layout. Small PSM layouts also produced Alloc an ENV failed errors during config writes. [#21440834]

Which 1MB partition TOML layout worked best for OpenBL602 on BL602L10, and why was the standard 1M TOML considered unsuitable?

The most successful 1MB layout used roughly FW 0xD7000, media 0x2000, PSM 0x8000, and factory 0x7000. That layout was repeatedly tested and gave working EasyFlash with saved settings. The standard 1MB TOML was considered unsuitable because it gave PSM only 8KB, which was too small for larger OpenBL602 config writes around 3.6KB. That caused garbage-collection churn, failed ENV allocation, and settings not surviving reboot. Later discussion proposed cleaner variants, but the custom 32KB PSM TOML was the de facto working baseline. [#21432034]

How does a 1MB BL602L10 compare with a 2MB or 4MB BL602 module for running OpenBL602, OTA, LFS, and web features?

A 1MB BL602L10 can run OpenBL602, but it has far less room for OTA, LFS, Berry, and web extras than 2MB or 4MB modules. On 1MB, users had to trade partition space carefully, and LFS was often absent. A later 1MB-oriented build explicitly omitted Berry. OTA without a real second firmware partition failed, and media or LFS often had to be reduced or removed. By contrast, 2MB releases were already normal, and 4MB modules offered much more room for media and storage experiments. One tester estimated about 85.15KB free after a 793,444-byte build in an 860KB firmware partition. [#21438613]

What is PinDeepSleep in OpenBeken/OpenBL602, and why does its absence on BL602 matter for battery-powered temperature and humidity devices?

PinDeepSleep is a low-power wake mechanism that lets a device sleep deeply and wake from a GPIO event. "PinDeepSleep is a wake-on-pin sleep mode that cuts power use between reports, while still allowing a sensor or button GPIO to wake the MCU." Its absence on BL602 matters because battery devices like temperature and humidity sensors then stay in higher-power modes and drain cells much faster. The thread states BL602 had no PinDeepSleep support at that time, while Beken and XR families did. That made 1MB BL602 less attractive for battery-powered TH devices than for mains-powered switches. [#21598541]

Why does a BL602 module sometimes boot loop or behave unstably during Wi-Fi startup when powered on jumper wires or a breakout board?

Because BL602 Wi-Fi startup is sensitive to supply impedance, grounding, and noise on test wiring. Multiple testers saw loops exactly during AP start or flash erase, then fixed them by shortening VCC or ground leads, moving the module back into the original device, or avoiding noisy computer-powered setups. One module looped even around 3.5V–3.6V on bench wiring, then became stable after the VCC wire was shortened. Another tester confirmed stability improved when ground was connected closer to the board. In short, the module may be fine, but jumper-wire power delivery is not. [#21434069]

What wiring and resistor setup should be used to enter BL602 UART download mode with GPIO8, and how can a bad connection leave the module stuck in boot mode?

Use UART plus GPIO8 pulled high for download mode, preferably through a resistor rather than a hard short while experimenting. The thread mentions 10k as a practical pull-up value between 3.3V and IO8, while a NodeMCU-style BL602 board showed a 4.7k path to VDD and about 32k from IO8 to ground. A bad direct connection or damaged pad can leave the module always entering the bootloader, showing no normal firmware logs. One user measured abnormal resistance after forcing GPIO8 and then had to pull 3.3V again just to flash. [#21440301]

When replacing a Cozylife BL602 module with an ESP-12S or ESP-02S, what boot-pin issues like GPIO17 or GPIO0 need to be checked first?

Check whether any BL602 signal maps onto an ESP boot strap pin, especially GPIO0. In this thread, GPIO17 on the original module was called out because, if it drives the equivalent ESP boot path, the transplanted ESP-12S may fail to boot. One user warned that an earlier swap needed about a 1k pull-up from IO0 to 3.3V, otherwise GPIO0 stayed low at boot and the ESP never started. For this Cozylife switch, the safe rule was: trace GPIO17 first, then decide whether the swap is practical. [#21301840]

What caused some 1MB BL602 OpenBL602 builds to connect to an AP but fail during WPA/WPA2 handshake or open-network association?

The failures were inconsistent and looked partly like Wi-Fi stack maturity issues, not only flash size. Testers saw successful AP scan and association, but some WPA/WPA2 attempts stalled on the 4-way handshake, with hostapd reporting repeated EAPOL-Key timeout and deauth reason 15. Open networks also failed in at least one test build. Later discussion suggested PMF or router security settings affected reliability, and one maintainer said changing PMF made connection reliable during porting. So the main cause was unstable or incomplete Wi-Fi behavior in some builds, especially on 1MB test paths. [#21440513]

How should I troubleshoot a 1MB BL602 device that boots OpenBL602 but becomes slow, times out on web requests, or crashes when using the GPIO finder?

Start with power integrity, then test with minimal web load. 1. Reboot and confirm stable free RAM and Wi-Fi association before using the UI. 2. Avoid GPIO finder bursts first, because repeated /api/pins requests caused timeouts and memory drops in the thread. 3. Test from a clean AP setup, short wiring, and a light web session before enabling more features. One user watched free memory fall from about 113,856 bytes to 18,336 bytes, followed by Memory Allocate Failed and a dead web UI. That points to resource exhaustion under load, not a simple flash problem. [#21441931]

If OpenBL602 fits on a 1MB BL602L10, how much flash space is actually left for drivers and features like CHT83xx, Berry, media, or LFS?

Not much is left, so every feature costs something. In one working 1MB setup, the firmware partition was about 860KB, and a tested build size was 793,444 bytes, leaving roughly 85KB headroom. That made small drivers like CHT83xx look realistic, but large extras were harder. Later 1MB-oriented builds explicitly omitted Berry, and LFS was often missing or intentionally disabled. Media also got shrunk to 8KB or even 0KB in experiments. So 1MB BL602 can host core device support, but feature growth is tightly constrained. [#21438613]

What happened when users tried OTA on a 1MB BL602 layout without a proper OTA partition, and what checks would need to be added?

OTA failed and could destabilize the UI when no valid second firmware partition existed. One test tried an OTA file on a 1MB layout without proper OTA support and immediately logged error when get FW partition followed by a dead loop warning. Free memory then fell from about 102,080 bytes to 15,576 bytes, followed by Memory Allocate Failed. The thread conclusion was simple: OTA code needs a partition-existence check before starting the update path on 1MB layouts that do not reserve a real OTA slot. [#21620849]

Where can I find working OpenBL602 binaries for BL602L10 now, and how did support evolve from custom PR builds to standard releases working on 1MB flash too?

Use the normal OpenBL602 release for BL602 now, because the thread’s final update says the standard 2MB release also works on 1MB BL602L10. Support started with custom PR builds, especially the 1MB work around PR 1534, custom TOMLs, and manual SDK changes. Over time, the 1MB flash define became the key compatibility fix, and by January 4, 2026, the thread stated that end users could flash standard OpenBL602 on 1MB modules too. Earlier, the answer was a special PR build; later, it became the normal release path. [#21798426]
Generated by the language model.
ADVERTISEMENT