Course contentsShow
← Embedded Systems & Computer Architecture
Lesson 340 of 9365. Communication Protocols and Data TransferFree lesson

Implementing Asynchronous Framing and Start-Stop Bits

Learners will identify how asynchronous protocols use start, stop, and parity bits to maintain data integrity without a shared clock signal.

In this lesson, you will learn how asynchronous protocols establish synchronization between two devices without sharing a common clock signal.

The Challenge of Asynchronous Communication

When two devices communicate (like a microcontroller and a PC), they often don't share a clock wire. Because their internal oscillators might drift slightly, the receiver doesn't know exactly when a data bit arrives. To solve this, we use Asynchronous Framing, which adds extra control bits to each byte of data to tell the receiver when to start and stop listening.

Framing Anatomy

A standard asynchronous frame consists of a "Start" bit, the data bits, an optional "Parity" bit, and "Stop" bits:

  1. Start Bit: The line is normally held at a high voltage (Logic 1). The sender pulls the line low (Logic 0) to signal the start of a new frame. This "falling edge" wakes up the receiver’s internal timer.
  2. Data Bits: The actual payload (usually 8 bits) is sent sequentially. The receiver samples the line at specific intervals based on a pre-agreed speed (the baud rate).
  3. Parity Bit: This is a simple error-detection mechanism. If enabled, it counts the number of 1s in the data to ensure the total is either even or odd. If the receiver’s count doesn't match, it flags a parity error.
  4. Stop Bit(s): The sender releases the line back to a high voltage for at least one period. This ensures the line is in the correct state to detect the next start bit.

Visualizing the Frame

If you were to look at an oscilloscope, a byte like 0x41 ('A') might look like this:

Idle (High) -> Start (Low) -> [Data Bits 0-7] -> Parity -> Stop (High)

By wrapping data in this "frame," the receiver can identify the start of a transmission, process the data, verify its integrity, and reset itself for the next frame—all without needing a shared clock signal. This approach is the fundamental backbone of protocols like UART, enabling robust communication despite independent clock sources.

Key Takeaway: Asynchronous protocols rely on start and stop bits to frame raw data, allowing the receiver to synchronize its internal sampling to the sender's signal without a shared reference clock.