|
XPoint 0.1.0
Hardware-agnostic crosspoint matrix routing library
|
I2CInterface implementation that delegates to the Arduino Wire library. More...
#include <WireI2C.h>
Public Member Functions | |
| WireI2C () | |
| void | begin () override |
Initialize the I2C bus by calling Wire.begin(). | |
| void | writeRegister (uint8_t addr, uint8_t reg, uint8_t val) override |
Write val to register reg on device at 7-bit address addr. | |
| void | writeByte (uint8_t addr, uint8_t data) override |
| Write a single data byte to a device (no register address byte). | |
Public Member Functions inherited from I2CInterface | |
| virtual | ~I2CInterface () |
I2CInterface implementation that delegates to the Arduino Wire library.
Create one instance per I2C bus and pass a pointer to MCP23017Driver.
|
inline |
|
overridevirtual |
Initialize the I2C bus by calling Wire.begin().
No-op on host builds.
Reimplemented from I2CInterface.
|
overridevirtual |
Write a single data byte to a device (no register address byte).
Used by TCA9548AInterface to select a mux channel with a bare one-byte control word. Sequence: beginTransmission → write(data) → endTransmission. No-op on host builds (MockI2C test path uses the I2CInterface default).
| [in] | addr | 7-bit I2C device address. |
| [in] | data | Control byte to write. |
Reimplemented from I2CInterface.
|
overridevirtual |
Write val to register reg on device at 7-bit address addr.
Sequence: beginTransmission → write(reg) → write(val) → endTransmission. No-op on host builds.
| [in] | addr | 7-bit I2C device address. |
| [in] | reg | Register index. |
| [in] | val | Byte to write. |
Implements I2CInterface.