ESP32C3

Device embedded development product technical discussion, including topics such as TuyaOS, SDK, TuyaWind IDE and other developer tools.


Post Reply
Hashim
Posts: 3

I uses TuyaOS Development ESP32C3_TuyaOS-3.6.5
Linux Mint 22, python3.8, cmake 3.28.3
after compile tuyaos_demo_quickstart and download tuyaos_demo_quickstart_QIO_1.0.1.bin the module just print startup message.
it will not continue to run and will not enter the tuya_app_main() function.
The log is.

Code: Select all

ESP-RþESP-ROM:esp32c3-api1-20210207
Build:Feb  7 2021
rst:0x1 (POWERON),boot:0xd (SPI_FAST_FLASH_BOOT)
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fcd6100,len:0x1efc
load:0x403ce000,len:0x97c
load:0x403d0000,len:0x2fa8
entry 0x403ce000
[0;32mI (30) boot: ESP-IDF HEAD-HASH-NOTFOUND 2nd stage bootloader[0m
[0;32mI (30) boot: compile time 11:45:59[0m
D (30) bootloader_flash: XMC chip detected by RDID (00204016), skip.[0m
D (36) bootloader_flash: mmu set block paddr=0x00000000 (was 0xffffffff)[0m
[0;32mI (42) boot: chip revision: 3[0m
D (46) boot.esp32c3: magic e9[0m
D (49) boot.esp32c3: segments 03[0m
D (52) boot.esp32c3: spi_mode 02[0m
D (56) boot.esp32c3: spi_speed 0f[0m
D (59) boot.esp32c3: spi_size 02[0m
[0;32mI (62) boot.esp32c3: SPI Speed      : 80MHz[0m
[0;32mI (67) boot.esp32c3: SPI Mode       : DIO[0m
[0;32mI (72) boot.esp32c3: SPI Flash Size : 4MB[0m
[0;32mI (77) boot: Enabling RNG early entropy source...[0m
D (82) bootloader_flash: mmu set paddr=00000000 count=1 size=c00 src_addr=8000 src_addr_aligned=0[0m
D (91) boot: mapped partition table 0x8000 at 0x3c008000[0m
D (96) flash_parts: partition table verified, 8 entries[0m
[0;32mI (102) boot: Partition Table:[0m
[0;32mI (105) boot: ## Label            Usage          Type ST Offset   Length[0m
D (113) boot: load partition table entry 0x3c008000[0m
D (118) boot: type=1 subtype=2[0m
[0;32mI (121) boot:  0 nvs              WiFi data        01 02 00009000 00004000[0m
D (128) boot: load partition table entry 0x3c008020[0m
D (133) boot: type=1 subtype=0[0m
[0;32mI (136) boot:  1 otadata          OTA data         01 00 0000d000 00002000[0m
D (144) boot: load partition table entry 0x3c008040[0m
D (149) boot: type=1 subtype=1[0m
[0;32mI (152) boot:  2 phy_init         RF data          01 01 0000f000 00001000[0m
D (160) boot: load partition table entry 0x3c008060[0m
D (164) boot: type=0 subtype=10[0m
[0;32mI (168) boot:  3 ota_0            OTA app          00 10 00010000 00180000[0m
D (175) boot: load partition table entry 0x3c008080[0m
D (180) boot: type=0 subtype=11[0m
[0;32mI (183) boot:  4 ota_1            OTA app          00 11 00190000 00180000[0m
D (191) boot: load partition table entry 0x3c0080a0[0m
D (196) boot: type=1 subtype=aa[0m
[0;32mI (199) boot:  5 tuya             Unknown data     01 aa 003b0000 00028000[0m
D (207) boot: load partition table entry 0x3c0080c0[0m
D (212) boot: type=1 subtype=2[0m
[0;32mI (215) boot:  6 factory_nvs      WiFi data        01 02 003e0000 00004000[0m
[0;32mI (222) boot: End of partition table[0m
D (227) boot: OTA data offset 0xd000[0m
D (230) bootloader_flash: mmu set paddr=00000000 count=1 size=2000 src_addr=d000 src_addr_aligned=0[0m
D (239) boot: otadata[0]: sequence values 0x00000001[0m
D (244) boot: otadata[1]: sequence values 0xffffffff[0m
D (249) boot_comm: Only otadata[0] is valid[0m
D (254) boot: Active otadata[0][0m
D (257) boot: Mapping seq 0 -> OTA slot 0[0m
D (261) boot: Trying partition index 0 offs 0x10000 size 0x180000[0m
D (267) esp_image: reading image header @ 0x10000[0m
D (272) bootloader_flash: mmu set block paddr=0x00010000 (was 0xffffffff)[0m
D (279) esp_image: image header: 0xe9 0x06 0x02 0x02 403803fc[0m
V (285) esp_image: loading segment header 0 at offset 0x10018[0m
V (290) esp_image: segment data length 0x2d250 data starts 0x10020[0m
V (297) esp_image: segment 0 map_segment 1 segment_data_offs 0x10020 load_addr 0x3c100020[0m
[0;32mI (305) esp_image: segment 0: paddr=00010020 vaddr=3c100020 size=2d250h (184912) map[0m
D (313) esp_image: free data page_count 0x0000003f[0m
D (318) bootloader_flash: mmu set paddr=00010000 count=3 size=2d250 src_addr=10020 src_addr_aligned=10000[0m
V (357) esp_image: loading segment header 1 at offset 0x3d270[0m
D (357) bootloader_flash: mmu set block paddr=0x00030000 (was 0xffffffff)[0m
V (358) esp_image: segment data length 0x2da0 data starts 0x3d278[0m
V (364) esp_image: segment 1 map_segment 0 segment_data_offs 0x3d278 load_addr 0x3fc91200[0m
[0;32mI (373) esp_image: segment 1: paddr=0003d278 vaddr=3fc91200 size=02da0h ( 11680) load[0m
D (381) esp_image: free data page_count 0x0000003f[0m
D (386) bootloader_flash: mmu set paddr=00030000 count=2 size=2da0 src_addr=3d278 src_addr_aligned=30000[0m
V (398) esp_image: loading segment header 2 at offset 0x40018[0m
D (401) bootloader_flash: mmu set block paddr=0x00040000 (was 0xffffffff)[0m
V (408) esp_image: segment data length 0xfd244 data starts 0x40020[0m
V (414) esp_image: segment 2 map_segment 1 segment_data_offs 0x40020 load_addr 0x42000020[0m
[0;32mI (423) esp_image: segment 2: paddr=00040020 vaddr=42000020 size=fd244h (1036868) map[0m
D (431) esp_image: free data page_count 0x0000003f[0m
D (436) bootloader_flash: mmu set paddr=00040000 count=16 size=fd244 src_addr=40020 src_addr_aligned=40000[0m
V (608) esp_image: loading segment header 3 at offset 0x13d264[0m
D (608) bootloader_flash: mmu set block paddr=0x00130000 (was 0xffffffff)[0m
V (609) esp_image: segment data length 0x1c14 data starts 0x13d26c[0m
V (616) esp_image: segment 3 map_segment 0 segment_data_offs 0x13d26c load_addr 0x3fc93fa0[0m
[0;32mI (624) esp_image: segment 3: paddr=0013d26c vaddr=3fc93fa0 size=01c14h (  7188) load[0m
D (632) esp_image: free data page_count 0x0000003f[0m
D (637) bootloader_flash: mmu set paddr=00130000 count=1 size=1c14 src_addr=13d26c src_addr_aligned=130000[0m
V (648) esp_image: loading segment header 4 at offset 0x13ee80[0m
D (653) bootloader_flash: mmu set block paddr=0x00130000 (was 0xffffffff)[0m
V (660) esp_image: segment data length 0x11120 data starts 0x13ee88[0m
V (666) esp_image: segment 4 map_segment 0 segment_data_offs 0x13ee88 load_addr 0x40380000[0m
[0;32mI (674) esp_image: segment 4: paddr=0013ee88 vaddr=40380000 size=11120h ( 69920) load[0m
D (683) esp_image: free data page_count 0x0000003f[0m
D (688) bootloader_flash: mmu set paddr=00130000 count=2 size=11120 src_addr=13ee88 src_addr_aligned=130000[0m
V (710) esp_image: loading segment header 5 at offset 0x14ffa8[0m
D (711) bootloader_flash: mmu set block paddr=0x00140000 (was 0xffffffff)[0m
V (712) esp_image: segment data length 0x10 data starts 0x14ffb0[0m
V (718) esp_image: segment 5 map_segment 0 segment_data_offs 0x14ffb0 load_addr 0x50000010[0m
[0;32mI (726) esp_image: segment 5: paddr=0014ffb0 vaddr=50000010 size=00010h (    16) load[0m
D (735) esp_image: free data page_count 0x0000003f[0m
D (740) bootloader_flash: mmu set paddr=00140000 count=1 size=10 src_addr=14ffb0 src_addr_aligned=140000[0m
V (749) esp_image: image start 0x00010000 end of last section 0x0014ffc0[0m
D (756) bootloader_flash: mmu set block paddr=0x00140000 (was 0xffffffff)[0m
D (763) boot: Calculated hash: 282a76b848ce446acd96a666c14924625a6eb64e4b705cb68e32d33e51ce93f0[0m
[0;32mI (777) boot: Loaded app from partition at offset 0x10000[0m
[0;32mI (778) boot: Disabling RNG early entropy source...[0m
D (783) boot: Mapping segment 0 as DROM[0m
D (787) boot: Mapping segment 2 as IROM[0m
D (791) boot: calling set_cache_and_start_app[0m
D (796) boot: configure drom and irom and start[0m
V (800) boot: d mmu set paddr=00010000 vaddr=3c100000 size=184912 n=3[0m
V (807) boot: rc=0[0m
V (809) boot: i mmu set paddr=00040000 vaddr=42000000 size=1036868 n=16[0m
V (815) boot: rc=0[0m
D (818) boot: start: 0x403803fc[0m
[0;32mI (832) cpu_start: Pro cpu up.[0m
D (832) efuse: In EFUSE_BLK2__DATA4_REG is used 3 bits starting with 0 bit[0m
D (833) efuse: In EFUSE_BLK2__DATA4_REG is used 8 bits starting with 12 bit[0m
D (839) efuse: In EFUSE_BLK1__DATA3_REG is used 3 bits starting with 18 bit[0m
D (846) efuse: In EFUSE_BLK1__DATA5_REG is used 5 bits starting with 5 bit[0m
D (853) efuse: In EFUSE_BLK1__DATA4_REG is used 7 bits starting with 7 bit[0m
D (860) efuse: In EFUSE_BLK1__DATA4_REG is used 7 bits starting with 14 bit[0m
D (867) efuse: In EFUSE_BLK1__DATA4_REG is used 8 bits starting with 21 bit[0m
D (874) efuse: In EFUSE_BLK1__DATA4_REG is used 3 bits starting with 29 bit[0m
D (881) efuse: In EFUSE_BLK1__DATA5_REG is used 5 bits starting with 0 bit[0m
D (895) clk: RTC_SLOW_CLK calibration value: 3532634[0m
[0;32mI (904) cpu_start: Pro cpu start user code[0m
[0;32mI (904) cpu_start: cpu freq: 160000000[0m
[0;32mI (904) cpu_start: Application information:[0m
[0;32mI (907) cpu_start: Project name:     tuyaos_demo_quickstart[0m
[0;32mI (913) cpu_start: App version:      1[0m
[0;32mI (918) cpu_start: Compile time:     Nov  7 2024 11:45:39[0m
[0;32mI (924) cpu_start: ELF file SHA256:  650285542b6ace51...[0m
[0;32mI (930) cpu_start: ESP-IDF:          HEAD-HASH-NOTFOUND[0m
V (936) memory_layout: reserved range is 0x3c12ca9c - 0x3c12cab4[0m
D (942) memory_layout: Checking 4 reserved memory ranges:[0m
D (947) memory_layout: Reserved memory range 0x3fc80000 - 0x3fc91200[0m
D (954) memory_layout: Reserved memory range 0x3fc91200 - 0x3fc9f7c0[0m
D (960) memory_layout: Reserved memory range 0x3fcdf060 - 0x3fce0000[0m
D (966) memory_layout: Reserved memory range 0x50000000 - 0x50000020[0m
D (973) memory_layout: Building list of available memory regions:[0m
V (979) memory_layout: Examining memory region 0x3fc80000 - 0x3fca0000[0m
V (986) memory_layout: Start of region 0x3fc80000 - 0x3fca0000 overlaps reserved 0x3fc80000 - 0x3fc91200[0m
V (995) memory_layout: Start of region 0x3fc91200 - 0x3fca0000 overlaps reserved 0x3fc91200 - 0x3fc9f7c0[0m
D (1005) memory_layout: Available memory region 0x3fc9f7c0 - 0x3fca0000[0m
V (1011) memory_layout: Examining memory region 0x3fca0000 - 0x3fcc0000[0m
D (1018) memory_layout: Available memory region 0x3fca0000 - 0x3fcc0000[0m
V (1025) memory_layout: Examining memory region 0x3fcc0000 - 0x3fce0000[0m
V (1031) memory_layout: End of region 0x3fcc0000 - 0x3fce0000 overlaps reserved 0x3fcdf060 - 0x3fce0000[0m
D (1041) memory_layout: Available memory region 0x3fcc0000 - 0x3fcdf060[0m
V (1048) memory_layout: Examining memory region 0x50000000 - 0x50002000[0m
V (1054) memory_layout: Start of region 0x50000000 - 0x50002000 overlaps reserved 0x50000000 - 0x50000020[0m
D (1064) memory_layout: Available memory region 0x50000020 - 0x50002000[0m
[0;32mI (1071) heap_init: Initializing. RAM available for dynamic allocation:[0m
D (1078) heap_init: New heap initialised at 0x3fc9f7c0[0m
[0;32mI (1083) heap_init: At 3FC9F7C0 len 00020840 (130 KiB): DRAM[0m
[0;32mI (1089) heap_init: At 3FCC0000 len 0001F060 (124 KiB): STACK/DRAM[0m
D (1096) heap_init: New heap initialised at 0x50000020[0m
[0;32mI (1101) heap_init: At 50000020 len 00001FE0 (7 KiB): RTCRAM[0m
D (1108) FLASH_HAL: extra_dummy: 0[0m
V (1111) memspi: raw_chip_id: 164020
[0m
V (1115) memspi: chip_id: 204016
[0m
V (1119) memspi: raw_chip_id: 164020
[0m
V (1122) memspi: chip_id: 204016
[0m
D (1126) spi_flash: trying chip: issi[0m
D (1130) spi_flash: trying chip: gd[0m
D (1133) spi_flash: trying chip: mxic[0m
D (1137) spi_flash: trying chip: winbond[0m
D (1141) spi_flash: trying chip: boya[0m
D (1145) spi_flash: trying chip: th[0m
D (1148) spi_flash: trying chip: generic[0m
[0;32mI (1152) spi_flash: detected chip: generic[0m
[0;32mI (1157) spi_flash: flash io: dio[0m
D (1161) cpu_start: calling init function: 0x420e7a78[0m
D (1166) cpu_start: calling init function: 0x420e79b4[0m
D (1171) cpu_start: calling init function: 0x420e7538[0m
D (1176) cpu_start: calling init function: 0x420e739c[0m
D (1181) cpu_start: calling init function: 0x420d8cf8[0m
D (1187) efuse: In EFUSE_BLK2__DATA4_REG is used 3 bits starting with 0 bit[0m
D (1194) efuse: In EFUSE_BLK2__DATA5_REG is used 10 bits starting with 18 bit[0m
V (1201) ADC: Calib(V1) ADC1 atten=3: 06C6[0m
D (1205) cpu_start: calling init function: 0x4209566a[0m
D (1210) cpu_start: calling init function: 0x4208da08[0m
D (1215) cpu_start: calling init function: 0x4200002a[0m
V (1220) intr_alloc: esp_intr_alloc_intrstatus (cpu 0): checking args[0m
V (1227) intr_alloc: esp_intr_alloc_intrstatus (cpu 0): Args okay. Resulting flags 0xC02[0m
D (1235) intr_alloc: Connected src 39 to int 2 (cpu 0)[0m
V (1240) esp_dbg_stubs: esp_dbg_stubs_ll_init stubs 3fc95be4[0m
[0;32mI (1246) esp_core_dump_uart: Init core dump to UART[0m
[0;32mI (1252) coexist: coexist rom version 9387209[0m
V (1257) intr_alloc: esp_intr_alloc_intrstatus (cpu 0): checking args[0m
V (1263) intr_alloc: esp_intr_alloc_intrstatus (cpu 0): Args okay. Resulting flags 0x40E[0m
D (1271) intr_alloc: Connected src 50 to int 3 (cpu 0)[0m
[0;32mI (1276) cpu_start: Starting scheduler.[0m
V (1281) intr_alloc: esp_intr_alloc_intrstatus (cpu 0): checking args[0m
V (1281) intr_alloc: esp_intr_alloc_intrstatus (cpu 0): Args okay. Resulting flags 0x402[0m
D (1281) intr_alloc: Connected src 37 to int 4 (cpu 0)[0m
D (1281) heap_init: New heap initialised at 0x3fcc0000[0m
JSHANG
Posts: 35

Re: ESP32C3

Hi Hashim,

It looks like the partition table incorrect, the partition table of Tuya's as follows(vendor\esp32\tuyaos\partitions.csv):

Name, Type, SubType, Offset, Size

nvs, data, nvs, 0x9000, 0x4000
otadata, data, ota, 0xd000, 0x2000
phy_init, data, phy, 0xf000, 0x1000
ota_0,0, ota_0, 0x10000, 0x180000
ota_1,0, ota_1, 0x190000, 0x180000
tuya, data, 0xAA, 0x3b0000, 0x28000
factory_nvs, data, nvs, 0x3e0000, 0x4000

What's the offset address use for download tuyaos_demo_quickstart_QIO_1.0.1.bin?
You can try to download it like that:

屏幕截图 2024-11-07 204734.png

Thanks,

Hashim
Posts: 3

Re: ESP32C3

I have set the offset address of tuyaos_demo_quickstart_QIO_1.0.1.bin to 0x0, same problem.

JSHANG
Posts: 35

Re: ESP32C3

  1. Which module of C3 used for you?
  2. Could you show me the compile and startup message?
  3. Please try to program attachment bin file "tuyaos_demo_quickstart_QIO_1.0.1.bin", check is it can work or not.
Attachments
tuyaos_demo_quickstart_QIO_1.0.0.rar
(791.54 KiB) Downloaded 4 times
Hashim
Posts: 3

Re: ESP32C3

It's solved, Tuya_console_start() in main_app() set uart port to another pin
Thank you for your help.

Post Reply