From the course: Raspberry Pi: GPIO

Unlock the full course today

Join today to access over 24,200 courses taught by industry experts.

Understanding SPI in depth

Understanding SPI in depth

From the course: Raspberry Pi: GPIO

Understanding SPI in depth

- [Instructor] The serial peripheral interface is well-defined on a hardware level, even if it tends to wander on the software side. Understanding how SPI signals work will help implement projects and debug related problems. So let's take a deep dive into SPI. There are two lines used to exchange signals between the Raspberry Pi and an SPI module, MOSI and MISO. These are acronyms for Master Out, Slave In, and Master In, Slave Out. In our case, the Raspberry Pi is the master. The BME280, or OLED display, are the slaves. Chip enable, or chip select, or slave select are all names for the same signal. Each slave is tied to a Raspberry Pi GPIO pin. When the Raspberry Pi drops the pin voltage to zero, that particular chip is enabled and allowed to communicate over MOSI or MISO. At a low level, SPI depends on several timed events. First, the master, in this case the Raspberry Pi, sets the chip select signal from high, a positive…

Contents