3.65k likes | 3.88k Views
LOGIC DESIGN First Year - Computer Eng. Dept. Dr. Ihab Talkhan. Text book: M. Morris Mano, “ Digital Design” , third edition, Prentice Hall, 2002. References: M. Mano and C. R. Kime , “Logic and Computer Design Fundamentals”, Prentice Hall, 2000.
E N D
LOGIC DESIGNFirst Year - Computer Eng. Dept. Dr. Ihab Talkhan Dr. Ihab Talkhan
Text book: M. Morris Mano, “ Digital Design” , third edition, Prentice Hall, 2002 • References: • M. Mano and C. R. Kime , “Logic and Computer Design Fundamentals”, Prentice • Hall, 2000. • Daniel Gajski, “Principles of Digital Design”, Prentice Hall, 1997. Cairo University Faculty of Engineering Computer Engineering Department Introduction to Logic Design Sunday/Thursday –2007/2008 Course Description: Digital Logic Design, The nature of digital logic, numbering system, Boolean algebra, karnaugh maps, decision –making elements, memory elements, latches, flip-flops, design of combinational and sequential circuits, integrated circuits and logic families, shift registers, counters and combinational circuits, adders, substraters ,multiplication and division circuits, memory types. Exposure to logic design automation software. Credit: This course consists of 1 1 /2 lectures per week Dr. Ihab Talkhan
Instructor(s): Dr. Ihab E. Talkhan This course is designed to introduce the student to the basic techniques of design and analysis of digital circuits Dr. Ihab Talkhan
Grading: 60% (2 tests - no make-ups) • 15% Attendance • 25% Assignments (all assignments from the text book, end of chapter selected problems) • Testing dates: to be announced later • Final test date: refer to First term Schedule • Assistant: to be announced later • Office hours: to be announced later Dr. Ihab Talkhan
Design Cycle Dr. Ihab Talkhan
The Packaging Sequence Dr. Ihab Talkhan
ASIC Design Flow Dr. Ihab Talkhan
Course Ouline Hardware & Micro-program method Dr. Ihab Talkhan
Important Notes • Various binary systems suitable for representing information in digital components [ decimal & Alphanumeric]. • Digital system has a property of manipulating discrete elements of information, discrete information is contained in any set that is restricted to a finite number of elements, e.g. 10 decimal digits, the 26 letters of the alphabet, 25 playing cards, and other discrete quantities. Dr. Ihab Talkhan
Important Notes (cont.) • Early digital computers were used mostly for numeric computations, in this case the discrete elements used were the digits, from which the term digital computer has emerged. • Discrete elements of information are represented in a digital system by physical quantities called signal [voltages & currents] which have only two discrete values and are said to be binary. Dr. Ihab Talkhan
Voltage 5 Logic – 1 range 2 Intermediate region, crossed only during state transition Transition , occurs between the two limits 0.8 Logic – 0 range 0 time • Electrical Signals [ voltages or currents ] that exist throughout a digital system is in either of two recognizable values [ logic-1 or logic 0 ] Dr. Ihab Talkhan
Important Notes (cont.) • Digital computers use the binary number system that has two digits “0” and “1”, a binary digit is called a “bit”, thus information is represented in digital computers in groups of bits. • By using various coding technique, groups of bits can be made to represent not only binary numbers but also any other group of discrete symbols. • To simulate a process in a digital computer, the quantities must be quantized, i.e. a process whose variables are presented by continuous real-time signals needs its signals to be quantized using an analog-to-digital (A/D) conversion device. Dr. Ihab Talkhan
The memory unit: stores programs, inputs, outputs and other intermediate data. • The processor unit: performs arithmetic and other data-processing operations as specified by the program. • The control unit: supervises the flow of information between the various units. It also retrieves the instructions, one by one, from the program stored in memory and informs the processor to execute them Dr. Ihab Talkhan
Important Notes (cont.) • A CPU enclosed in a small integrated circuit package is called a microprocessor. • The program and data prepared by the user are transferred into the memory unit by means of an input devices such as a keyboard. • An output device, such as a printer, receives the results of the computations and the printed results are presented to the user. Dr. Ihab Talkhan
Numbering Systems • A number is base “r” contains r digits 0,1,2,…..(r-1) and is expressed with a power series in “r”. • A number can also be expressed by a string of coefficients [positional notation]. Least significant digit Most significant digit Radix point Dr. Ihab Talkhan
Numbering Systems (cont.) • The Aicoefficients contain “r” digits, and the subscript “ i ” gives the position of the coefficient, hence the weight riby which the coefficient must be multiplied. • To distinguish between numbers of different bases, we enclose the coefficients in parentheses and place a subscript after the right parenthesis to indicate the base of the number. Dr. Ihab Talkhan
Decimal Numbers • The decimal number system is of base or radix r = 10, because the coefficients are multiplied by powers of 10 and the system uses ten distinct digits [0,1,2,…9]. • Decimal number is represented by a string of digits, each digit position has an associated value of an integer raised to the power of 10. • Consider the number (724.5)10 Dr. Ihab Talkhan
Conversion from Any numbering System to Decimal System • To convert any numbering system to decimal, you expand the number to a power series with its base. • Example: • Convert (312.4)5 to its equivalent decimal, note that the number is in base 5. Conversion from base 5 number to its equivalent decimal number Radix 5 Dr. Ihab Talkhan
Binary Numbers • Converting a Binary number to its equivalent Decimal: (11010.11)2 Note that, when a bit is equal to “0”, it does not contribute to the sum during the conversion. Therefore, the conversion to decimal can be obtained by adding the numbers with powers of two corresponding to the bits that are equal to “1’. Dr. Ihab Talkhan
Computer Units • 210 = 1024 is referred to as Kilo “K” • 220 = 1,048,567 is referred to as Mega “M” • 230 is referred to as Giga “G” • Example: 16M = 224 = 16,777,216 Dr. Ihab Talkhan
Conversion from Decimal to Binary(Integer numbers only) • The conversion of a decimal number to binary is achieved by a method that successively subtracts powers of two from the decimal number, i.e. it is required to find the greatest number (power of two) that can be subtracted from the decimal number and produce a positive difference and repeating the same procedure on the obtained number till the difference is zero. Dr. Ihab Talkhan
Example • Find the binary equivalent of (625)10 • 625 – 512 = 113 512 = 29 • 113 – 64 = 49 64 = 26 • 49 – 32 = 17 32 = 25 • 17 – 16 = 1 16 = 24 • 1 – 1 = 0 1 = 20 • (625)10 = 29 + 26 + 25 + 24 + 20 = (1001110001) LSB MSB Position 10 Dr. Ihab Talkhan
General Method • If the number includes a radix point, it is necessary to separate it into an integer part and a fraction part, since each part must be converted differently. • The conversion of a decimal integer to a number in base “r“ is done by dividing the number and all successive quotients by “ r “ and accumulating the remainders. • The conversion of a decimal fraction to base “ r “ is accomplished by a method similar to that used for integer, except that multiplication by “ r “ is used instead of division, and integers are accumulated instead of remainders. Dr. Ihab Talkhan
Example • Find the binary equivalent of (41.6875)10 • Separate the number into an integer part & a fraction part. Integer Part: Fraction Part: Integer remainder MSB LSB LSB MSB ( .6875)10 = ( .1011)2 Thus: (41.6875)10L (101001.1011)2 (41)10 = (101001)2 Dr. Ihab Talkhan
Important Note • The process of multiplying fractions by “ r “ does not necessarily end with zero, so we must stop at a certain accuracy , i.e. number of fraction digits, otherwise this process might go forever. Dr. Ihab Talkhan
Octal Numbers • Octal number system is a base 8 system with eight digits [ 0,1,2,3,4,5,6,7 ]. • To find the equivalent decimal value, we expand the number in a power series with a base of “ 8 ”. • Example: • (127.4)8 = 1 x 82 + 2 x 81 + 7 x 80 + 4 x 8-1 = (87.5)10 Dr. Ihab Talkhan
Hexadecimal Numbers • The Hexadecimal number system is a base 16 system with the first ten digits borrowed from the decimal system and the letters A,B,C,D,E,F are used for digits 10,11,12,13,14 and 15 respectively. • To find the equivalent decimal value, we expand the number in a power series with a base of “ 16 ”. • Example: • (B65F)16 = 11 x 163 + 6 x 162 + 5 x 161 + 15 x 160 = (46687)10 Dr. Ihab Talkhan
Note • It is customary to borrow the needed “ r “ digits for the coefficients from the decimal system, when the base of the numbering system is less than 10. • The letters of the alphabet are used to supplement the digits when the base of the number is greater than 10. Dr. Ihab Talkhan
Important Property • The Octal & Hexadecimal systems are useful for representing binary quantities indirectly because they posses the property that their bases are powers of “2”. • Octal base = 8 = 23 & Hexadecimal base = 16 = 24, from which we conclude: • Each Octal digit correspond to three binary digits • Each Hexadecimal digit correspond to four binary digits. Dr. Ihab Talkhan
Conversion from Binary to Octal/Hexadecimal • The conversion from Binary to either Octal or Hexadecimal is accomplished by partitioning the Binary number into groups of three or four digits each respectively, starting from the binary point and proceeding to the left and to the right. Then, the corresponding Octal or Hexadecimal is assigned to each group. • Note that, 0’s can be freely added to the left or right to the Binary number to make the total number of bits a multiple of three or four. Dr. Ihab Talkhan
Example • Find the Octal equivalent of the Binary number: ( 10110001101011.11110000011)2 010 110 001 101 011 . 111 100 000 110 2 6 1 5 3 7 4 0 6 (010110001101011.111100000110)2 L(26153.7406)8 Added “0’s” Dr. Ihab Talkhan
Example • Find the Hexadecimal equivalent of the Binary number: ( 10110001101011.11110000011)2 0010 1100 0110 1011 . 1111 0000 0110 2 C 6 B F 0 6 (10110001101011.11110000011)2 L(2C6B.F06)16 Added “0’s” Dr. Ihab Talkhan
Conversion from Octal/Hexadecimal to Binary • Conversion from Octal or Hexadecimal to Binary is done by a procedure reverse to the previous one. • Each Octal digit is converted to a three-digit binary equivalent. • Each Hexadecimal digit is converted to its four-digit binary equivalent. Dr. Ihab Talkhan
Example • Find the Binary equivalent of (673.12)8 6 7 3 . 1 2 110 111 011 001 010 (673.12)8 = (110111011.001010)2 Dr. Ihab Talkhan
Example • Find the Binary equivalent of (3A6.C)16 3 A 6 . C 0011 1010 0110 1100 (3A6.C)16 = (110111011.001010)2 Dr. Ihab Talkhan
Important Note • The Octal or Hexadecimal equivalent representation is more convenient because the number can be expressed more compactly with a third or fourth of the number of digits. Dr. Ihab Talkhan
Carry Two digits Arithmetic 1 + 1 = 10 Binary 1 + 1 = 1 Dr. Ihab Talkhan
Arithmetic Operations • Arithmetic operations with numbers in base “ r “ follow the same rules as for decimal numbers Addition Subtraction Dr. Ihab Talkhan
Arithmetic Operations (cont.) Multiplication Division divisor dividend subtract remainder Dr. Ihab Talkhan
Notes • The rules for subtraction are the same as in decimal, except that a borrow from a given column adds “2” to the minuend digit. • In division, we have only two choices for the greatest multiple of the divisor Zero and the divisor itself. Dr. Ihab Talkhan
Arithmetic Operations with Base “r” Systems • Arithmetic operations with Octal , Hexadecimal or any other base “r” system is done by using the following methods: • Formulation of tables from which one obtains sums and products of two digits in base “r”. • Converting each pair of digits in a column to decimal , add the digits in decimal, and then convert the result to the corresponding sum and carry in base “r” system. Dr. Ihab Talkhan
Example • Add : (59F)16 + (E46)16 Equivalent Decimal Hexadecimal Carry 1 =16+5 =16+3 Dr. Ihab Talkhan
Note • The idea is to add F+6 in hexadecimal, by adding the equivalent decimals 15+6 = 21, then converting (21)10 back to hexadecimal knowing that; 21 = 16+5 gives a sum digit of 5 and a carry “1” to the next higher order column digit Dr. Ihab Talkhan
Multiplication • The multiplication of two base “r” numbers is done by performing all arithmetic operations in decimal and converting intermediate results one at a time. Dr. Ihab Talkhan