ESPHome 2026.11.0b6
Loading...
Searching...
No Matches
esphome::sgp4x::SGP4xComponent Class Referencefinal

This class implements support for the Sensirion sgp4x i2c GAS (VOC) sensors. More...

#include <sgp4x.h>

Inheritance diagram for esphome::sgp4x::SGP4xComponent:
esphome::PollingComponent esphome::sensor::Sensor esphome::sensirion_common::SensirionI2CDevice esphome::Component esphome::EntityBase esphome::i2c::I2CDevice

Public Member Functions

 SUB_SENSOR (humidity) SUB_SENSOR(temperature) void setup() override
 
void update () override
 
void take_sample ()
 
void dump_config () override
 
void set_store_baseline (bool store_baseline)
 
 SUB_SENSOR (voc) SUB_SENSOR(nox) void set_voc_algorithm_tuning(uint16_t index_offset
 
void set_nox_algorithm_tuning (uint16_t index_offset, uint16_t learning_time_offset_hours, uint16_t learning_time_gain_hours, uint16_t gating_max_duration_minutes, uint16_t gain_factor)
 
- Public Member Functions inherited from esphome::PollingComponent
 PollingComponent ()
 
 PollingComponent (uint32_t update_interval)
 Initialize this polling component with the given update interval in ms.
 
void set_update_interval (uint32_t update_interval)
 Manually set the update interval in ms for this polling object.
 
void call_setup () override
 
virtual uint32_t get_update_interval () const
 Get the update interval in ms of this sensor.
 
void start_poller ()
 
void stop_poller ()
 
- Public Member Functions inherited from esphome::Component
virtual void setup ()
 Where the component's initialization should happen.
 
virtual void loop ()
 This method will be called repeatedly.
 
virtual float get_setup_priority () const
 priority of setup().
 
float get_actual_setup_priority () const
 
void set_setup_priority (float priority)
 
void call ()
 
virtual void on_shutdown ()
 
virtual void on_safe_shutdown ()
 
virtual bool teardown ()
 Called during teardown to allow component to gracefully finish operations.
 
virtual void on_powerdown ()
 Called last before a reboot or deep sleep to power down hardware.
 
uint8_t get_component_state () const
 
void reset_to_construction_state ()
 Reset this component back to the construction state to allow setup to run again.
 
bool is_in_loop_state () const
 Check if this component has completed setup and is in the loop state.
 
bool is_idle () const
 Check if this component is idle.
 
void mark_failed ()
 Mark this component as failed.
 
void mark_failed (const LogString *message)
 
bool ESPHOME_ALWAYS_INLINE setup_check (bool ok)
 Marks the component failed with message (default "Communication failed") unless ok; returns ok.
 
bool ESPHOME_ALWAYS_INLINE setup_check (bool ok, const LogString *message)
 
void disable_loop ()
 Disable this component's loop.
 
void enable_loop ()
 Enable this component's loop.
 
void enable_loop_soon_any_context ()
 Thread and ISR-safe version of enable_loop() that can be called from any context.
 
bool is_failed () const
 
bool is_ready () const
 
virtual bool can_proceed ()
 
bool status_has_warning () const
 
bool status_has_error () const
 
void status_set_warning ()
 
void status_set_warning (const char *message)
 
void status_set_warning (const LogString *message)
 
bool status_comm_result (bool ok)
 Clears the warning when ok, else sets it with message (default "Communication failed"); returns ok.
 
bool status_comm_result (bool ok, const LogString *message)
 
void status_set_error ()
 
void status_set_error (const LogString *message)
 
void status_clear_warning ()
 
void status_clear_error ()
 
 ESPDEPRECATED ("Use status_momentary_warning() without a name. Removed in 2027.5.0", "2026.11.0") void status_momentary_warning(const char *name
 
void status_momentary_warning (uint32_t length=5000)
 Set warning status flag and clear it after length ms.
 
void status_momentary_warning (const LogString *message, uint32_t length=5000)
 
 ESPDEPRECATED ("Use status_momentary_error() without a name. Removed in 2027.5.0", "2026.11.0") void status_momentary_error(const char *name
 
void status_momentary_error (uint32_t length=5000)
 Set error status flag and clear it after length ms.
 
void status_momentary_error (const LogString *message, uint32_t length=5000)
 
bool has_overridden_loop () const
 
const LogString * get_component_log_str () const ESPHOME_ALWAYS_INLINE
 Get the integration where this component was declared as a LogString for logging.
 
bool should_warn_of_blocking (uint32_t blocking_time, uint32_t &threshold_ms_out)
 
- Public Member Functions inherited from esphome::sensor::Sensor
 Sensor ()
 
int8_t get_accuracy_decimals ()
 Get the accuracy in decimals, using the manual override if set.
 
void set_accuracy_decimals (int8_t accuracy_decimals)
 Manually set the accuracy in decimals.
 
bool has_accuracy_decimals () const
 Check if the accuracy in decimals has been manually set.
 
StateClass get_state_class ()
 Get the state class, using the manual override if set.
 
void set_state_class (StateClass state_class)
 Manually set the state class.
 
bool get_force_update () const
 Get whether force update mode is enabled.
 
void set_force_update (bool force_update)
 Set force update mode.
 
void add_filter (Filter *filter)
 Add a filter to the filter chain. Will be appended to the back.
 
void add_filters (std::initializer_list< Filter * > filters)
 Add a list of vectors to the back of the filter chain.
 
void set_filters (std::initializer_list< Filter * > filters)
 Clear the filters and replace them by filters.
 
void clear_filters ()
 Clear the entire filter chain.
 
float get_state () const
 Getter-syntax for .state.
 
float get_raw_state () const
 Get the last state received by publish_state(), before any filters were applied.
 
void publish_state (float state)
 Publish a new state to the front-end.
 
template<typename F >
void add_on_state_callback (F &&callback)
 Add a callback that will be called every time a filtered value arrives.
 
template<typename F >
void add_on_raw_state_callback (F &&callback)
 Add a callback that will be called every time the sensor sends a raw value.
 
void internal_send_state_to_frontend (float state)
 
- Public Member Functions inherited from esphome::EntityBase
 ESPDEPRECATED ("Use get_name_to() or get_log_name() instead. Will be removed in ESPHome 2027.5.0", "2026.11.0") const StringRef &get_name() const
 The name is in flash here; the first call makes a RAM copy that is kept for the life of the device.
 
StringRef get_name_to (std::span< char, ENTITY_NAME_BUF_SIZE > buffer) const
 Get the name of this Entity, copied out of flash into buffer.
 
 ESPDEPRECATED ("Use get_name_to() or get_log_name() instead. Will be removed in ESPHome 2027.5.0", "2026.11.0") const StringRef &get_name() const
 
const StringRef & get_name_to (std::span< char, ENTITY_NAME_BUF_SIZE >) const
 
bool name_equals (const StringRef &other) const
 
const ProgmemStringRef & get_name_progmem () const
 The name as stored, for consumers that read flash themselves (e.g. API progmem fields).
 
size_t write_name_to (char *buf, size_t buf_size) const
 Copy the name into buf (null terminated), returns its length.
 
const LogString * get_log_name () const
 Get the name for a "%s" log argument (LOG_STR_ARG).
 
bool has_own_name () const
 
uint32_t get_object_id_hash () const
 
StringRef get_object_id_to (std::span< char, OBJECT_ID_MAX_LEN > buf) const
 Get object_id with zero heap allocation For static case: returns StringRef to internal storage (buffer unused) For dynamic case: formats into buffer and returns StringRef to buffer.
 
size_t write_object_id_to (char *buf, size_t buf_size) const
 Write object_id directly to buffer, returns length written (excluding null) Useful for building compound strings without intermediate buffer.
 
bool is_internal () const
 
void set_internal (bool internal)
 
bool is_disabled_by_default () const
 
EntityCategory get_entity_category () const
 
const char * get_device_class_to (std::span< char, MAX_DEVICE_CLASS_LENGTH > buffer) const
 
ProgmemStringRef get_device_class_progmem () const
 The device class as stored (in flash on ESP8266), for consumers that read flash themselves.
 
StringRef get_unit_of_measurement_ref () const
 
const char * get_icon_to (std::span< char, MAX_ICON_LENGTH > buffer) const
 
ProgmemStringRef get_icon_progmem () const
 The icon as stored (in flash on ESP8266), for consumers that read flash themselves.
 
uint32_t get_device_id () const
 
Device * get_device () const
 
bool has_state () const
 
void set_has_state (bool state)
 
 ESPDEPRECATED ("Use make_entity_preference<T>() instead, or preferences won't be migrated. " "See https://github.com/esphome/backlog/issues/85. Will be removed in 2027.1.0.", "2026.7.0") uint32_t get_preference_hash()
 Get a unique hash for storing preferences/settings for this entity.
 
template<typename T >
ESPPreferenceObject make_entity_preference (uint32_t version=0)
 Create a preference object for storing this entity's state/settings.
 
template<typename T >
ESPPreferenceObject make_entity_preference (uint32_t version, bool in_flash)
 As make_entity_preference(), stored in flash or RTC memory where the backend supports the choice.
 
- Public Member Functions inherited from esphome::sensirion_common::SensirionI2CDevice
bool read_data (uint16_t *data, uint8_t len)
 Read data words from I2C device.
 
bool read_data (uint16_t &data)
 Read 1 data word from I2C device.
 
bool get_register (uint16_t command, uint16_t *data, uint8_t len, uint8_t delay=0)
 get data words from I2C register.
 
bool get_register (uint16_t i2c_register, uint16_t &data, uint8_t delay=0)
 Read 1 data word from 16 bit I2C register.
 
bool get_8bit_register (uint8_t i2c_register, uint16_t *data, uint8_t len, uint8_t delay=0)
 get data words from I2C register.
 
bool get_8bit_register (uint8_t i2c_register, uint16_t &data, uint8_t delay=0)
 Read 1 data word from 8 bit I2C register.
 
template<class T >
bool write_command (T i2c_register)
 Write a command to the I2C device.
 
template<class T >
bool write_command (T i2c_register, uint16_t data)
 Write a command and one data word to the I2C device .
 
template<class T >
bool write_command (T i2c_register, const std::vector< uint16_t > &data)
 Write a command with arguments as words.
 
template<class T >
bool write_command (T i2c_register, const uint16_t *data, uint8_t len)
 Write a command with arguments as words.
 
- Public Member Functions inherited from esphome::i2c::I2CDevice
 I2CDevice ()=default
 we use the C++ default constructor
 
void set_i2c_address (uint8_t address)
 We store the address of the device on the bus.
 
uint8_t get_i2c_address () const
 Returns the I2C address of the object.
 
void set_i2c_bus (I2CBus *bus)
 we store the pointer to the I2CBus to use
 
I2CRegister reg (uint8_t a_register)
 calls the I2CRegister constructor
 
I2CRegister16 reg16 (uint16_t a_register)
 calls the I2CRegister16 constructor
 
ErrorCode read (uint8_t *data, size_t len) const
 reads an array of bytes from the device using an I2CBus
 
ErrorCode read_register (uint8_t a_register, uint8_t *data, size_t len)
 reads an array of bytes from a specific register in the I²C device
 
ErrorCode read_register16 (uint16_t a_register, uint8_t *data, size_t len)
 reads an array of bytes from a specific register in the I²C device
 
ErrorCode write (const uint8_t *data, size_t len) const
 writes an array of bytes to a device using an I2CBus
 
ErrorCode write_read (const uint8_t *write_data, size_t write_len, uint8_t *read_data, size_t read_len) const
 writes an array of bytes to a device, then reads an array, as a single transaction
 
ErrorCode write_register (uint8_t a_register, const uint8_t *data, size_t len) const
 writes an array of bytes to a specific register in the I²C device
 
ErrorCode write_register16 (uint16_t a_register, const uint8_t *data, size_t len) const
 write an array of bytes to a specific register in the I²C device
 
bool write_registers (const I2CRegValue *table, size_t count) const
 Write each register and value of table in order, stopping at the first failure.
 
template<size_t N>
bool write_registers (const I2CRegValue(&table)[N]) const
 
bool check_chip_id (Component *component, uint8_t a_register, uint8_t expected, uint8_t mask=0xFF)
 Read the 8-bit ID at a_register and accept it when it matches expected in the bits set in mask.
 
bool read_bytes (uint8_t a_register, uint8_t *data, uint8_t len)
 Compat APIs All methods below have been added for compatibility reasons.
 
bool read_bytes_raw (uint8_t *data, uint8_t len) const
 
template<size_t N>
optional< std::array< uint8_t, N > > read_bytes (uint8_t a_register)
 
template<size_t N>
optional< std::array< uint8_t, N > > read_bytes_raw ()
 
bool read_bytes_16 (uint8_t a_register, uint16_t *data, uint8_t len)
 
bool read_byte (uint8_t a_register, uint8_t *data)
 
optional< uint8_t > read_byte (uint8_t a_register)
 
bool read_byte_16 (uint8_t a_register, uint16_t *data)
 
bool read_bytes_16_le (uint8_t a_register, uint16_t *data, uint8_t len)
 Read len 16-bit values stored least significant byte first; no conversion is compiled on little-endian hosts.
 
bool read_bytes_16_le (uint8_t a_register, int16_t *data, uint8_t len)
 
bool read_byte_16_le (uint8_t a_register, uint16_t *data)
 Read a 16-bit value stored least significant byte first.
 
bool write_bytes (uint8_t a_register, const uint8_t *data, uint8_t len) const
 
bool write_bytes (uint8_t a_register, const std::vector< uint8_t > &data) const
 
template<size_t N>
bool write_bytes (uint8_t a_register, const std::array< uint8_t, N > &data)
 
bool write_bytes_16 (uint8_t a_register, const uint16_t *data, uint8_t len) const
 
bool write_byte (uint8_t a_register, uint8_t data) const
 
bool write_byte_16 (uint8_t a_register, uint16_t data) const
 
bool write_byte_16_le (uint8_t a_register, uint16_t data) const
 Write a 16-bit value least significant byte first.
 
bool update_register (uint8_t a_register, uint8_t mask, uint8_t value)
 Read a register, replace the bits in mask with those of value and write it back.
 

Data Fields

uint16_t learning_time_offset_hours
 
uint16_t uint16_t learning_time_gain_hours
 
uint16_t uint16_t uint16_t gating_max_duration_minutes
 
uint16_t uint16_t uint16_t uint16_t std_initial
 
uint16_t uint16_t uint16_t uint16_t uint16_t gain_factor
 
- Data Fields inherited from esphome::Component
uint32_t length = 5000)
 
- Data Fields inherited from esphome::sensor::Sensor
float state
 This member variable stores the last state that has passed through all filters.
 

Protected Member Functions

void self_test_ ()
 
int16_t sensirion_init_sensors_ ()
 
void update_gas_indices_ ()
 
void measure_raw_ ()
 
- Protected Member Functions inherited from esphome::Component
friend void::setup ()
 
friend void::original_setup ()
 
void set_component_source_ (uint8_t index)
 Set where this component was loaded from for some debug messages.
 
void call_dump_config_ ()
 
void enable_loop_slow_path_ ()
 
void set_component_state_ (uint8_t state)
 Helper to set component state (clears state bits and sets new state)
 
bool set_status_flag_ (uint8_t flag)
 Helper to set a status LED flag on both this component and the app.
 
bool set_error_flag_ (const LogString *message)
 Set the error flag and log it; true when it was not set before.
 
void set_interval (const char *name, uint32_t interval, std::function< void()> &&f)
 Set an interval function with a const char* name.
 
void set_interval (uint32_t id, uint32_t interval, std::function< void()> &&f)
 Set an interval function with a numeric ID (zero heap allocation).
 
void set_interval (InternalSchedulerID id, uint32_t interval, std::function< void()> &&f)
 
void set_interval (uint32_t interval, std::function< void()> &&f)
 
bool cancel_interval (const char *name)
 Cancel an interval function.
 
bool cancel_interval (uint32_t id)
 
bool cancel_interval (InternalSchedulerID id)
 
void set_timeout (const char *name, uint32_t timeout, std::function< void()> &&f)
 Set a timeout function with a const char* name.
 
void set_timeout (uint32_t id, uint32_t timeout, std::function< void()> &&f)
 Set a timeout function with a numeric ID (zero heap allocation).
 
void set_timeout (InternalSchedulerID id, uint32_t timeout, std::function< void()> &&f)
 
void set_timeout (uint32_t timeout, std::function< void()> &&f)
 
bool cancel_timeout (const char *name)
 Cancel a timeout function.
 
bool cancel_timeout (uint32_t id)
 
bool cancel_timeout (InternalSchedulerID id)
 
void defer (const char *name, std::function< void()> &&f)
 Defer a callback to the next loop() call with a const char* name.
 
void defer (std::function< void()> &&f)
 Defer a callback to the next loop() call.
 
void defer (uint32_t id, std::function< void()> &&f)
 Defer a callback with a numeric ID (zero heap allocation)
 
bool cancel_defer (const char *name)
 Cancel a defer callback using the specified name, name must not be empty.
 
bool cancel_defer (uint32_t id)
 
void status_clear_warning_slow_path_ ()
 
void status_clear_error_slow_path_ ()
 
- Protected Member Functions inherited from esphome::EntityBase
friend void::setup ()
 
friend void::original_setup ()
 
void configure_entity_ (const char *name, uint32_t object_id_hash, uint32_t entity_fields)
 Combined entity setup from codegen: set name, object_id hash, entity string indices, and flags.
 
void set_device_ (Device *device)
 
ESPPreferenceObject make_entity_preference_ (size_t size, uint32_t version)
 Non-template helpers for make_entity_preference() to avoid code bloat.
 
ESPPreferenceObject make_entity_preference_ (size_t size, uint32_t version, bool in_flash)
 
uint32_t entity_preference_key_ (uint32_t version)
 Key for both helpers; preference hash migration goes here.
 
- Protected Member Functions inherited from esphome::sensirion_common::SensirionI2CDevice
bool write_command_ (uint16_t command, CommandLen command_len, const uint16_t *data, uint8_t data_len)
 Write a command with arguments as words.
 
bool get_register_ (uint16_t reg, CommandLen command_len, uint16_t *data, uint8_t len, uint8_t delay, uint8_t sensirion_options=0)
 get data words from I2C register.
 

Protected Attributes

uint16_t voc_sraw_
 
uint16_t nox_sraw_
 
SgpType sgp_type_ {SGP40}
 
uint64_t serial_number_
 
bool self_test_complete_
 
VOCGasIndexAlgorithm voc_algorithm_
 
optional< GasTuning > voc_tuning_params_
 
float voc_state0_
 
float voc_state1_
 
int32_t voc_index_ = 0
 
int32_t nox_index_ = 0
 
NOxGasIndexAlgorithm nox_algorithm_
 
optional< GasTuning > nox_tuning_params_
 
uint16_t measure_time_
 
uint8_t samples_read_ = 0
 
uint8_t samples_to_stabilize_ = static_cast<int8_t>(GasIndexAlgorithm_INITIAL_BLACKOUT) * 2
 
bool store_baseline_
 
optional< uint32_t > nox_conditioning_start_ {}
 
ESPPreferenceObject pref_
 
uint32_t seconds_since_last_store_
 
SGP4xBaselines voc_baselines_storage_
 
- Protected Attributes inherited from esphome::PollingComponent
uint32_t update_interval_
 
- Protected Attributes inherited from esphome::Component
uint8_t component_source_index_ {0}
 Index into component source PROGMEM lookup table (0 = not set)
 
uint8_t warn_if_blocking_over_ {WARN_IF_BLOCKING_OVER_CS}
 Warn threshold in centiseconds (max 2550ms)
 
uint8_t component_state_ {0x00}
 State of this component - each bit has a purpose: Bits 0-2: Component state (0x00=CONSTRUCTION, 0x01=SETUP, 0x02=LOOP, 0x03=FAILED, 0x04=LOOP_DONE) Bit 3: STATUS_LED_WARNING Bit 4: STATUS_LED_ERROR Bit 5: Has overridden loop() (set at registration time) Bits 6-7: Unused - reserved for future expansion.
 
volatile bool pending_enable_loop_ {false}
 ISR-safe flag for enable_loop_soon_any_context.
 
ComponentRuntimeStats runtime_stats_
 
- Protected Attributes inherited from esphome::sensor::Sensor
float raw_state_ {NAN}
 The last state passed to publish_state(), before filters.
 
LazyCallbackManager< void(float)> raw_callback_
 Storage for raw state callbacks.
 
LazyCallbackManager< void(float)> callback_
 Storage for filtered state callbacks.
 
Filter * filter_list_ {nullptr}
 Store all active filters.
 
int8_t accuracy_decimals_ {-1}
 Accuracy in decimals (-1 = not set)
 
StateClass state_class_ {STATE_CLASS_NONE}
 State class (STATE_CLASS_NONE = not set)
 
struct esphome::sensor::Sensor::SensorFlags sensor_flags_
 
- Protected Attributes inherited from esphome::EntityBase
ProgmemStringRef name_
 
uint32_t object_id_hash_ {}
 
Device * device_ {}
 
struct esphome::EntityBase::EntityFlags flags_
 
uint8_t device_class_idx_ {}
 
uint8_t uom_idx_ {}
 
uint8_t icon_idx_ {}
 
- Protected Attributes inherited from esphome::sensirion_common::SensirionI2CDevice
i2c::ErrorCode last_error_
 last error code from I2C operation
 
- Protected Attributes inherited from esphome::i2c::I2CDevice
I2CBus * bus_ {nullptr}
 pointer to I2CBus instance
 
uint8_t address_ {0x00}
 store the address of the device on the bus
 

Additional Inherited Members

- Public Types inherited from esphome::sensirion_common::SensirionI2CDevice
enum  CommandLen : uint8_t { ADDR_8_BIT = 1 , ADDR_16_BIT = 2 }
 
- Static Public Member Functions inherited from esphome::sensirion_common::SensirionI2CDevice
static const char * sensirion_convert_to_string_in_place (uint16_t *array, size_t length)
 This function performs an in-place conversion of the provided buffer from uint16_t values to big endianness.
 

Detailed Description

This class implements support for the Sensirion sgp4x i2c GAS (VOC) sensors.

Definition at line 59 of file sgp4x.h.

Member Function Documentation

◆ dump_config()

void esphome::sgp4x::SGP4xComponent::dump_config ( )
overridevirtual

Reimplemented from esphome::Component.

Definition at line 257 of file sgp4x.cpp.

◆ measure_raw_()

void esphome::sgp4x::SGP4xComponent::measure_raw_ ( )
protected

Definition at line 164 of file sgp4x.cpp.

◆ self_test_()

void esphome::sgp4x::SGP4xComponent::self_test_ ( )
protected

Definition at line 109 of file sgp4x.cpp.

◆ sensirion_init_sensors_()

int16_t esphome::sgp4x::SGP4xComponent::sensirion_init_sensors_ ( )
protected

◆ set_nox_algorithm_tuning()

void esphome::sgp4x::SGP4xComponent::set_nox_algorithm_tuning ( uint16_t index_offset,
uint16_t learning_time_offset_hours,
uint16_t learning_time_gain_hours,
uint16_t gating_max_duration_minutes,
uint16_t gain_factor )
inline

Definition at line 82 of file sgp4x.h.

◆ set_store_baseline()

void esphome::sgp4x::SGP4xComponent::set_store_baseline ( bool store_baseline)
inline

Definition at line 72 of file sgp4x.h.

◆ SUB_SENSOR() [1/2]

esphome::sgp4x::SGP4xComponent::SUB_SENSOR ( humidity )
override

◆ SUB_SENSOR() [2/2]

esphome::sgp4x::SGP4xComponent::SUB_SENSOR ( voc )

◆ take_sample()

void esphome::sgp4x::SGP4xComponent::take_sample ( )

Definition at line 234 of file sgp4x.cpp.

◆ update()

void esphome::sgp4x::SGP4xComponent::update ( )
overridevirtual

Implements esphome::PollingComponent.

Definition at line 243 of file sgp4x.cpp.

◆ update_gas_indices_()

void esphome::sgp4x::SGP4xComponent::update_gas_indices_ ( )
protected

Definition at line 133 of file sgp4x.cpp.

Field Documentation

◆ gain_factor

uint16_t uint16_t uint16_t uint16_t uint16_t esphome::sgp4x::SGP4xComponent::gain_factor
Initial value:
{
this->voc_tuning_params_ = GasTuning{
uint16_t uint16_t uint16_t uint16_t std_initial
Definition sgp4x.h:77
uint16_t uint16_t learning_time_gain_hours
Definition sgp4x.h:76
uint16_t uint16_t uint16_t gating_max_duration_minutes
Definition sgp4x.h:76
uint16_t learning_time_offset_hours
Definition sgp4x.h:75
optional< GasTuning > voc_tuning_params_
Definition sgp4x.h:106
uint16_t uint16_t uint16_t uint16_t uint16_t gain_factor
Definition sgp4x.h:77

Definition at line 77 of file sgp4x.h.

◆ gating_max_duration_minutes

uint16_t uint16_t uint16_t esphome::sgp4x::SGP4xComponent::gating_max_duration_minutes

Definition at line 76 of file sgp4x.h.

◆ learning_time_gain_hours

uint16_t uint16_t esphome::sgp4x::SGP4xComponent::learning_time_gain_hours

Definition at line 76 of file sgp4x.h.

◆ learning_time_offset_hours

uint16_t esphome::sgp4x::SGP4xComponent::learning_time_offset_hours

Definition at line 75 of file sgp4x.h.

◆ measure_time_

uint16_t esphome::sgp4x::SGP4xComponent::measure_time_
protected

Definition at line 115 of file sgp4x.h.

◆ nox_algorithm_

NOxGasIndexAlgorithm esphome::sgp4x::SGP4xComponent::nox_algorithm_
protected

Definition at line 112 of file sgp4x.h.

◆ nox_conditioning_start_

optional<uint32_t> esphome::sgp4x::SGP4xComponent::nox_conditioning_start_ {}
protected

Definition at line 120 of file sgp4x.h.

◆ nox_index_

int32_t esphome::sgp4x::SGP4xComponent::nox_index_ = 0
protected

Definition at line 111 of file sgp4x.h.

◆ nox_sraw_

uint16_t esphome::sgp4x::SGP4xComponent::nox_sraw_
protected

Definition at line 98 of file sgp4x.h.

◆ nox_tuning_params_

optional<GasTuning> esphome::sgp4x::SGP4xComponent::nox_tuning_params_
protected

Definition at line 113 of file sgp4x.h.

◆ pref_

ESPPreferenceObject esphome::sgp4x::SGP4xComponent::pref_
protected

Definition at line 121 of file sgp4x.h.

◆ samples_read_

uint8_t esphome::sgp4x::SGP4xComponent::samples_read_ = 0
protected

Definition at line 116 of file sgp4x.h.

◆ samples_to_stabilize_

uint8_t esphome::sgp4x::SGP4xComponent::samples_to_stabilize_ = static_cast<int8_t>(GasIndexAlgorithm_INITIAL_BLACKOUT) * 2
protected

Definition at line 117 of file sgp4x.h.

◆ seconds_since_last_store_

uint32_t esphome::sgp4x::SGP4xComponent::seconds_since_last_store_
protected

Definition at line 122 of file sgp4x.h.

◆ self_test_complete_

bool esphome::sgp4x::SGP4xComponent::self_test_complete_
protected

Definition at line 103 of file sgp4x.h.

◆ serial_number_

uint64_t esphome::sgp4x::SGP4xComponent::serial_number_
protected

Definition at line 101 of file sgp4x.h.

◆ sgp_type_

SgpType esphome::sgp4x::SGP4xComponent::sgp_type_ {SGP40}
protected

Definition at line 100 of file sgp4x.h.

◆ std_initial

uint16_t uint16_t uint16_t uint16_t esphome::sgp4x::SGP4xComponent::std_initial

Definition at line 77 of file sgp4x.h.

◆ store_baseline_

bool esphome::sgp4x::SGP4xComponent::store_baseline_
protected

Definition at line 118 of file sgp4x.h.

◆ voc_algorithm_

VOCGasIndexAlgorithm esphome::sgp4x::SGP4xComponent::voc_algorithm_
protected

Definition at line 105 of file sgp4x.h.

◆ voc_baselines_storage_

SGP4xBaselines esphome::sgp4x::SGP4xComponent::voc_baselines_storage_
protected

Definition at line 123 of file sgp4x.h.

◆ voc_index_

int32_t esphome::sgp4x::SGP4xComponent::voc_index_ = 0
protected

Definition at line 109 of file sgp4x.h.

◆ voc_sraw_

uint16_t esphome::sgp4x::SGP4xComponent::voc_sraw_
protected

Definition at line 97 of file sgp4x.h.

◆ voc_state0_

float esphome::sgp4x::SGP4xComponent::voc_state0_
protected

Definition at line 107 of file sgp4x.h.

◆ voc_state1_

float esphome::sgp4x::SGP4xComponent::voc_state1_
protected

Definition at line 108 of file sgp4x.h.

◆ voc_tuning_params_

optional<GasTuning> esphome::sgp4x::SGP4xComponent::voc_tuning_params_
protected

Definition at line 106 of file sgp4x.h.


The documentation for this class was generated from the following files: