ECE 3110: Introduction to Digital SystemsChapters 1,2 summaryDigital Design BasicsElectronic and software aspect of digital designIntegrated Circuits (IC)Programmable Logic Device (PLD)Application-Specific ICs (ASIC)Digital Design LevelsBinary RepresentationPositional NotationSlide 11Hex to Binary, Binary to HexConversion of Any Base to DecimalConversion of Decimal Integer To ANY BaseConversion of Decimal Integer To ANY Base ExampleBinary addition/subtraction rulesBinary, Decimal additionSubtractionRepresentation of Negative NumbersNOTE:Ranges (N bits)Sign extensionConversions for signed numbersHex to Signed Decimal Conversion RulesSigned Decimal to Hex conversionsigned addition/subtractionDetecting Two’s Complement OverflowCodesHow to construct Gray CodeAnother method to construct Gray CodeECE 3110: Introduction to Digital SystemsReview #1(Chapter 1 ,2)2Chapters 1,2 summaryAnalog<-->Digital: advantages, electronic aspects, software aspects, digital design levels.IC: wafer, die, classifications, PLC,ASICPositional number systems: binary, octal, decimal,hexUnsigned numbers: conversions, addition/subtraction/multiplication/divisionSigned numbers: representations, conversions, addition/subtractionSign extensionOverflowBinary Codes for decimal numbers:BCD,2421,excess-3….Gray codeOther codes3Digital Design BasicsAnalog vs. DigitalWhy we need digital?Reproducibility, economy, programmability…Digital DevicesGates, FFsCombinational, sequential circuits4Electronic and software aspect of digital designDigital abstractionNoise MarginspecificationExamples of software tools5Integrated Circuits (IC)A collection of one or more gates fabricated on a single silicon chip.Wafer, dieSmall-scale integration (SSI): 1-20DIP: dual in-line-pin packagePin diagram, pinoutMSI: 20-200 gatesLSI: 200-200,000VLSI: >100,000, 50million (1999)6Programmable Logic Device (PLD)ICs which Logic function can be programmed after manufacture.2-level AND-OR gates using user-programmable connectionsPLAs: programmable Logic Arrarys.PALs: programmable array logic devicesProgrammable logic devices (PLDs)CPLD: complex PLDFPGA: Field-Programmable Gate Array7Application-Specific ICs (ASIC)Semi-custom IC: chips designed for a particular, limited product/applicationReducing chip count, size, power consumptionHigher performance.NRE: nonrecurring engineering costStandard cells: libraryGate array: an IC with internal structure as an array of gates, unspecified interconnection8Digital Design LevelsMany representations of digital logicDevice Physics and IC manufacturingMoore’s Law [1965, Gordon Moore]: Transistor level --->Logic design, functional building blocksTransistor level, Truth table, gate level logic, prepackaged blocks, equations, HDL9Binary RepresentationThe basis of all digital data is binary representation.Binary - means ‘two’1, 0True, FalseHot, ColdOn, OffWe must be able to handle more than just values for real world problems1, 0, 56True, False, MaybeHot, Cold, Warm, CoolOn, Off, Leaky10Positional NotationBaseRadixWeightRadix 2, 8, 10,1611Unsigned numbersN binary digits (N bits) can represent unsigned integers from 0 to 2N-1.Conversions:Hex <----->binaryOctal <-----> binary(padded with zero)Any base <----->decimalOperations (binary): addition/subtraction/multiplication/division12Hex to Binary, Binary to HexA2F16 = 1010 0010 11112 34516 = 0011 0100 01012Binary to Hex is just the opposite, create groups of 4 bits starting with least significant bits. If last group does not have 4 bits, then pad with zeros for unsigned numbers.10100012 = 0101 00012 = 5116 Padded with a zero13Conversion of Any Base to DecimalConverting from ANY base to decimal is done by multiplying each digit by its weight and summing.1011.112 = 1x23 + 0x22 + 1x21 + 1x20 + 1x2-1 + 1x2-2 = 8 + 0 + 2 + 1 + 0.5 + 0.25 = 11.75Binary to DecimalHex to DecimalA2F16 = 10x162 + 2x161 + 15x160 = 10 x 256 + 2 x 16 + 15 x 1 = 2560 + 32 + 15 = 260714Conversion of Decimal Integer To ANY BaseDivide Number N by base R until quotient is 0. Remainder at EACH step is a digit in base R, from Least Significant digit to Most significant digit.15Conversion of Decimal Integer To ANY BaseExampleConvert 53 to binary 53/2 = 26, rem = 1 26/2 = 13, rem = 0 13/2 = 6 , rem = 1 6 /2 = 3, rem = 0 3/2 = 1, rem = 1 1/2 = 0, rem = 1 5310 = 1101012 = 1x25 + 1x24 + 0x23 + 1x22 + 0x21 + 1x20 = 32 + 16 + 0 + 4 + 0 + 1 = 53 Least Significant DigitMost Significant Digit16cin or binX Y Couts Boutd0 0 0 0 0 0 00 0 1 0 1 1 10 1 0 0 1 0 10 1 1 1 0 0 01 0 0 0 1 1 11 0 1 1 0 1 01 1 0 1 0 0 01 1 1 1 1 1 1Binary addition/subtraction rules17Binary, Decimal addition 34+ 17------ 51from LSD to MSD:7+4 = 1; with carry out of 1 to next column1 (carry) + 3 + 1 = 5.answer = 51.Decimal 1010112+ 0000012--------------- 1011002From LSB to MSB:1+1 = 0, carry of 11 (carry)+1+0 = 0, carry of 11 (carry)+0 + 0 = 1, no carry1 +0 = 10 + 0 = 0 1 + 0 = 1 answer = 1011002Binary18SubtractionDecimal 900- 001------- 8990-1 = 9; with borrow of 1 from next column0 -1 (borrow) - 0 = 9, with borrow of 1 9 - 1 (borrow) - 0 = 8.Answer = 899.Binary 1002- 0012 ------- 01120-1 = 1; with borrow of 1 from next column0 -1 (borrow) - 0 = 1, with borrow of 1 1 - 1 (borrow) - 0 = 0.Answer = 0112.19Representation of Negative NumbersSigned-Magnitude Representation: Negates a number by changing its sign.Complement Number Systems: negates a number by taking its complement.Diminished Radix-Complement RepresentationOne’s-ComplementRadix-Complement RepresentationTwo’s-Complement20NOTE:Fix number of digitsSM, 1’s complement, 2’s complement may be different for NEGATIVE numbers, but for positive numbers, the representations in SM, 1’s complement, 2’s complement are the SAME, equals to the unsigned binary representation.21Ranges (N bits)1’s complement can represent the signed integers -(2(N-1) - 1) to + (2(N-1) - 1 )unsigned binary can represent unsigned integers from 0 to 2N-1.SM can represent the signed integers -(2(N-1) - 1)
View Full Document