Hi, I have tested my ESP32 thing PLUS in several circuits and by itself in deep sleep and it cannot sleep under 7mA. I do not understand what I am missing as the product page advertises 2.5 µA deep sleep current. I also tested the same code with a generic ESP32 WROVER and it consumes twice less with an onboard LED turned on during deep sleep. Am I missing something? Is there some circuitry that needs to be pulled up on board?
Here is the code I have been using:
#include <Arduino.h>
#define LED_GPIO (GPIO_NUM_13)
#define TACT_GPIO (GPIO_NUM_27)
void setup()
{
Serial.begin(9600);
Serial.println("hello going to sleep");
pinMode(LED_GPIO, OUTPUT);
pinMode(27, INPUT);
digitalWrite(LED_GPIO, HIGH);
delay(3000);
digitalWrite(LED_GPIO, LOW);
pinMode(LED_GPIO, INPUT);
Serial.println("now");
esp_sleep_enable_ext0_wakeup(TACT_GPIO, 0); // 0 = Wake up on Low
Serial.flush();
esp_deep_sleep_start();
}
void loop()
{
}