就是我在使用esp_http_client_init()函数时,运行时会报错,板子不断reboot,这是什么原因导致的,有什么解决的办法吗?
以下是我调用esp_http_client_init()的相关函数
esp_http_client_config_t config;
config.event_handler = ocr_http_event_handler;
config.buffer_size = 4 * 1024;
config.timeout_ms = 4000;
config.url = temp_url.c_str();
Serial.print("config.url = ");
Serial.println(config.url);
esp_http_client_handle_t client = esp_http_client_init(&config);
esp_http_client_set_method(client, HTTP_METHOD_POST);
esp_http_client_set_header(client, "Content-Type", "application/x-www-form-urlencoded");
esp_http_client_set_post_field(client, temp_url.c_str(), sizeof(temp_url.c_str()));
以下是报错的内容
Guru Meditation Error: Core 1 panic'ed (LoadProhibited). Exception was unhandled.
Core 1 register dump:
PC : 0x4008d858 PS : 0x00060730 A0 : 0x800d7a48 A1 : 0x3ffb1e00
A2 : 0x0000000f A3 : 0x0000000b A4 : 0x000000ff A5 : 0x0000ff00
A6 : 0x00ff0000 A7 : 0xff000000 A8 : 0x00000001 A9 : 0x00000000
A10 : 0x3ffdf50c A11 : 0x3f401614 A12 : 0x000000ff A13 : 0x0000ff00
A14 : 0x00ff0000 A15 : 0xff000000 SAR : 0x00000019 EXCCAUSE: 0x0000001c
EXCVADDR: 0x0000000f LBEG : 0x4008d879 LEND : 0x4008d889 LCOUNT : 0xfffffffd
ELF file SHA256: 0000000000000000
Backtrace: 0x4008d858:0x3ffb1e00 0x400d7a45:0x3ffb1e10 0x400d161b:0x3ffb1e30 0x400d1bb9:0x3ffb1ec0 0x400d537c:0x3ffb1fb0 0x400908de:0x3ffb1fd0
以下是错误的出处
C:\Users\28032\AppData\Local\Arduino15\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-97-gc752ad5-5.2.0\bin>xtensa-esp32-elf-addr2line -e python.ino.elf 0x4008d858:0x3ffb1e00 0x400d7a45:0x3ffb1e10 0x400d161b:0x3ffb1e30 0x400d1bb9:0x3ffb1ec0 0x400d537c:0x3ffb1fb0 0x400908de:0x3ffb1fd0
/home/mak/e/p/newlib_old/newlib_xtensa-bin/newlib_xtensa-2.2.0/xtensa-esp32-elf/newlib/libc/machine/xtensa/../../../../.././newlib/libc/machine/xtensa/strlen.S:46
/home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/esp_http_client/esp_http_client.c:335
C:\Users\28032\Documents\Arduino\python/python.ino:163
C:\Users\28032\Documents\Arduino\python/python.ino:283
C:\Users\28032\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\cores\esp32/main.cpp:30
/home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/freertos/port.c:355 (discriminator 1)
esp32 不断重启
Jump to
- English Forum
- Explore
- News
- General Discussion
- FAQ
- Documentation
- Documentation
- Sample Code
- Discussion Forum
- Hardware
- ESP-IDF
- ESP-BOX
- ESP-ADF
- ESP-MDF
- ESP-WHO
- ESP-SkaiNet
- ESP32 Arduino
- IDEs for ESP-IDF
- ESP-AT
- ESP IoT Solution
- ESP RainMaker
- Rust
- ESP8266
- Report Bugs
- Showcase
- Chinese Forum 中文社区
- 活动区
- 乐鑫活动专区
- 讨论区
- 全国大学生物联网设计竞赛乐鑫答疑专区
- ESP-IDF 中文讨论版
- 《ESP32-C3 物联网工程开发实战》书籍讨论版
- 中文文档讨论版
- ESP-AT 中文讨论版
- ESP-BOX 中文讨论版
- ESP IoT Solution 中文讨论版
- ESP-ADF 中文讨论版
- ESP Mesh 中文讨论版
- ESP Cloud 中文讨论版
- ESP-WHO 中文讨论版
- ESP-SkaiNet 中文讨论版
- ESP 生产支持讨论版
- 硬件问题讨论
- 项目展示
Who is online
Users browsing this forum: No registered users and 42 guests
- All times are UTC
- Top
- Delete cookies
About Us
Espressif Systems is a fabless semiconductor company providing cutting-edge low power WiFi SoCs and wireless solutions for wireless communications and Internet of Things applications. ESP8266EX and ESP32 are some of our products.