Talking to hardware from your development board is when the real fun starts with a project. You can connect sensors, actuators, and more to make your project come alive with motion, sensation, sound, etc. However to communicate with other hardware typically requires knowledge of a serial protocol like I2C or SPI. These protocols are the common language that chips and add-on boards talk so they can be connected to a development board. The board knows how to ‘speak’ these protocols and control the connected hardware. This guide explores two very common serial protocols, I2C and SPI.
This guide covers lower level details about I2C and SPI communications that most users will not need to deal with directly. Ideally, there will already be a library specifically written for a breakout that takes care of all these details. Be sure to check the breakout specific guide first.
The information in this guide is mainly useful for anyone wanting to write a new driver library for some device. Or is just curious about lower level details about I2C/SPI communications.