23 void setup()
override;
Base for expanders that cache reads per loop. With an interrupt pin the cache stays valid until INT f...
This Class provides the methods to read/write bytes from/to an i2c device.
uint16_t input_mask_
The state read in read_gpio_ - 1 means HIGH, 0 means LOW.
void setup() override
Check i2c availability and setup masks.
uint16_t mode_mask_
Mask for the pin mode - 1 means output, 0 means input.
uint16_t output_mask_
The mask to write as output state - 1 means HIGH, 0 means LOW.
void set_reset(bool reset)
void digital_write_hw(uint8_t pin, bool value) override
PCF8574Component()=default
void register_input_pin(uint8_t pin)
void pin_mode(uint8_t pin, gpio::Flags flags)
Helper function to set the pin mode of a pin.
void dump_config() override
void set_pcf8575(bool pcf8575)
uint16_t configured_input_pins_
bool digital_read_cache(uint8_t pin) override
bool pcf8575_
TRUE->16-channel PCF8575, FALSE->8-channel PCF8574.
bool digital_read_hw(uint8_t pin) override
ESPHOME_EXPANDER_PIN_SUMMARY_DECL(esphome::pcf8574::PCF8574Component)