ESPHome  2024.4.1
Data Structures | Enumerations | Variables
esphome::deep_sleep Namespace Reference

Data Structures

class  AllowDeepSleepAction
 
class  DeepSleepComponent
 This component allows setting up the node to go into deep sleep mode to conserve battery. More...
 
class  EnterDeepSleepAction
 
struct  Ext1Wakeup
 
class  PreventDeepSleepAction
 
struct  WakeupCauseToRunDuration
 

Enumerations

enum  WakeupPinMode { WAKEUP_PIN_MODE_IGNORE = 0, WAKEUP_PIN_MODE_KEEP_AWAKE, WAKEUP_PIN_MODE_INVERT_WAKEUP }
 The values of this enum define what should be done if deep sleep is set up with a wakeup pin on the ESP32 and the scenario occurs that the wakeup pin is already in the wakeup state. More...
 

Variables

bool global_has_deep_sleep = false
 

Enumeration Type Documentation

◆ WakeupPinMode

The values of this enum define what should be done if deep sleep is set up with a wakeup pin on the ESP32 and the scenario occurs that the wakeup pin is already in the wakeup state.

Enumerator
WAKEUP_PIN_MODE_IGNORE 

Ignore the fact that we will wake up when going into deep sleep.

WAKEUP_PIN_MODE_KEEP_AWAKE 

As long as the wakeup pin is still in the wakeup state, keep awake.

WAKEUP_PIN_MODE_INVERT_WAKEUP 

Automatically invert the wakeup level.

For example if we were set up to wake up on HIGH, but the pin is already high when attempting to enter deep sleep, re-configure deep sleep to wake up on LOW level.

Definition at line 27 of file deep_sleep_component.h.

Variable Documentation

◆ global_has_deep_sleep

bool esphome::deep_sleep::global_has_deep_sleep = false

Definition at line 15 of file deep_sleep_component.cpp.