Upload
aizen14
View
224
Download
19
Embed Size (px)
Citation preview
8/10/2019 Digital System IED 12303
1/100
1
Chapter ONE: Digital Electronic IED 12303
8/10/2019 Digital System IED 12303
2/100
2
Chapter ONE
1. In digital electronics numeral system is anessential process used by computer in
order to communicate from one part toanother for entire system.
2. The system can use, with the most
common ones are: binary (base-2), octal(base-8), decimal (base 10) andhexadecimal (base 16).
8/10/2019 Digital System IED 12303
3/100
3
Chapter ONE
1. Decimal : 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9.
2. Binary : 0, 1, 0,0,1,1,0.
3. Octal : 0, 1, 2, 3, 4, 5, 6 and 7.
4. Hexadecimal : 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B,C, D, E, F.
8/10/2019 Digital System IED 12303
4/100
4
Chapter ONE
1. All of the number system can beencountered in every digital system which
is embedded in their systems for instancesoftware.
2. Since all electronic gadget today are usingmicroprocessor, hence the understanding
of number system is a must.
8/10/2019 Digital System IED 12303
5/100
5
Chapter ONE
8/10/2019 Digital System IED 12303
6/100
6
Chapter ONE
8/10/2019 Digital System IED 12303
7/1007
Chapter ONE
1. All of the number in the system can beconverted among them. For instance,
Decimal to Binary, Binary to Decimal,Binary to Hexadecimal ect.
2. The conversion of these numeral systems
are subjected to the mathematical rules.
8/10/2019 Digital System IED 12303
8/1008
Chapter ONE
1. All of the number in the system can beconverted among them. For instance,
Decimal to Binary, Binary to Decimal,Binary to Hexadecimal ect.
2. The conversion of these numeral systems
are subjected to the mathematical rules.
8/10/2019 Digital System IED 12303
9/1009
Chapter ONE
1. All of the number in the system can beconverted among them. For instance,
Decimal to Binary, Binary to Decimal,Binary to Hexadecimal ect.
2. The conversion of these numeral systems
are subjected to the mathematical rules.
Binary to Decimal
8/10/2019 Digital System IED 12303
10/10010
Chapter ONE
1. Least Significant Bit (LSB) and MostSignificant Bit (MSB) are need to be
determined in certain numeral system.
Binary to Decimal
8/10/2019 Digital System IED 12303
11/10011
Chapter ONE
1. Conversion example. Convert thefollowing Binary number to Decimal
number.
Binary to Decimal
(256) + (64) + (32) + (4) + (1) = 35710
8/10/2019 Digital System IED 12303
12/100
12
Chapter ONE
1. ExerciseConvert the followings Binary system to
Decimal :
i) 10012ii) 101102
iii) 1101001012iv) 11001011002v) 11001001112
Binary to Decimal
8/10/2019 Digital System IED 12303
13/100
13
Chapter ONE
1. So far, the Binary number is converted toDecimal numeral system. However, the
process can be reversed from Decimal toBinary as well.
2. Example: Convert Decimal 35710 to Binary
Decimal to Binary
h
8/10/2019 Digital System IED 12303
14/100
14
Chapter ONE
1. Solution
2 357 result 178 reminder 12 178 result 89 reminder 0
2 89 result 44 reminder 1
2 44 result 22 reminder 0
2 22 result 11 reminder 02 11 result 5 reminder 1
2 5 result 2 reminder 1
2 2 result 1 reminder 0
2 1 result 0 reminder 1
Decimal to Binary
Ch ONE
8/10/2019 Digital System IED 12303
15/100
15
Chapter ONE
Ch ONE
8/10/2019 Digital System IED 12303
16/100
16
Chapter ONE
2. ExerciseConvert the following Decimal numbers to
Binary number.
i) 76ii) 278iii) 403iv) 657v) 860
Decimal to Binary
Ch ONE
8/10/2019 Digital System IED 12303
17/100
17
Chapter ONE
3. ExerciseConvert the following Octal numbers to
Decimal number.
i) 76ii) 278iii) 403iv) 657v) 860
Decimal to Octal
Ch t ONE
8/10/2019 Digital System IED 12303
18/100
18
Chapter ONE
The Octal numeral is based on 8 system. Theconversion from Octal to Decimal can be
done with following technique.
Example: Convert 3458 to base 10 numeralsystem.
345 octal = (3 * 82) + (4 * 81) + (5 * 80) = (3 *64) + (4 * 8) + (5 * 1) = 229
Octal to Decimal
Ch t ONE
8/10/2019 Digital System IED 12303
19/100
19
Chapter ONE
Binary operations when dealing with binaryare often occur including Additional,
Subtraction, Multiplication and Division.
These operations are embedded in computersystems, however the process are notobviously visible because their process onlyoccur in operation system.
Ch t ONE
8/10/2019 Digital System IED 12303
20/100
20
Chapter ONE
Example : Suppose add the binary numbers11112 and 1102 similar to the way we add the
decimal numbers 1510and 610.
Solution :
Additional
Chapter ONE
8/10/2019 Digital System IED 12303
21/100
21
Chapter ONE
Additional
Chapter ONE
8/10/2019 Digital System IED 12303
22/100
22
Chapter ONE
Additional
8/10/2019 Digital System IED 12303
23/100
Chapter ONE
8/10/2019 Digital System IED 12303
24/100
24
Chapter ONE
Additional
Chapter ONE
8/10/2019 Digital System IED 12303
25/100
25
Chapter ONE
AdditionalExercise
Chapter ONE
8/10/2019 Digital System IED 12303
26/100
26
Chapter ONE
SubtractionHow to subtract the binary numbers101012and 11102
Chapter ONE
8/10/2019 Digital System IED 12303
27/100
27
Chapter ONE
SubtractionHow to subtract the binary numbers101012and 11102
Chapter ONE
8/10/2019 Digital System IED 12303
28/100
28
Chapter ONE
SubtractionHow to subtract the binary numbers101012and 11102
Chapter ONE
8/10/2019 Digital System IED 12303
29/100
29
Chapter ONE
SubtractionExercise
1. 101 112. 11001 11013. 1011001 -1010014. 1101001 - 11000015. 11010101 10100101
Chapter ONE
8/10/2019 Digital System IED 12303
30/100
30
Chapter ONE
Multiplication
How to multiply the binary numbers11112and 10112
Chapter ONE
8/10/2019 Digital System IED 12303
31/100
31
Chapter ONE
Multiplication
How to multiply the binary numbers11112and 10112
Chapter ONE
8/10/2019 Digital System IED 12303
32/100
32
Chapter ONE
Multiplication
How to multiply the binary numbers11112and 10112
Chapter ONE
8/10/2019 Digital System IED 12303
33/100
33
C apte O
Multiplication
How to multiply the binary numbers11112and 10112
Chapter ONE
8/10/2019 Digital System IED 12303
34/100
34
p
Multiplication
How to multiply the binary numbers11112and 10112
8/10/2019 Digital System IED 12303
35/100
Chapter ONE
8/10/2019 Digital System IED 12303
36/100
36
p
Multiplication
Exercise
1. 10100 * 112. 110001 * 1113. 1100100 * 1014. 110111 * 100011
Chapter ONE
8/10/2019 Digital System IED 12303
37/100
37
p
Division
How to divide 1000012by 1102
Chapter ONE
8/10/2019 Digital System IED 12303
38/100
38
p
Division
How to divide 1000012by 1102
Chapter ONE
8/10/2019 Digital System IED 12303
39/100
39
p
Division
How to divide 1000012by 1102
Chapter ONE
8/10/2019 Digital System IED 12303
40/100
40
Division
How to divide 1000012by 1102
Chapter ONE
8/10/2019 Digital System IED 12303
41/100
41
Division
How to divide 1000012by 1102
Chapter ONE
8/10/2019 Digital System IED 12303
42/100
42
Division
How to divide 1000012by 1102
Chapter ONE
8/10/2019 Digital System IED 12303
43/100
43
Division
How to divide 1000012by 1102
Chapter ONE
8/10/2019 Digital System IED 12303
44/100
44
Division
Exercise
1. 111100 / 1012. 1010010 / 1003. 1111101 / 104. 11001000 / 1005. 100101100 / 1000
8/10/2019 Digital System IED 12303
45/100
Chapter ONE
8/10/2019 Digital System IED 12303
46/100
46
Floating point
Convert 2.62510to Binary.0.625 x 2 = 1.25 1 (MSB)0.25 x 2 = 0.5 00.5 x 2 = 1.0 1 (LSB)
Hence the answer is 10.101
Chapter ONE
8/10/2019 Digital System IED 12303
47/100
47
Floating point
Convert 0.4062510to Binary.0.40625 x 2 = 0.8125 0 (MSB)0.8125 x 2 = 1.625 10.625 x 2 = 1.25 10.25 x 2 = 0.5 00.5 x 2 = 1 1 (LSB)
Hence the answer is 0.01101
8/10/2019 Digital System IED 12303
48/100
Chapter ONE
8/10/2019 Digital System IED 12303
49/100
49
1s Complement
Representing a signed number with 1'scomplement is done by changing all thebits that are 1 to 0 and all the bits that
are 0 to 1. Reversing the digits in thisway is also called complementing anumber.
Chapter ONE
8/10/2019 Digital System IED 12303
50/100
50
1s Complement
How can we represent the number -510in 1's complement?
1.First, we write the positive value of thenumber in binary.
0101 (+5)
2.Next, we reverse each bit of the number so 1's
become 0's and 0's become 1's
1010 (-5)
Chapter ONE
8/10/2019 Digital System IED 12303
51/100
51
1s Complement
Chapter ONE
8/10/2019 Digital System IED 12303
52/100
52
1s Complement
Here is a quick summary of how
to find the 1's complement
representation of any decimal
number x.
1.If x is positive, simply
convert xto binary.
2.If x is negative, write the
positive value of xin binary
3.Reverse each bit.
Chapter ONE
8/10/2019 Digital System IED 12303
53/100
53
2s Complement
Representing a signed numberwith 2's complement is done byadding 1 to the 1's complement
representation of the number.
1. First, we write the positiveof the number in binary.
2. Next, we reverse each bit toget the 1's complement.
3. Last, we add 1 to thenumber.
Chapter ONE
8/10/2019 Digital System IED 12303
54/100
54
2s Complement
Chapter ONE
8/10/2019 Digital System IED 12303
55/100
55
Addition
If 2 Two's Complementnumbers are added, and theyboth have the same sign (both
positive or both negative), thenoverflow occurs if and only ifthe result has the opposite sign.Overflow never occurs when
adding operands with differentsigns.
Chapter ONE
8/10/2019 Digital System IED 12303
56/100
56
Unsigned bit
1. The binary numbers can berepresented in positive andnegative binary number.
2. The unsigned binary bit is akind of binary number thatuse for positive binary only.
3. Example, +25 express in 8-bit binary system.
ans : 0001 1001
Chapter ONE
8/10/2019 Digital System IED 12303
57/100
57
Signed bit
1. The signed binary system isuse to indicate whether theis said to be Negative or
Positive.2. It can be seen that, in natureall numbers are in positiveand negative number.
3. The procedure of makingthe bit signed is if thenumber is Positive, let theleft most bit is 0while 1 ifthe number is negative.
Chapter ONE
8/10/2019 Digital System IED 12303
58/100
58
2s Complement
8/10/2019 Digital System IED 12303
59/100
Chapter ONE
8/10/2019 Digital System IED 12303
60/100
60
Signed bit
1. The numbers can beexpressed in 3 ways
i) Sign-Magnitude system
ii) 1scomplement systemiii) 2scomplement system
2. Example: Express the
decimal -39 by using thosethree sign system.
Chapter ONE
8/10/2019 Digital System IED 12303
61/100
61
Signed bit
1. Sign-Magnitude system+ 39 = 0010 0111-39 = 1010 0111
Sign bit is zero if+ve
Sign bit is ONE if
-ve2. 1scomplement system+ 39 = 0010 0111-39 = 1101 1000
3. 2scomplement system+ 39 = 0010 0111-39 = 1101 1000
+ 1
= 1101 1001
Chapter ONE
8/10/2019 Digital System IED 12303
62/100
62
Signed bit
1. The unsigned-magnitudesystem is apply for positivenumber only.
2. The range for unsignednumber is as follows :
Chapter ONE
8/10/2019 Digital System IED 12303
63/100
63
unsigned bit
1. Example: If 4, 8 bits systemare used, determine theirmaximum and minimum
allowed.2. N=4, 0 to 2N-1 = 24-1= 15 or0000 to 1111
3. N=8, 0 to 2N-1 = 28-1= 255 or
0000 000 to 1111 1111
Chapter ONE
8/10/2019 Digital System IED 12303
64/100
64
Signed bit
1. The number system can bepresented in three ways ofthe signed binary forms,
that is Signed-MagnitudeSystem, 1s complement and2scomplement system.
Chapter ONE
8/10/2019 Digital System IED 12303
65/100
65
Signed bit
1. Sign-Magnitude system+ 39 = 0010 0111-39 = 1010 0111
Sign bit is zero if+ve
Sign bit is ONE if
-ve2. 1scomplement system+ 39 = 0010 0111-39 = 1101 1000
3. 2scomplement system+ 39 = 0010 0111-39 = 1101 1000
+ 1
= 1101 1001
Chapter ONE
8/10/2019 Digital System IED 12303
66/100
66
Signed bit
1. Determining the decimalvalue for signed numbers.
Signed binary number canbe determined as follows :Let the binary number is
0010 0111 = +39
(1 x 2^5 ) + ( 1 x 2^2) + (1 x 2^1 )+ ( 1 x 2^ 0) = 32 + 4 + 2 + 1= + 39
Chapter ONE
8/10/2019 Digital System IED 12303
67/100
67
Signed bit
Let the signed binary number is1010 0111 = -39
(-1 x 2^ 7) + (1 x 2^5 ) + ( 1 x 2^2)+ (1 x 2^1 ) + ( 1 x 2^ 0) = -127+32 + 4 + 2 + 1= - 39 ( since the MSB is bit 1 )
Chapter ONE
8/10/2019 Digital System IED 12303
68/100
68
Signed bit
1. Determining the decimal valuefor signed 1s complementnumbers.
Let the 1s complement binarynumber is1101 1000 = -39
(-1 x 2^ 7 ) + (1 x 2^6 ) + (1 x 2^4 )+ ( 1 x 2^3)= -128+64+ 4 + 2 = - 40Adding 1to the answer gives -39
Chapter ONE
8/10/2019 Digital System IED 12303
69/100
69
Signed bit
1. Determining the decimal valuefor signed 2s complementnumbers.
Let the 2s complement signedbinary number is
1101 1001 = -39
(-1 x 2^ 7 ) + (1 x 2^6 ) + (1 x 2^4 )+ ( 1 x 2^3) + ( 1 x 2^0)= -128+64 +16+ 8+1
= - 39
Chapter ONE
8/10/2019 Digital System IED 12303
70/100
70
1. Adding two positive
numbers must give apositive result unlessoverflow occurred.
2. Adding two negativenumbers must give anegative result unlessoverflow occurred.
3. The overflow occurs becausethe operation addition andsubtraction is over theminimum and maximum
allowed by its N bit system.
8/10/2019 Digital System IED 12303
71/100
Chapter ONE
8/10/2019 Digital System IED 12303
72/100
72
1. (+A) + (+B) = -C OR2. (-A) + (-B) = +C
3. Example : 7 + 4 ( use 8 bitsigned binary system)
0000 0111
+ 0000 01000000 1011 = ( +11) correct
1. Example : 16 -24 ( use 8 bit
signed binary system)0001 0000
+ 1110 10001111 1000 = ( - 8) correct
Sign bit iscorrect
Sign bit is
correct
Chapter ONE
8/10/2019 Digital System IED 12303
73/100
73
1. (+A) + (+B) = -C OR2. (-A) + (-B) = +C
3. Example : 125 + 58 ( use 8 bitsigned binary system)
0111 1101
+ 0011 10101011 0111 = ( -72) incorrect
1. Example : -88 -41 ( use 8 bit
signed binary system)0010 1000
+ 0010 10100101 0010 = (- 46) incorrect
Sign bit isincorrect
Sign bit is
incorrect
Chapter ONE
8/10/2019 Digital System IED 12303
74/100
74
Signed bit
1. The logic gates are primaryelectronics invention indigital era. Gates in
electronics including OR,AND, INVERTER ect.2. Logic gates are comprises of
analog electronic devicessuch as transistors anddiodes.
8/10/2019 Digital System IED 12303
75/100
Chapter ONE
8/10/2019 Digital System IED 12303
76/100
76
1. Digital circuitry may include
Multiplexer, Register,Counter ect.
2. The gates can be embeddedonto chip.
3. SSI: Small-scale Integration,Gates< 102. MSl: Medium-scale
Integration,10 10004. VLSI: Very Large-scale
Integration, Gates>100000
Chapter ONE
8/10/2019 Digital System IED 12303
77/100
77
Chapter ONE
8/10/2019 Digital System IED 12303
78/100
78
8/10/2019 Digital System IED 12303
79/100
Chapter ONE
8/10/2019 Digital System IED 12303
80/100
80
Chapter ONE
8/10/2019 Digital System IED 12303
81/100
81
1. A truth table shows how a
logic circuit's outputresponds to variouscombinations of the inputs,using logic 1 for true and
logic 0 for false. Allpermutations of the inputsare listed on the left, and theoutput of the circuit is listedon the right.
Chapter ONE
8/10/2019 Digital System IED 12303
82/100
82
Chapter ONE
8/10/2019 Digital System IED 12303
83/100
83
Chapter ONE
8/10/2019 Digital System IED 12303
84/100
84
1. The deriving of Booleanexpression is essential whendealing with logic gate.
2. Boolean expression can beobtained by using standardlogic gate principals.
Chapter ONE
8/10/2019 Digital System IED 12303
85/100
85
Chapter ONE
8/10/2019 Digital System IED 12303
86/100
86
Chapter ONE
8/10/2019 Digital System IED 12303
87/100
87
Chapter ONE
8/10/2019 Digital System IED 12303
88/100
88
1. Any complex Booleanexpression however can besimplified into simplest one
depending on the expressionitself.
2. The simplicity of theexpression leads the
expression more compactand easy to read.
Chapter ONE
8/10/2019 Digital System IED 12303
89/100
89
1. On the other hand, thesimplify version of Booleanexpression can be achieved
by obeying the set of rulesstated on the previous slide.
Chapter ONE
8/10/2019 Digital System IED 12303
90/100
90
Chapter ONE
8/10/2019 Digital System IED 12303
91/100
91
Chapter ONE
8/10/2019 Digital System IED 12303
92/100
92
Chapter ONE
8/10/2019 Digital System IED 12303
93/100
93
Chapter ONE
8/10/2019 Digital System IED 12303
94/100
94
Chapter ONE
8/10/2019 Digital System IED 12303
95/100
95
Chapter ONE
8/10/2019 Digital System IED 12303
96/100
96
8/10/2019 Digital System IED 12303
97/100
8/10/2019 Digital System IED 12303
98/100
Chapter ONE
8/10/2019 Digital System IED 12303
99/100
99
Chapter ONE
8/10/2019 Digital System IED 12303
100/100