Firebeetle Esp32 V4 deep sleep

userHead Dor 2022-08-16 03:53:08 850 Views1 Replies

Hi,

I've been trying to get the get the firebeetle into deep sleep for some time with no success,

When measuring the current I'm getting above [email protected].

I'm using the code below from the user manual, also I installed the board as shown in the manual.

 

What am I missing ?

 

void setup() {
// put your setup code here, to run once:
pinMode(D9,OUTPUT);
digitalWrite(D9,HIGH);
delay(1000);
digitalWrite(D9,LOW);
ESP.deepSleep(5000000);
}

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

 

 

 

2022-08-23 15:40:51

The sample code is to restart esp32 after 5 seconds, you can set wakeup from external interrupt after deep sleep, refer to the following code:

 

void setup() {

// put your setup code here, to run once:

pinMode(D9,OUTPUT);

digitalWrite(D9,HIGH);

delay(1000);

digitalWrite(D9,LOW);

esp_deep_sleep_enable_ext0_wakeup(GPIO_NUM_25,LOW); 

esp_deep_sleep_start();

}

void loop() {

// put your main code here, to run repeatedly:

}

userHeadPic Winster