CHAPTER 3.2
Course Overview
Course Title: COSC 3332 Computer Organization and Architecture
Instructor: Dr. Qi Zhu
Course Objectives
Design simple logic circuits.
Understand the interaction of digital circuits in complex computer systems.
Key Concepts
Circuit Types:
Combinational Circuits: Output solely based on current inputs.
Sequential Circuits: Output depends on input and current state (needs memory).
Basic Boolean Operators: Used in digital logic circuits.
Combinational Circuits
Outputs determined by inputs at any moment.
Examples:
AND Gate: Uses an enable line to control output. If enable = 0, output = 0; if enable = 1, output follows inputs.
Selective Inverter: Uses an invert line; output is either the complement or same as input based on invert line status.
Multiplexer (MUX): Routes one of several inputs to a single output based on select lines. Can handle $2^n$ inputs for $n$ select lines.
Decoder: Converts binary input into one active output line while others remain inactive. Useful in CPUs to select instructions.
Adders:
Half Adder: Adds two bits.
Full Adder: Adds two bits and carry-in; used in multi-bit adders (ripple-carry).
Sequential Circuits
State Memory: Uses flip-flops (e.g., SR, JK, D) for memory.
Feedback Connections: Allow outputs to influence inputs, forming loops.
Timing Diagrams: Show voltage states over time to visualize sequential behavior.
Clock Signal: Synchronizes changes in state within circuits; shorter clock period increases frequency of changes.
Flip-Flops
SR Flip-Flop: Basic memory element, can become unstable when both inputs are high.
JK Flip-Flop: Modified SR for stable outputs with both inputs high; behaves according to J and K inputs.
D Flip-Flop: Synced to clock; changes output only with input changes, fundamental for memory.
Finite State Machines (FSM)
Represent behavior of sequential circuits; two types:
Moore Machines: Outputs depend on states.
Mealy Machines: Outputs depend on transitions.
Register and Memory
Registers: Basic building blocks of instruction set architecture. Consist of multiple flip-flops.
Main Memory: Conceptually an array of registers, each with a unique address.