Logic Design Computer Architecture and Design Lecture 1
Youpyo Hong & Kangwoo DGU Computer Architecture? Instruction set operation encoding, memory addressing techniques Data representations signed magnitude, floating-point Addressing direct, indirect, relative I/O mechanisms memory mapped, I/O mapped So, it is a mixture of hardwares and softwares. 2
Youpyo Hong & Kangwoo DGU HW & SW for Computers Hardware : Electronic components & electromechanical devices that comprise the physical entity of the device Software : Programs composed of a sequence of instructions System Software Programs to make use of the core function of computers Example: Operating systems, Compilers Application Software Programs for various users application Example: Games, Word-processor Firmware Programs directly related to hardware control Example: Device driver 3
Youpyo Hong & Kangwoo DGU Computer Hardware We have learned hardware design in digital logic design courses. Brief review on digital logic design follows. 4 Memory Central processing Unit Central processing Unit Input-Output processor Input-Output processor Input devices Input devices Output devices Output devices
Youpyo Hong & Kangwoo DGU Transistors : Basic Elements for HW Logic gates are physically implemented by Transistors. If N & P transistors in a single semiconductor place, it is called CMOS technology. 5 N - type V CA nS C B A - + P - type V BC pS C B A - + Source Drain Gate C B A C B A Source Drain Gate C B A C B A Switch Transistor Logic Symbol
Youpyo Hong & Kangwoo DGU v out C B A C B A V DD v in xz Details on transistors are covered in semiconductor & integrated circuit design courses. Our design ground is digital logic as follows. Inverter Gate 6
Youpyo Hong & Kangwoo DGU Boolean Algebra Boolean algebra is an algebra that deals with binary variables and logic operations. Three representations for a function. Boolean Function ( = Logic Expression) Algebraic expression with binary variables, logic operation symbols, parenthesis & equal sign Truth Table A relationship between the function and its variables Logic Diagram Expression of Boolean function using logic gates 7
Youpyo Hong & Kangwoo DGU Examples 8 Truth Table x y z F Logic Diagram x y z F F = x + y’z Boolean Function
Youpyo Hong & Kangwoo DGU Logic Simplification Why ? To minimize the number of logic gates, the propagation delay and the cost while performing the same function How? Using the basic identities of Boolean algebra or Using the karnaugh-map simplification or Using other approaches 9
Youpyo Hong & Kangwoo DGU Karnaugh-Map Simplification AB CD F(A,B,C,D) = (0,1,2,6,8,9,10) F = BD’ + B’C’ + A’CD’ A BC F(A,B,C) = (3,4,6,7) F = BC + AC’ A BC F(A,B,C) = (0,2,4,5,6) F = C’ + AB’
Youpyo Hong & Kangwoo DGU Combinational Logic (= Circuit) Outputs are determined by current inputs only. (No memory in combinational logic.) 11 Combinational Circuit m output variables n input variables Problem statement Assign letter symbols to I/O Build a truth table Simplification for each output Logic Diagram Circuit Design Procedure
Youpyo Hong & Kangwoo DGU Half Adder Example 12 xy 00 CS Truth Table S = x’y + xy’ = x y C = xy Boolean Function x y C S Logic Diagram
Youpyo Hong & Kangwoo DGU Sequential Logic Outputs are determined by current inputs and the memory contents. Basic unit of memory is flip-flop that stores 1 bit information. You need to understand the concept of latch, register and RAM. 13
Youpyo Hong & Kangwoo DGU Flip-Flops 14 Q(t)Q(t+1) 00 SR 0x x0 SR Flip-Flop Q(t)Q(t+1) 00 D D Flip-Flop Q(t)Q(t+1) 00 JK 0x x x1 11x0 JK Flip-Flop Q(t)Q(t+1) 00 D T Flip-Flop
Youpyo Hong & Kangwoo DGU Sequential Circuit Configuration 15 Combinational Circuit inputsoutputs Flip-Flops clock
Youpyo Hong & Kangwoo DGU Sequential Circuit Design Flow 16 Draw a State Transition Diagram Assign state Variables to the states Determine the types of flip-flops to use Translate state diagram to State Table with current states, inputs, outputs, next states Extend state table to Excitation Table including inputs to flip-flops Determine Boolean functions for the outputs and for the inputs of flip-flops Draw a Logic Diagram
Youpyo Hong & Kangwoo DGU Sequential Circuit Example 17 J Q K J Q K A B clock x J A = BxJ B = x K B = xK A = Bx State Diagram Variables Flip-flop types State Table Excitation Table Boolean function Logic Diagram Procedure