我在使用esp32在arduino中执行简单任务时遇到此看门狗定时器错误

问题描述 投票:0回答:1

我已经看到很多论坛都讨论过这个问题,但似乎没什么用。我正在使用esp32,它一切都很好,直到这个看门狗定时器错误出现。我是新手,所以我无法解决这个问题。我有另一个代码,但我复制了一个非常简单的块,并创建了一个新文件,但看门狗计时器错误也出现在这里。我不知道是什么问题。它说idle0没有重置watach dog计时器,并且“wifi”任务正在cpu0上运行。

错误日志E(42418)task_wdt:任务监视程序被触发。以下任务未及时重置监视程序:E(42418)task_wdt: - IDLE0(CPU 0)E(42418)task_wdt:当前正在运行的任务:E(42418)task_wdt:CPU 0:wifi E(42418)task_wdt:CPU 1:IDLE1 E(42418)task_wdt:正在中止。 abort()在核心0上的PC 0x400d96f7处调用

Backtrace:0x4008c470:0x3ffbe270 0x4008c6a1:0x3ffbe290 0x400d96f7:0x3ffbe2b0 0x400815dd:0x3ffbe2d0 0x40136087:0x00000000

重新启动... ets 2016年6月8日00:22:57

rst:0xc(SW_CPU_RESET),引导:0x17(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模式:DIO,时钟div: 1 load:0x3fff0018,len:4 load:0x3fff001c,len:1100 load:0x40078000,len:10088 load:0x40080400,len:6380 entry 0x400806a4

我已经尝试在cpu1或核心1上运行我的任务但是wifi会自动在cpu或core0上运行。并得到同样的错误。我也试过添加延迟,但没有任何作用。



char *wssid = "PTCL-TB";
char *wpassword = "pakistan";

bool connected2Wifi = false;
void setup() {
 // put your setup code here, to run once:

 Serial.begin(115200);
 delay(10);
 Serial.println('\n');

 WiFi.begin(wssid, wpassword);             // Connect to the network
 Serial.print("Connecting to ");
 Serial.print(wssid);

 while (WiFi.status() != WL_CONNECTED) { // Wait for the Wi-Fi to connect
   delay(500);
   Serial.print('.');
 }

 Serial.println('\n');
 Serial.println("Connection established!");  
 Serial.print("IP address:\t");
 Serial.println(WiFi.localIP()); 
}

void loop() {
 // put your main code here, to run repeatedly:

} ```

I want to connect to wifi in this task. It's very simple and i have also copied it from a reliable source whose code was running. but the error seems to be rigid.
arduino watchdog esp32
1个回答
0
投票

转到工具 - > CPU频率并将其设置为160,80或240 MHz(支持WiFi / BT的那些)。

© www.soinside.com 2019 - 2024. All rights reserved.