Main Content

I2C Devices

Read and write to I2C devices connected to Arduino®hardware

Create an Arduino object usingarduinobefore you use I2C functions. SeeConnect to Arduino Hardwarefor more information.

Note

All functions, exceptscanI2CBus, can be used to generate code using the MATLAB Function block. For more details, seeDeploy Arduino Functions to Arduino Hardware Using MATLAB Function Block.

Functions

device Connection to device on I2C bus onArduinoor ESP32 hardware
scanI2CBus 年代can I2C bus onArduinohardware for device address
read Read data from I2C bus
write Write data to I2C bus
readRegister 读取数据从I2C设备注册
writeRegister Write data to I2C device register

Topics