0% found this document useful (0 votes)
40 views19 pages

Digital UNIT - I

The document discusses various number systems used in digital electronics including binary, decimal, octal, and hexadecimal. It provides examples and methods for converting between these number systems. Key points covered include: - The four main number systems used in digital electronics are binary, decimal, octal, and hexadecimal. - Binary uses two digits (0 and 1) while other systems use bases of 10, 8, and 16 respectively. - Methods like binary-to-decimal conversion sum place values of 1s in the binary number. - Floating point numbers represent real numbers using a fractional component.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
40 views19 pages

Digital UNIT - I

The document discusses various number systems used in digital electronics including binary, decimal, octal, and hexadecimal. It provides examples and methods for converting between these number systems. Key points covered include: - The four main number systems used in digital electronics are binary, decimal, octal, and hexadecimal. - Binary uses two digits (0 and 1) while other systems use bases of 10, 8, and 16 respectively. - Methods like binary-to-decimal conversion sum place values of 1s in the binary number. - Floating point numbers represent real numbers using a fractional component.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 19

Digital Electronics

UINT I
Numbering System
Many number systems are in use in digital technology. The most common are the
decimal, binary, octal, and hexadecimal systems. The decimal system is clearly the most familiar
to us because it is a tool that we use eery day. Examining some of its characteristics will hel! us
to better understand the other systems. The four numerical re!resentation systems that are used
most commonly in the digital system are,
Decimal
"inary
#ctal
$exadecimal
Decimal System
The decimal system is com!osed of %& numerals or symbols. These %& symbols are &, %,
', (, ), *, +, ,, -, .. Using these symbols as digits of a number, we can ex!ress any /uantity. The
decimal system is also called the base0%& system because it has %& digits.
10
3
10
2
10
1
10
0
1%&&& 1%&& 1%& 1%
Most 2ignificant Digit
Een though the decimal system has only %& symbols, any number of any magnitude can
be ex!ressed by using our system of !ositional weighting.
Decimal Examples

*'%&

%&')%&

+)&&&%&
Binary System
In the binary system, there are only two symbols or !ossible digit alues, & and %. This
base0' system can be used to re!resent any /uantity that can be re!resented in decimal or other
base system. This system has been deelo!ed since the machines can understand only two logics,
% or &.
2
3
2
2
2
1
2
0
1- 1) 1' 1%
Most 2ignificant Digit
Binary Examples
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics

%%'

%&%&'

%%&&&'

Binary Counting
The "inary counting se/uence is shown in the table4
2
3
2
2
2
1
2
0
Decimal
& & & & &
& & & % %
& & % & '
& & % % (
& % & & )
& % & % *
& % % & +
& % % % ,
% & & & -
% & & % .
% & % & %&
% & % % %%
% % & & %'
% % & % %(
% % % & %)
% % % % %*
Representing Binary Quantities
In digital systems the information that is being !rocessed is usually !resented in binary
form. "inary /uantities can be re!resented by any deice that has only two o!erating states or
!ossible conditions. E.g. a switch is only o!en or closed. 5e arbitrarily 6as we define them7 let
an o!en switch re!resent binary & and a closed switch re!resent binary %. Thus we can re!resent
any binary number by using series of switches.
Typical oltage !ssignment
Binary 1" 8ny oltage between '9 to *9
Binary 0" 8ny oltage between &9 to &.-9
Not use#" 9oltage between &.-9 to '9 in * 9olt :M#2 and TT; ;ogic, this may cause
error in a digital circuit. Today<s digital circuits wor=s at %.- olts, so this statement may not hold
true for all logic circuits.
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
5e can see another significant difference between digital and analog systems. In digital
systems, the exact oltage alue is not im!ortant> eg, a oltage of (.+9 means the same as a
oltage of ).(9. In analog systems, the exact oltage alue is im!ortant.
The binary number system is the most im!ortant one in digital systems, but seeral others
are also im!ortant. The decimal system is im!ortant because it is uniersally used to re!resent
/uantities outside a digital system. This means that there will be situations where decimal alues
hae to be conerted to binary alues before they are entered into the digital system.
In additional to binary and decimal, two other number systems find wide0s!read
a!!lications in digital systems. The octal 6base0-7 and hexadecimal 6base0%+7 number systems
are both used for the same !ur!ose0 to !roide an efficient means for re!resenting large binary
system.
$ctal System
The octal number system has a base of eight, meaning that it has eight !ossible digits4 &,
%, ', (, ), *, +, and ,.
%
3
%
2
%
1
%
0
1*%' 1+) 1- 1%
Most 2ignificant Digit
$ctal Examples

'(,-

')-

%%-
&exa#ecimal System
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
The hexadecimal system uses base %+. Thus, it has %+ !ossible digit symbols. It uses the
digits & through . !lus the letters 8, ", :, D, E, and ? as the %+ digit symbols.
1'
3
1'
2
1'
1
1'
0
1)&.+ 1'*+ 1%+ 1%
Most 2ignificant Digit
&exa#ecimal Examples
')%+
%%%+
Con(ersion"
:onerting from one code form to another code form is called code conersion, li=e
conerting from binary to decimal or conerting from hexadecimal to decimal.
Binary)To)Decimal Con(ersion
8ny binary number can be conerted to its decimal e/uialent sim!ly by summing
together the weights of the arious !ositions in the binary number which contain a %.
Binary Decimal
%%&%%'
'
)
6%7@'
(
6%7@'
'
6&7@'
%
6%7@'
&
6%7 1%+@-@&@'@%
Aesult ',%&
Bou should hae noticed that the method is to find the weights 6i.e., !owers of '7 for each
bit !osition that contains a %, and then to add them u!.
Decimal)To)Binary Con(ersion
The method of conerting the decimal number to binary is called as Double dabble
6Ae!eated diision by '7 method. :onert '*%& to binary
Di(ision Remain#er Binary
'*C' 1 %'@ remainder of % % 6;east 2ignificant "it7
%'C' 1 + @ remainder of & &
+C' 1 ( @ remainder of & &
(C' 1 % @ remainder of % %
%C' 1 & @ remainder of % % 6Most 2ignificant "it7
Aesult '*%& 1 %%&&%'
T*e +lo, c*art -or Double #abble met*o# is as -ollo,s"
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
$ctal)To)Decimal Con(ersion
8ny octal number can be conerted to its decimal e/uialent sim!ly by summing
together the !roduct of weights 6!ower of -7 of the arious !ositions and the number !resent in
that !osition in the octal number.
Example"
'(+%+ 1 ' x 6-
'
7 @ ( x 6-
%
7 @ + x 6-
&
7 1 %*-%&
Decimal)To)$ctal Con(ersion
The method of conerting the decimal number to octal is called as #ctal dabble
6Ae!eated diision by -7 method.
Example" :onert %,,%& to octal and binary
Di(ision Result Binary
%,,C- 1 ''@ remainder of % % 6;east 2ignificant "it7
''C - 1 ' @ remainder of + +
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
' C - 1 & @ remainder of ' ' 6Most 2ignificant "it7
Aesult %,,%& 1 '+%-
"inary 1 &%&%%&&&%'
&exa#ecimal)To)Decimal Con(ersion
8ny hexadecimal number can be conerted to its decimal e/uialent sim!ly by summing
together the !roduct of weights 6!ower of %+7 of the arious !ositions and the number !resent in
that !osition in the hexadecimal number number.
Example"
'8?%+ 1 ' x 6%+
'
7 @ %& x 6%+
%
7 @ %* x 6%+
&
7 1 +-,%&
Decimal)To)&exa#ecimal Con(ersion
The method of conerting the decimal number to hexadecimal is called as $ex dabble
6Ae!eated diision by %+7 method
Example" con(ert 3.%10 to *exa#ecimal an# binary"
Di(ision Result &exa#ecimal
(,-C%+ 1 '(@ remainder of %& 8 6;east 2ignificant "it7'(
'(C%+ 1 % @ remainder of , ,
%C%+ 1 & @ remainder of % % 6Most 2ignificant "it7
Aesult (,-%& 1 %,8%+
"inary 1 &&&% &%%% %&%&'
Binary)To)$ctal / $ctal)To)Binary Con(ersion
#ctal Digit & % ' ( ) * + ,
"inary E/uialent &&& &&% &%& &%% %&& %&% %%& %%%
Each #ctal digit is re!resented by three binary digits.
Example"
%&& %%% &%&' 1 6%&&7 6%%%7 6&%&7' 1 ) , '-
Binary)To)&exa#ecimal /&exa#ecimal)To)Binary Con(ersion
$exadecimal Digit & % ' ( ) * + ,
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
"inary E/uialent &&&& &&&% &&%& &&%% &%&& &%&% &%%& &%%%
$exadecimal Digit - . 8 " : D E ?
"inary E/uialent %&&& %&&% %&%& %&%% %%&& %%&% %%%& %%%%
Each $exadecimal digit is re!resented by four bits of binary digit0
Example"
%&%% &&%& %%%%' 1 6%&%%7 6&&%&7 6%%%%7' 1 " ' ?%+
+loating 1oint Numbers
8 real number or floating !oint number is a number which has both an integer and a
fractional !art.
Exam!les for real decimal numbers are %'(.)*%&, &.%'()%&, etc.
10
3
10
2
10
1
10
0
10
)1
10
)2
10
)3
1%&&& 1%&& 1%& 1% . 1&.% 1&.&% 1&.&&%
Most 2ignificant Digit Decimal !oint ;east 2ignificant Digit
Exam!les for real binary numbers are %%&&.%%&&', &.%&&%', etc.
2
3
2
2
2
1
2
0
2
)1
2
)2
2
)3
1- 1) 1' 1% . 1&.* 1&.'* 1&.%'*
Most 2ignificant Digit "inary !oint ;east 2ignificant Digit
Exam!les for real octal numbers are %'.(-, %%.%-, etc.
%
3
%
2
%
1
%
0
%
)1
%
)2
%
)3
1*%' 1+) 1- 1% . 1%C- 1%C+) 1%C*%'
Most 2ignificant Digit #ctal !oint ;east 2ignificant Digit
Exam!les for real hexadecimal numbers are ').+%+, %%.%%+, etc.
1'
3
1'
2
1'
1
1'
0
1'
)1
1'
)2
1'
)3
1)&.+ 1'*+ 1%+ 1% . 1%C%+ 1%C'*+ 1%C)&.+
Most 2ignificant Digit $exa Decimal !oint ;east 2ignificant Digit
Binary !##ition
The binary addition is ery much similar to decimal addition and the addition of two bits
is gien as,
& @ & 1 && > 2um & and :arry &
& @% 1 &% > 2um % and :arry &
% @ & 1 &% > 2um % and :arry &
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
% @ % 1 %& > 2um & and :arry %
In the aboe addition the result is se!arated into two !arts such as 2um and :arry.
5hen the addition of multi!le bits is !erformed the carry of !reious bit will be added
with current bit addition. 5hen the carry is Dero the aboe addition result is followed. 5hen the
carry is one the result will be as follows,
% @ & @ & 1 && > 2um % and :arry &
% @ & @% 1 &% > 2um & and :arry %
% @ % @ & 1 &% > 2um & and :arry %
% @ % @ % 1 %& > 2um % and :arry %
Example"
&%% (
@%&& @)
%%% ,
Binary Subtraction
The binary subtraction ery much similar to decimal subtraction the subtraction two bits
is gien as,
& 0 & 1 && > Difference & and "orrow &
& 0 % 1 %% > Difference % and "orrow %
% 0 & 1 %& > Difference % and "orrow &
% 0 % 1 && > Difference & and "orrow &
In the aboe addition the result is se!arated into two !arts such as Difference and "orrow.
5hen the 2ubtraction of multi!le bits is !erformed, the borrow of !reious bit will be
subtracted with current bit subtraction. 5hen, the borrow is Dero the aboe subtraction result is
followed. 5hen the borrow is one the result will be as follows,
% @ & @ & 1 %% > Difference % and "orrow %
% @ & @% 1 &% > Difference & and "orrow %
% @ % @ & 1 && > Difference & and "orrow &
% @ % @ % 1 %% > Difference % and "orrow %
Example"
%%& +
0 %&% 0*
&&% %
Note" If the subtrahend is grater than the minuend, then the result will be re!resented indirectly
6'Es com!lement of the difference7.
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
Binary 2ultiplication
The multi!lication of two bits is gien as,
& x & 1 &
& x % 1 &
% x & 1 &
% x % 1 %
The multi!lication can be done by two different methods, one is by using the aboe rules
as li=e normal multi!lication, another by re!eated addition method. In re!eated addition method
the multi!licand will be added with the same alue and the count 6multi!lier7 alue is
decremented by one and this !rocess will be continued until the count 6multi!lier7 alue reaches
Dero.
Example"
Normal method4
%%% x multi!licand , x
%&% multi!lier *
%%% (*
&&&
%%%
%&&&%%
Ae!eated addition method4
%%% 6multi!licand7 count 1 %&% 6multi!lier7 %
if, count F & @%%% count 1 count 0%
%%%&
if, count F & @%%% count 1 count 0%
...
it continues until the count reaches Dero.
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
Binary Di(ision
The diision of two bits is gien as,
& C & 1 &
% C % 1 %
The diision can be done by two different methods, one is by using the aboe rules as
li=e normal diision, another by re!eated subtraction method. In re!eated subtraction method the
diisor alue will be subtracted from the diidend and the count 6/uotient7 alue is incremented
by one and this !rocess will be continued until the diidend alue is greater than diisor alue.
the final alue of the diidend that is less than the diisor alue is remainder.
Example"
Normal method4
G%&GG G(G
%% H %%& diidend ( H +
%%G multi!lier (
&& &

Ae!eated subtraction method4
%%& 6diidend7 count 1 & 6/uotient7
if, diidend F diisor 0&%% count 1 count @% 6i.e., &%7
&%%
if, diidend F diisor 0&%% count 1 count @% 6i.e., %&7
&&
2to! the subtraction !rocess since the diidend alue 6&&7 is less than the diisor alue 6%%7. The
final diidend alue I&&J is remainder and the final count alue I%&J is the /uotient.
13s an# 23s Complement
There are two ty!es of com!lement for binary number system, namely, %Es com!lement
and 'Es com!lement. %Es com!lement and 'Es com!lement can be used to !erform subtraction
using adder. 8lso they are used to re!resent negatie numbers.
13s complement
The %Es com!lement of the binary digit 6bit7 is defined as % minus that bit,
i.e., %Es com!lement of % is % 0 % 1 &
%Es com!lement of & is % 0 & 1 %
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
Example"
Binary number 13s cimplement
%&%% &%&&
%%&%& &&%&%
23s complement
The 'Es com!lement of the binary digit 6bit7 is adding % with the %Es com!lement
alue of that number.
Example"
Binary number 23s complement
%&&% &%%%
%&&%& &%%%&
Subtraction using complement met*o#
13s complement subtraction
In this method the following three ste!s are followed,
Ta=e the minuend in binary format as it is.
Ta=e the %Es com!lement for subtrahend and add with the minuend.
If carry is !roduced, add the carry to the sum.
The carry !roduced is called end0around carry. If carry is not !roduced it indicates that
the result is negatie and the result is in %Es com!lement method.
Example"
%%& 6minuend7 +
&%& 6subtrahend7 0*
% &&& %
If the carry is K%E, then add the carry with the result and the result is !ositie. The final answer is
&&%.
%&% 6minuend7 *
&&% 6subtrahend7 0+
& %%& 0%
If the carry is K&E, the result is negatie and the %Es com!lement of the result will gie the
difference. The final answer is &&%.
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
23s complement subtraction
In this method the following ste!s are followed,
Ta=e the minuend in binary format as it is.
Ta=e the 'Es com!lement for subtrahend and add it with the minuend.
If carry is !roduced, ignore the carry.
Example"
%%& 6minuend7 +
&%% 6subtrahend7 0*
% &&% %
If the carry is K%E, then the result is !ositie and the direct answer will be !roduced. The final
answer is &&%.
%&% 6minuend7 *
&%& 6subtrahend7 0+
& %%% 0%
If the carry is K&E, the result is negatie and the 'Es com!lement of the result will gie the
difference. The final answer is &&%.
Binary Co#es
"inary codes are codes which are re!resented in binary system with modification from
the original ones. The different ty!es of codes are4
5eighted codes
Non 5eighted :odes
4eig*te# Co#es
5eighted binary codes are those which obey the !ositional weighting !rinci!les, each
!osition of the number re!resents a s!ecific weight. The binary counting se/uence is an exam!le.
Decimal %521 2521 6211 Excess)3
& &&&& &&&& &&&& &&%%
% &&&% &&&% &&&% &%&&
' &&%& &&%& &&%% &%&%
( &&%% &&%% &%&% &%%&
) &%&& &%&& &%%% &%%%
* &%&% %&%% %&&& %&&&
+ &%%& %%&& %&%& %&&%
, &%%% %%&% %%&& %&%&
- %&&& %%%& %%%& %&%%
. %&&% %%%% %%%% %%&&
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
%521 Co#e/BCD Co#e
The ":D 6"inary :oded Decimal7 is a straight assignment of the binary e/uialent. It is
!ossible to assign weights to the binary bits according to their !ositions. The weights in the ":D
code are -,),',%.
Example" The bit assignment %&&% can be seen by its weights to re!resent the decimal .
because4
%x-@&x)@&x'@%x% 1 .
2521 Co#e
This is a weighted code, its weights are ', ), ' and %. 8 decimal number is re!resented in
)0bit form and the total four bits weight is ' @ ) @ ' @ % 1 .. $ence the ')'% code re!resents the
decimal numbers from & to ..
6211 Co#e
This is a weighted code, its weights are *, ', % and %. 8 decimal number is re!resented in
)0bit form and the total four bits weight is * @ ' @ % @ % 1 .. $ence the *'%% code re!resents the
decimal numbers from & to .
Non 4eig*te# Co#es
Non weighted codes are codes that are not !ositionally weighted. That is, each !osition
within the binary number is not assigned a fixed alue.
Excess)3 Co#e
Excess0( is a non weighted code used to ex!ress decimal numbers. The code deries its
name from the fact that each binary code is the corres!onding -)'% code !lus &&%%6(7.
Example" %&&& of -)'% 1 %&%% in Excess0(
7ray Co#e
The gray code belongs to a class of codes called minimum change codes, in which only
one bit in the code changes when moing from one code to the next. The Lray code is non0
weighted code, as the !osition of bit does not contain any weight. The gray code is a reflectie
digital code which has the s!ecial !ro!erty that any two subse/uent numbers codes differ by only
one bit. This is also called a unit0distance code. In digital Lray code has got a s!ecial !lace.
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
Decimal Number Binary Co#e 7ray Co#e
& &&&& &&&&
% &&&% &&&%
' &&%& &&%%
( &&%% &&%&
) &%&& &%%&
* &%&% &%%%
+ &%%& &%&%
, &%%% &%&&
- %&&& %%&&
. %&&% %%&%
%& %&%& %%%%
%% %&%% %%%&
%' %%&& %&%&
%( %%&% %&%%
%) %%%& %&&%
%* %%%% %&&&
Binary to 7ray Con(ersion
Lray :ode M2" is binary code M2".
Lray :ode M2"0% is the M#A of binary code M2" and M2"0%.
M2"0' bit of gray code is M#A of M2"0% and M2"0' bit of binary code.
M2"0N bit of gray code is M#A of M2"0N0% and M2"0N bit of binary code.
Error Detecting an# Correction Co#es
?or reliable transmission and storage of digital data, error detection and correction is
re/uired. "elow are a few exam!les of codes which !ermit error detection and error correction
after detection.
Error Detecting Co#es
5hen data is transmitted from one !oint to another, li=e in wireless transmission, or it is
Nust stored, li=e in hard dis=s and memories, there are chances that data may get corru!ted. To
detect these data errors, we use s!ecial codes, which are error detection codes.
1arity
In !arity codes, eery data byte, or nibble 6according to how user wants to use it7 is
chec=ed if they hae een number of ones or een number of Deros. "ased on this information an
additional bit is a!!ended to the original data. Thus if we consider -0bit data, adding the !arity
bit will ma=e it . bit long.
8t the receier side, once again !arity is calculated and matched with the receied !arity
6bit .7, and if they match, data is o=, otherwise data is corru!t.
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
There are two ty!es of !arity4
E(en parity" :hec=s if there is an een number of ones> if so, !arity bit is Dero. 5hen
the number of ones is odd then !arity bit is set to %.
$## 1arity" :hec=s if there is an odd number of ones> if so, !arity bit is Dero. 5hen
number of ones is een then !arity bit is set to %.
#ther than the !arity arious ty!es of chec= sum techni/ues are used to detect the error in the
transmitted data such as, 8dding all bytes, :A:, ?letcher<s chec=sum, 8dler0(', etc.,
Error)Correcting Co#es
Error0correcting codes not only detect errors, but also correct them. This is used normally
in 2atellite communication, where turn0around delay is ery high as is the !robability of data
getting corru!t.
&amming Co#e
$amming code adds a minimum number of bits to the data transmitted in a noisy
channel, to be able to correct eery !ossible one0bit error. It can detect 6not correct7 two0bit
errors and cannot distinguish between %0bit and '0bits inconsistencies. In general it can<t detect
(6or more70bits errors. The hamming detection code is formed based on the !arity.
The number of !arity bits 6!7 has to be used in hamming code for the gien number of
data bits 6m7 can be found with the hel! of the following relation,
'
!
F ! @ m @ %
7eneral algorit*m
The following general algorithm generates a single0error correcting 62E:7 code for any
number of bits.
%. Number the bits starting from %4 bit %, ', (, ), *, etc.
'. 5rite the bit numbers in binary. %, %&, %%, %&&, %&%, etc.
(. 8ll bit !ositions that are !owers of two 6hae only one % bit in the binary form of their
!osition7 are !arity bits.
). 8ll other bit !ositions, with two or more % bits in the binary form of their !osition, are
data bits.
*. Each data bit is included in a uni/ue set of ' or more !arity bits, as determined by the
binary form of its bit !osition.
%. Oarity bit % coers all bit !ositions which hae the least significant bit set4 bit %
6the !arity bit itself7, (, *, ,, ., etc.
'. Oarity bit ' coers all bit !ositions which hae the second least significant bit set4
bit ' 6the !arity bit itself7, (, +, ,, %&, %%, etc.
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
(. Oarity bit ) coers all bit !ositions which hae the third least significant bit set4
bits ),, %'%*, '&'(, etc.
). Oarity bit - coers all bit !ositions which hae the fourth least significant bit set4
bits -%*, ')(%, )&),, etc.
*. In general each !arity bit coers all bits where the binary 8ND of the !arity
!osition and the bit !osition is non0Dero.
The form of the !arity is irreleant. Een !arity is sim!ler from the !ers!ectie of
theoretical mathematics, but there is no difference in !ractice.
This general rule can be shown isually4
Bit position 1 2 3 5 6 ' . % 8 10 11 12 13 15 16 1' 1. 1% 18 20
...
Enco#e# #ata bits p1 p2 #1 p5 #2 #3 #5 p% #6 #' #. #% #8 #10 #11 p1' #12 #13 #15 #16
1arity
bit
co(erage
p1 M M M M M M M M M M
p2 M M M M M M M M M M
p5 M M M M M M M M M
p% M M M M M M M M
p1' M M M M M
The =ey thing about $amming :odes that can be seen from isual ins!ection is that any
gien bit is included in a uni/ue set of !arity bits. To chec= for errors, chec= all of the !arity bits.
The !attern of errors, called the error syn#rome, identifies the bit in error. If all !arity bits are
correct, there is no error. #therwise, the sum of the !ositions of the erroneous !arity bits
identifies the erroneous bit.
!SC99 Co#e
82:II stands for 8merican 2tandard :ode for Information Interchange. It has become a
world standard al!hanumeric code for microcom!uters and com!uters. It is a ,0bit code
re!resenting '
,
1 %'- different characters. These characters re!resent '+ u!!er case letters 68 to
P7, '+ lowercase letters 6a to D7, %& numbers 6& to .7, (( s!ecial characters and symbols and ((
control characters. The ,0bit code is diided into two !ortions, the leftmost ( bits !ortion is
called Done bits and the )0bit !ortion on the right is called numeric bits.
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
EBCD9C co#e
E":DI: stands for Extended "inary :oded Decimal Interchange :ode. It is mainly used
with large com!uter systems li=e mainframes. E":DI: is an -0bit code and thus accommodates
u! to '*+ characters. 8n E":DI: code is diided into two !ortions4 ) Done bits 6on the left7 and
) numeric bits 6on the right7.
EBCD9C
:0 :1 :2 :3 :5 :6 :' :. :% :8 :! :B :C :D :E :+

0;

NU;
&&&&
0
2#$
&&&%
1
2TM
&&&'
2
ETM
&&&(
3
2E;
4
$T
&&&.
5
AN;
6
DE;
&&,?
7
LE
8
2O2
9
AOT
10
9T
&&&"
11
??
&&&:
12
:A
&&&D
13
2#
&&&E
14
2I
&&&?
15

1;

D;E
&&%&
16
D:%
&&%%
17
D:'
&&%'
18
D:(
&&%(
19
AE2
ENO
20
N;
&&-*
21
"2
&&&-
22
O#:
23
:8N
&&%-
24
EM
&&%.
25
U"2
26
:U%
27
I?2
&&%:
28
IL2
&&%D
29
IA2
&&%E
30
IU2
IT"
&&%?
31

2;

D2
32
2#2
33
?2
34
5U2
35
"BO
INO
36
;?
&&&8
37
ET"
&&%,
38
E2:
&&%"
39
28
40
2?E
41
2M
25
42
:2O
43
M?8
44
ENQ
&&&*
45
8:3
&&&+
46
"E;
&&&,
47
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics

3;
48 49
2BN
&&%+
50
IA
51
OO
52
TAN
53
N"2
54
E#T
&&&)
55
2"2
56
IT
57
A??
58
:U(
59
D:)
&&%)
60
N83
&&%*
61 62
2U"
&&%8
63

5;

2O
&&'&
64
A2O
&&8&
65 66 67 68 69 70 71 72 73 74
.
&&'E
75
R
&&(:
76
6
&&'-
77
@
&&'"
78
H
&&,:
79

6;

S
&&'+
80 81 82 83 84 85 86 87 88 89
T
&&'%
90
U
&&')
91
V
&&'8
92
7
&&'.
93
>
&&("
94
W
&&8:
95

';

0
&&'D
96
C
&&'?
97 98 99 100 101 102 103 104 105
X
&&8+
106
,
&&':
107
Y
&&'*
108
G
&&*?
109
F
&&(E
110
Z
&&(?
111

.;
112 113 114 115 116 117 118 119 120
[
&&+&
121
4
&&(8
122
\
&&'(
123
]
&&)&
124
<
&&',
125
1
&&(D
126
^
&&''
127

%;
128
a
&&+%
129
b
&&+'
130
c
&&+(
131
#
&&+)
132
e
&&+*
133
-
&&++
134
g
&&+,
135
*
&&+-
136
i
&&+.
137 138 139 140 141 142
_
&&"%
143

8;
144
<
&&+8
145
=
&&+"
146
l
&&+:
147
m
&&+D
148
n
&&+E
149
o
&&+?
150
p
&&,&
151
>
&&,%
152
r
&&,'
153 154 155 156 157 158 159

!;
160
`
&&,E
161
s
&&,(
162
t
&&,)
163
u
&&,*
164
(
&&,+
165
,
&&,,
166
x
&&,-
167
y
&&,.
168
?
&&,8
169 170 171 172 173 174 175

B;

a
&&*E
176 177 178 179 180 181 182 183 184 185
b
&&*"
186
c
&&*D
187 188 189 190 191

C;

d
&&,"
192
!
&&)%
193
B
&&)'
194
C
&&)(
195
D
&&))
196
E
&&)*
197
+
&&)+
198
7
&&),
199
&
&&)-
200
9
&&).
201
2$B
&&8D
202 203 204 205 206 207

D;

e
&&,D
208
@
&&)8
209
A
&&)"
210
B
&&):
211
2
&&)D
212
N
&&)E
213
$
&&)?
214
1
&&*&
215
Q
&&*%
216
R
&&*'
217 218 219 220 221 222 223

E;

f
&&*:
224 225
S
&&*(
226
T
&&*)
227
C
&&**
228

&&*+
229
4
&&*,
230
D
&&*-
231
E
&&*.
232
F
&&*8
233 234 235 236 237 238 239

+;

0
&&(&
240
1
&&(%
241
2
&&('
242
3
&&((
243
5
&&()
244
6
&&(*
245
'
&&(+
246
.
&&(,
247
%
&&(-
248
8
&&(.
249 250 251 252 253 254
E#
255
:0 :1 :2 :3 :5 :6 :' :. :% :8 :! :B :C :D :E :+
&ollerit* co#e
De!artment of Electronics 3ar!agam Uniersity
Digital Electronics
&ollerit* co#e is the %'0bit code used on a !unched0card. 5e often refer to the !unched0
cards used in com!uter systems as $ollerith cards in honor of $erman $ollerith 6%-+&%.'.7. 8
$ollerith string is a se/uence of %'0bit characters> they are encoded as two 82:II characters,
containing + bits each4 the first character contains !unches %', &, ', ), +, - and the second
character contains !unches %%, %, (, *, ,, .> interleaing the two characters gies the original %'
bits. To ma=e the characters !rintable on 82:II terminals, bit , is always set to &, and bit + is set
to the com!lement of bit *. These two bits are ignored when reading $ollerith cards.
1arity !#(antages
The adantages of Oarity are,
2ingle bit error can be detected.
It ery much easier to form.
It re/uires only one bit to detect the error.
It act as is the base for other ty!es of error detection and correction codes li=e $amming
code.
De!artment of Electronics 3ar!agam Uniersity

You might also like