Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
93 views

Data Comms Codes

The document discusses fundamental concepts of data communications including data communication codes, error control, and hardware components. It describes several data communication codes including Baudot code, ASCII, and EBCDIC. Baudot code was an early 5-bit code used for telegraphy. ASCII is the most widely used 7-bit code for text representation. EBCDIC is an 8-bit code developed by IBM for use in mainframe systems.
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)
93 views

Data Comms Codes

The document discusses fundamental concepts of data communications including data communication codes, error control, and hardware components. It describes several data communication codes including Baudot code, ASCII, and EBCDIC. Baudot code was an early 5-bit code used for telegraphy. ASCII is the most widely used 7-bit code for text representation. EBCDIC is an 8-bit code developed by IBM for use in mainframe systems.
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/ 11

Fundamental Concepts of Data

Communications
■ Describe data communications modems
■ Explain the block diagram of a modem
■ Explain what is meant by Bell System–compatible modems
■ Describe modem synchronization and modem equalization
■ Describe the ITU-T modem recommendations

1
INTRODUCTION
To understand how a data communications network works as an entity, it is necessary
first to understand the fundamental concepts and components that make up the network.
The fundamental concepts of data communications include data communications code,
error control (error detection and correction), and character synchronization, and
fundamental hardware includes various pieces of computer and networking equipment,
such as line con- trol units, serial interfaces, and data communications modems.

2 DATA COMMUNICATIONS CODES

Data communications codes are often used to represent characters and symbols, such as
let- ters, digits, and punctuation marks. Therefore, data communications codes are called
character codes, character sets, symbol codes, or character languages.
2-1 Baudot
Code
The Baudot code (sometimes called the Telex code) was the first fixed-length character
code developed for machines rather than for people. A French postal engineer named
Thomas Murray developed the Baudot code in 1875 and named the code after Emile Bau-
dot, an early pioneer in telegraph printing. The Baudot code (pronounced baw-dough) is a
fixed-length source code (sometimes called a fixed-length block code). With fixed-length
source codes, all characters are represented in binary and have the same number of
symbols (bits). The Baudot code is a five-bit character code that was used primarily for
low-speed teletype equipment, such as the TWX/Telex system and radio teletype
(RTTY). The latest version of the Baudot code is recommended by the CCITT as the
International Alphabet No. 2 and is shown in Table 1.
2-2 ASCII
Code
In 1963, in an effort to standardize data communications codes, the United States adopted
the Bell System model 33 teletype code as the United States of America Standard Code
for Information Exchange (USASCII), better known as ASCII-63. Since its adoption,
ASCII (pronounced as-key) has progressed through the 1965, 1967, and 1977 versions,
with the
1977 version being recommended by the ITU as International Alphabet No. 5, in the
United States as ANSI standard X3.4-1986 (R1997), and by the International Standards
Organiza- tion as ISO-14962 (1997).
ASCII is the standard character set for source coding the alphanumeric character
set that humans understand but computers do not (computers only understand 1s and
0s). ASCII is a seven-bit fixed-length character set. With the ASCII code, the least-
significant bit (LSB) is designated b0 and the most-significant bit (MSB) is designated b7
as shown here:
b7 b6 b5 b4 b3 b2 b1 b0
MSB LSB
Direction of propagation
The terms least and most significant are somewhat of a misnomer because character
codes do not represent weighted binary numbers and, therefore, all bits are equally sig-

150
Table 1 Baudot Code

Bit

Letter Figure Bit: 4 3 2 1 0

A — 1 1 0 0 0
B ? 1 0 0 1 1
C : 0 1 1 1 0
D $ 1 0 0 1 0
E 3 1 0 0 0 0
F ! 1 0 1 1 0
G & 0 1 0 1 1
H # 0 0 1 0 1
I 8 0 1 1 0 0
J ' 1 1 0 1 0
K ( 1 1 1 1 0
L ) 0 1 0 0 1
M . 0 0 1 1 1
N , 0 0 1 1 0
O 9 0 0 0 1 1
P 0 0 1 1 0 1
Q 1 1 1 1 0 1
R 4 0 1 0 1 0
S bel 1 0 1 0 0
T 5 0 0 0 0 1
U 7 1 1 1 0 0
V ; 0 1 1 1 1
W 2 1 1 0 0 1
X / 1 0 1 1 1
Y 6 1 0 1 0 1
Z ″ 1 0 0 0 1
Figure shift 1 1 1 1 1
Letter shift 1 1 0 1 1
Space 0 0 1 0 0
Line feed (LF) 0 1 0 0 0
Blank (null) 0 0 0 0 0

nificant. Bit b7 is not part of the ASCII code but is generally reserved for an error detec-
tion bit called the parity bit, which is explained later in this chapter. With character
codes, it is more meaningful to refer to bits by their order than by their position; b0 is the
zero- order bit, b1 the first-order bit, b7 the seventh-order bit, and so on. However, with
serial data transmission, the bit transmitted first is generally called the LSB. With
ASCII, the low-order bit (b0) is transmitted first. ASCII is probably the code most often
used in data communications networks today. The 1977 version of the ASCII code with
odd parity is shown in Table 2 (note that the parity bit is not included in the hex code).
2-3 EBCDIC
Code
The extended binary-coded decimal interchange code (EBCDIC) is an eight-bit fixed-
length character set developed in 1962 by the International Business Machines
Corporation (IBM). EBCDIC is used almost exclusively with IBM mainframe computers
8
and peripheral equipment. With eight bits, 2 , or 256, codes are possible, although only
139 of the 256 codes are actually assigned characters. Unspecified codes can be assigned
to specialized characters and functions. The name binary coded decimal was selected
because the second hex character for all letter and digit codes contains only the hex values
from 0 to 9, which have the same binary sequence as BCD codes. The EBCDIC code is
shown in Table 3.
Table 2 ASCII-77: Odd Parity

Binary Code Binary Code

Bit 7 6 5 4 3 2 1 0 Hex Bit 7 6 5 4 3 2 1 0 Hex

NUL 1 0 0 0 0 0 0 0 00 @ 0 1 0 0 0 0 0 0 40
SOH 0 0 0 0 0 0 0 1 01 A 1 1 0 0 0 0 0 1 41
STX 0 0 0 0 0 0 1 0 02 B 1 1 0 0 0 0 1 0 42
ETX 1 0 0 0 0 0 1 1 03 C 0 1 0 0 0 0 1 1 43
EOT 0 0 0 0 0 1 0 0 04 D 1 1 0 0 0 1 0 0 44
ENQ 1 0 0 0 0 1 0 1 05 E 0 1 0 0 0 1 0 1 45
ACK 1 0 0 0 0 1 1 0 06 F 0 1 0 0 0 1 1 0 46
BEL 0 0 0 0 0 1 1 1 07 G 1 1 0 0 0 1 1 1 47
BS 0 0 0 0 1 0 0 0 08 H 1 1 0 0 1 0 0 0 48
HT 1 0 0 0 1 0 0 1 09 I 0 1 0 0 1 0 0 1 49
NL 1 0 0 0 1 0 1 0 0A J 0 1 0 0 1 0 1 0 4A
VT 0 0 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1 1 1 0 1 0 7A
; 0 0 1 1 1 0 1 1 3B { 1 1 1 1 1 0 1 1 7B
1 0 1 1 1 1 0 0 3C | 0 1 1 1 1 1 0 0 7C
0 0 1 1 1 1 0 1 3D } 1 1 1 1 1 1 0 1 7D
0 0 1 1 1 1 1 0 3E 1 1 1 1 1 1 1 0 7E
? 1 0 1 1 1 1 1 1 3F DEL 0 1 1 1 1 1 1 1 7F

NUL null VT vertical tab SYN synchronous


SOH start of heading FF form feed ETB end of transmission block
STX start of text CR carriage return CAN cancel
ETX end of text SO shift-out SUB substitute
EOT end of transmission SI shift-in ESC escape
ENQ enquiry DLE data link escape FS field separator
ACK acknowledge DC1 device control 1 GS group separator
BEL bell DC2 device control 2 RS record separator
BS back space DC3 device control 3 US unit separator
HT horizontal tab DC4 device control 4 SP space
NL new line NAK negative acknowledge DEL delete

Table 3 EBCDIC Code

Binary Code Binary Code

Bit 0 1 2 3 4 5 6 7 Hex Bit 0 1 2 3 4 5 6 7 Hex

NUL 0 0 0 0 0 0 0 0 00 1 0 0 0 0 0 0 0 80
SOH 0 0 0 0 0 0 0 1 01 a 1 0 0 0 0 0 0 1 81
STX 0 0 0 0 0 0 1 0 02 b 1 0 0 0 0 0 1 0 82
ETX 0 0 0 0 0 0 1 1 03 c 1 0 0 0 0 0 1 1 83
0 0 0 0 0 1 0 0 04 d 1 0 0 0 0 1 0 0 84
PT 0 0 0 0 0 1 0 1 05 e 1 0 0 0 0 1 0 1 85
0 0 0 0 0 1 1 0 06 f 1 0 0 0 0 1 1 0 86
0 0 0 0 0 1 1 1 07 g 1 0 0 0 0 1 1 1 87
0 0 0 0 1 0 0 0 08 h 1 0 0 0 1 0 0 0 88
0 0 0 0 1 0 0 1 09 i 1 0 0 0 1 0 0 1 89
0 0 0 0 1 0 1 0 0A 1 0 0 0 1 0 1 0 8A
0 0 0 0 1 0 1 1 0B 1 0 0 0 1 0 1 1 8B
FF 0 0 0 0 1 1 0 0 0C 1 0 0 0 1 1 0 0 8C
0 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 1 1 0 0 0 0 F0
0 1 1 1 0 0 0 1 71 1 1 1 1 1 0 0 0 1 F1
0 1 1 1 0 0 1 0 72 2 1 1 1 1 0 0 1 0 F2
0 1 1 1 0 0 1 1 73 3 1 1 1 1 0 0 1 1 F3
0 1 1 1 0 1 0 0 74 4 1 1 1 1 0 1 0 0 F4
0 1 1 1 0 1 0 1 75 5 1 1 1 1 0 1 0 1 F5
0 1 1 1 0 1 1 0 76 6 1 1 1 1 0 1 1 0 F6
0 1 1 1 0 1 1 1 77 7 1 1 1 1 0 1 1 1 F7
0 1 1 1 1 0 0 0 78 8 1 1 1 1 1 0 0 0 F8
0 1 1 1 1 0 0 1 79 9 1 1 1 1 1 0 0 1 F9
: 0 1 1 1 1 0 1 0 7A 1 1 1 1 1 0 1 0 FA
# 0 1 1 1 1 0 1 1 7B 1 1 1 1 1 0 1 1 FB
@ 0 1 1 1 1 1 0 0 7C 1 1 1 1 1 1 0 0 FC
0 1 1 1 1 1 0 1 7D 1 1 1 1 1 1 0 1 FD
0 1 1 1 1 1 1 0 7E 1 1 1 1 1 1 1 0 FE
” 0 1 1 1 1 1 1 1 7F 1 1 1 1 1 1 1 1 FF

DLE data-link escape ITB end of intermediate transmission block


DUP duplicate NUL null
EM end of medium PT program tab ENQ
enquiry RA repeat to address EOT
end of transmission SBA set buffer address ESC
escape SF start field
ETB end of transmission block SOH start of heading
ETX end of text SP space
EUA erase unprotected to address STX start of text
FF form feed SUB substitute
FM field mark SYN synchronous
IC insert cursor NAK negative acknowledge
Fundamental Concepts of Data
Communications

FIGURE 1 Typical bar code

3 BAR
CODES
Bar codes are those omnipresent black-and-white striped stickers that seem to appear on
virtually every consumer item in the United States and most of the rest of the world. Al-
though bar codes were developed in the early 1970s, they were not used extensively un-
til the mid-1980s. A bar code is a series of vertical black bars separated by vertical white
bars (called spaces). The widths of the bars and spaces along with their reflective abili-
ties represent binary 1s and 0s, and combinations of bits identify specific items. In addi-
tion, bar codes may contain information regarding cost, inventory management and con-
trol, security access, shipping and receiving, production counting, document and order
processing, automatic billing, and many other applications. A typical bar code is shown
in Figure 1.
There are several standard bar code formats. The format selected depends on what
types of data are being stored, how the data are being stored, system performance, and
which format is most popular with business and industry. Bar codes are generally
classified as being discrete, continuous, or two-dimensional (2D).

Discrete code. A discrete bar code has spaces or gaps between characters.
Therefore, each character within the bar code is independent of every other
character. Code 39 is an example of a discrete bar code.
Continuous code. A continuous bar code does not include spaces between
characters. An example of a continuous bar code is the Universal Product Code
(UPC).
2D code. A 2D bar code stores data in two dimensions in contrast with a
conventional linear bar code, which stores data along only one axis. 2D bar codes
have a larger storage capacity than one-dimensional bar codes (typically 1 kilobyte
or more per data symbol).

3-1 Code
39
One of the most popular bar codes was developed in 1974 and called Code 39 (also called
Code 3 of 9 and 3 of 9 Code). Code 39 uses an alphanumeric code similar to the ASCII
code. Code 39 is shown in Table 4. Code 39 consists of 36 unique codes representing the
10 digits and 26 uppercase letters. There are seven additional codes used for special char-
acters, and an exclusive start/stop character coded as an asterisk (*). Code 39 bar codes
are ideally suited for making labels, such as name badges.
Each Code 39 character contains nine vertical elements (five bars and four
spaces). The logic condition (1 or 0) of each element is encoded in the width of the bar
or space (i.e., width modulation). A wide element, whether it be a bar or a space,
represents a logic 1, and a narrow element represents a logic 0. Three of the nine
elements in each Code 39 character must be logic 1s, and the rest must be logic 0s. In
addition, of the three logic
1s, two must be bars and one a space. Each character begins and ends with a black bar
with alternating white bars in between. Since Code 39 is a discrete code, all characters
are separated with an intercharacter gap, which is usually one character wide. The aster-
isks at the beginning and end of the bar code are start and stop characters, respectively.
Fundamental Concepts of Data
Communications
Table 4 Code 39 Character Set

Character Binary Code Bars Spaces Check Sum


b8 b7 b6 b5 b4 b3 b2 b1 b0 b8b6b4b2b0 b7b5b3b1 Value

0 0 0 0 1 1 0 1 0 0 00110 0100 0
1 1 0 0 1 0 0 0 0 1 10001 0100 1
2 0 0 1 1 0 0 0 0 1 01001 0100 2
3 1 0 1 1 0 0 0 0 0 11000 0100 3
4 0 0 0 1 1 0 0 0 1 00101 0100 4
5 1 0 0 1 1 0 0 0 0 10100 0100 5
6 0 0 1 1 1 0 0 0 0 01100 0100 6
7 0 0 0 1 0 0 1 0 1 00011 0100 7
8 1 0 0 1 0 0 1 0 0 10010 0100 8
9 0 0 1 1 0 0 1 0 0 01010 0100 9
A 1 0 0 0 0 1 0 0 1 10001 0010 10
B 0 0 1 0 0 1 0 0 1 01001 0010 11
C 1 0 1 0 0 1 0 0 0 11000 0010 12
D 0 0 0 0 1 1 0 0 1 00101 0010 13
E 1 0 0 0 1 1 0 0 0 10100 0010 14
F 0 0 1 0 1 1 0 0 0 01100 0010 15
G 0 0 0 0 0 1 1 0 1 00011 0010 16
H 1 0 0 0 0 1 1 0 0 10010 0010 17
I 0 0 1 0 0 1 1 0 0 01010 0010 18
J 0 0 0 0 1 1 1 0 0 00110 0010 19
K 1 0 0 0 0 0 0 1 1 10001 0001 20
L 0 0 1 0 0 0 0 1 1 01001 0001 21
M 1 0 1 0 0 0 0 1 0 11000 0001 22
N 0 0 0 0 1 0 0 1 1 00101 0001 23
O 1 0 0 0 1 0 0 1 0 10100 0001 24
P 0 0 1 0 1 0 0 1 0 01100 0001 25
Q 0 0 0 0 0 0 1 1 1 00011 0001 26
R 1 0 0 0 0 0 1 1 0 10010 0001 27
S 0 0 1 0 0 0 1 1 0 01010 0001 28
T 0 0 0 0 1 0 1 1 0 00110 0001 29
U 1 1 0 0 0 0 0 0 1 10001 1000 30
V 0 1 1 0 0 0 0 0 1 01001 1000 31
W 1 1 1 0 0 0 0 0 0 11000 1000 32
X 0 1 0 0 1 0 0 0 1 00101 1000 33
Y 1 1 0 0 1 0 0 0 0 10100 1000 34
Z 0 1 1 0 1 0 0 0 0 01100 1000 35
0 1 0 0 0 0 1 0 1 00011 1000 36
. 1 1 0 0 0 0 1 0 0 10010 1000 37
space 0 1 1 0 0 0 1 0 0 01010 1000 38
* 0 1 0 0 1 0 1 0 0 00110 1000 —
$ 0 1 0 1 0 1 0 0 0 00000 1110 39
/ 0 1 0 1 0 0 0 1 0 00000 1101 40
0 1 0 0 0 1 0 1 0 00000 1011 41
% 0 0 0 1 0 1 0 1 0 00000 0111 42

Figure 2 shows the Code 39 representation of the start/stop code (*) followed by an in-
tercharacter gap and then the Code 39 representation of the letter A.
3-2 Universal Product
Code
The grocery industry developed the Universal Product Code (UPC) sometime in the early
1970s to identify their products. The National Association of Food Chains officially
adopted the UPC code in 1974. Today UPC codes are found on virtually every grocery
item from a candy bar to a can of beans.
Fundamental Concepts of Data
Communications
Intercharacter gap Intercharacter gap

X 3X

Bar
code

Binary code 0 1 00 1 0 1 00 1 0000 1 00 1


Character asterisk (*) A Next character
Start guard pattern

X = width of narrow bar or space


3X = width of wide bar or space

FIGURE 2 Code 39 bar code

Figures 3a, b, and c show the character set, label format, and sample bit patterns for
the standard UPC code. Unlike Code 39, the UPC code is a continuous code since there
are no in- tercharacter spaces. Each UPC label contains a 12-digit number. The two long
bars shown in Figure 3b on the outermost left- and right-hand sides of the label are called
the start guard pat- tern and the stop guard pattern, respectively. The start and stop guard
patterns consist of a 101 (bar-space-bar) sequence, which is used to frame the 12-digit
UPC number. The left and right halves of the label are separated by a center guard
pattern, which consists of two long bars in the center of the label (they are called long
bars because they are physically longer than the other bars on the label). The two long bars
are separated with a space between them and have spaces on both sides of the bars.
Therefore, the UPC center guard pattern is 01010 as shown in Figure 3b. The first six
digits of the UPC code are encoded on the left half of the label (called the left-hand
characters), and the last six digits of the UPC code are encoded on the right half (called
the right-hand characters). Note in Figure 3a that there are two binary codes for each
character. When a character appears in one of the first six digits of the code, it uses a left-
hand code, and when a character appears in one of the last six digits, it uses a right-hand
code. Note that the right-hand code is simply the complement of the left-hand code. For
example, if the second and ninth digits of a 12-digit code UPC are both 4s, the digit is
encoded as a 0100011 in position 2 and as a 1011100 in position 9. The UPC code for
the 12-digit code 012345
543210 is

0001101 0011001 0010011 0111101 0100011 1011100 0110001 1001110 1000010 1101100 1100110 1110010
0 1 2 3 4 5 5 4 3 2 1 0

left-hand codes right-hand codes

The first left-hand digit in the UPC code is called the UPC number system
character, as it identifies how the UPC symbol is used. Table 5 lists the 10 UPC number
system char- acters. For example, the UPC number system character 5 indicates that the
item is intended to be used with a coupon. The other five left-hand characters are data
characters. The first five right-hand characters are data characters, and the sixth right-
hand character is a check character, which is used for error detection. The decimal value
of the number system char- acter is always printed to the left of the UPC label, and on
most UPC labels the decimal value of the check character is printed on the right side of
the UPC label.
With UPC codes, the width of the bars and spaces does not correspond to logic 1s
and 0s. Instead, the digits 0 through 9 are encoded into a combination of two variable-
UPC Character Set

Left-hand Decimal Right-hand


character digit character

0001101 0 1110010
0011001 1 1100110
0010011 2 1101100
0111101 3 1000010
0100011 4 1011100
0110001 5 1001110
0101111 6 1010000
0111011 7 1000100
0110111 8 1001000
0001011 9 1110100

(a)

Number system Center guard Character


character pattern check

Start guard Stop guard


pattern Five left-hand Five right-hand
pattern
data characters data characters
(35 bits) (35 bits)

101 6 digits 01010 6 digits 101

(b)

0 1 0 0 0 1 1 1 0 1 1 1 0 0

Left-hand character 4 Right-hand character 4

(c)

FIGURE 3 (a) UPC version A character set; (b) UPC label format; (c) left-
and right-hand bit sequence for the digit 4

width bars and two variable-width spaces that occupy the equivalent of seven bit
positions. Figure 3c shows the variable-width code for the UPC character 4 when used in
one of the first six digit positions of the code (i.e., left-hand bit sequence) and when used
in one of the last six digit positions of the code (i.e., right-hand bit sequence). A single
bar (one bit po- sition) represents a logic 1, and a single space represents a logic 0.
However, close exami- nation of the UPC character set in Table 5 will reveal that all UPC
digits are comprised of bit patterns that yield two variable-width bars and two variable-
width spaces, with the bar and space widths ranging from one to four bits. For the UPC
character 4 shown in Figure
3c, the left-hand character is comprised of a one-bit space followed in order by a one-bit
bar, a three-bit space, and a two-bit bar. The right-hand character is comprised of a one-
bit bar followed in order by a one-bit space, a three-bit bar, and a two-bit space.
Fundamental Concepts of Data
Communications
Table 5 UPC Number System Characters

Character Intended Use

0 Regular UPC codes


1 Reserved for future use
2 Random-weight items that are symbol marked at the store
3 National Drug Code and National Health Related Items Code
4 Intended to be used without code format restrictions and with
check digit protection for in-store marking of nonfood items
5 For use with coupons
6 Regular UPC codes
7 Regular UPC codes
8 Reserved for future use
9 Reserved for future use

0 0 0 1 1 0 1 1 1 1 0 0 1 0

Left-hand version of the character 0 Right-hand version of the character 0

FIGURE 4 UPC
character 0

Example
1
Determine the UPC label structure for the digit 0.
Solution From Figure 3a, the binary sequence for the digit 0 in the left-hand character field
is
0001101, and the binary sequence for the digit 0 in the right-hand character field is 1110010.
The left-hand sequence is comprised of three successive 0s, followed by two 1s, one 0, and one
1. The three successive 0s are equivalent to a space three bits long. The two 1s are equivalent to a
bar two bits long. The single 0 and single 1 are equivalent to a space and a bar, each one bit long.
The right-hand sequence is comprised of three 1s followed by two 0s, a 1, and a 0. The three
1s are equivalent to a bar three bits long. The two 0s are equivalent to a space two bits long. The
sin- gle 1 and single 0 are equivalent to a bar and a space, each one bit long each. The UPC pattern
for the digit 0 is shown in Figure 4.

You might also like