SME
Embedded Systems · Problem type
UART, SPI or I²C?
Use this for “A bus has two shared wires, pull-up resistors and a 7-bit address for each device. Is it UART, SPI or I²C?”
Sort
Which protocol is it?
Tap a card, then tap its group.
UART has no clock wire; SPI has a clock and a select line for each device; I²C has a clock and a data line that every device shares.
Assumptions
•
Each card is a feature of exactly one of the three buses as a microcontroller uses it.
•
UART links two devices; SPI has one master and several slaves; I²C lets many devices share one pair of wires.
Topic check
See what you know: 5 questions on this topic
New questions each time. Pass to mark it complete.
Related lessons
Serial protocols
Main lesson
Baud-rate register and error
Use this for “A 16 MHz microcontroller sets its UART to 115 200 baud. What goes in UBRR, and how far off is the baud rate?”
SPI throughput
Use this for “An SPI bus clocks at 8 MHz. How many bytes a second can it move, and how long does a 16-bit transfer take?”
I²C transaction time
Use this for “How long does a 400 kHz I²C write of 2 data bytes take, address byte included?”