Download presentation
Presentation is loading. Please wait.
1
Overview of Digital Electronics
Embedded Systems Overview of Digital Electronics
2
Binary Numbers and Others
System Radix Allowable Digits Binary ,1 Octal ,1,2,3,4,5,6,7 Decimal ,1,2,3,4,5,6,7,8,9 Hexadecimal ,1,2,3,4,5,6,7,8,9,A, B, C, D, E, F (4021.2)5 = 4 x x x x x 5-1 4 x x (1/5) = (511.4)10 (B65F)16 = x x x x 160 11 x x x = (46687)10
3
Number Base Conversion
Conversion from Decimal fraction (0.6875)10 to Binary: Integer Fraction Coefficient x 2= a_1=1 x 2= a_2=0 x 2= a_3=1 x 2= a_4=1 (0.6875)10=(0.1011)2 The conversion from decimal fraction to any base-r system is similar to the example. Multiplication is by r instead of 2, and the coefficients found from the integers may range in value from 0 to r-1 instead of 0 and 1. Example: (0.513)10=(?)8
4
Binary Numbers Operations work similarly in all bases
5
Octal and Hexadecimal Numbers
The conversion from binary to octal and hexadecimal plays an important part in digital systems (computers). Since 23 = 8 and 24 = 16
6
Octal and Hexadecimal Numbers
Conversion from Octal to binary: ( ) 8 = ( ) 2 Conversion from Hexadecimal to binary: (306.D) 16 = ( ) 2 Conversion from Hexadecimal to Decimal: (37B) x x x 160 = 3 x x x 1 = = (891) 10
7
Complements Simplifies Two types exist the subtraction operation
Logical operations Two types exist The radix complement (r’s complement) 10’s complement, 2’s complement The diminished radix complement ((r-1)’s complement) 9’s complement, 1’s complement
8
Diminished Radix (r-1) complement
Given a number N in base r having n digits: (r-1)’s complement of N is (rn-1)-N When r=10, (r-1)’s complement is called 9’s complement. 10n-1 is a number represented by n 9’s. 9’s complement of is (n=6) =453299 9’s complement of is (n=6) =987601
9
Diminished Radix (r-1) complement
Given a number N in base r having n digits: (r-1)’s complement of N is (rn-1)-N When r=10, (r-1)’s complement is called 9’s complement. 10n-1 is a number represented by n 9’s. 9’s complement of is (n=6) =453299 9’s complement of is (n=6) =987601
10
1’s complement For binary numbers, r=2 and r-1=1.
1’s complement of N is (2n-1)-N If n=4, 2n= So, 2n-1=1111. To determine the 1’s complement of a number, subtract each digit from 1. Or, bit flip!!! Replace 0’s with 1’s, 1’s with 0’s!!! Example: If N= , 1’s comp.= If N= , 1’s comp.=
11
Radix (r’s) complement
Given a number N in base r having n digits: r’s complement of N is rn-N When r=10, r’s complement is called 10’s complement. 10’s complement of is (n=6) =453300 10’s complement of is (n=6) =987602
12
Radix (r’s) complement
The 10’s complement of decimal 2389 = (104 –1) – = 7611. The 2’s complement of binary = (26 –1) – = 012389= (106 –1) – = 246700= (106 –1) – =
13
Signed Binary Numbers 00001001 = 9
Example: Represent +9 and -9 in eight bit system = 9 Signed magnitude =-9 Signed-1’s complement Signed-2’s complement
18
Two digital circuit types
Combinational digital circuits: Consist of logic gates Their current outputs are determined from the present combination of inputs. Their operations can be specified logically by sets of Boolean functions. Sequential digital circuits: Employ storage elements in addition to logic gates. Their outputs are a function of the inputs and the state of the storage elements. Their outputs depend on current inputs and past input. They have feedback connections. Digital System Design May 2, 2019
19
Combinational circuits
2n possible combinations of input values Specific functions Adders, subtractors, comparators, decoders, encoders, and multiplexers MSI (Medium Scale Integration) circuits or standard cells Digital System Design May 2, 2019
20
Example Combinational Circuit (1/2)
Circuit controls the level of fluid in a tank inputs are: HI - 1 if fluid level is too high, 0 otherwise LO - 1 if fluid level is too low, 0 otherwise outputs are: Pump - 1 to pump fluid into tank, 0 for pump off Drain - 1 to open tank drain, 0 for drain closed input to output relationship is described by a truth table Digital System Design May 2, 2019
21
Example Combinational Circuit (2/2)
HI 1 LO Pump x Drain Tank level is OK Low level, pump more in High level, drain some out inputs cannot occur Truth Table Representation HI Pump Schematic Representation Drain LO Digital System Design May 2, 2019
22
Analysis of A Combinational Circuit
make sure that it is combinational not sequential No feedback path derive its Boolean functions (truth table) design verification a verbal explanation of its function Ex. What is the output function of this circuit? Digital System Design May 2, 2019
23
Example Analysis Analysis steps Label all gate outputs with symbols
Find Boolean functions for all gates Express functions in terms of input variables + simplify Substitution: F = (T2T3)’ = ((xT1)’(yT1)’)’ = (xT1)+(yT1) = x(xy)’+y(xy)’= =(x(x’+y’)) + (y(x’+y’)) = xx’+xy’+yx’+yy’ = xy’+yx’ = x y T1=(xy)’ T2=(x T1)’ F=(T2T3)’ T3=(yT1)’ Digital System Design May 2, 2019
24
Example (1/3) What are the output functions F1 and F2?
Digital System Design May 2, 2019
25
Example (2/3) Start with expressions that depend only on input variables: T2 = ABC T1 = A+B+C F2 = AB + AC + BC Express other outputs that depend on already defined internal signals T3 = F2’T1 F1 = T3 + T2 Digital System Design May 2, 2019
26
Example (3/3) Simplify: F1 = T3+T2 = F2’T1+ABC
= (AB+AC+BC)'(A+B+C)+ABC = (A'+B')(A'+C')(B'+C')(A+B+C)+ABC = (A'+B'C')(AB'+AC'+BC'+B'C)+ABC = A'BC'+A'B'C+AB'C'+ABC A full-adder F1: the sum F2: the carry Digital System Design May 2, 2019
27
Truth Table Digital System Design May 2, 2019
28
Binary Adders Addition is important function in computer system
What does an adder have to do? Add binary digits Generate carry if necessary Consider carry from previous digit Binary adders operate bit-wise A 16-bit adder uses 16 one-bit adders Binary adders come in two flavors Half adder : adds two bits and generate result and carry Full adder : also considers carry input Two half adders make one full adder Digital System Design May 2, 2019
29
Binary Half Adder Specification: Outputs:
Design a circuit that adds two bits and generates the sum and a carry Outputs: Two inputs: x, y Two output: S (sum), C (carry) 0+0=0 ; 0+1=1 ; 1+0=1 ; 1+1=10 The S output represents the least significant bit of the sum. The C output represents the most significant bit of the sum or (a carry). Digital System Design May 2, 2019
30
Implementation of Half Adder
the flexibility for implementation S=x y S = (x+y)(x'+y') S' = xy+x'y' S = (C+x'y')' C = xy = (x'+y')' S = x'y+xy' C = xy Half Adder X Y S C Digital System Design May 2, 2019
31
Full-Adder Specification: Inputs: Truth table:
A combinational circuit that forms the arithmetic sum of three bits and generates a sum and a carry Inputs: Three inputs: x,y,z Two outputs: S, C Truth table: Full Adder X Y S Z C Digital System Design May 2, 2019
32
Implementation of Full Adder
S=x’y’z+ x’yz’ + xyz’ + xyz C= xy + xz + yz Digital System Design May 2, 2019
33
Alternative Implementation of Full Adder
S = z (x y)= z’(xy’+x’y) + z(xy’+x’y)’ = z’(xy’+x’y) + z(xy+x’y’) =xy’z’+x’yz’+ xyz +x’y’z C = x y + (x y) z =z(xy’ + x’y) + xy= xy’z+ x’yz+ xy = xy + xz + yz Digital System Design May 2, 2019
34
Binary Adder A binary adder is a digital circuit that produces the arithmetic sum of two binary numbers. A binary adder can be implemented using multiple full adders (FA). Digital System Design May 2, 2019
35
Example: Add 2 binary numbers
Subscript i: 3 2 1 Input carry Augend Addend Ci Ai Bi Sum Carry Si Ci+1 Digital System Design May 2, 2019
36
Example:4-bit binary adder
4-bit Ripple Carry Adder Classical example of standard components Would require truth table with 29 entries! C A B S Digital System Design May 2, 2019
37
Carry Propagation In any combinational circuit, the signal must propagate through the gates before the correct output is available in the output terminals. Total propagation time = the propagation delay of a typical gateX the number of gate levels The longest propagation delay time in a binary adder is the time it takes the carry to propagate through the full adders. This is because each bit of the sum output depends on the value of the input carry. This makes the binary adder very slow. Digital System Design May 2, 2019
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.