Module 6 of 10

Communication Protocols

Lessons

About This Module

A microcontroller rarely works alone. Sensors, displays, memory chips, and other processors all need to exchange data with it, and they do so using agreed sets of rules called communication protocols. Knowing how each one moves bits over the wires makes datasheets easier to read and wiring problems easier to track down.

You'll start with an overview of the three most common serial protocols, then look at each one in turn. UART is the simple two-wire link behind serial monitors and many modules. I2C shares just two lines between many devices using addresses. SPI trades extra wires for higher speed and full-duplex transfers.

By the end you'll be able to choose the right protocol for a given part and recognise its signals on an oscilloscope or logic analyser. Once you've finished, move on to RTOS & Concurrency to learn how to run several tasks at once.

Lessons

4 videos
01

Protocols: UART, I2C, and SPI Serial Communications

A first look at how the three most common serial protocols work, with examples that show what each one is used for and how they compare.

02

Understanding UART

The UART serial protocol explained with an oscilloscope: the two-wire connection, asynchronous timing, baud rate, and how data is framed with start and stop bits.

03

I2C and How to Use It

How the two-wire I2C bus lets several devices share one connection, and how to put it to use in a real circuit.

04

Understanding SPI

A technical overview of the Serial Peripheral Interface and how it transfers digital data between a controller and its peripherals.