1 Digital Design and Computer Architecture Lecture 1 Digital Design and Computer Architecture Harris & Harris Morgan Kaufmann / Elsevier, 2007
2 Logistics Handouts: –Syllabus, Lecture Notes Lab 1 posted on the website: – Reading for next Monday (9/29: 點名 ) – , 1.9,
3 Overview More Logistics: –Course Objectives –Course Requirements –Schedule Digital Design –Managing Complexity –Number Systems –Logic Gates
4 Course Objectives To become a competent digital designer To learn to recognize and apply the principles of abstraction, modularity, hierarchy, and regularity in digital design To hone your debugging skills by designing, building, and testing digital circuits To design, build, and test your own clock To understand what’s under the hood of a computer To have fun while you’re doing it!
5 Course Requirements Class Participation –If you need to miss class, me beforehand Assignments: –Weekly problem sets (10%), due Monday Morning –Semester labs ( 電子鐘 15% + 組合語言程式 15%) –Reading Exams –Midterm (25%) –Final (35%) Team policy for bi-weekly discussion –(75% 個人成績 +25% 團體成績 ) for Midterm and Final –Number of team member 5~6, –Bonus for participation: +3; –leader +5
6 Syllabus Read the syllabus!
7 Digital Design General engineering principles for complex systems: –Abstraction –Discipline –The three -Y’s Hierarchy Modularity Regularity
8 Abstraction Hiding details when they aren’t important
9 Discipline Intentionally restricting your design choices (so that you can work more productively at a higher level of abstraction)
10 The Three -Y’s Hierarchy –Dividing a system into modules and submodules Modularity –Well-defined functions and interfaces Regularity –Uniformity, so modules can be easily reused
11 Digital Abstraction 1’s and 0’s bits: binary digit
12 Decimal numbers Binary numbers Number Systems
13 Decimal to binary conversion: –Convert to decimal Decimal to binary conversion: –Convert to binary Number Conversion
14 Hexadecimal Numbers Hex DigitDecimal EquivalentBinary Equivalent A B C D E F151111
15 Hexadecimal to binary conversion: –Convert 4AF 16 (0x4AF) to binary Hexadecimal to decimal conversion: –Convert 0x4AF to decimal Number Conversion
16 Bits, Bytes, Nibbles… Bits Bytes & Nibbles Bytes (how they are put in memory?)
17 Decimal Binary Addition
18 Add the following 4-bit binary numbers Binary Addition Examples
19 Signed Binary Numbers Sign and Magnitude: –1 sign bit, N-1 magnitude bits –Example: -5 = = Two’s Complement( why? ) –Same as unsigned binary, but most significant bit (msb) has value of -2 N-1 –Most positive 4-bit number: –Most negative 4-bit number:
20 “Taking the Two’s Complement” Reversing the sign of a two’s complement number Method: 1.Invert the bits 2.Add 1 Example: Reverse the sign of
21 Two’s Complement Examples Take the two’s complement of Take the two’s complement of 1010.
22 Two’s Complement Addition Add 6 + (-6) using two’s complement numbers. Add using two’s complement numbers.
23 Logic Gates
24 Two-Input Logic Gates
25 More Two-Input Logic Gates
26 Multiple-Input Logic Gates How about 4-input XOR?
27 Next Time Beneath the digital abstraction Transistors Boolean algebra