Manufacturing test requires forcing internal states and observing internal effects. Scan converts sequential logic into a chain of controllable and observable storage elements.
Idea | Meaning | Where it is covered |
|---|---|---|
Controllability | Test logic can drive an internal node to 0 and 1 | |
Observability | A node effect can propagate to a scan-out or a primary output | |
Test mode | Clocks, resets, and constraints stay deterministic while shifting | |
Scan chain | Muxed-D flops stitched si-to-so, shifting vectors in and out |
5 lessons, about 24 min
Functional patterns check behaviour the designer thought of. Manufacturing test must also catch defects the designer never modelled, which needs direct control and observation of internal state.
The whole topic on one page, taken from each lesson's Remember box. Read it before an interview, or print it.
Why scan exists
A scan flop has a mux in front: scan_en = 1 takes the previous flop, scan_en = 0 takes the functional input.
ATPG treats each capture cycle as combinational logic between scan flops.
Scan improves access, not coverage. Untestable logic stays untestable until the RTL gives the tool a path to it.
Rule of thumb: scan adds a second way to reach the same state; it does not change the function.
The scan chain at RTL abstraction
A scan flop is a D flop with a 2:1 mux; the first bit shifted in ends in the last flop, and is the first bit out.
A scan operation costs about (longest chain + capture cycles) x patterns, plus one final unload.
scan_en must be quasi-static for stuck-at and launch-off-capture tests; a glitch corrupts the vector.
Test-mode integration checklist
OR the functional enable with test mode so shifting never depends on functional activity.
Masking hides an X but does not remove its source; record every mask as a coverage hole.
Debug low coverage in order: unconstrained inputs, masked X sources, un-overridable clocks, then the chain.
Controllability and observability in practice
A test-mode override may shorten a delay; it must change nothing when test mode is low.
A sticky flag latches the first pulse until reset, so a later shift-out sees it.
Never override a signal whose name carries a guard: allow, grant, secure, lock, privilege.
Rule of thumb: shorten delays in test mode, never bypass permission checks.
Fault Coverage by Hand
A pattern detects a fault only when it activates the net to the opposite value and the difference propagates to an observed output.
Fault coverage divides by every fault; test coverage divides by the faults left after untestable ones are removed. Report both.
Scan turns flops into pseudo-inputs and pseudo-outputs, so the logic between flops can be tested like a combinational circuit.
Rule of thumb: never accept a coverage number without the fault list it was divided by and a reviewed reason for every excluded fault.
Mini project: the capstone: a resilient streaming peripheral, stage by stage
Code lab: Scan chain stub
Code lab: DFT scan enable
Interview: run a mock interview on this topic