edited by
9,942 views
26 votes
26 votes

In a data link protocol, the frame delimiter flag is given by $0111$. Assuming that bit stuffing is employed, the transmitter sends the data sequence $01110110$ as

  1. $01101011$
  2. $011010110$
  3. $011101100$
  4. $0110101100$
edited by

3 Answers

Best answer
45 votes
45 votes

The answer will be option D.

The bit stuffing is done after every two $‘11\text{'} ($as the flag is $0111)$ to differentiate the data part from the flag- there must not be $``111"$ in the data so after every $11$ a $‘0\text{'}$ is added. The receiver also knows this and so, it decodes every $``110"$ as $``11".$ Therefore, option D is the answer.

edited by
10 votes
10 votes
In the above question, if, in the data link layer bits stuffing is employed
then bit stuffing is done using the flag delimiter. If there is a flag
of n bits then we will compare the data sequence with the flag and for every
n-1 bits matched found, a bit 0 is stuffed in the data sequence after the matched
sequence.
Thus using the above logic
Delimiter flag: 0111
Data sequence: 01110110
So, for a flag of 4 bits we will compare data sequence with pattern of
3 bits i.e. 011.
0 1 1 0 1 0 1 1 0 0
In the above pattern the underlined bits are found matched, hence, 0 in italics
is stuffed. Thus resulting in the data sequence as 0110101100 which is option D

http://www.geeksforgeeks.org/gate-gate-it-2004-question-80/
0 votes
0 votes

Answer is D.

Explanation:

For differentiating that we have send the data not the delimiter in betwen we use a 0, process being called stuffing.

Our data that needed to be send = 01110110

Delimiter pattern = 0111

so in our data 0 1 1 “a Zero is stuffed” 1 0 1 1 0

therefore data will be modified as  011010110

but when this data will be send to receiver it will generate problems.

 

Here’s how:

Receiver will read data from left to right as

0 1 1 (Oh the sender stuffed this 0) [cause receiver also knows about the delimiter pattern]

so it will remove the stuffed zero.

next,

0 1 1 1 0 1 1 (Oh this zero must be also added by the sender to remove the delimiter pattern, it must be removed.)

and therefore it will be left with 0111011 

But was this the original data? no!

Therefore an extra 0 will be added to the data to preserve the data.

 

now, the data that will be send should be 0110101100

 

and now the receiver will read the data as

0 1 1 (this zero is stuffed therefore should be removed) 1 0 1 1 (this zero is stuffed therefore should be removed) 0

 

and hence the data will be 0 1 1 1 0 1 1 0 

Answer:

Related questions

24 votes
24 votes
6 answers
3
Ishrat Jahan asked Nov 2, 2014
6,154 views
In the TCP/IP protocol suite, which one of the following is NOT part of the IP header?Fragment OffsetSource IP addressDestination IP addressDestination port number