Interacting with the peripherals of a microcontroller unit (MCU) is extremely important in many applications. In this chapter, we'll discuss several different ways of implementing peripheral drivers. Up to this point, we've been using blinking LEDs as a means of interacting with our development board. This is about to change. As we seek to gain a deeper understanding of peripheral drivers, we'll start to focus on different ways of implementing a driver for a common communication peripheral—the universal asynchronous receiver/transmitter (UART). As we transfer data from one UART to another, we'll uncover the important role that peripheral and direct memory access (DMA) hardware plays when creating efficient driver implementations.
We'll start by exploring a UART peripheral by implementing an extremely simple polled receive-only...