Tải bản đầy đủ
2 Layer 1—physical layer interface: DTE/DCE, line interfaces and protocols

2 Layer 1—physical layer interface: DTE/DCE, line interfaces and protocols

Tải bản đầy đủ

Layer 1 — physical layer interface: DTE/DCE, line interfaces and protocols

71

information. At a minimum, the physical interface specification needs to define the precise
nature of the medium (e.g., wire grade, impedance etc); the exact electrical (or equivalent)
signals which are to be used on the line and the details of the line code which shall be used for
bit synchronisation as discussed in Chapter 2. Many modern physical interface specifications
also stipulate the precise mechanical connectors (i.e., plugs and sockets) which should be
used for the interface, but this is not always defined. As well as the basic electrical (radio
or optical) interface, the physical layer specification defines control procedures (the physical
layer protocol ) which allows one or both of the devices at either end of the line (i.e., the
physical medium) to control the line itself.
There are three main types of physical interface to be distinguished from one another:
• DTE-to-DCE interfaces. These are the asymmetric point-to-point user-network interfaces
(UNIs) used typically to connect end devices (e.g., computers) to modems, line terminating
units (LTU), channel service units (CSU), data service units (DSUs), network terminating
units (NT or NTU). All the latter are examples of data circuit terminating equipment (DCE);
• Line interfaces or trunk interfaces (symmetrical point-to-point line interfaces) — most
NNIs and some UNIs are of this type;
• Shared medium interfaces (point-to-multipoint interfaces) — usually used as UNIs. [The
most commonly used shared media are local area networks (LANs). LANS are widely
used to connect end-users PCs to internal office data networks].
In general terms, the UNI (user-network interface) always employs a DTE-to-DCE type
interface, while trunk interfaces tend to use symmetrical, higher bit rate NNI (networknode interface).
Figure 3.3 shows a network in which three routers and two DTEs are interconnected. Both
DTEs are connected to the network by means of DTE/DCE interfaces. Routers C and B are
also connected to the line which interconnects them by means of DTE/DCE (e.g., V.24 or
RS-232) interfaces. Routers A & B and A & C, meanwhile, are interconnected by means of
direct trunk interfaces (DCE/DCE3 ). In these cases, the DCE function is included within the
router itself.

Figure 3.3 DTE/DCE Interface and Trunk or line interface.
3

The ‘DCE/DCE interface’: tempting as it may be, it is not correct to call the long-distance connection between
DCEs a ‘DCE/DCE interface’. Instead, one should refer to the line interface or network interface. The term
‘DCE/DCE interface’ is reserved for the case in which the UNI interface (normally used to connect a DTE to
a DCE) is used to connect a second DCE instead. A cross-cable is used for this purpose, as we discover in
Figure 3.8b.

72

Basic data networks and protocols

DTE-to-DCE interfaces
DCEs (data circuit-terminating equipment) form the ‘end-point’ of a network or long-distance
telecommunications line, allowing point-to-point communication between remote computers
and terminals (which are generically called DTE or data terminal equipment ).
The first DCEs were modems and were designed to be used at either end of a datalink
created by means of a dial-up telephone connection. The modem (like all other types of
DCE) had to provide an interface for connecting to the serial data communications port of
the computer, but also be capable of setting up, receiving, clearing and controlling telephone
connections.
As we have already discussed, the basic functions of all types of DCE are to:
• convert the physical interface emanating from the DTE (data terminal equipment) into a line
interface format suitable for long-distance transmission, and provide for digital/analogue
signal conversion if necessary;
• provide for network termination of the long-distance line, being a source of power for the
line and network as necessary;
• forward data received from the DTE to the network;
• deliver data received from the network to the DTE;
• clock and bit-synchronise4 the data transmission of the DTE during the data transfer phase;
• set up the physical connection forming the medium and clear it as required and/or requested
by the DTE. This may be necessary where the physical link is actually a dial-up connection
across a telephone network, or a temporary radio path.
Some DCEs are controlled by the associated DTE, others act autonomously on behalf of the
DTE. The user’s data and the control signals (functions) are conveyed from DTE to DCE or
DCE to DTE by means of dedicated control leads defined as part of the DTE–DCE interface.
Detailed procedures define how the functions are used and how the states of the DTE and DCE
can be changed from idle, through ready to the data transfer phase and afterwards arrange
for clearing of the connection.
Typical physical layer interface specifications for a DTE-to-DCE interface comprise up to
four different components, including a definition of:
• the physical connector;
• the electrical interface;
• the controls and functions for establishing the link: changing from one state (e.g., idle) to
another (e.g., ready or data transfer) or vice versa;
• the procedures (i.e., sequences of commands) which define the use of the controls. (The
controls and procedures form together form the physical layer protocol.)
The most commonly used DTE/DCE interfaces are illustrated in Figure 3.4. There are two main
categories of DTE/DCE interfaces: X.21-type interfaces (for digital lines) and X.21bis -type
interfaces (used in modems for analogue lines). The other V-series and X-series recommendations listed in Figure 3.4 define individual aspects of specific interfaces.
4

See Chapter 2.

Layer 1 — physical layer interface: DTE/DCE, line interfaces and protocols

73

Note: You may be wondering why all the specifications and standards defining DTE/DCE interfaces
have such different designations. This is because different naming standards are used by the different
standards-publishing organisations. ISO (International Organization for Standardization) uses a simple
numbering scheme (but I haven’t yet worked out the logic behind the individual numbers). I T U - T
(International Telecommunications Union—Standardization sector) issues recommendations in
various series. The X-series defines ‘interfaces and procedures intended for use in general data
communications’. The V-series defines‘ data communications over the telephone network’ (e.g.
modems). Sometimes the same recommendation is issued with a recommendation number in both
series (e.g.V.10/X.26).The nomenclature RS, mean while, stands for recommended standard. This
designation is used by the United States EIA/TIA (Electronic Industries Alliance or Association/
Telecommunications Industries Association).

Figure 3.4

Standards, specifications and ITU-T recommendations defining DTE/DCE interfaces.

DCEs intended for use between DTEs and analogue wide area network (WAN) lines are
called modems. Such modems conform at their DTE/DCE interface with ITU-T recommendations X.21bis and V.24/V.28. X.21bis sets out the entire framework of the DTE-to-DCE
interface used by the modem. V.24 (and RS-232 as well) set out the signals and circuits
(together with their names and numbers) used at the interface. But which signal is sent on
exactly which wire and via which pin of the connector is defined by either V.28 (RS-232),
V.35 or V.36 accordingly.
There are five DTE-to-DCE interfaces in common usage. These (as shown in Figure 3.4) are:
• V.24/V.28 (25-pin DB-25 plug) is the most common interface used between computers
and analogue modems. In Europe this interface is simply referred to as ‘V.24’ and in North
America as RS-232.
• V.36 (37-pin plug), usually referred to as RS-449) is the most commonly used interface
in North America, the UK and France for high bit rate DCEs and those used to connect
digital lines. Very confusingly, many people refer to ‘V.35’ even though they really mean
‘V.36’.
• V.35 is a similar interface to V.36 but with a different connector. Its usage is restricted to
certain types of IBM computers and networking equipment.

74

Basic data networks and protocols

• X.21 (V.11) is the main interface used in Germany, Austria, Switzerland for interfacing
digital line DCEs and high bit rate lines to DTEs. It is often referred to simply as ‘X.21’
without specifying V.11.
• X.21 (V.10) is the version of the X.21 interface designed for use in conjunction with
coaxial cables. It is also simply referred to as ‘X.21’ without specifying V.10.
Unfortunately, newcomers to DTE/DCE standards can easily be confused by the various specifications, since lazy experts often do not define in full the interfaces they wish to refer to. It
is commonplace, for example, to refer only to ‘V.24’ when in fact the complete V.24/V.28
interface is meant. The V.24/V.28 (or RS-232) interface uses the 25-pin DB-25 connector
(ISO 2110) commonly seen on older modems. Similarly, when referring to DCEs used on
digital line circuits, people often speak of ‘X.21’ without saying whether the interface is
V.10 (for unbalanced circuits, i.e., coaxial cables) or V.11 (for balanced circuits, i.e., twisted
pair cable).

Network synchronisation
One of the major functions of the DCE (data circuit terminating equipment) is to ensure that
the DTE (data terminal equipment) transmits its data in a manner bit-synchronised with the
network (i.e., at precisely the right bit rate and at the correct interval in time).
In a public digital transmission network, the network operator uses an extremely accurate
master clock (typically a caesium clock or the extremely accurate clock signal of the satellite
global positioning system) to synchronise his or her entire network. This ensures that slip,
jitter, wander and other undesirable effects (as discussed in chapter 2) do not affect signals
as they move from one node to the next through the network.
The clock signal is sent to all devices within the network, by means of a hierarchical synchronisation plan (Figure 3.5). Each node in the network is configured to receive a primary
clock signal and a secondary (or back-up) clock signal. When the primary source fails, the
node reverts to the secondary. The clock is propagated as far as the DCEs, and from each
DCE is passed on to the corresponding DTE, thus ensuring that all the DTEs maintain an
accurate and network-compatible transmitting bit rate.

Figure 3.5

Hierarchical network synchronisation plan with nominated primary and secondary sources
DCEs and DTE/DCE Interfaces intended for use with analogue lines (Modems).

Layer 1 — physical layer interface: DTE/DCE, line interfaces and protocols

75

In the case of analogue transmission lines, the DCE cannot rely on the network to provide
accurate clocking information, since the bit rate of the signal received from the remote end is
not accurately regulated by the PTO’s (public telecommunications organisation or operator)
analogue network. For this reason, an internal clock is needed within the DCE in order to
maintain an accurate transmitting bit rate.

DTE/DCE control signals
DTE/DCE interfaces were originally multi-lead interfaces, with separate wires or circuits
dedicated for each control action. The control signals defined by ITU-T recommendation V.24
and EIA RS-232 are the most widely used. These are listed in Table 3.1.

DTE/DCE electrical interface
As an example of a standardised physical layer electrical interface, Figure 3.6 illustrates the
‘negative logic’ voltages defined by RS-232 and V.28 for use on each of the DTE/DCE circuits
defined in Table 3.1. For a mark (binary value ‘1’), the transmitter should output a voltage
between −5 V and −15 V. The receiver, meanwhile, interprets any received voltage between
−3 V and −15 V as a mark. Similarly, when transmitting a space (binary value ‘0’), the
Table 3.1
Signal
code

DTE/DCE control signals defined by EIA RS-232/ITU-T recommendation V.24

Signal
meaning

EIA
ITU-T
Db-9 pin
DB-25
Connector pin number Rec. V.24 signal
name
signal
(EIA 562)
number
name
(ISO 2110)

CTS

Clear-to-send

5

8

106

CB

DCD

data carrier
detect

8

1

109

CF

DSR

data set ready

6 (not always
used)

6

107

CC

DTR

20

4

108.2

CD

GND

data terminal
ready
Ground

7

5

102

AB

RC

Receiver clock

17 (little used)



115

DD

RI

Ring indicator

22

9

125

CE

RTS

Request-to-send

4

7

105

CA

RxD

Receive data

3

2

104

BB

TC

Transmitter
clock
Transmit data

15 (little used)



114

DB

2

3

103

BA

TxD

Signal meaning
for binary value
‘1’ or
‘mark’
From DCE to DTE.. ‘I am
ready when you are’
From DCE to DTE.. ‘I
am receiving your
carrier signal’
From DCE (the ‘data set’
to DTE).. ‘I am ready
to send data’
From DTE to DCE.. ‘I am
ready to communicate’
Signal ground — voltage
reference value
Receive clock signal
(from DCE to DTE)
From DCE to DTE.. ‘I
have an incoming call
for you’
From DTE to DCE..
‘please send my data’
DTE receives data from
DCE on this pin
Transmit clock signal
(From DCE to DTE)
DTE transmits data to
DCE on this pin

76

Basic data networks and protocols

Figure 3.6

Defined output (send) and input (detect) voltages of RS-232 and V.28 circuits.

output voltage shall be between +5 V and +15 V, and any received voltage between +3 V
and +15 V shall be interpreted as a space. This is a non-return-to-zero /NRZ)5 code. The wider
voltage span used by the receiver rules out the possibility of marks or spaces being ‘lost’ on the
line due to signal attenuation. Note that the maximum cabling length of a V.28/RS-232-based
interface is around 15 to 25 m.

DTE/DCE connectors and cables
The familiar 25-pin DB-25 connector (ISO 2110) used on modems is illustrated in Figure 3.7a.
The DTE normally has a male connector (i.e., pins exposed in the socket) while the DCE has
a female connector (socket with holes to receive pins). The DTE-to-DCE connection cable
comprises a cable with a female plug at one end (for the DTE) and a male plug at the other

Figure 3.7
5

See Chapter 2.

Connectors used for V.24/V.28 or RS-232 interface.

Layer 1 — physical layer interface: DTE/DCE, line interfaces and protocols

77

(for the DCE). This ensures, in particular, that the TxD (transmit data) and RxD (receive data)
leads are correctly wired. (Recall from Chapter 2: the DTE transmits data on ‘TxD’ for the
DCE to receive. The DTE receives data from the DCE on lead ‘RxD’.) The cable simply
connects pin 1 at the DTE to pin 1 at the DCE, pin 2 to pin 2, etc. (Figure 3.8a).
Some personal computers still present a 25-pin male connector as their means of connecting
to an external modem or similar device, but more common nowadays is the 9-pin DB-9 connector (EIA 562) as the serial interface port. The nine most critical leads of the V.24-defined
interface can simply be transposed into this smaller connector (Figure 3.7b) and therefore save
valuable space on the back of the laptop computer.
As time has moved on, computer users have not only wanted to have smaller serial port
connectors on their PCs, they have also been innovative in finding ways of interconnecting
their computers directly over the serial port. You can even directly connect two DTEs together
by using a special null modem cable (Figure 3.8b). This is designed to ‘trick’ each of the
computers into thinking it is communicating with a DCE. In a null modem cable, the TxD
and RxD leads are ‘crossed’ since both devices expect to send on TxD and receive on RxD.
MORAL: be very careful with computer cables, socket adapters and gender changers (male to
female plug or socket adapters). Just because you can make the plug fit into the socket doesn’t
mean it’s the right cable for the purpose! Don’t be surprised if the system doesn’t work!

Hayes AT-command set
Early modem development concentrated on the need to adapt the telephone network to enable
the carriage of data communication. The earliest modem was developed by a telephone
company (AT&T) and was designed, like telephone networks of the day (date: 1956), in
a hardware-oriented fashion. There were no microprocessors at the time. From this heritage
resulted the relatively complex hardware-oriented interface V.24, with its multiple pin plugs,
cables and sockets. But as time progressed, modems became more sophisticated, introducing
the potential to control the modem by means of software commands. The most commonly

Figure 3.8

DTE/DCE and null modem cable types.

78

Basic data networks and protocols

used command set used for this purpose in the Hayes AT command set, developed by Hayes
Microcomputer corporation in the 1970s.
AT is short for attention. These are the two ASCII characters which precede each of the
commands sent from a computer to a Hayes compatible modem (most modems are nowadays).
Common commands are:
• ATDT (followed by a number) = dial this number using tone dialling
• ATDP (followed by a number) = dial this number using pulse dialling
• [X1] = dial immediately
• [X3] = wait for dial tone
• [W] = wait for second dial tone (e.g., when dialling via a PBX, private branch exchange)
• ATA = manual answer incoming calls
• ATH = hang up
• ATS0 = 0 = disable auto answer
• ATZ = modem reset
The modem responds by acknowledging the commands with the response ‘OK’. As well as
the above commands, there are a number of signals which allow the internal configuration
of the modem to be changed (e.g., change bit rate, timeouts, etc.). Rather than requiring
dedicated leads, as in the V.24 interface, AT commands are sent directly over the TxD and
RxD leads prior to establishment of a connection. (They therefore cannot be confused with
user data.)
Since the AT command set provides a powerful means of controlling the modem, the need
for the multiple pins of the V.24 interface has reduced. Hence the typical use of seven leads
(Figure 3.8a). But when using the ready-busy-protocol, only four are necessary (Figure 3.8c).
An alternative scheme to the Hayes AT command set is offered by ITU-T recommendation
V.25bis .

DTE/DCE interfaces for digital line bit rates exceeding 64 kbit/s — V.35/V.36
and X.21
DCEs (data circuit terminating equipment) used for the termination of digital leaselines (bit
rates from 64 kbit/s to 45 Mbit/s or even higher) go by a variety of names:
• CSU (channel service unit);
• DSU (data service unit);
• LTU (line terminating unit);
• NTU (network terminating unit).
Such devices have to cope with the special demands of high bit rate signals — in particular
their sensitivity to electromagnetic interference.
In the UK, France and North America, the V.36 interface is most commonly used to connect
DTEs to DCEs designed to terminate lines of bit rates between 64 kbit/s and 1.544 Mbit/s

Layer 1 — physical layer interface: DTE/DCE, line interfaces and protocols

Figure 3.9

79

Usual connectors for V.35 and V.36 (RS-449) interfaces.

(North America) or 2.048 Mbit/s (Europe). The V.36 interfaces is well suited for cases in
which the DCE is connected to the main network by means of coaxial cable. Coaxial cables
were initially used to carry digital leaselines from customer premises to the nearest telephone
exchange building (coaxial cable local loops).
The connectors and pin layouts of the V.35 and RS-449 (V.35/V.36) interfaces are illustrated in Figure 3.9. Note that many more circuits and pins are needed than in the case
of V.24 or RS-232, because each of the main signals (transmit, receive, etc.) is allocated
a pair of wires (‘a’ and ‘b’ leads) rather than using only the ‘a’ lead and sharing a common ‘b-lead’ or ground. This precaution helps prevent possible interference between the
signals, and is necessary to support the higher bit rates which V.35 and RS-449 interfaces are
designed for.
In Germany and other continental European countries, the X.21 (V.11) interface is normally used for the DTE/DCE interface of digital leaselines. The emergence of X.21 and V.11
was driven by the use of standard telephone cabling (two twisted pair cables — i.e., 4-wire)
for the local loop section of digital leaselines (from customer premises to the nearest telephone exchange). X.21 was also a natural choice because, at the time of conception of X.21,
Deutsche Telekom (then called Deutsche Bundespost) needed a control mechanism capable
for setting up dial-connections across their (now extinct) Datex-L public circuit-switched data
network (PSDN).
X.21 was developed later than V.24 and RS-232 with the specific objective of catering
for higher bit rate lines, which became possible with the advent of digital telephone leaselines. X.21 line bit rates are usually an integral multiple of the standard digital telephone
channel bandwidth (64 kbit/s) — hence the so-called n*64 kbit/s rates: 128 kbit/s, 192 kbit/s,
256 kbit/s, 384 kbit/s, 512 kbit/s, 768 kbit/s, 1024 kbit/s, 1536 kbit/s, 2048 kbit/s.
Together with the related recommendations X.24, V.10 (also known as X.26) and V.11
(also known as X.27), X.21 sets out an interface requiring far fewer interconnection circuits

80

Basic data networks and protocols

than necessary for the earlier V.24 and RS-232 interfaces. In addition, X.21 was specifically
targetted on synchronous communication.6
X.21 uses separate pairs of ‘a’ and ‘b’ leads for the main signal circuits, rather than
employing a common signal (or ground ). This helps prevent interference between signals and
allows for much greater DTE-DCE cabling distances of up to 100 m (the maximum cabling
length had previously been limited by V.24/V.28 to around only 15–25 m).
Instead of a large number of separate circuits for the individual control signals (as in
V.24–Table 3.1), X.21 uses the control lead (from DTE to DCE) and the indication lead
(from DCE to DTE) in a way which enables multiple control and indication messages to be
sent using the transmit (T) and receive (R) pairs, thus greatly reducing the number of wires
required for DTE/DCE cables and the number of pins and sockets needed in X.21 connectors
(Figure 3.10). A simple logic achieves this:
• When the control leads (C) are set ‘on’, then the data transmitted on the transmit leads
(T) is to be interpreted by the DCE as a control message and acted on accordingly.
• When the indicate leads (I) are set by the DCE to ‘on’, then the DCE is ready to receive
data. Otherwise, when ‘off’, the data sent by the DCE to the DTE on the receive leads (R)
may be either information being sent to the DTE or the idle state (a string of ‘1’s is sent
in this case).
The control signals and states defined by X.21 are listed in Table 3.2. DTE and DCE negotiate
their way from the idle state through selection and connection to the data transfer state.
Following the end of the communication session, the clearing procedure returns the line back
to the idle state.

Subrate multiplexing
When bit speeds below the basic digital channel bit rate of 64 kbit/s are required by the
DTE, then the DCE may have to carry out an additional function: breaking down the line

Figure 3.10
6

See Chapter 2.

Connector and pin-layout according to ITU-T recommendation X.21.

Layer 1 — physical layer interface: DTE/DCE, line interfaces and protocols
Table 3.2
State
number
1
2
3

4

5
6
7
8
9
10
11
12
13
13S
13R
14
15
16
17
18
19
20
21
22

23

24
25

81

Communication states: ITU-T recommendation X.21

State
name
Ready
Call request
Proceed-to-select
request (i.e., request
dial)
Selection signal
sequence (i.e.,
number to be
dialled)
DTE waiting
DCE waiting
Call progress signal
Incoming call
Call accepted
Call information (from
DCE)
Connection in progress
Ready for data (i.e., to
communicate)
Data transfer (i.e.,
communication)
Send data
Receive data
DTE controlled not
ready, DCE ready
Call collision
DTE clear request
DCE clear
confirmation
DTE ready, DCE not
ready
DCE clear indication
DTE clear indication
DCE ready
DTE uncontrolled not
ready (fault), DCE
not ready
DTE controlled not
ready, DCE not
ready
DTE uncontrolled
fault, DCE ready
DTE provided
information

T
(transmit)

C
(control)

R
(receive)

I
(indication)

1
0
0

Off
On
On

1
1
+

Off
Off
Off

ASCII [7 bit]
(IA5)

On

+

Off

1
1
1

On
On
On

Off
Off
Off

1
1
1

Off
On
On

1
1

On
On

+
SYN
ASCII [7 bit]
(IA5)
Bell
Bell
ASCII [7 bit]
(IA5)
1
1

Data

On

Data

On

Data
1
01

On
Off
Off

1
Data
1

Off
On
Off

0
0
0

On
Off
Off

Bell
X(any signal)
0

Off
X(any signal)
Off

1

Off

0

Off

X(any signal)
0
0
0

X(any signal)
Off
Off
Off

0
0
1
0

Off
Off
Off
Off

01

Off

0

Off

0

Off

1

Off

ASCII [7 bit]
(IA5)

Off

1

On

Off
Off
Off
Off
On

bandwidth of 64 kbit/s into a number of lower bit rate channels. This process is called sub-rate
multiplexing (or terminal adaption). Terminal adaption is defined in ITU-T recommendation
V.110. The process can derive one or a number of lower bit rate channel bit rates from a
64 kbit/s channel: 600 bit/s, 1200 bit/s, 2.4 kbit/s, 4.8 kbit/s, 7.2 kbit/s, 9.6 kbit/s, 12 kbit/s,
14.4 kbit/s, 19.2 kbit/s, etc.