Download Flow and Error Control I-Basic Data Communication Systems-Lecture Slides and more Slides Digital Systems Design in PDF only on Docsity!
Flow and Error Control
11-1^ FRAMING^ The data link layer needs to pack bits into frames, sothat each frame is distinguishable from another. Ourpostal system practices a type of framing. The simpleact of inserting a letter into an envelope separates onepiece of information from another; the envelope servesas the delimiter.
Figure 11.2^ Byte stuffing and unstuffing
Note Byte stuffing is the process of adding 1extra byte whenever there is a flag orescape character in the text.
Note Bit stuffing is the process of adding oneextra 0 whenever five consecutive 1sfollow a 0 in the data, so that thereceiver does not mistakethe pattern 0111110 for a flag.
Figure 11.4^ Bit stuffing and unstuffing
Note Flow control refers to a set of proceduresused to restrict the amount of datathat the sender can send beforewaiting for acknowledgment.
Note Error control in the data link layer isbased on automatic repeat request,which is the retransmission of data.
Figure^ Taxonomy of protocols discussed in this chapter
NOISELESS CHANNELS Let us first assume we have an ideal channel in whichno^ frames^ are^ lost,^ duplicated,
or^ corrupted.^ We introduce two protocols for this type of channel. Topics discussed in this section: Simplest ProtocolStop-and-Wait Protocol
Figure 11.7 shows an example of communication usingthis^ protocol.^ It^ is^ very
simple.^ The^ sender^ sends
a sequence^ of^ frames^ without
even^ thinking^ about^ the
Example 11.1 receiver. To send three frames, three events occur at thesender site and three events at the receiver site. Note thatthe data frames are shown by tilted boxes; the height ofthe box defines the transmission time difference betweenthe first bit and the last bit in the frame.
Example 11.2Figure 11.9 shows an example of communication usingthis protocol. It is still very simple. The sender sends oneframe and waits for feedback from the receiver. When theACK arrives, the sender sends the next frame. Note thatsending two frames in the protocol involves the sender infour events and the receiver in two events.
- Figure 11.7 Flow diagram for Example 11.
- Figure 11.9 Flow diagram for Example 11.