I2C-Kommunikation
I2C, oder Inter-Integrated Circuit, ist eine Chip-zu-Chip-Schnittstelle, die die Zwei-Draht-Kommunikation unterstützt. Sie können Verbindungen zu I2C-Peripheriegeräten herstellen und Daten von diesen lesen und schreiben. Erstellen Sie das Schnittstellenobjekt mithilfe der Funktion device mit einem aardvark- oder ni845x-Objekt.
Zur Nutzung der I2C-Schnittstelle benötigen Sie entweder einen Total Phase® Aardvark I2C/SPI™ Host-Adapter oder ein NI™ USB-8451 oder USB-8452 I2C/SPI-Schnittstellengerät.
Funktionen
Themen
- I2C Interface Overview
Connect to I2C controller boards and peripheral devices and communicate with them from MATLAB®.
- Configure I2C Controller Board Communication
Discover and connect to Total Phase Aardvark™ or NI USB-845x controller boards using the
aardvarkorni845xinterface. - Transmit Data to Peripheral Device Over I2C Interface
Communicate with an I2C peripheral device connected to a Total Phase Aardvark or an NI USB-845x controller board.
- Install Instrument Control Toolbox Support Package for Total Phase Aardvark I2C/SPI Interface
Install the support package for a Total Phase Aardvark controller to communicate with I2C and SPI interfaces in MATLAB.
- Install Instrument Control Toolbox Support Package for National Instruments NI-845x I2C/SPI Interface
Install the support package for an NI USB-845x controller to communicate with I2C and SPI interfaces in MATLAB.
- Transition Your Code to aardvark or ni845x Interface
Create I2C connections using the
devicefunction with anaardvarkorni845xobject instead ofi2c.
Fehlersuche
Troubleshoot the I2C interface.
