SPI is a fast four-wire bus for high-speed communication between a controller and chips — used when a robot needs to move data quickly to displays, high-rate sensors, SD cards, and ADCs.
SPI is a fast way for a robot's main chip to talk to another chip — like a high-rate sensor, a screen, or an SD card. It uses more wires than I2C but moves data much quicker.
When a robot needs to move data fast between chips — refreshing a display, reading a high-rate sensor, logging to an SD card — the go-to bus is SPI.
What it is
SPI (Serial Peripheral Interface) is a four-wire synchronous bus:
SCLK — clock (from the controller).
MOSI — Controller Out, Peripheral In (data to the device).
MISO — Controller In, Peripheral Out (data back).
CS / SS — chip-select, one per device, to pick which peripheral is active.
It's full-duplex (data flows both ways at once) and runs much faster than I2C — many megahertz, sometimes tens.
Fast, full-duplex, one device at a time
The controller pulls one device's chip-select low to talk to it. More wires than I2C, but faster and simpler at the signaling level.
SPI vs I2C — the classic choice
Robotics designers constantly pick between the two:
I2C — two shared wires, device addresses, slower. Best for many low-speed sensors on minimal pins.
SPI — four wires plus a chip-select per device, faster, full-duplex. Best when speed matters or a device demands it.
The cost of SPI's speed is pins: each peripheral needs its own chip-select line, so many SPI devices eat up controller pins. So a robot often uses I2C for its cluster of slow sensors and SPI for the few that need bandwidth.
Where you'll see it
High-rate IMUs and ADCs, displays (TFT/OLED), SD cards for logging, flash memory, some encoders, and radio modules — anywhere fast, reliable chip-to-chip transfer is needed on a robot's board.
Why it matters
SPI is one of the three essential serial buses (I2C, SPI, UART) that connect a robot's electronics. Knowing when to reach for SPI's speed versus I2C's simplicity is a basic, everyday design decision in building robot hardware.