Skip to content
DenseChip
Learn
PracticeCode labInterview

DenseChip

Navigate

Menu

LearnPracticeCode labInterview

Tools

All toolsSV editorCode repoResume
DenseChip

Practice, courses, and chip-design tools in one focused workspace.

LearnPracticeCode labInterviewToolsLearning paths

© 2026 DenseChip

AboutContactPrivacyTerms
Skip to lesson

Course contents

  • How to Use This Course
  • Reading Paths
  • Concept Map
  • How to Read the Diagrams
  • Part 0: What Is a Protocol?10
  • Part 1: Timing and Clocking11
    • Common-Clock Interfaces
    • Asynchronous Serial and Oversampling
    • Source-Synchronous Clocks and Strobes
    • Embedded Clocks and Clock Recovery
    • Skew and Deskew
    • Clock Relationships
    • Elastic Buffers and Clock Compensation
    • Self-Timed Handshakes
    • Crossing at the Interface
    • Protocols Compared: Timing and Clocking
    • Drills: Timing and Clocking
  • Part 2: Encoding and Framing12
  • Part 3: Handshakes13
  • Part 4: Flow Control17
  • Part 5: Transactions19
  • Part 6: Concurrency and Performance17
  • Part 7: Ordering13
  • Part 8: Sharing and Arbitration12
  • Part 9: Deadlock and Liveness13
  • Part 10: Reliability and Recovery20
  • Part 11: Bring-Up and Link Management10
  • Part 12: Power8
  • Part 13: Shared State and Coherence9
  • Part 14: Security and Isolation7
  • Part 15: Specifying and Verifying11
  • Part 16: Protocols Dissected17
  • Part 17: Capstones5
  • Part 18: Interview Preparation6
Loading lesson

‹Part 1: Timing and Clocking
  1. Topics
  2. First Principles of Hardware Protocols
  3. Part 1: Timing and Clocking
  4. Protocols Compared: Timing and Clocking

Part 1 · Timing and Clocking · All levels

Protocols Compared: Timing and Clocking

How nine protocols answer "when is the data valid?": clocking scheme, how the receiver finds bits, and how clock differences are handled.

On this page

    Every protocol in this table had to decide how its receiver knows when to sample. Read across a row for one protocol's whole answer; read down a column to see the range of answers to one sub-question.

    Clocking, side by side

    Protocol

    Clocking scheme

    How the receiver finds each bit

    How clock differences are handled

    APB, AXI (on chip)

    Common clock

    Samples on the shared clock edge

    Not needed inside one domain; explicit crossings between domains

    SPI

    Master-driven clock with the data

    Samples on the clock edge set by its mode (CPOL, CPHA)

    None needed: there is only the master's clock; slave-to-master data pays a round trip

    I2C

    Master-driven clock line (SCL)

    Data is sampled while SCL is high; SDA changes only while SCL is low

    None needed; a slave may stretch SCL to slow the master

    UART

    No clock: asynchronous framing

    Re-locks on each start bit, samples mid-bit (commonly 16x oversampling)

    Tolerates a few percent total mismatch per frame

    CAN

    No clock: asynchronous with resynchronisation

    Edges at least every six bits, guaranteed by bit stuffing

    Receivers realign on edges throughout the frame

    DDR memory

    Source-synchronous, double data rate

    Each data group has its own strobe (DQS); edge-aligned on reads, centre-aligned on writes

    Strobe and data share the delay; the controller trains capture timing

    PCI Express Gen1–2

    Embedded clock (CDR)

    8b/10b: at most five identical bits in a row

    Elastic buffer adds or removes SKP symbols; lanes deskewed using ordered sets

    PCI Express Gen3–5

    Embedded clock (CDR)

    128b/130b: sync header with a transition on every block, scrambled data

    Same: SKP-based clock compensation, lane deskew

    USB 2.0

    Embedded clock

    NRZI plus a stuffed 0 after six 1s

    Receiver tracks the transmitter's timing from transitions

    10 Gb/s Ethernet (10GBASE-R)

    Embedded clock (CDR)

    64b/66b: sync header 01 or 10 on every block, scrambled payload

    Receiver recovers and tracks the transmitter's clock

    What the table shows

    • Distance and rate pick the scheme. On chip and short: a common clock. Short, wide and fast: a strobe per group. Long or very fast: an embedded clock with CDR. Slow and cheap: no clock at all.

    • Embedded clocks hand work to the protocol. Every CDR protocol in the table guarantees transitions (a code, stuffing or a sync header) and, for continuous streams, defines filler symbols for clock compensation.

    • Master-driven clocks are simple but one-directional. SPI and I2C avoid clock-difference problems by having only one clock, and pay for it in speed on the return path.

    Where each idea is explained

    • 1.1 Common-Clock Interfaces

    • 1.2 Asynchronous Serial and Oversampling

    • 1.3 Source-Synchronous Clocks and Strobes

    • 1.4 Embedded Clocks and Clock Recovery

    • 1.5 Skew and Deskew

    • 1.7 Elastic Buffers and Clock Compensation

    Tip

    Fill in a row for an interface you know that is not here, for example a camera or display link. If you cannot say how it handles clock differences, that is the first question to ask of its specification.

    Keep going

    Next: Drills: Timing and Clocking. Interview questions, a whiteboard exercise and a ten-question checkpoint for Part 1.

    Related topics

    • Part 1 overview: Timing and Clocking

    • Course hub

    Previous

    24 / 234

    Next: Drills: Timing and Clocking

    Up next

    Up nextDrills: Timing and Clocking

    Sign in to save progress

    Practice this lessonReport an error

    See also

    • Common-Clock Interfaces
    • Asynchronous Serial and Oversampling
    • Source-Synchronous Clocks and Strobes