Digital Circuits Text Book –M. M. Mano, "Digital Design," 3rd Ed., Prentice Hall Inc., Reference –class notes Grade –quizzes:15% –mid-term:27.5% x 2 –final:30% Course contents –Chapter 1-7, Chapter 9 –Finite State Machines –Verilog Examples
Digital age Digital computers –many scientific, industrial and commercial applications –space program Digital systems –telephone switching exchanges –digital camera –electronic calculators, PDA's –digital TV Discrete information-processing systems Why binary? –reliability: a transistor circuit is either on or off (two stable states) Chapter 1: Binary Systems
A digital computer - stored program - control unit - arithmetic computations and logical operations
Binary Numbers Base (or radix) –2 –example: 0110 Number base conversion –example: 41 = Complements –1's complements –2's complements –Subtraction = addition with the 2's complement –Signed binary numbers »signed-magnitude, signed 1's complement, and signed 2's complement.
M - N M + the 2 ’ s complement of N –M + (2 n - N) = M - N + 2 n If M ≧ N –Produce an end carry, 2 n, which is discarded If M < N –We get 2 n - (N - M), which is the 2 ’ s complement of (N-M)
Binary Codes n-bit binary code – 2 n distinct combinations BCD – Binary Coded Decimal (4-bit) –00000 –10001 –91001 BCD addition Get the binary sum If the sum > 9, add 6 to the sum Obtain the correct BCD digit sum and a carry
Binary Codes Error-detection code –one parity bit - an even combination of error is undetected – > (even parity) (odd) Excess-3 code BCD code + 3 Self-complementing (9 ’ s complement: 3 ’ = 6; 6 ’ =3) Gray code –only one bit change between two consecutive numbers –avoid glitch problems ASCII code –American Standard Code for Information Interchange –alphanumeric characters, printable characters (symbol), control characters –control characters: format effectors, information separators, and communication control characters
Binary Storage and Registers A binary cell –two stable state –store one bit of information –examples: flip-flop circuits, ferrite cores, capacitor A register –a group of binary cells –AX in x86 CPU Register Transfer –a transfer of the information stored in one register to another –one of the major operations in digital system –an example
Transfer of information
The other major component of a digital system –circuit elements to manipulate individual bits of information
Binary Logic Boolean algebra Binary variables –two discrete values (true or false) Logical operations –AND, OR, NOT Truth tables
Switching circuits: a transistor is either on or off L = ABL = A+B
Binary signals –Electrical signals: voltages or currents –two separate voltage levels: logic-1 and logic-0 –the intermediate region is crossed only during state transition
Logic Gates Logic circuits –circuits = logical manipulation paths Computations and controls –combinations of logic circuits Logic Gates
Timing diagram