ESPHome  2022.11.4
Public Member Functions | Protected Attributes
esphome::sensor::DeltaFilter Class Reference

#include <filter.h>

Inheritance diagram for esphome::sensor::DeltaFilter:

Public Member Functions

 DeltaFilter (float min_delta)
optional< float > new_value (float value) override
- Public Member Functions inherited from esphome::sensor::Filter
virtual void initialize (Sensor *parent, Filter *next)
 Initialize this filter, please note this can be called more than once. More...
void input (float value)
void output (float value)

Protected Attributes

float min_delta_
float last_value_ {NAN}
- Protected Attributes inherited from esphome::sensor::Filter
friend Sensor
Filternext_ {nullptr}
Sensorparent_ {nullptr}

Detailed Description

Definition at line 325 of file filter.h.

Constructor & Destructor Documentation

◆ DeltaFilter()

esphome::sensor::DeltaFilter::DeltaFilter ( float  min_delta)

Definition at line 318 of file filter.cpp.

Member Function Documentation

◆ new_value()

optional< float > esphome::sensor::DeltaFilter::new_value ( float  value)

Implements esphome::sensor::Filter.

Definition at line 319 of file filter.cpp.

Field Documentation

◆ last_value_

float esphome::sensor::DeltaFilter::last_value_ {NAN}

Definition at line 333 of file filter.h.

◆ min_delta_

float esphome::sensor::DeltaFilter::min_delta_

Definition at line 332 of file filter.h.

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