Arduino-esp32: Power consumption in deep sleep after WIFI connection

Created on 20 May 2019  路  1Comment  路  Source: espressif/arduino-esp32

Without WIFI i have 7uA in deep sleep
After wifi connection - 1.3mA

#include <WiFi.h>
#include <esp_wifi.h>
#include <esp_sleep.h>
#include "soc/rtc_cntl_reg.h"
#include "esp_deep_sleep.h"
#include "rom/rtc.h"
#include "driver/rtc_io.h"
#include <sys/time.h>

void setup(){
  esp_sleep_enable_ext0_wakeup(GPIO_NUM_15,0);
  WiFi.config(IPAddress(192,168,2,215), IPAddress(192,168,2,1), IPAddress(255,255,255,0), IPAddress(192,168,2,1));
  WiFi.mode(WIFI_STA);
  WiFi.begin("", "");
  while (WiFi.status() != WL_CONNECTED);
}

void loop(){
  esp_wifi_stop();
  WiFi.mode(WIFI_OFF);
  esp_deep_sleep_start();
}

What's wrong?

Most helpful comment

Ok, i found a solution about that!
https://github.com/espressif/esp-idf/issues/2315
```cpp

include "driver/adc.h"

adc_power_off();

>All comments

Ok, i found a solution about that!
https://github.com/espressif/esp-idf/issues/2315
```cpp

include "driver/adc.h"

adc_power_off();

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mistergreen picture mistergreen  路  4Comments

paramono picture paramono  路  4Comments

merlinschumacher picture merlinschumacher  路  4Comments

Curclamas picture Curclamas  路  4Comments

zuqualla picture zuqualla  路  4Comments