12 namespace ltr_als_ps {
29 void setup()
override;
90 uint8_t number_of_adjustments{0};
162 this->on_ps_high_trigger_callback_.add(std::move(callback));
166 this->on_ps_low_trigger_callback_.add(std::move(callback));
uint16_t ps_cooldown_time_s_
const float DATA
For components that import data from directly connected sensors like DHT.
bool is_any_als_sensor_enabled_() const
void set_als_glass_attenuation_factor(float factor)
sensor::Sensor * actual_gain_sensor_
void set_als_meas_repeat_rate(MeasurementRepeatRate rate)
float get_setup_priority() const override
void set_als_gain(AlsGain gain)
void set_ps_high_threshold(uint16_t threshold)
void set_ltr_type(LtrType type)
uint16_t ps_threshold_high_
bool check_part_number_()
DataAvail is_als_data_ready_(AlsReadings &data)
void add_on_ps_low_trigger_callback_(std::function< void()> callback)
float glass_attenuation_factor_
CallbackManager< void()> on_ps_high_trigger_callback_
void set_als_auto_mode(bool enable)
LTRPsHighTrigger(LTRAlsPsComponent *parent)
void apply_lux_calculation_(AlsReadings &data)
This class simplifies creating components that periodically check a state.
uint16_t ps_threshold_low_
void check_and_trigger_ps_()
struct esphome::ltr_als_ps::LTRAlsPsComponent::AlsReadings als_readings_
IntegrationTime integration_time_
void set_ps_low_threshold(uint16_t threshold)
MeasurementRepeatRate repeat_rate_
bool automatic_mode_enabled_
CallbackManager< void()> on_ps_low_trigger_callback_
bool are_adjustments_required_(AlsReadings &data)
sensor::Sensor * infrared_counts_sensor_
void set_actual_integration_time_sensor(sensor::Sensor *sensor)
sensor::Sensor * full_spectrum_counts_sensor_
void set_ps_cooldown_time_s(uint16_t time)
void set_als_integration_time(IntegrationTime time)
void configure_integration_time_(IntegrationTime time)
IntegrationTime501 integration_time
sensor::Sensor * proximity_counts_sensor_
void dump_config() override
sensor::Sensor * actual_integration_time_sensor_
void set_full_spectrum_counts_sensor(sensor::Sensor *sensor)
void read_sensor_data_(AlsReadings &data)
void set_ambient_light_sensor(sensor::Sensor *sensor)
void add_on_ps_high_trigger_callback_(std::function< void()> callback)
Implementation of SPI Controller mode.
void publish_data_part_1_(AlsReadings &data)
void configure_gain_(AlsGain gain)
Base-class for all sensors.
bool is_any_ps_sensor_enabled_() const
void set_ps_gain(PsGain gain)
sensor::Sensor * ambient_light_sensor_
This Class provides the methods to read/write bytes from/to an i2c device.
void set_infrared_counts_sensor(sensor::Sensor *sensor)
esphome::sensor::Sensor * sensor
LTRPsLowTrigger(LTRAlsPsComponent *parent)
void publish_data_part_2_(AlsReadings &data)
void set_actual_gain_sensor(sensor::Sensor *sensor)
void set_proximity_counts_sensor(sensor::Sensor *sensor)