ESPHome 2026.6.0-dev
Loading...
Searching...
No Matches
xgzp68xx.h
Go to the documentation of this file.
1#pragma once
2
6
7namespace esphome::xgzp68xx {
8
22
24 public:
27 void set_k_value(uint16_t k_value) { this->k_value_ = k_value; }
29 void set_pressure_oversampling(XGZP68XXOversampling pressure_oversampling) {
30 this->pressure_oversampling_ = pressure_oversampling;
31 }
32
33 void update() override;
34 void setup() override;
35 void dump_config() override;
36
37 protected:
40 uint16_t k_value_;
43};
44
45} // namespace esphome::xgzp68xx
This class simplifies creating components that periodically check a state.
Definition component.h:585
This Class provides the methods to read/write bytes from/to an i2c device.
Definition i2c.h:132
Base-class for all sensors.
Definition sensor.h:47
XGZP68XXOversampling last_pressure_oversampling_
Definition xgzp68xx.h:42
void read_pressure_()
Internal method to read the pressure from the component after it has been scheduled.
XGZP68XXOversampling pressure_oversampling_
Definition xgzp68xx.h:41
void set_pressure_oversampling(XGZP68XXOversampling pressure_oversampling)
Set the pressure oversampling value. Defaults to 4096X.
Definition xgzp68xx.h:29
SUB_SENSOR(temperature) SUB_SENSOR(pressure) void set_k_value(uint16_t k_value)
Definition xgzp68xx.h:25
XGZP68XXOversampling
Enum listing all oversampling options for the XGZP68XX.
Definition xgzp68xx.h:10
@ XGZP68XX_OVERSAMPLING_32768X
Definition xgzp68xx.h:18
@ XGZP68XX_OVERSAMPLING_1024X
Definition xgzp68xx.h:13
@ XGZP68XX_OVERSAMPLING_256X
Definition xgzp68xx.h:11
@ XGZP68XX_OVERSAMPLING_UNKNOWN
Definition xgzp68xx.h:20
@ XGZP68XX_OVERSAMPLING_8192X
Definition xgzp68xx.h:16
@ XGZP68XX_OVERSAMPLING_2048X
Definition xgzp68xx.h:14
@ XGZP68XX_OVERSAMPLING_4096X
Definition xgzp68xx.h:15
@ XGZP68XX_OVERSAMPLING_16384X
Definition xgzp68xx.h:17
@ XGZP68XX_OVERSAMPLING_512X
Definition xgzp68xx.h:12
uint16_t temperature
Definition sun_gtil2.cpp:12
uint8_t pressure
Definition tt21100.cpp:7