Module 3: Sequential Circuit Design
Combinational logic circuits compute outputs based strictly on present input values. A combinational circuit cannot store past events or retain operational history. When an application requires memory—such as counting button presses, executing multi-step protocols, or tracking processor program counters—the system requires sequential logic. Module 3 examines digital circuits that store and update internal state across time.
State and the Memory Hierarchy
A computer differs fundamentally from a simple calculator. A computer executes sequential programs where each computational step depends on preceding operations. Hardware maintains this continuity through state:
- Registers: Hold active datapath operands and intermediate variables.
- Program Counter (PC): Points to the address of the current executing instruction.
- Stack Pointer (SP): Preserves execution contexts during subroutine calls.
The fundamental physical unit of digital state is the flip-flop. A flip-flop stores one bit of binary data until updated by an active clock edge. Cascading flip-flops creates register files, pipeline stages, First-In First-Out (FIFO) buffers, and high-speed cache memories.
Architecture of a Sequential Circuit
A sequential circuit consists of two complementary subsystems (Figure 1):
- Combinational Next-State and Output Logic: Evaluates external inputs and the current state vector to calculate output signals and the next state vector.
- State Storage Registers: Parallel flip-flops capture the next state vector synchronously on active clock edges.
- Feedback Interconnect: Routes the registered current state back to the combinational logic inputs, allowing the circuit to maintain continuity across clock cycles.
Core Projects in Module 3
Module 3 guides the complete specification, synthesis, and simulation of three industrial sequential circuits:
- Traffic Light Controller: A multi-interval Finite State Machine (FSM) with timing countdown counters.
- Serial Pattern Detector: A sequence detector that asserts a flag upon detecting target pattern
1011in a continuous serial bit stream. - Vending Machine Controller: An interactive FSM that accepts coin inputs, tracks cumulative balances, dispenses products, and returns change.
Each project progresses from state transition diagrams to excitation tables and synthesizable Verilog code.
Section Breakdown
Table 1 details the technical sections of Module 3:
| Section | Title | Primary Technical Topics |
|---|---|---|
| 3.1 | Latches and Flip-Flops | Bistability, SR latches, D latches, edge-triggered D flip-flops, JK/T types, setup and hold timing. |
| 3.2 | Synchronous Design & Clocks | Clock distribution networks, clock skew and jitter, hazards of asynchronous design, metastability. |
| 3.3 | Finite State Machines (FSM) | Moore versus Mealy models, state transition diagrams, state assignment encoding, Verilog FSM templates. |
| 3.4 | Registers & Shift Registers | Parallel-load registers, serial-in serial-out (SISO), universal shift registers, linear-feedback shift registers (LFSR). |
| 3.5 | Binary Counters | Asynchronous ripple counters, synchronous binary counters, modulo-$N$ counters, up/down counters, Gray code counters. |
| 3.6 | Memory Arrays | Register file design, Static RAM (SRAM) cell topologies, Dynamic RAM (DRAM), ROM arrays, and memory hierarchies. |
Critical Timing Requirements: Setup, Hold, and Metastability
In combinational logic, propagation delay affects operational frequency, but not functional logic states. In sequential logic, timing directly determines logical correctness:
- Setup Time ($t_{\text{setup}}$): The data input ($D$) must remain stable for a minimum duration before the active clock edge. Violating setup time causes internal transistor nodes to enter an undefined, non-binary state called metastability.
- Hold Time ($t_{\text{hold}}$): The data input ($D$) must remain stable for a minimum duration after the active clock edge. Violating hold time causes the flip-flop to sample the new incoming value prematurely, corrupting the pipeline register. Hold time violations cannot be fixed by reducing the clock frequency.
Module 3 defines timing parameters rigorously and derives mathematical constraints to guarantee race-free synchronous operation.
Getting Started
Section 3.1 analyzes the physics of bistable feedback and single-bit memory storage.