ESPHome 2026.5.0-dev
Loading...
Searching...
No Matches
esphome::runtime_stats::RuntimeStatsCollector Class Reference

#include <runtime_stats.h>

Public Member Functions

 RuntimeStatsCollector ()
 
void set_log_interval (uint32_t log_interval)
 
uint32_t get_log_interval () const
 
void process_pending_stats (uint32_t current_time)
 
void record_loop_active (uint32_t active_us, uint32_t before_us, uint32_t tail_us)
 

Protected Member Functions

void log_stats_ ()
 

Static Protected Member Functions

static bool compare_period_time (Component *a, Component *b)
 
static bool compare_total_time (Component *a, Component *b)
 

Protected Attributes

uint32_t log_interval_
 
uint32_t next_log_time_ {0}
 
uint64_t period_active_count_ {0}
 
uint64_t period_active_time_us_ {0}
 
uint32_t period_active_max_us_ {0}
 
uint64_t total_active_count_ {0}
 
uint64_t total_active_time_us_ {0}
 
uint32_t total_active_max_us_ {0}
 
uint64_t period_before_time_us_ {0}
 
uint64_t total_before_time_us_ {0}
 
uint64_t period_tail_time_us_ {0}
 
uint64_t total_tail_time_us_ {0}
 

Detailed Description

Definition at line 19 of file runtime_stats.h.

Constructor & Destructor Documentation

◆ RuntimeStatsCollector()

esphome::runtime_stats::RuntimeStatsCollector::RuntimeStatsCollector ( )

Definition at line 13 of file runtime_stats.cpp.

Member Function Documentation

◆ compare_period_time()

bool esphome::runtime_stats::RuntimeStatsCollector::compare_period_time ( Component * a,
Component * b )
staticprotected

Definition at line 132 of file runtime_stats.cpp.

◆ compare_total_time()

bool esphome::runtime_stats::RuntimeStatsCollector::compare_total_time ( Component * a,
Component * b )
staticprotected

Definition at line 136 of file runtime_stats.cpp.

◆ get_log_interval()

uint32_t esphome::runtime_stats::RuntimeStatsCollector::get_log_interval ( ) const
inline

Definition at line 27 of file runtime_stats.h.

◆ log_stats_()

void esphome::runtime_stats::RuntimeStatsCollector::log_stats_ ( )
protected

Definition at line 17 of file runtime_stats.cpp.

◆ process_pending_stats()

void esphome::runtime_stats::RuntimeStatsCollector::process_pending_stats ( uint32_t current_time)

Definition at line 140 of file runtime_stats.cpp.

◆ record_loop_active()

void esphome::runtime_stats::RuntimeStatsCollector::record_loop_active ( uint32_t active_us,
uint32_t before_us,
uint32_t tail_us )
inline

Definition at line 41 of file runtime_stats.h.

◆ set_log_interval()

void esphome::runtime_stats::RuntimeStatsCollector::set_log_interval ( uint32_t log_interval)
inline

Definition at line 23 of file runtime_stats.h.

Field Documentation

◆ log_interval_

uint32_t esphome::runtime_stats::RuntimeStatsCollector::log_interval_
protected

Definition at line 63 of file runtime_stats.h.

◆ next_log_time_

uint32_t esphome::runtime_stats::RuntimeStatsCollector::next_log_time_ {0}
protected

Definition at line 64 of file runtime_stats.h.

◆ period_active_count_

uint64_t esphome::runtime_stats::RuntimeStatsCollector::period_active_count_ {0}
protected

Definition at line 69 of file runtime_stats.h.

◆ period_active_max_us_

uint32_t esphome::runtime_stats::RuntimeStatsCollector::period_active_max_us_ {0}
protected

Definition at line 71 of file runtime_stats.h.

◆ period_active_time_us_

uint64_t esphome::runtime_stats::RuntimeStatsCollector::period_active_time_us_ {0}
protected

Definition at line 70 of file runtime_stats.h.

◆ period_before_time_us_

uint64_t esphome::runtime_stats::RuntimeStatsCollector::period_before_time_us_ {0}
protected

Definition at line 77 of file runtime_stats.h.

◆ period_tail_time_us_

uint64_t esphome::runtime_stats::RuntimeStatsCollector::period_tail_time_us_ {0}
protected

Definition at line 79 of file runtime_stats.h.

◆ total_active_count_

uint64_t esphome::runtime_stats::RuntimeStatsCollector::total_active_count_ {0}
protected

Definition at line 72 of file runtime_stats.h.

◆ total_active_max_us_

uint32_t esphome::runtime_stats::RuntimeStatsCollector::total_active_max_us_ {0}
protected

Definition at line 74 of file runtime_stats.h.

◆ total_active_time_us_

uint64_t esphome::runtime_stats::RuntimeStatsCollector::total_active_time_us_ {0}
protected

Definition at line 73 of file runtime_stats.h.

◆ total_before_time_us_

uint64_t esphome::runtime_stats::RuntimeStatsCollector::total_before_time_us_ {0}
protected

Definition at line 78 of file runtime_stats.h.

◆ total_tail_time_us_

uint64_t esphome::runtime_stats::RuntimeStatsCollector::total_tail_time_us_ {0}
protected

Definition at line 80 of file runtime_stats.h.


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