ESPHome 2026.2.1
Loading...
Searching...
No Matches
esphome::cover Namespace Reference

Data Structures

class  CloseAction
 
class  ControlAction
 
class  Cover
 Base class for all cover devices. More...
 
class  CoverCall
 
class  CoverPositionCondition
 
class  CoverPositionTrigger
 
class  CoverPublishAction
 
struct  CoverRestoreState
 Struct used to store the restored state of a cover. More...
 
class  CoverTraits
 
class  CoverTrigger
 
class  OpenAction
 
class  StopAction
 
class  ToggleAction
 

Typedefs

template<typename... Ts>
using CoverIsOpenCondition = CoverPositionCondition<true, Ts...>
 
template<typename... Ts>
using CoverIsClosedCondition = CoverPositionCondition<false, Ts...>
 
using CoverOpenedTrigger = CoverPositionTrigger<true>
 
using CoverClosedTrigger = CoverPositionTrigger<false>
 

Enumerations

enum  CoverOperation : uint8_t { COVER_OPERATION_IDLE = 0 , COVER_OPERATION_OPENING , COVER_OPERATION_CLOSING }
 Enum encoding the current operation of a cover. More...
 

Functions

const LogString * cover_command_to_str (float pos)
 
 PROGMEM_STRING_TABLE (CoverOperationStrings, "IDLE", "OPENING", "CLOSING", "UNKNOWN")
 
const LogString * cover_operation_to_str (CoverOperation op)
 
struct esphome::cover::CoverRestoreState __attribute__ ((packed))
 

Variables

enum esphome::cover::CoverOperation __attribute__
 

Typedef Documentation

◆ CoverClosedTrigger

Definition at line 123 of file automation.h.

◆ CoverIsClosedCondition

template<typename... Ts>
using esphome::cover::CoverIsClosedCondition = CoverPositionCondition<false, Ts...>

Definition at line 104 of file automation.h.

◆ CoverIsOpenCondition

template<typename... Ts>
using esphome::cover::CoverIsOpenCondition = CoverPositionCondition<true, Ts...>

Definition at line 103 of file automation.h.

◆ CoverOpenedTrigger

Definition at line 122 of file automation.h.

Enumeration Type Documentation

◆ CoverOperation

Enum encoding the current operation of a cover.

Enumerator
COVER_OPERATION_IDLE 

The cover is currently idle (not moving)

COVER_OPERATION_OPENING 

The cover is currently opening.

COVER_OPERATION_CLOSING 

The cover is currently closing.

Definition at line 79 of file cover.h.

Function Documentation

◆ __attribute__()

struct esphome::cover::CoverRestoreState esphome::cover::__attribute__ ( (packed) )

◆ cover_command_to_str()

const LogString * esphome::cover::cover_command_to_str ( float pos)

Definition at line 13 of file cover.cpp.

◆ cover_operation_to_str()

const LogString * esphome::cover::cover_operation_to_str ( CoverOperation op)

Definition at line 25 of file cover.cpp.

◆ PROGMEM_STRING_TABLE()

esphome::cover::PROGMEM_STRING_TABLE ( CoverOperationStrings ,
"IDLE" ,
"OPENING" ,
"CLOSING" ,
"UNKNOWN"  )

Variable Documentation

◆ __attribute__

enum esphome::cover::CoverOperation esphome::cover::__attribute__