CN Unit II Part I
CN Unit II Part I
in
Character Count
This method uses a field in the header to specify the number of characters in the frame. When the data
link layer at the destination sees the character count, it knows how many characters follow, and hence
where the end of the frame is. The disadvantage is that if the count is garbled by a transmission error, the
destination will lose synchronization and will be unable to locate the start of the next frame. So, this
method is rarely used.
Character stuffing
In the second method, each frame starts with the ASCII character sequence DLE STX and ends with the
sequence DLE ETX. This method overcomes the drawbacks of the character count method. However,
character stuffing is closely associated with 8-bit characters and this is a major hurdle in transmitting
arbitrary sized characters.
Bit stuffing
The third method allows data frames to contain an arbitrary number of bits and allows character codes
with an arbitrary number of bits per character. At the start and end of each frame is a flag byte consisting
of the special bit pattern 01111110. Whenever the sender's data link layer encounters five consecutive 1s
in the data, it automatically stuffs a zero bit into the outgoing bit stream. This technique is called bit
stuffing
Physical layer coding violations
The final framing method is physical layer coding violations and is applicable to networks in which the
encoding on the physical medium contains some redundancy. In such cases normally, a 1 bit is a high-low
pair and a 0 bit is a low-high pair. The combinations of low-low and high-high which are not used for data
may be used for marking frame boundaries.
To ensure reliable communication, there needs to exist flow control (managing the amount of data the
sender sends), and error control (that data arrives at the destination error free).
• Flow and error control needs to be done at several layers.
• For node-to-node links, flow and error control is carried out in the data-link layer.
Page no: 2 Get real-time updates from RGPV
Downloaded from www.rgpvnotes.in
• For end-point to end-point, flow and error control is carried out in the transport layer.
There may be three types of errors:
Problem with Stop-And-Wait protocol is that it is very inefficient. At any one moment, only in frame is in
transition. The sender will have to wait at least one round trip time before sending next. The waiting can
be long for a slow network such as satellite link.
Stop and Wait Protocol
Characteristics
• Used in Connection-oriented communication.
• It offers error and flow control
• It is used in Data Link and Transport Layers
• Stop and Wait ARQ mainly implements Sliding Window Protocol concept with Window Size 1
Useful Terms:
• Propagation Delay: Amount of time taken by a packet to make a physical journey from one router to
another router.
Propagation Delay = (Distance between routers) / (Velocity of propagation)
• RoundTripTime (RTT) = 2* Propagation Delay
• TimeOut (TO) = 2* RTT
• Time To Live (TTL) = 2* TimeOut. (Maximum TTL is 180 seconds)
3. Delayed Acknowledgement:
This is resolved by introducing sequence number for acknowledgement also.
Page no: 5 Get real-time updates from RGPV
Downloaded from www.rgpvnotes.in
HYBRID ARQ
The HARQ is the use of conventional ARQ along with an Error Correction technique called 'Soft Combining',
which no longer discards the received bad data (with error).
With the 'Soft Combining' data packets that are not properly decoded are not discarded anymore. The
received signal is stored in a 'buffer', and will be combined with next retransmission.
That is, two or more packets received each one with insufficient SNR to allow individual decoding can be
combined in such a way that the total signal can be decoded!
The following image explains this procedure. The transmitter sends a package [1]. The package [1] arrives,
and is 'OK'. If the package [1] is 'OK' then the receiver sends an 'ACK'.
In our example, we see that the package arrived 2 times 'wrong'. And what is the limit of these
retransmissions? Up to 4. IE, we can have up to 4 retransmissions in each process. This is the maximum
number supported by 'buffer'.
SDLC identifies two types of network nodes: primary and secondary. Primary nodes control the operation
of other stations, called secondary. The primary polls the secondary in a predetermined order and
secondary can then transmit if they have outgoing data. The primary also sets up and tears down links and
manages the link while it is operational. Secondary nodes are controlled by a primary, which means that
secondary can send information to the primary only if the primary grants permission.
1. Information (I) frame: Carries upper-layer information and some control information. This
frame sends and receives sequence numbers, and the poll final (P/F) bit performs flow and
error control. The send-sequence number refers to the number of the frame to be sent next.
The receive-sequence number provides the number of the frame to be received next. Both
sender and receiver maintain send- and receive-sequence numbers.
A primary station uses the P/F bit to tell the secondary whether it requires an immediate
response. A secondary station uses the P/F bit to tell the primary whether the current frame is
the last in its current response.
2. Supervisory (S) frame: Provides control information. An S frame can request and suspend
transmission, reports on status, and acknowledge receipt of I frames. S frames do not have an
information field.
3. Unnumbered (U) frame: Supports control purposes and is not sequenced. A U frame can be
used to initialize secondary. Depending on the function of the U frame, its control field is 1 or 2
bytes. Some U frames have an information field.
• Data---Contains path information unit (PIU) or exchange identification (XID) information.
• Frame Check Sequence (FCS) ---Precedes the ending flag delimiter and is usually a cyclic
redundancy check (CRC) calculation remainder. The CRC calculation is redone in the receiver. If the
result differs from the value in the original frame, an error is assumed.
HDLC
High-Level Data Link Control (HDLC) is a bit-oriented code-transparent synchronous data link layer
protocol. HDLC provides both connection-oriented and connectionless service. HDLC can be used for point
to multipoint connections, but is now used almost exclusively to connect one device to another, using what
is known as Asynchronous Balanced Mode (ABM). The original master-slave modes Normal Response
Mode (NRM) and Asynchronous Response Mode (ARM) are rarely used.
FRAMING
HDLC frames can be transmitted over synchronous or asynchronous serial communication links. Those links
have no mechanism to mark the beginning or end of a frame, so the beginning and end of each frame has
to be identified. This is done by using a frame delimiter, or flag, which is a unique sequence of bits that is
guaranteed not to be seen inside a frame. This sequence is '01111110', or, in hexadecimal notation, 0x7E.
Each frame begins and ends with a frame delimiter. A frame delimiter at the end of a frame may also mark
the start of the next frame. A sequence of 7 or more consecutive 1-bits within a frame will cause the frame
to be aborted.
When no frames are being transmitted on a simplex or full-duplex synchronous link, a frame delimiter is
continuously transmitted on the link. Using the standard NRZI encoding from bits to line levels (0 bit =
transition, 1 bit = no transition), this generates one of two continuous waveforms, depending on the initial
state:
8 bits 8 or more bits 8 or 16 bits Variable length, 0 or more bits 16 or 32 bits 8 bits
BISYNC
Binary Synchronous Communication (BSC or Bisync) is an IBM character-oriented, half duplex link protocol,
announced in 1967 after the introduction of System/360. It replaced the synchronous transmit-receive
(STR) protocol used with second generation computers. The intent was that common link management
rules could be used with three different character encodings for messages. Six-bit Transcode looked
backwards to older systems.
BISYNC establishes rules for transmitting binary-coded data between a terminal and a host computer's
BISYNC port. While BISYNC is a half-duplex protocol, it will synchronize in both directions on a full-duplex
channel. BISYNC supports both point-to-point (over leased or dial-up lines) and multipoint transmissions.
Each message must be acknowledged, adding to its overhead.
BISYNC is character oriented, meaning that groups of bits (bytes) are the main elements of transmission,
rather than a stream of bits. The BISYNC frame is pictured next. It starts with two sync characters that the
receiver and transmitter use for synchronizing. This is followed by a start of header (SOH) command, and
then the header. Following this are the start of text (STX) command and the text. Finally, an end of text
(EOT) command and a cyclic redundancy check (CRC) end the frame. The CRC provides error detection and
correction.
Use free search: [give notes and place diagram in between topics on the following The data link layer:
Design issues & function, Error detection & correction, Forward error
correction Versus Retransmission, Hamming code & CRC codes, Framing: Fixed size and
Variable size Frame, Bit stuffing and Byte stuffing. Data link layer protocols:
Simplest, Stop and Wait, Sliding window protocols, PPP, SLIP, HDLC. The medium
access sublayer: Static and Dynamic Channel Allocation, Protocols: ALOHA Protocol,
CSMA (CSMA/CD, CSMA/CA), Collision Free Protocol- Bit