ESPHome  2024.10.2
mcp23x17_base.h
Go to the documentation of this file.
1 #pragma once
2 
5 #include "esphome/core/hal.h"
6 
7 namespace esphome {
8 namespace mcp23x17_base {
9 
11  // A side
23  // B side
35 };
36 
38  public:
39  bool digital_read(uint8_t pin) override;
40  void digital_write(uint8_t pin, bool value) override;
41  void pin_mode(uint8_t pin, gpio::Flags flags) override;
42  void pin_interrupt_mode(uint8_t pin, mcp23xxx_base::MCP23XXXInterruptMode interrupt_mode) override;
43 
44  protected:
45  void update_reg(uint8_t pin, bool pin_value, uint8_t reg_a) override;
46 
47  uint8_t olat_a_{0x00};
48  uint8_t olat_b_{0x00};
49 };
50 
51 } // namespace mcp23x17_base
52 } // namespace esphome
void digital_write(uint8_t pin, bool value) override
void update_reg(uint8_t pin, bool pin_value, uint8_t reg_a) override
bool digital_read(uint8_t pin) override
const uint32_t flags
Definition: stm32flash.h:85
Implementation of SPI Controller mode.
Definition: a01nyub.cpp:7
void pin_interrupt_mode(uint8_t pin, mcp23xxx_base::MCP23XXXInterruptMode interrupt_mode) override
void pin_mode(uint8_t pin, gpio::Flags flags) override