Number_systems-3 in Digital circuits and systems.pdf

prateekjain415709 10 views 13 slides Jul 08, 2024
Slide 1
Slide 1 of 13
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13

About This Presentation

Digital circuits and systems


Slide Content

DIGITAL LOGIC DESIGN
NUMBER SYSTEMS AND
CODES
1

Binary codes for decimal numbers
•A binary number of n digits gives 2
n
distinct combinations which can be
used to represent distinct group of quantities
•Different binary codes available are weighted codes, un-weighted codes,
self-complementing codes, reflecting codes
•Weighted codes: Each bit position is assigned a weighing factor and each
digit is evaluated by adding the weights of all the ones in the coded
combination
Eg: BCD code, 2-4-2-1 code, (8, 4,-2,-1) code, etc
2

Binary codes for decimal numbers
•Un-weighted codes: Weight is not assigned to the bit positions
Eg: Excess-3 code
•Self complementing code: 9’s complement of the decimal number is
obtained by changing 1’s to 0’s and viceversa.
Eg: 2-4-2-1 code, Excess-3 code
8,4, -2 -1 code
3

BCD code
•Decimal numbers 0 –9 can be represented using 4 bits.
•There are 6 unused combinations in this coding scheme.
4

Different binary codes for decimal
numbers
5

BCD number
Convert decimal to BCD number
Convert BCD to Decimal
BCD Addition
6

Convert decimal to BCD number
7

Convert BCD to Decimal
8

BCD Addition
➢step1:AddthetwoBCDnumbers,usingtherulesforbinaryaddition
➢step2:Ifa4bitsumisequaltolessthan9,itisavalidBCDnumber.
➢step3:Ifa4bitsumisgreaterthan9,orifacarryoutofthe4bit
groupisgenerated,itisaninvalidresult.Add6(0110)tothe4bitsum
inordertoskipthesixinvalidstatesandreturnthecodeto8421.Ifa
carryresultwhen6isadded,Simplyaddthecarrytothenext4bit
group.
9

10

11

12

13