### Lecture 5: Logic Design -- Latches, Flip-Flops, and Synchronous Circuits

Text: Appendix B.4 to 7

(discuss simulation and Assignment #2)

#### Combinational vs. sequential circuits

• in a combinational circuit, output (after some delay) is a function of inputs
• in contrast, a sequential circuit holds state information: the output is a function of the state of the device, as well as its inputs; in other words, sequential circuits have memory

#### Simple latches

• RS latch (reset-set latch): set and reset inputs (text, figure B.12)
• D-type latch: clock and data inputs (text, figure B.13): use of clock to control when a latch is updated
• register: set of latches with a common clock

#### Synchronous circuit

• consists of a set of registers controlled by a common clock, along with a combinatorial circuit to compute the next state (text, figures B.10, B.11, B.27)
• up-counter as simple example of synchronous circuit
• race problem if same latches are used for input to and output from combinatorial circuit (figure B.11)
• use of edge-triggered registers to address race problem