1
0
mirror of https://github.com/esphome/esphome.git synced 2025-01-18 12:05:41 +00:00

[nau7802] fix bad blocking code (esphome/issues#6395)

This commit is contained in:
Curtis Malainey 2025-01-12 08:47:52 -08:00
parent 4d7c6b28e1
commit 9d27b1b70d
No known key found for this signature in database
GPG Key ID: C3A617BA5EC68602
2 changed files with 0 additions and 6 deletions

View File

@ -120,8 +120,6 @@ void NAU7802Sensor::complete_setup_() {
// PGA stabilizer cap on output
i2c::I2CRegister pwr_reg = this->reg(POWER_REG);
pwr_reg |= POWER_PGA_CAP_EN;
this->setup_complete_ = true;
}
void NAU7802Sensor::dump_config() {
@ -317,7 +315,5 @@ void NAU7802Sensor::update() {
bool NAU7802Sensor::is_data_ready_() { return this->reg(PU_CTRL_REG).get() & PU_CTRL_CYCLE_READY; }
bool NAU7802Sensor::can_proceed() { return this->setup_complete_; }
} // namespace nau7802
} // namespace esphome

View File

@ -61,7 +61,6 @@ class NAU7802Sensor : public sensor::Sensor, public PollingComponent, public i2c
void setup() override;
void loop() override;
bool can_proceed() override;
void dump_config() override;
float get_setup_priority() const override;
void update() override;
@ -80,7 +79,6 @@ class NAU7802Sensor : public sensor::Sensor, public PollingComponent, public i2c
int32_t offset_calibration_;
bool offset_calibration_failed_ = false;
bool gain_calibration_failed_ = false;
bool setup_complete_ = false;
//
// Config values