Title: Error Correction
1Error Correction
- Retransmission
- simplest, most effective
- least expensive, most common
- Automatic Repeat reQuest (ARQ)
- Stop and Wait ARQ
- Continuous ARQ
2Error Correction
- Stop and Wait ARQ - sender stops and waits for a
response from the receiver - ACK - acknowledgment - no errors detected
- NAK - negative acknowledgment - message contained
an error
3Error Correction
- Continuous ARQ - sender continues with
transmission and examines return acknowledgments
at the same time - called sliding window
- LAP-M retransmit only those packets with errors
- Go-Back-N ARQ - retransmit from point of error
4Continuous ARQ (sliding window)
Transmitter
Receiver
Go-Back-N ARQ
MSG0
MSG3
MSG2
MSG1
NAK2
MSG4
MSG3
MSG2
MSG5
LAP-N ARQ (Link Access Protocol for Modems)
MSG0
MSG3
MSG2
MSG1
NAK2
MSG5
MSG6
MSG2
MSG4
5Forward Error Correction
- Uses codes containing sufficient redundancy to
prevent errors without retransmission - Essential for satellite transmissions, where
propagation delay is significant - V.34 modem standard includes forward error
checking
6Forward Error Correction
- Example techniques include
- Hagelbarger code - corrects up to six consecutive
bit errors provided at least 19 valid bits follow - Bose-Chaudhuri code - capable of correcting
double errors and detect up to four errors - Hamming code - associates even parity bits with
unique combinations of data bits - Reed-Solomon technique - more sophisticated
technique
7Hamming Code
D3
P2
P1
D7
D6
D5
P4
Data to be sent D3D5D6D7 1010
1
1
0
0
0
1
1
8Forward Error Correction
- Used with CD/ROM disk and audio compact disk
technology - Data is encoded as a series of microscopic pits
and flat spaces that are read by laser - This medium is very prone to errors - once data
is stored, there is no way to correct it - Forward error correction is used to correct the
stored errors when reading the CD
9Forward Error Correction
- Used in main RAM memory
- Alpha particles in the plastic encasement of
memory chips cause soft errors - RAM memory actually contains more than their
advertised amount in order to provide extra bits
for forward error checking - Without this capability, PCs would not be
reliable enough for general acceptance
1 MB 220 bytes 8,388,608 bits 16 MB
134,217,728 bits The MTBF, due to soft error,
for such a RAM memory, would be 1 million
years 2.7 days 134,217,728
10Data Link Layer Protocols
- Focused on message delineation
- indicates where the message starts and stops
- and the parts of the message transmitted
- needed to determine which part of the message is
the error control portion
11Data Link Protocols
- Asynchronous Transmission
- Often called start-stop transmission because
the sending device can transmit a character
whenever convenient - A start and stop bit are appended to each
character sent - Typically used on point-to-point full duplex
circuits
12Data Link Protocols
- Asynchronous File Transfer Protocols
- XMODEM - takes the data being transmitted and
divides it into blocks - uses stop and wait ARQ - YMODEM - CRC-16 error checking - multiple file
transfer capability - ZMODEM - CRC-32 error checking - dynamically
adjusts its packet size according to
communication circuit conditions - KERMIT - CRC-24 error checking, flexible, can be
adjusted to support a variety of different packet
sizes
13Asynchronous FTP
XMODEM FORMAT
SOH STX Checksum 1 byte
1 byte 1 byte
Message 128 bytes
Packet (block) 1 byte
14Asynchronous FTP
- KERMIT
- Very popular protocol developed by Columbia
University - Flexible - can be adjusted during transmission
- 1000 byte packets with CRC-24
- Uses either stop-and-wait or continuous ARQ
15Data Link Protocols
- Synchronous Transmission
- Used for high-speed transmission of a block of
data (frame or packet) - Start/stop bits are NOT required
- Synchronization established by sending a group of
SYN characters
16Synchronous Transmission
- There are many protocols for synchronous
transmission that fall into three broad
categories - Byte-oriented
- Bit-oriented
- Byte-count
17Data Link Protocols
- Synchronous Transmission
- Binary Synchronous Communication (BSC)
- mainframe protocol developed by IBM in 1967
- byte-oriented protocol
- Synchronous Data Link Control (SDLC)
- mainframe protocol developed by IBM in 1972
- bit-oriented protocol
- control fields and data do not have to be in
8-bit bytes
Start Flag 01111110 8 bits
Control 8 bits
Frame check SEQ
16 or 32 bits
End Flag 01111110 8 bits
Address 8 bits
Message (variable length)
18Synchronous Transmission
- High-level Data Link Control (HDLC)
- developed by the International Organization for
Standardization (ISO) - similar to SDLC except the address and control
fields are longer - LAP-B (Link Access Procedure-Balanced) is a
scaled down version of HDLC - benefits are beyond the scope of this class
19Synchronous Transmission
- Token Ring (IEEE 802.5)
- developed by IBM in early 1980s
- LAN protocol
- supports transparency automatically
- byte-orientated protocol
- frame - starts and ends with a special electrical
signal
20Synchronous Transmission
- Ethernet (IEEE 802.3)
- developed by Digital, Intel, and Xerox in 1970s
- LAN protocol
- byte-count protocol
- supports transparency automatically
- includes a field that specifies the length of the
message portion of the packet - uses a contention media access protocol
21Synchronous Transmission
Token Ring format
Start Frame Destination
Source Message End
delimiter control address
address variable
delimiter 1 byte 1 byte 6
bytes 6 bytes max of 4500
1 byte
Access Frame control check
sequence1 byte 4 bytes
Ethernet format
Destination Source Length
Message CRC-32 address
address 2 bytes
variable 4 bytes 6 bytes
6 bytes
max of 1492
22Synchronous Transmission
- Serial Line Internet Protocol (SLIP)
- byte-oriented protocol developed in 1980s
- one of two widely used protocols to connect a
client computer to an ISP - uses TCP/IP
- designed for point-to-point telephone connections
- Problems
- no error control
- transparency is an issue
End 11000000 1 byte
End 11000000 1 byte
Message (variable)
23Synchronous Transmission
- Point-to-Point Protocol (PPP)
- byte-oriented protocol developed in the early
1990s to replace SLIP - better because it includes error control
- supports network protocols beyond the Internet
protocols - transparency is still a problem
Flag 01111110 1 byte
Flag 01111110 1 byte
Control 1 byte
Message (variable) max 1500 bytes
Address 1 byte
Protocol 2 bytes
CRC-16 2 bytes
24Data Link Protocol
- Isochronous Transmission
- Combines the elements of both synchronous and
asynchronous data transmission - required to have a start and stop bit
- sender and receiver are synchronized
- data can be transmitted at higher speeds
25Transmission Efficiency
- The number of bits of user information divided by
the total bits sent - BI
- EC
- BT
- where
- EC efficiency of the code
- BI number of bits of user information
- BT number of total bits transmitted
- (user information overhead)
26Transmission Efficiency
- Asynchronous Transmission
- 7-bit ASCII characters
- assuming 1 parity bit
- 1 start bit and 1 stop bit
- BI 7 7
- EC (70)
- BT 7 1 2 10
27Transmission Efficiency
- Synchronous Transmission
- 8-bit EBCDIC characters
- assuming 100 character frame of information
- 32-bit frame check sequence
- 8-bits start and end flag
- 8-bits address
- 8-bits control
- BI 800 800
- EC (92.6)
- BT 800 64 864
28Transmission Efficiency
What is the best packet size for synchronous
transmission?
- Why is the efficiency low for very small
packets? - Why is the efficiency low for very large
packets?
29Transmission Efficiency
- Throughput is the total number of information
bits received per second, after taking into
account the overhead bits and the need to
retransmit packets containing errors - Transmission Rate of Information Bits (TRIB)
describes the effective rate of data transfer
30Throughput (TRIB)
- Measures the effective rate at which information
is transmitted over a link per unit of time - ANSI provides the basic definition for
calculating TRIB - Divide the number of information bits transferred
by the total time required for the transfer - number of information bits transferred
- TRIB
- total transfer time
31Throughput (TRIB)
TRIB number of information bits accepted
total transfer time TRIB K(M - C)(1 - P)
M R where K information bits per
character M block length in characters R
modem transmission rate in characters per
second C average of non-information bits
per block P probability that a block will
require retrans because of error T time
between blocks in seconds
T
32Throughput (TRIB)
- The following TRIB example shows the calculation
of throughput assuming a 4800 bits per second
half-duplex circuit. - 7(400-10)(1-0.01)
- (400/600) 0.025
- where K 7 bits per character (information)
- M 400 characters per block
- R 600 characters per second (derived from
4800 bps - divided by 8 bits/character)
- C 10 control characters per block
- P 0.01 (10-2) or one retransmission out of
100 blocks - transmitted 1
- T 25 milliseconds (0.025) turnaround time
TRIB 3908 bits per second
33Throughput (TRIB)
- 7(400-10)(1-0.01)
- (400/600) 0
- If all factors in the calculation remain constant
except for the circuit, which is changed into
full duplex (no turnaround time delays, T0) then
the TRIB increases to 4054 bps. - Look at the equation where the turnaround value
(T) is 0.025. If there is a further propagation
delay time of 475 milliseconds (0.475), this
figure changes to 0.500. For demonstrating how a
satellite channel affects TRIB, the total delay
time is now 500 milliseconds. Still using the
figures above (except for the new 0.500 delay
time), we reduce the TRIB for our half-duplex,
satellite link to 2317 bps, which is almost
one-half for the full-duplex (no turnaround time)
4054 bps.
TRIB 4054 bits per second
34Throughput (TRIB)
- 7(200-15)(1-0.02)
- (200/1200) 0.030
- Consider a 9600 bps half-duplex circuit in which
ASCII characters are sent with one parity bit for
each character. Assume 200 characters per block
of which 15 are for control, ther is a 2 error
probability, and a 30 millisecond turnaround
time.
TRIB 6440 bits per second