Firebeetle 2 esp32c6 error: pll_cal exceeds 2ms!
I am compiling my project with arduino ide, it worked fine for 2 weeks now, but snce 3 day ago, i am getting this error when the device wakes fom deep sleep or restarts after working for a few hours:
error: pll_cal exceeds 2ms
after getting this error, the wifi will not connect ever again, no matter the deep sleeps after that or software resets…
commands like abort() or ESP.restart() do not work to fix this issue, only when i press the hardware reset button.
did i get a faulty board, or is this a software issue?
a bit of the neccessary code:
setup
///
Serial.begin(115200);
analogReadResolution(12);
#ifdef DEVELOPMENT
delay(1000);
#endif
General::InitDevice()
////
RTC_DATA_ATTR unsigned long bootCount = 0;
RTC_DATA_ATTR unsigned long requestFails = 0;
void General::InitDevice() {
Serial.println("---------------------");
Serial.print("bootCount: ");
Serial.println(bootCount);
Serial.print("requestFails: ");
Serial.println(requestFails);
if (requestFails > 2) {
abort();
//ESP.restart();
}
Serial.println("Init Device");
preferences.begin(PROJECT, false);
++bootCount;
String uid = preferences.getString("uid", "");
if (uid.length() <= 0) {
uid = General::GenerateUUID();
preferences.putString("uid", uid);
}
Serial.print("uid: ");
Serial.println(uid);
String hostname = PROJECT + String("-") + uid.substring(0, 8); //project name + first 8 chars from uid
WiFiClass::setHostname(hostname.c_str());
Serial.print("SSID: ");
Serial.println(WIFI_SSID);
uint8_t wifiFails = 0;
WiFiClass::mode(WIFI_STA);
//WiFi.setAutoReconnect(true);
WiFi.begin(WIFI_SSID, WIFI_PASS);
while (WiFiClass::status() != WL_CONNECTED) {
delay(500);
Serial.print(".");
if (wifiFails > 24) {
requestFails++;
General::PutToSleep();
}
wifiFails++;
}
Serial.println("Connected!")
///
void General::PutToSleep(unsigned long microSeconds) {
uptime += millis();
General::UpdateStatus(DeviceState::SLEEP);
//WiFi.setSleep(false);
WiFi.disconnect();
ESP.deepSleep(microSeconds);
}
Hi, I think it has something to do with the hardware (power issue). Apparently, I use a 10uF capacitor and connect it to 3.3v pin and GND pin of the esp32-c6 and it fixes the problem. Try with your board. But I have another problem with the board. I can't seem to get the current consumption to decrease when I put it in deep sleep mode (The product wiki says it should be around 16uA). I use the standard ESP32/DeepSleep/TimerWakeUp sketch and connect a multimeter in series with the board to monitor the current consumption. Do you have any idea?
FakhrullahsI have the same issue with the exact board :(
FakhrullahsAny good update on your board though?