ESP32排坑表

问题1: 官方代码第一次烧录,无限重启报错

  • ESP32-DevKitC 板载的是 ESP32-SOLO-1 模组,烧录第一个示例程序后,不断重启报错信息如下:
ELF file SHA256: bd0533951ab2ae2f

Rebooting...
ets Jun  8 2016 00:22:57

rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:6928
load:0x40078000,len:15388
load:0x40080400,len:3824
entry 0x4008064c
I (27) boot: ESP-IDF v5.0-beta1-dirty 2nd stage bootloader
I (27) boot: compile time 17:09:48
I (27) boot: chip revision: V100
I (31) boot_comm: chip revision: 1, min. bootloader chip revision: 0
I (38) boot.esp32: SPI Speed      : 40MHz
I (43) boot.esp32: SPI Mode       : DIO
I (47) boot.esp32: SPI Flash Size : 2MB
I (52) boot: Enabling RNG early entropy source...
I (57) boot: Partition Table:
I (61) boot: ## Label            Usage          Type ST Offset   Length
I (68) boot:  0 nvs              WiFi data        01 02 00009000 00006000
I (76) boot:  1 phy_init         RF data          01 01 0000f000 00001000
I (83) boot:  2 factory          factory app      00 00 00010000 00100000
I (90) boot: End of partition table
I (95) boot_comm: chip revision: 1, min. application chip revision: 0
I (102) esp_image: segment 0: paddr=00010020 vaddr=3f400020 size=0799ch ( 31132) map
I (122) esp_image: segment 1: paddr=000179c4 vaddr=3ffb0000 size=02648h (  9800) load
I (126) esp_image: segment 2: paddr=0001a014 vaddr=40080000 size=06004h ( 24580) load
I (140) esp_image: segment 3: paddr=00020020 vaddr=400d0020 size=15544h ( 87364) map
I (171) esp_image: segment 4: paddr=0003556c vaddr=40086004 size=055e0h ( 21984) load
I (181) esp_image: segment 5: paddr=0003ab54 vaddr=50000000 size=00010h (    16) load
I (187) boot: Loaded app from partition at offset 0x10000
I (187) boot: Disabling RNG early entropy source...
I (202) cpu_start: Pro cpu up.
E (202) cpu_start: Running on single core variant of a chip, but app is built with multi-core support.
E (205) cpu_start: Check that CONFIG_FREERTOS_UNICORE is enabled in menuconfig

abort() was called at PC 0x400d0d08 on core 0


Backtrace: 0x40081ada:0x3ffe3b60 0x400855b9:0x3ffe3b80 0x4008a1aa:0x3ffe3ba0 0x400d0d08:0x3ffe3c10 0x40081184:0x3ffe3c40 0x400795cd:0x3ffe3c90 |<-CORRUPTED 
  • 出错原因Log打印消息已给出提示Running on single core variant of a chip, but app is built with multi-core support.

  • 原因分析:
    ESP32-SOLO-1 模组用的是单核CPU,而程序是基于multi-core模式编译的,此时只需要通过mencuconfig将宏参CONFIG_FREERTOS_UNICORE使能即可。

在这里插入图片描述


问题2:找不到编译相关工具

  • 如:调用idf.py的时候报错
idf.py set-target esp32
ESP-IDF v4.4.2-dirty
'cmake' must be available on the PATH to use idf.py 
  • 解决:Windows环境下需要调用export.ps1
PS E:\esp32\idf\esp-idf-v5.0-beta1> .\export.ps1
Setting IDF_PATH: E:\esp32\idf\esp-idf-v5.0-beta1
Checking Python compatibility
Adding ESP-IDF tools to PATH...

Name                           Value
----                           -----
OPENOCD_SCRIPTS                D:\Espressif\tools\openocd-esp32\v0.11.0-esp32-20220706\openocd-esp32\share\openocd\scripts
IDF_CCACHE_ENABLE              1
ESP_IDF_VERSION                5.0

Added to PATH
-------------
E:\esp32\idf\esp-idf-v5.0-beta1\components\esptool_py\esptool
E:\esp32\idf\esp-idf-v5.0-beta1\components\app_update
E:\esp32\idf\esp-idf-v5.0-beta1\components\espcoredump
E:\esp32\idf\esp-idf-v5.0-beta1\components\partition_table
D:\Espressif\tools\xtensa-esp-elf-gdb\11.2_20220715\xtensa-esp-elf-gdb\bin
D:\Espressif\tools\riscv32-esp-elf-gdb\11.2_20220715\riscv32-esp-elf-gdb\bin
D:\Espressif\tools\xtensa-esp32s2-elf\esp-2022r1-RC1-11.2.0\xtensa-esp32s2-elf\bin
D:\Espressif\tools\xtensa-esp32s3-elf\esp-2022r1-RC1-11.2.0\xtensa-esp32s3-elf\bin
D:\Espressif\tools\riscv32-esp-elf\esp-2022r1-RC1-11.2.0\riscv32-esp-elf\bin
D:\Espressif\tools\esp32ulp-elf\2.28.51-esp-20191205\esp32ulp-elf-binutils\bin
D:\Espressif\tools\esp32s2ulp-elf\2.28.51-esp-20191205\esp32s2ulp-elf-binutils\bin
D:\Espressif\tools\cmake\3.23.1\bin
D:\Espressif\tools\openocd-esp32\v0.11.0-esp32-20220706\openocd-esp32\bin
D:\Espressif\tools\ninja\1.10.2\
D:\Espressif\tools\idf-exe\1.0.3\
D:\Espressif\tools\ccache\4.3\ccache-4.3-windows-64
D:\Espressif\tools\dfu-util\0.9\dfu-util-0.9-win64
E:\esp32\idf\esp-idf-v5.0-beta1\tools
Checking if Python packages are up to date...
ERROR: D:\Espressif\python_env\idf5.0_py3.10_env\Scripts\python.exe doesn't exist! Please run the install script or "idf_tools.py install-python-env" in order to create it

Detected installed tools that are not currently used by active ESP-IDF version.
For removing idf-driver, idf-python-wheels use command 'python.exe E:\esp32\idf\esp-idf-v5.0-beta1\tools\idf_tools.py uninstall'
For free up even more space, remove installation packages of those tools. Use option 'python.exe E:\esp32\idf\esp-idf-v5.0-beta1\tools\idf_tools.py uninstall --remove-archives'.


Done! You can now compile ESP-IDF projects.
Go to the project directory and run:
    idf.py build




PS E:\esp32\idf\esp-idf-v5.0-beta1>

注意:上述Log 中的报错提示

 ERROR: D:\Espressif\python_env\idf5.0_py3.10_env\Scripts\python.exe doesn't exist! Please run the install script or "idf_tools.py install-python-env" in order to create it
  • 解决方案:idf_tools.py install-python-env

  • 2
    点赞
  • 5
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值