57 bool Transaction(uint8_t* dataToSend,
int sendSize, uint8_t* dataReceived,
81 bool Write(
int registerAddress, uint8_t data);
109 bool Read(
int registerAddress,
int count, uint8_t* data);
I2C bus interface class.
Definition: I2C.h:23
I2C(Port port, int deviceAddress)
Constructor.
bool Read(int registerAddress, int count, uint8_t *data)
Execute a read transaction with the device.
bool ReadOnly(int count, uint8_t *buffer)
Execute a read only transaction with the device.
bool Transaction(uint8_t *dataToSend, int sendSize, uint8_t *dataReceived, int receiveSize)
Generic transaction.
bool Write(int registerAddress, uint8_t data)
Execute a write transaction with the device.
I2C & operator=(I2C &&)=default
bool WriteBulk(uint8_t *data, int count)
Execute a bulk write transaction with the device.
bool VerifySensor(int registerAddress, int count, const uint8_t *expected)
Verify that a device's registers contain expected values.
int GetDeviceAddress() const
bool AddressOnly()
Attempt to address a device on the I2C bus.
@ kOnboard
Definition: I2C.h:25
@ kMXP
Definition: I2C.h:25
A move-only C++ wrapper around a HAL handle.
Definition: Types.h:96
constexpr auto count() -> size_t
Definition: core.h:1203
Definition: AprilTagPoseEstimator.h:15