Data Communication Sample Tutorial& Answer
Data Communication Sample Tutorial& Answer
Data Communications
ECE 4111
(3 marks)
Protocols are needed since they provide a set of rules that govern data
communication. A protocol defines what is communicated, in what way and when.
This provides accurate and timely transfer of information between different
devices on a network.
(b)
For each of the following four networks, discuss the consequences if a connection
fails.
i.
Five devices arranged in a mesh topology
(1 marks)
ii.
Five devices arranged in a star topology (not counting the hub) (1 marks)
iii.
Five devices arranged in a bus topology
(1 marks)
iv.
Five devices arranged in a ring topology
(1 marks)
i.
ii.
iii.
iv.
(c)
Mesh topology: If one connection fails, the other connections will still be
working.
Star topology: The other devices will still be able to send data through the
hub; there will be no access to the device which has the failed connection
to the hub.
Bus Topology: All transmission stops if the failure is in the bus. If the
drop-line fails, only the corresponding device cannot operate.
Ring Topology: The failed connection may disable the whole network
unless it is a dual ring or there is a by-pass mechanism.
Find the 8-bit data stream for each case shown in Fig. 1.
(8 marks)
Data Communications
ECE 4111
a. NZR-I code
c. AMI code
c. Manchester code
Fig. 1
The data stream can be found as
a. NRZ-I: 01110011
b. Differential Manchester: 10101110
c. AMI: 01100101
d. Manchester: 10110011
(for each case: 0.5 mark deduction for 1 bit error, for more errors (consider the
result totally wrong) deduct 2 marks)
(d)
Identify different layers of TCP/IP reference model and list at least 1 protocol
used in each layer excluding TCP and IP protocol.
(5 marks)
Layer #
5
4
3
Layer Name
Application
Transport
Network
Data link
Physical
Protocol used
HTTP, SMPT, FTP
UDP, SCTP
ICMP, IGMP, ARP,
BGP, OSPF, RIP
PPP, HDLC, Frame
Relay, ATM, DSL
EIA/TIA-232, V.24, V.35
Data Communications
ECE 4111
(b)
i.
ii.
(2 marks)
We need to use synchronous TDM and combine 20 digital sources, each of 100
Kbps. Each output slot carries 1 bit from each digital source, but one extra bit is
added to each frame for synchronization. Answer the following questions:
i.
What is the size of an output frame in bits?
(2 marks)
ii.
What is the output frame rate?
(2 marks)
iii.
What is the duration of an output frame?
(2 marks)
iv.
What is the output data rate?
(2 marks)
v.
What is the efficiency of the system (ratio of useful bits to the total bits).
(2 marks)
i.
ii.
iii.
iv.
v.
Each output frame carries 1 bit from each source plus one extra bit for
synchronization. Frame size = 20 1 + 1 = 21 bits.
Each frame carries 1 bit from each source. Frame rate = 100,000
frames/s.
Frame duration = 1 /(frame rate) = 1 /100,000 = 10 s.
Data rate = (100,000 frames/s) (21 bits/frame) = 2.1 Mbps
In each frame 20 bits out of 21 are useful. Efficiency = 20/21= 95%
Data Communications
ECE 4111
During the connection establishment, resources are allocated between the caller
and the callee. Generally, resources are frequency intervals in a Frequency
Division Multiplexing (FDM) scheme or more recently time slots in a Time
Division Multiplexing (TDM) scheme. The set of resources allocated for a
connection is called a circuit. A path is a sequence of links located between nodes
called switches. The path taken by data between its source and destination is
determined by the circuit on which it is flowing, and does not change during the
lifetime of the connection. The circuit is terminated when the connection is closed.
In circuit switching, resources remain allocated during the full length of a
communication, after a circuit is established and until the circuit is terminated
and the allocated resources are freed. Resources remain allocated even if no data
is flowing on a circuit, hereby wasting link capacity when a circuit does not carry
as much traffic as the allocation permits. This is a major issue since frequencies
(in FDM) or time slots (in TDM) are available in finite quantity on each link, and
establishing a circuit consumes one of these frequencies or slots on each link of
the circuit. As a result, establishing circuits for communications that carry less
traffic than allocation permits can lead to resource exhaustion and network
saturation, preventing further connections from being established. If no circuit
can be established between a sender and a receiver because of a lack of
resources, the connection is blocked.
Virtual circuit packet switching (VC-switching) is a packet switching technique
which merges datagram packet switching and circuit switching to extract both of
their advantages. VC-switching is a variation of datagram packet switching
where packets flow on so-called logical circuits for which no physical resources
like frequencies or time slots are allocated. Each packet carries a circuit
identifier which is local to a link and updated by each switch on the path of the
packet from its source to its destination. A virtual circuit is defined by the
sequence of the mappings between a link taken by packets and the circuit
identifier packets carry on this link. This sequence is set up at connection
establishment time and identifiers are reclaimed during the circuit termination.
There is a trade-off between connection establishment and forwarding time costs
that exists in circuit switching and datagram packet switching. In VC-switching,
routing is performed at circuit establishment time to keep packet forwarding fast.
Other advantages of VC-switching include the traffic engineering capability of
circuit switching, and the resources usage efficiency of datagram packet
switching. Nevertheless, a main issue of VC-Switched networks is the behavior on
a topology change. As opposed to Datagram Packet Switched networks which
automatically recompute routing tables on a topology change like a link failure,
in VC-switching all virtual circuits that pass through a failed link are interrupted.
Hence, rerouting in VC-switching relies on traffic engineering techniques.
(b)
Explain with proper diagram the steps needed to create a virtual circuit between
two computers assuming there are 3 switches in between.
(8 marks)
Data Communications
ECE 4111
VC setup request
(c)
VC setup acknowledgement
A sender needs to send the four data items 0x3456, OxABCC, 0x02BC, and
OxEEEE. Answer the following:
i.
Find the checksum at the sender site.
(3 marks)
ii.
Find the checksum at the receiver site if the second data item is changed to
OxABCE.
(3 marks)
Data Communications
ECE 4111
(4 marks)
Explain what is meant by the term data transparency and how it is achieved in
HDLC.
(4 marks)
HDLC is a data link protocol which uses a unique bit sequence to delimit the start
and end of each PDU transported by the data link layer service. In HDLC, frames
are delimited by a sequence of bits known as a "flag". The flag sequence is a
unique 8-bit sequence of the form 0111 1110. The way in which this is performed
is described in the text and diagrams which follow.
Data Communications
ECE 4111
The flags before and after an HDLC frame indicate the start and end of the frame
Transparency: The flag sequence must never occur within the content of a frame
otherwise it could be confused with an intentionally sent flag. A technique known
as 0-bit insertion or bit stuffing is used to prevent random data synthesising a
flag. The technique is said to make HDLC transparent, since any stream of bits
may be present between the open and closing flag of a frame. The transparency is
achieved by encoding the data by inserting a 0-bit after any sequence of 5
consecutive 1's within the payload, as shown,
(c)
Data is transmitted over a half-duplex radio link at a rate of 28.8 kbps using a
stop-and-wait ARQ strategy. Frames have a block length of 256 bytes of which 5
are non-information bytes. If the propagation delay is 1 ms and processing delays
and acknowledgement transmission time can be neglected, determine:
i.
The throughput in the absence of errors,
(2 marks)
4
ii.
The throughput in the presence of a bit error rate of 10
(4 marks)
Frame transmission time, t f =
256 8
= 0.071 sec = 71 msec
28.8 10 3
Data Communications
ECE 4111
(d)
An Ethernet MAC sublayer receives 3020 bytes of data from the upper layer.
i.
How many frames need to be generated and sent to carry the data? (3 marks)
What is the size of data in each frame and why?
(3 marks)
ii.
i.
The maximum data size in the Standard Ethernet is 1500 bytes. The data of 3020
bytes, therefore, must be split between three frames. The standard dictates that
the all frames must carry the maximum possible number of bytes (1500) except
the last; the last (third) frame then needs to carry only 20 bytes of data (it
requires padding).
ii.
ii.
Highlight the key functional differences of the categories that have been
identified in Q.5 (a) i.
(6 marks)
Data Communications
ECE 4111
(b)
10
(7 marks)
Data Communications
(c)
ECE 4111
In a CDMA/CD network with a data rate of 10 Mbps, the minimum frame size is
found to be 512 bits for the correct operation of the collision detection process.
What should be the minimum frame size if we increase the data rate to 100 Mbps?
(5 marks)
The relationship between the minimum frame size and the data rate can be found
as follows.
We know that
Tfr = (frame size) / (data rate) = 2 Tp = 2 distance / (propagation
speed)
or
(frame size) = [2 (distance) / (propagation speed)] (data rate)]
or
(frame size) = K (data rate)
This means that minimum frame size is proportional to the data rate (K is a constant). When the data rate is increased, the frame size must be increased in a network with a fixed length to continue the proper operation of the CSMA/CD. In
Example 12.5, we mentioned that the minimum frame size for a data rate of 10
Mbps is 512 bits. We calculate the minimum frame size based on the above proportionality relationship
Data rate = 10 Mbps minimum frame size = 512 bits
Data rate = 100 Mbps minimum frame size = 5120 bits
11
Data Communications
Q.6
(a)
ECE 4111
[20 marks]
According to IEEE specification bridges are required to use spanning tree
algorithm. What type of problem is solved by creating spanning tree in LAN
systems?
(2 marks)
A spanning tree is a graph in which there is no loop thus spanning tree algorithm
helps to create loop free network topology.
(b)
Find the Spanning tree for the system shown in Fig.1. Choose B1 as the root
bridge. You must demonstrate with diagrams the forwarding and the blocking
ports, after applying the spanning tree procedure.
(6 marks)
B1
1
LAN 1
LAN 2
1
3
B2
B4
B3
2
3
2
LAN 4
1
B5
LAN 3
LAN 7
2
LAN 6
LAN 5
2
1
B6
2
B7
12
Data Communications
ECE 4111
B1
1
LAN 1
LAN 2
1
3
B2
B4
B3
2
2
3
LAN 4
1
B5
LAN 3
LAN 7
2
LAN 6
LAN 5
2
1
B6
2
B7
(c)
(4 marks)
(d)
Compare and contrast X.25 with Frame Relay by identifying the limitations of
X.25 and highlighting the key features of Frame Relay
(8 marks)
13
Data Communications
ECE 4111
Limitations of X.25:
i.
X.25 has a low 64-kbps data rate. By the 1990s, there was a need for
higher data-rate WANs.
ii.
X.25 has extensive flow and error control at both the data link layer and
the network layer. This was so because X.25 was designed in the 1970s,
when the available transmission media were more prone to errors. Flow
and error control at both layers create a large overhead and slow down
transmissions. X.25 requires acknowledgments for both data link layer
frames and network layer packets that are sent between nodes and
between source and destination.
iii.
Originally X.25 was designed for private lise, not for the Internet. X.25
has its own network layer. This means that the user's data are encapsulated
in the network layer packets of X.25. The Internet, however, has its own
network layer, which means if the Internet wants to use X.25, the Internet
must deliver its network layer packet, called a datagram, to X.25 for
encapsulation in the X.25 packet. This doubles the overhead.
iii.
iv.
v.
vi.
Frame relay operates at a higher speed (1.544 Mbps and recently 44.376
Mbps) hence it can easily be used instead of a mesh of T-1 or T-3 lines.
Frame relay operates in physical and data link layers. Therefore it can
easily be used as a backbone network to provide services to protocols that
already have a network layer protocol, such as Internet.
Frame relay allows bursty data.
Frame relay allows a frame size of 9000 bytes, which can easily
accommodate all LAN frame sizes.
Frame relay is less expensive than other traditional WANs.
Frame relay has error detection at the data link layer only. There is no
flow control and error control (no retransmission policy). It was designed
this way to provide fast transmission capability for more reliable media
and for those protocols that have flow and error control at the higher
layers.
14