



















Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




















Uploaded PDF: Complete Digital Design by Mark Balch (McGraw-Hill, 2003 ).
Syllabus Unit Coverage in PDF Action taken
sequential circuits
Partial: flip-flops (Ch. 1. 8 ), synchronous logic and counters ( 1. 9 ), timing ( 1. 10 ), FSM bubble diagrams and Verilog FSMs (Ch. 10. 4 – 10. 6 ). Not covered: state reduction, state assignment, iterative circuits, ASM charts
PDF used where available; rest from standard subject knowledge
sequential circuits
Only metastability and clock-domain synchronizers (Ch. 10. 3 ), FIFO sync (Ch. 4. 8 )
Mostly standard subject knowledge
Not covered (only JTAG/boundary scan, diagnostics, Ch. 19. 5 – 19. 7 )
Standard subject knowledge; JTAG used for DFT
not described in detail
PDF + standard knowledge
Note on repetition claims: No previous question papers were provided, so I do NOT claim any question is "frequently repeated". Priorities below are based on syllabus weight and typical 16 - mark suitability only.
Introduction. A sequential circuit has outputs that depend on present inputs AND past history (stored state). A clocked synchronous circuit changes state only at the active clock edge, all flip- flops sharing the same clock (Balch: "synchronous circuits consist of state-full elements (flops) with combinatorial logic providing feedback to generate the next state"). Analysis means: given the circuit, find its behaviour.
General model
Moore model: Z = f(Q) only. Mealy model: Z = f(Q, X).
Steps of analysis
Inputs X ──►[ Combinational logic ]──► Outputs Z ▲ │ next-state Y (flip-flop inputs) │ ▼ present state ◄[ Flip-flops ]◄── CLOCK Q
Worked example. Circuit with two D flip-flops A, B and input x: D_A = A·x + B·x ; D_B = A'·x ; output y = (A + B)·x'
Present A B x= 0 : Next AB, y x= 1 : Next AB, y
00 00 , 0 01 , 0
01 00 , 1 11 , 0
10 00 , 1 11 , 0
11 00 , 1 10 , 0
(Derivation: for AB= 01 ,x= 1 : D_A = 0 · 1 + 1 · 1 = 1 , D_B = 1 · 1 = 1 → 11 .) The state diagram is drawn from this table: 4 circles ( 00 , 01 , 10 , 11 ), arcs labelled x/y.
Flip-flop timing note (PDF, 1. 10 ). The clock period must satisfy t_CLK ≥ t_CO + t_PROP + t_SU (plus skew/jitter); hold-time requires t_CO + t_PROP(min) > t_H.
Applications. Counters, sequence detectors, control units, serial adders. Conclusion. Analysis converts a logic diagram into a state table/diagram, which reveals the function and allows verification.
Design steps
Flip-flop excitation tables
Q→Q⁺ D T J K S R
0 → 0 0 0 0 X 0 X
0 → 1 1 1 1 X 1 0
1 → 0 0 1 X 1 0 1
1 → 1 1 0 X 0 X 0
Example: Mealy detector for 101 (overlap allowed) States: S 0 (no progress), S 1 (got " 1 "), S 2 (got " 10 ").
PS x= 0 x= 1
S 0 S 0 , 0 S 1 , 0
S 1 S 2 , 0 S 1 , 0
S 2 S 0 , 0 S 1 , 1
Assign S 0 = 00 , S 1 = 01 , S 2 = 10 ( 11 unused = don't care). Let state = AB.
AB x A⁺B⁺ z
00 0 00 0
00 1 01 0
01 0 10 0
01 1 01 0
10 0 00 0
10 1 01 1
Using D flip-flops (D = next state), K-map with don't cares for 11 :
D_A = A'B x' D_B = x z = A x
Circuit: two D flip-flops, gates: AND(A',B,x'), AND(A,x) for output; D_B directly driven by x. (PDF
Verilog (from PDF style): two always blocks – clocked state register + combinational next- state/output block with a default to avoid hung states.
Conclusion. A systematic procedure guarantees a correct, minimal circuit.
Definition. An iterative circuit is a combinational circuit built from a cascade of identical cells; each cell takes primary inputs of its bit position plus carry/state signals from the previous cell and produces outputs plus signals to the next cell. It is the combinational equivalent of a sequential machine processing bits serially (cells replace time steps).
Design procedure: ( 1 ) design one cell as a sequential-style state table where the "state" = signal passed between cells; ( 2 ) minimise states; ( 3 ) assign codes; ( 4 ) derive logic; ( 5 ) replicate n times and set boundary conditions.
Example – Parity checker / Ripple-carry adder.
x0 ─┐ x1 ─┐ xn-1 ─┐ ┌───▼──┐ c 1 ┌──▼───┐ c 2 ┌───────▼┐ cn │Cell 0 ├───►│Cell 1 ├──►...►│Cell n-1├──► └──┬───┘ └──┬───┘ └───┬────┘ z0 z1 zn- (c 0 = boundary input)
PART 2 – 2 - MARK QUESTIONS (UNIT 1 )
PART 3 – UNIT 1 IMPORTANT TOPICS
Must-study 16 M: Analysis; State reduction + assignment; Design with example (sequence detector/counter); ASM chart. Key terms: Moore/Mealy, excitation table, state table, one-hot, ASM block. Do not skip: Flip-flop equations/excitation tables; K-map simplification with don't cares; at least one worked design.
Definition. Asynchronous sequential circuits have no clock; state changes occur in response to input changes. Memory is provided by feedback paths with delays (gate delays Δ), not flip-flops. (Contrast with PDF 3. 5 : asynchronous MPU bus uses signal sequencing, not a clock.)
Modes: Fundamental mode (only one input changes at a time, and inputs change only when circuit is stable) and pulse mode.
General model
Analysis procedure
Example (SR latch with NOR gates): Y = S + R'y
y SR= 00 01 11 10
0 0 0 1 →? 1
1 1 0 0 (unstable if
R) …
(Y = S + R'y: for 00 : Y=y (stable); 01 : Y= 0 ; 10 : Y= 1 ; 11 forbidden/Y= 1
when S= 1 .) Stable states are those where Y=y.
Conclusion. The analysis shows stable/unstable states and reveals races and hazards.
Inputs x ──►[ Combinational ]──► Outputs Z ▲ │ Y (excitation, secondary next) │ [Delay Δ] └── y (secondary/present state) ◄┘
GD= 00 01 11 10
a (Q= 0 ) a a b a
b (Q= 1 ) b b b a
With state variable y: Y = GD + G'y + Dy (the last term, the consensus term,
prevents a static- 1 hazard when G changes while D=y= 1 ).
Output Z = y.
Implementation: AND-OR network of the three terms with feedback.
Note. Only one input may change at a time (fundamental mode). Conclusion. Careful hazard and race handling is the key to correct asynchronous design.
Hazard: a momentary (unwanted) glitch caused by unequal propagation delays, in a circuit that otherwise has correct steady-state behaviour.
Detection: K-map covering (static), flow table 3 - change test (essential). Elimination summary table
Hazard Cause Removal
Static- 1 Uncovered adjacent 1s Redundant (consensus) product term
Static- 0 Uncovered adjacent 0s Redundant sum term
Dynamic Multi-path delays Use hazard-free two-level realization
Essential Input vs feedback delay Add delay element
Conclusion. Hazard-free design is critical because a glitch in an asynchronous circuit can be memorised as a wrong state.
Part A – Metastability (PDF 10. 3 ). When an asynchronous signal violates a flip-flop's setup/hold window, the output may hover at an intermediate voltage for an unpredictable time before settling to 0 or 1. It does not damage the flop but can corrupt logic.
Data synchronizers (PDF 10. 3 and 4. 8 )
Part B – Real-time scenario: Traffic-light controller (Moore FSM)
Inputs: car sensor S on side road, timer expiry T. States: G_main (main green, side red), Y_main (main yellow), G_side (side green), Y_side (side yellow). Transitions: G_main →(S= 1 & T= 1 )→ Y_main → (T) → G_side →(S= 0 or T)→ Y_side →(T)→ G_main. Outputs: lights per state (Moore). Encoding: 2 bits (G_main= 00 , Y_main= 01 , G_side= 11 , Y_side= 10 – Gray to minimise glitches). Implementation: 2 D flip-flops, next-state logic, timer (counter) giving T. Use synchronized S (two-flop) as S is asynchronous – ties both parts together. A "vending machine" or "elevator controller" can also be used as the example.
PART 1 – 16 - MARK QUESTIONS
Faults: physical defects (opens, shorts) modelled logically. Stuck-at fault model: a line is permanently at 0 (s-a- 0 ) or 1 (s-a- 1 ). Others: bridging, stuck-open, delay faults. Single stuck-at fault assumption: only one fault at a time.
Fault table method
Example: circuit F = AB + C. Faults: A s-a- 0 , B s-a- 0 , AB-output s-a- 0 etc. Vectors for F: good F for 110 = 1 ; A s-a- 0 gives 0 → 110 detects A s-a- 0 , B s-a- 0 , (AB node) s-a- 0. For C s-a- 0 : need C= 1 , AB= 0 , e.g., 001. For C s-a- 1 : C= 0 , AB= 0 → output should be 0 , becomes 1 → 000. Selected minimal test set { 110 , 001 , 000 , plus vectors for A s-a- 1 ( 011? A= 0 ,B= 1 ,C= 0 → good 0 , fault 1 : A s-a- 1 gives AB= 1 → F= 1 ✓.) } e.g., 010 and 100. Table gives set { 110 , 001 , 000 , 010 , 100 } covers all single faults.
Advantages: exhaustive, gives minimum set. Disadvantages: table size explodes with n – impractical for large circuits.
Fault equivalence/collapsing: faults producing identical behaviour (e.g., all inputs s-a- 0 of an AND gate ≡ output s-a- 0 ) are grouped to reduce table. Fault dominance also reduces faults.
A. Path sensitization. Principle: to detect fault on line L: ( 1 ) Activate – set L to opposite of the stuck value; ( 2 ) Propagate – choose a path from L to a primary output and set all side inputs of gates on the path to non-controlling values ( 1 for AND/NAND, 0 for OR/NOR); ( 3 ) Justify – find input vector producing these values. Example: For F = (AB)+(C·D), test A s-a- 0 : A= 1 ; B= 1 (to make AB= 1 for activation and pass); side input of OR is CD must be 0 (e.g., C= 0 ). Test: A= 1 ,B= 1 ,C= 0 , D=x. Good F= 1 , faulty F= 0 → detected. Limitations: reconvergent fanout may block single-path sensitization → need multi-path sensitization (a fault detectable only by sensitizing several paths simultaneously).
B. Boolean difference. For F(x1…xn), the Boolean difference with respect to xᵢ is dF/dx ᵢ = F(x ᵢ = 0 ) ⊕ F(x ᵢ = 1 ). It equals 1 exactly for input combinations where F depends on xᵢ (a change in xᵢ changes F).
Test for x ᵢ s-a- 0 : xᵢ · (dF/dxᵢ) = 1. Test for x ᵢ s-a- 1 : xᵢ' · (dF/dxᵢ) = 1. Example: F = AB + C. dF/dA = ( 0 ·B+C) ⊕ (B+C) = C ⊕ (B+C) = B C'. A s-a- 0 test: A·B·C' = 1 → A= 1 ,B= 1 ,C= 0 ✔ (same as path sensitization). A s-a- 1 test: A'·B·C' = 1 → A= 0 ,B= 1 ,C= 0. For internal lines, treat the line as an independent variable; for multiple outputs, apply to each output.
Comparison: Boolean difference is algebraic and exact for any structure (including reconvergence), but symbolic computation is heavy for large circuits.
Idea (Roth, 1966 ). Systematic, complete algorithm for generating a test for a single stuck-at fault. Uses five values: 0 , 1 , X, D, D' where D = 1 in good circuit/ 0 in faulty, D' = 0 in good/ 1 in faulty.
Terms
Singular cover: truth-table (cube) form of a gate's normal function. Primitive D-cube of a fault (PDCF): inputs that excite the fault and produce D or D' at its output (e.g., AND gate output s-a- 0 : inputs 11 → output D). Propagation D-cubes: make gate output follow D/D' from input (e.g., AND: D· 1 → D). D-frontier: gates whose output is X but one or more inputs are D/D'. J-frontier: gates with specified output not yet justified by inputs.
Steps
Example. Circuit: F = (A·B)+C, fault: AB node s-a- 0. PDCF: A= 1 ,B= 1 → D at AND output. D-drive through OR: C= 0 → F=D. Test: A= 1 ,B= 1 ,C= 0 (good 1 , faulty 0 ).
Advantages: complete (finds test if exists), handles reconvergent fanout. Disadvantages: can be slow; improved variants: PODEM, FAN.
Fault tolerance: a system continues correct operation despite faults.
Must-study: Boolean difference (numerical practice), D-algorithm (worked example), path sensitization, DFT scan + BIST, fault table. Key terms: s-a- 0 / 1 , D-frontier, TMR, MISR, JTAG.
Need for PLDs (PDF 11. 1 ). ASICs: high speed and low unit cost but long, expensive development (mask costs $ 50 k–$ 1 M+) and no changes. PLDs: general logic resources, rapid customization, reprogrammability, short time-to-market; penalties: higher unit cost, slower, more power. Low-end designs may even be cheaper in PLD (pad-limited dies, volume).
Basic structure: programmable AND array and OR array (sum-of-products).
Device AND array OR array Notes
PROM Fixed (decoder) Programmable Truth-table/memory style, 2ⁿ words
PLA Programmable Programmable Flexible, product-term sharing, costly/slower
PAL Programmable Fixed Cheap, fast; outputs with fixed OR
GAL Programmable (EEPROM,
reprogrammable)
Fixed Adds output macrocell; replaces PAL. Examples 16 V 8 , 22 V 10
CPLD Multiple GAL-like blocks + switch matrix
Non-volatile, deterministic timing
FPGA LUT-based logic cells + routing SRAM, high density
GAL (PDF 11. 2 ). Fuse (EEPROM) cells at AND array; true and complemented inputs; unused AND gates disabled; macrocell contains flip-flop, OR/NOR polarity mux, output enable, feedback to AND array. 22 V 10 : 10 macrocells, 12 dedicated inputs; pin-to-pin delay as low as 4 ns, tCO 3 ns, up to ~ 250 MHz. Predictable timing because logic passes through just two gate levels.
CPLD (PDF 11. 3 ). Multiple GAL-type logic blocks interconnected via central switch matrix; scales linearly; product-term sharing; multiple global clocks; multi-voltage I/O banks. Xilinx XC 9500 : 18 macrocells per function block, 54 inputs from switch matrix, 36 – 288 macrocells, 3. 5 ns pin-to-pin. Non-volatile EEPROM storage; good for control logic, state machines, glue logic.
FPGA (PDF 11. 4 ). Array of logic cells ( 4 - input LUT as small SRAM, flip-flop, carry logic), programmable routing, embedded RAM blocks, clock managers (PLL/DLL), I/O cells with registers (and DDR support). SRAM-based (volatile; reconfigured at power-on). Suited to data-path designs with thousands of flops; timing depends on routing → floorplanning and iterative place-and-route.
CPLD vs FPGA table
Feature CPLD FPGA
Architecture Product-term (AND/OR) blocks LUT + flip-flop cells
Density Hundreds of macrocells Thousands–millions
Timing Predictable Routing dependent
Storage Non-volatile EEPROM/flash Mostly SRAM (volatile)
Best for Control, glue logic Data-path, complex designs
Conclusion. Choice depends on speed, density, cost and development time.
FPGA architecture (PDF 11. 4 ). Three main parts: CLBs/logic cells, programmable interconnect, I/O blocks, plus embedded RAM and clock resources.
Xilinx FPGA overview. SRAM-configured; bitstream loaded from PROM/host at power-on (master/slave/peripheral/serial modes); configuration memory cells control LUTs, multiplexers and pass-transistor routing switches.
XC 4000 family (standard knowledge; PDF only gives generic FPGA data).
Design flow: HDL/schematic → synthesis → mapping to CLBs → place & route → bitstream → configuration → verification (PDF 11. 4 : routing can take minutes to hours; floorplanning helps).
Advantages: reprogrammable, high density, fast prototyping. Disadvantages: volatile, higher cost per gate, routing delays unpredictable. Applications: prototyping, DSP, networking, interface logic.
PART 2 – 2 - MARK QUESTIONS (UNIT 4 )
IOB IOB IOB IOB IOB [CLB][CLB][CLB] IOB CLBs in matrix, surrounded by IOBs IOB [CLB][CLB][CLB] IOB Switch matrices (programmable interconnect points) between CLBs IOB IOB IOB IOB
Must-study: PLD families comparison, FSM on PLA/PAL (with PLA table), CPLD vs FPGA, XC 4000 CLB. Do not skip: GAL macrocell, product-term sharing, LUT concept.
(PDF teaches Verilog only; VHDL material is from standard subject knowledge. Verilog equivalents from PDF Ch.10 are shown for comparison.)
VHDL = VHSIC Hardware Description Language (IEEE 1076 ). A design = entity (interface) + architecture (behaviour/structure).
Operators (in order of precedence, low→high)
Concurrent statements (execute simultaneously, order irrelevant; in architecture body): signal assignment y <= a and b; , conditional ( when…else ), selected ( with…select ), process statement, component instantiation, generate statements.
Sequential statements (execute in order, inside process/subprogram): variable/signal assignment, if…elsif…else , case…when , loops ( for , while ), wait , null.