ESPHome  2024.11.2
ads1115.h
Go to the documentation of this file.
1 #pragma once
2 
5 
6 #include <vector>
7 
8 namespace esphome {
9 namespace ads1115 {
10 
20 };
21 
29 };
30 
34 };
35 
36 class ADS1115Component : public Component, public i2c::I2CDevice {
37  public:
38  void setup() override;
39  void dump_config() override;
41  float get_setup_priority() const override { return setup_priority::DATA; }
42  void set_continuous_mode(bool continuous_mode) { continuous_mode_ = continuous_mode; }
43 
46 
47  protected:
48  uint16_t prev_config_{0};
50 };
51 
52 } // namespace ads1115
53 } // namespace esphome
const float DATA
For components that import data from directly connected sensors like DHT.
Definition: component.cpp:19
float request_measurement(ADS1115Multiplexer multiplexer, ADS1115Gain gain, ADS1115Resolution resolution)
Helper method to request a measurement from a sensor.
Definition: ads1115.cpp:79
AlsGain501 gain
void set_continuous_mode(bool continuous_mode)
Definition: ads1115.h:42
float get_setup_priority() const override
HARDWARE_LATE setup priority.
Definition: ads1115.h:41
Implementation of SPI Controller mode.
Definition: a01nyub.cpp:7
This Class provides the methods to read/write bytes from/to an i2c device.
Definition: i2c.h:133