Tuesday, August 19, 2014

Foundations of Computer Networking chapter-2


Chapter 2 Physical      Layer


The physical layer is primarily concerned with physically transmitting data over some medium such as wire, optical fiber or electromagnetic. Usual concerns are: how far and how fast does the medium allow data transmission, how is data represented, and how efficiently is the medium utilized.

2.1 Theoretical Basis for Data Communication

Computers operate on binary data. To be transmitted over some physical medium, binary data are generally converted into electrical or optical signals.
  • Data - A binary 0 may be represented by a -12 volts and a binary 1 as +12 volts which the receiver of the data must interpret from voltage back to binary data. If the original signal transmitted becomes attenuated (e.g. lower voltage) or  distorted (i.e. misshapen) by characteristics of the medium or external interference the electrical signal may be misinterpreted by the receiver. A few of the factors limiting the distance and data rate of a medium are discussed below.

  • Capacitance - Wire and many other conductors act as capacitors, storing and releasing some of the energy over time rather than transmitting it instantaneously. The undesirable effect of capacitance on a signal is rounding and flattening, at high transmission rates the bits transmitted can run together by the time received. Capacitance generally increases as the length of the medium increases, placing an upper limit on the distance a signal can be transmitted. The figure at right shows cumulative capacitance, resistance and random noise effects on a square wave signal transmitted and received. 

  •  
  • Resistance - Electrical resistance is analogous to friction. Resistance consumes some portion of the power causing current to flow, converting the signal electrical energy into thermal energy or heat. Generally, the greater the length of the conductor, the greater the resistance and the more signal energy lost. This acts to limit communication distance as the power of the signal sent is dissipated and the signal attenuates. Amplifiers can compensate somewhat but amplify the signal and any noise. A repeater attempts to regenerate and transmit the original digital signal, in principal eliminating the noise.
     
  • Noise - Noise distorts the original signal and can be caused by external sources such as motors, signals on nearby wires or thermal noise (i.e. random electron movement), etc.
     
  • Amplitude - The height of a wave, usually represented on the y-axis. Represented by A.

    What is the maximum and minimum amplitude of the signal in the figure below?

  • Waves - Data communication depends upon energy carried from the sender to the receiver. The amplitude of the energy level can be varied over time to represent 0's and 1's in digital communication, forming a wave. A single sine wave with amplitude between 1 and -1 is given in figure at right.
  • period - The time required to complete one full cycle or wave. Represented by T.
     
    • What is the period of a wave with 1 full cycle observed in 2 seconds?
       
    • What is the period of a wave with 1000 full cycles observed in 2 seconds?

  • frequency - The number of waves that pass a point in a one second. Represented by f. Frequency is expressed in Hertz or waves per second (waves/second). The single wave in Figure 1 has a frequency of 1 Hz. if observed for 1 second. 3 waves passing a point in 1 second would have the frequency of 3/1=3 Hz., where 1/4 of a wave passing in one second (i.e. 1 wave passing in 4 seconds) would have the frequency of 1/4/1=.25 Hz. Frequency is then the reciprocal of the period T,
                  f = 1/T
    so a wave with period T=1/5 second has a frequency f=(1 wave) / (1/5 sec) = 5 waves / second = 5 Hz.
    • What is the frequency of a signal with waves having a period of 1/1000 sec. ?
  • What is the frequency of a wave that completes 1000 cycles in 2 seconds?
     
  • What is the frequency of a wave that completes 1 cycle in 2 seconds?
  • Fundamental frequency - The lowest frequency component of a signal. Signals often consist of multiples of the fundamental frequency. The somewhat square wave of Figure 4 below is made up of the summation of the waves in Figures 1, 2, and 3.
    Suppose that the frequency of Figure 1 is 10 Hz.

    • The frequency of Figure 2 is 3 times Figure 1 or 30 Hz., and the frequency of Figure 3 is 5 times Figure 1 or 50 Hz.
  • Figures 2 and 3 are multiples of the Figure 1 frequency, Figure 4 the summation of Figures 1+2+3.
     
  • The fundamental frequency is that of Figure 1 or 10 Hz.
  • What must be the fundamental frequency if Figure 2 is 90 Hz?
  • Harmonics - Multiple of the fundamental frequency. Figure 2 is 3 times the fundamental frequency of Figure 1 so is the 3rd harmonic. Figure 3 is 5 times so is the 5th harmonic. Also known as an overtone.
  • If Figure 1 is 50 Hz, what is the frequency of the 2nd harmonic?
  • Of the 100th harmonic?

2.1.1 Fourier Analysis

The key insight to draw from this section is that a reasonably behaved periodic wave, such as a square wave used in digital communication, can be approximated by summing a number of sine and cosine waves of different frequencies and amplitudes. Jean-Bapiste Fourier developed the method given in the text for computing the appropriate amplitudes and frequencies of the individual waves that change over time.
To see how this method works we'll start with Figure 1, the fundamental frequency having a period of 1/10 second. By adding sine waves to produce:
Figure 4 = Figure 1 + Figure 2 + Figure 3
where
Figure 1:    f1=10 Hz., A1=1
Figure 2:    f2=30 Hz., A2=0.3
Figure 3:    f3=50 Hz., A3=.2
we produce a reasonable approximation of a square wave in Figure 4. By adding more, higher frequency sine waves, the approximation more closely resembles a square wave. In general, the periodic sine function examined here can be expressed as the infinite series:
A1 sin(t) + A2 sin(3t) + A3 sin(5t) + A4 sin(7t) + ....
where t= time and A=amplitude; adding higher frequencies produce a better approximation of a square wave. Note that the general case stated in the text is required for the analysis of any given wave. Here we are approximating a square wave by combining higher frequency waves that are multiples of the fundamental frequency but at a lower amplitude
Figure 1  10 Hz.

Figure 2  30 Hz.

Figure 3  50 Hz.

Figure 4 = Figure 1 + Figure 2 + Figure 3

Exercise

  • If using IE, run an Excel spreadsheet to test the theory. 
  • Click View | Toolbars | Chart.
  • Column A = 0..6 pi or 3 complete cycles.
  • Graph columns:
    • B=sin(A) or 3 sine waves of amplitude -1..1.
    • C=1/3*sin(A*3) or 9 sine waves of amplitude -1/3..1/3
    • D=1/5*sin(A*5) or 15 sine waves of amplitude -1/5..1/5
    • E = B+C+D
Practical application of Fourier analysis
There is a practical observation for us from Fourier's result. Due to capacitance and resistance the signal sent over a conductor degrades as distance increases, and the higher frequency signals are the most sensitive to distortion.
Because higher frequency waves travel slower than low frequency waves, the high frequency component of one data bit are eventually overtaken by the low frequency components of a later bit.
From the figures above, Fourier analysis shows us that as higher frequencies with lower amplitudes are added the resulting wave more closely approximates a square wave. Conversely, if higher frequencies are removed, the square wave signal degrades to look more like the fundamental frequency wave, not good news when sending a digital signal that must approximate a square wave. 
The following illustrates in (a) the ideal digital signal sent, (b) the fundamental or first harmonic, and progressively better approximations by adding additional, higher frequency and lower amplitude signals.

2.1.2 Bandwidth-Limited Signals

  • Bit-rate - The number of transmitted bits per second (bps)

    What is a common bits per second rate of a telephone modem? a cable modem?
  • Encoding - Data must be encoded for transmission. For example, one bit (0 or 1) can be sent using two voltage levels (-12 and +12 in RS-232). Two bits (00, 01, 10, or 11) can be sent at a time using four voltage levels, three bits using eight voltage levels, eight bits using 256 voltage levels, in general n bits can be sent at a time using 2n levels of encoding. Because of signal degradation due to noise, resistance, capacitance, etc., it is difficult to reliably discern small changes in signals.
Consider the figure at right where two voltage levels are encoded for binary 0 = -12v and 1 = +12v versus four voltage levels where binary 00 = 0v, 01 = 2v, 10 = 4v, and 11 = 6v. In the same time period the four voltage level encoding transmits twice the number of bits, 0001101100 versus 01010 using the two level encoding.
What is 25?
How many levels of encoding are needed to encode 5 bits?
Baud - The number of changes in a data signal per second. A four-level encoding yields two bits per voltage change at a baud rate of 100 (100 signal changes per second) gives a bit per second (bps) rate of 200. Using two-level encoding, the baud rate and the bits per second are the same since each change yields one bit of data.

How many voltage levels are required to send 8 bits per baud?
How many bits could be sent per baud using an 32 level encoding scheme? 
A 256 level encoding yields 8 bits per baud. What is the bit rate at 100 baud?

It is common for data signals to only transmit 1 bit per baud. Why not transmit at the much higher rate of 8 bits per baud and send 8 times bits per second?

  • Voice grade line - Telephone lines generally are artificially limited  to 3000 Hz. by a low-pass filter that only passes lower frequency signals. This helps to remove high frequency distortion from the signal but limits the data rate possible.
Problem - How successful would you expect to be able to transmit data over a voice grade phone line? Consider sending 8 bits at b bps. The table below illustrates the practical relation that as the data rate increases demanding higher frequency signal components, the number of harmonics sent decreases, which we have seen degrades the signal fidelity.
  • T = time to send 8 bits = 8 bits / b bits/sec. = 8 / b sec. At 10 bps, T = (8 / 10) sec. = 0.8 sec.
  • f  = 1/T = 1/8/b sec. = b/8 Hz.= fundamental frequency = first harmonic. 8 bits at 10 bps, f  = 1/0.8 sec. = 1.25 Hz.
  • Highest harmonic = 3000/b/8 = 3000/f since 3000 Hz. is the highest frequency passed through the telephone filter. 8 bits at 10 bps, the highest harmonic = 3000 Hz. / 1.25 Hz. = 2400 harmonic.
Relation between data rate and harmonics
Bps T First Harmonic (f Hz=1/T) # Harmonics Sent
10  .8 sec.  1/0.8 sec. = 1.25 Hz.  3000 Hz./ 1.25 Hz. = 2400
100  .08 sec.  1/0.08 sec. = 12.5  Hz.  3000 Hz./12.5 Hz. = 240
1000  .008 sec.  1/0.008 sec. = 125 Hz. 3000 Hz./125 Hz. = 24
10000 .0008 sec.  1/0.0008 sec. = 1250 Hz. 3000 Hz./1250 Hz. = 2
For example, to send 8 bits at 100 bps, each bit occupies 0.01 seconds on the wire so that 8 bits are sent in T=0.08 seconds. The first harmonic is the lowest frequency wave with f = 1/T = 1/0.08 sec. = 12.5 Hz. Recall that 12.5 Hz. means that there are 12.5 cycles of the signal wave in 1 second. With a maximum signal bandwidth of 3000 Hz. the highest multiple (the harmonic) of the first harmonic is 3000 Hz./12.5 Hz. = 240. That implies that at 100 bps the 8 bits can be represented by waves with frequency components a multiple of 240 times the fundamental frequency. From the table, one should expect the square wave representing the 8 bits to transmit much more reliably sent at 100 bps than if sent at 1000 bps or 10000 bps.
2.1.3 The Maximum Data Rate of a Channel
  • Nyquist - Running a signal through a low-pass filter of bandwidth H removes noise at frequencies higher than H. The phone company limits the bandwidth of your connection to lower frequencies by using a low-pass filter. A signal of bandwidth H can be completely captured by taking 2H samples per second. Essentially that means that one must sample a 3000 Hz. signal 6000 time per second to accurately measure the signal. Sampling faster isn't useful but sampling slower than the Nyquist limit means that some changes in the signal will be missed and data lost.
  • Consider Figure 6 where the arrows indicate when sampling of the signal occurs. Assuming the data value changes at a frequency of H=3, examining the signal only 3 times per second misses the data completely. If the low voltage represented a 0 value, the sampling error of Figure 6 would indicate that 000 was transmitted rather than 010101. Figure 7 illustrates sampling faster than necessary, greater than 2H, sampling each data change multiple times but the data would be correctly sampled as 010101. Nyquist proved that sampling a H frequency signal at 2H was fast enough.
    Figure 6  Figure 7
    In general, for a signal of V encoding levels:
                maximum data rate = 2H log2 V bps
    Example:    A 3000 Hz. voice grade line with eight level encoding has:
    maximum data rate = (2 * 3000* log2 8) bps = (2 * 3000* log2 23) bps = 2*3000*3 bps = 18000 bps
  • What is the maximum data rate for a voice grade line with 32 level encoding?
     
  • What is the maximum data rate for a voice grade line with 2 level encoding?
     
  • What is the maximum data rate for a current modem over a voice grade line?
  • S/N Signal-to-noise ratio - The measure of thermal noise present as the ratio of signal power to noise power. For S=signal and N=noise, signal-to-noise ratio is S/N. Note that as N approaches S (S/N becomes small) the signal is difficult to distinguish from the noise, a large S/N is desirable.

  • Decibels - Unit in which signal-to-noise ratio quantity 10 log10 S/N is given. Large decibel measures are good news for data transmission. Example: For S=10000 and N=10
  • ; and S=100 and N=10.
        signal-to-noise ratio = 10 log10 S/N = 10 log10 10000/10 = 10 log10 103 = 30 dB
        signal-to-noise ratio = 10 log10 S/N = 10 log10 100/10 = 10 log10 101 = 10 dB

  • Shannon - Nyquist assumed a perfect channel having no noise,  a common assumption in carefully controlled environments (e.g. RS-232C, USB, etc.). For a channel with signal-to-noise of S/N and bandwidth H the theoretical maximum data rate is:

      • maximum bps = H log2 (1+S/N) bps

  • Effects of Noise - Electrical conductors are subject to thermal noise and external noise from electrical fields (motors, power wiring, etc.). Unfortunately, the noise is added to the data signal and can lead to errors by the receiver. In the below figure, what is received is the combined data transmitted and noise (i.e. Data + Noise). The receiver must sample the signal regularly to determine the received data value. When the received signal is a high voltage at the instant sampled, a 1 bit is recorded, if a low voltage sampled then a 0 bit is recorded. Two bits are in error due to the noise.

2.2 Transmission Media
2.2.2 Twisted Pair - The most common media used for local phone and local area networks. Consists of two copper wires twisted together in a specific pattern to reduce interaction between the signals (cross-talk) on nearby wires.
Signals on wires running in parallel at a close proximity tend to interact producing cross-talk, the twists reduce interference. Advantages of wire is low cost, ease of installation and connections, and relatively high data rates of 2 Mbps for up to several kilometers are possible. Limitations include low data rate for connecting networks over long distances and need for regenerating the original signal.
  • Category 3 - Consists of 4 twisted pairs (8 total wires) commonly used for phones and early LANs such as 10 Mbps Ethernet.
  • Category 5 - Similar to Category 3 but with more strategically placed twists to reduce cross-talk. Can be used for phones and LANs including 100Mbps Ethernet over short distances.
2.2.3 Baseband Coaxial Cable - Baseband systems support a single frequency and a single transmitter at a time. The cable consists of a copper core conductor wrapped in an insulator wrapped in a braided outer conductor covered by a protective plastic insulator. Commonly used for digital broadcast transmission for LAN (e.g. Ethernet). With better shielding has higher data rate over longer distance, up to 1 or 2 Gbps over 1 kilometer. Generally used in backbones to connect twisted-pair networks but recently being replaced by fiber optics. Somewhat more difficult to install than twisted pair because of cable stiffness.
2.2.4 Broadband Coaxial Cable - Broadband systems support multiple frequencies and multiple transmitters. Standard cable television cabling supports multiple stations. Similar to baseband coaxial cable but used for analog transmission. Has bandwidth of 300 Mhz over 100 kilometers since analog signaling of TV, etc. is much less critical than digital. The bandwidth can be divided in multiple channels with each channel used to carry a different transmission, data, television, telephone, etc. Transmitting digital data requires converting the digital signal to analog, transmitting, then converting back to digital. For data communications, one channel can be allocated for sending and another for receiving over same cable.
2.2.5 Fiber Optics - Fiber optics avoids the limitations of wire due to resistance and capacitance, is impervious to electrical noise, is smaller than wire, has nearly unlimited bandwidth potential. As the text points out, it is now possible to transmit data faster than a computer can generate data. Today at least, computation is somewhat slower than communication.
The system consists of three components: light source (an LED for lower cost, lower data rate, and shorter distance or semiconductor laser), the optical fiber, and the light detector. Refraction of light at the surface of the fiber transmits the light waves long distances with little loss. Though more expensive to install and purchase, it is the medium of choice for fixed connections of over a few meters long given its many other advantages over copper.
2.3 Wireless Transmission
l = wavelength, the distance between maxima or minima of two wave peaks. Usually given in meters.
f = frequency in Hertz
c = speed of light, slightly less than 3x108 mps.
lf = c
  • A 300 MHz wave is then about 1 meter long.
l = c/f = 3x108 meters per second/3x108 waves per second = 1 meter per wave.
  • A 3 MHz wave is then about 100 meters long.
l = c/f = 3x108 meters per second/3x106 waves per second = 100 meters per wave.
  • AM Radio - Uses frequencies around 106 Hz or 1 MHz.
  • FM Radio - Uses frequencies around 108 Hz or 100 MHz.
  • TV - Uses frequencies around 108 Hz-1010 Hz or 100 MHz to 10 GHz.
  • Coax - Uses frequencies around 105 Hz-109 Hz or 100 KHz to 1 GHz.
  • Twisted pair - Uses frequencies around 104 Hz-109 Hz or 10 KHz to 1GHz.
  • Fiber optics - Uses frequencies around 1014 Hz-1015 Hz or 100 THz to 1000 THz.

2.5 The Telephone System - Read the text pages 118-124, it is both entertaining and enlightening.
2.5.3 The Local Loop - Conductor generally is copper having the limitations of signal transmission examined earlier. Each instance of an impairment to a digital signal increases the likelihood that the transmitted data will be incorrectly received. Due to these problems it is unwise to send a wide range of frequencies, unfortunately digital signals are made up of square waves, which have been shown to consist of a low frequency fundamental wave and many higher frequency waves.
(a) DC signaling    (b) AC signaling
The major transmission problems associated with baseband (i.e. DC or sending discrete voltages to form a square wave representing a digital value) signaling at high speeds and long distances are:
  • Attenuation - Loss of energy as signal propagates outward from source. As we have seen, the amplitude of higher frequencies are smaller so the amount of loss affects higher frequencies more.
  • Delay distortion - Different signal frequency components travel at different speeds. As the signal propagates, higher frequency components travel more slowly than lower frequency so that high frequency components of one bit are overtaken by lower frequency components of later bits when transmitted long distances. The high frequency components of leading bits become mixed with the low frequency components of later bits.
  • Noise - Unwanted energy other than the transmission. Sources are thermal noise from the random movement of electrons in wire, cross talk between wires, spikes due to outside sources such as lightning, motors, lighting, broadcasts, etc.
Modems - Modulator/demodulator, accepts serial bit stream and produces a modulated carrier signal as output. The reverse occurs on the receiver, where a modulated carrier signal is converted into a bit stream.
  • Carrier wave - Modems avoid baseband (DC) problems of attenuation and delay distortion by use of (AC) a sinusoidal carrier wave, a continuous 1000-2000 Hz tone (heard on acoustical modems) on which data is transmitted by modulating the wave amplitude, frequency, and/or phase. More than one modulation method may be used at the same time. Changes occur only at specific intervals known to both the sender and receiver. The sine carrier wave would appear similar to (a) below.

  • Amplitude modulation - Two different voltage levels can represent 0 and 1, more voltage levels allow representing more bits per voltage change. (c) above illustrates the amplitude of a sine wave.
     
  • Frequency modulation - Two tones or frequencies are used to represent 0 and 1. (b) above illustrates how the frequency can be modulated where a low frequency might represent a 0 and a high frequency a 1 bit.
     
  • Phase modulation - Graphically, a horizontal shift of the carrier wave. (d) above illustrates how the phase can be modulated, a sine wave shifted by k degrees (recall sine 0 degrees is 0, sine 90 degrees is 1, sine 180 degrees is 0, sine 270 degree is -1). A shift of 90 and 270 degrees can be used to represent 0 and 1 respectively. No shift in the interval can indicate that the previous data is repeated. Four phase shifts can be used to send two bits per baud.
The figure below illustrates in (a) a sine wave shifted 0 degrees or starting at y=sine 0 = 0 and in (b) a shift of 90 degrees or starting at y=sine 90 = 1.

Figure 8. a) binary signal. b) Amplitude modulation. c) Frequency modulation. d) Phase modulation

An example of the types of modulation is given in Figure 8. The binary signal of Figure 8a, is modulated in the successive figures.
Amplitude - In Figure 8b, when the carrier wave frequency is present a 1 is transmitted, when no carrier a 0 is transmitted.
Frequency - In Figure 8c, a high frequency indicates a 1 while a low frequency is a 0.
Phase - In Figure 8d, the phase is shifted (part of the normal sine wave is missing) by a fixed number of degrees. Apparently, when the data is 0 a phase shift indicates the next data is a 1 or vice versa, and no shift is a continuation of the same bit value. A phase shift of 180 degrees is used when sending a 1 after a 0 and 315 degrees for 0 after a 1.
Figure 9. a) 3 bits/baud modulation. b) 4 bits/baud modulation.

Combined modulation - Figure 9a illustrates the use of two amplitude levels and four phase shifts giving a total of eight distinct modulation values; amplitude is the distance from the origin; phase the angle relative to the right horizontal axis. One possible encoding of the amplitude/phase modulation is given in the table below.
Figure 9b is a 4 bit/baud amplitude/phase modulation called QAM (Quadrature Amplitude Modulation) used to transmit 9600 bps over a 2400 baud capable line using 2 voltage levels and 12 phase shifts. Higher bit rates are possible by increasing the bits/baud rate if the modulations can be reliably distinguished.
Amplitude/Phase encoding of 
Figure 9a
Voltage Phase Binary
5 0 000
10 0 001
5 90 010
10 90 011
5 180 100
10 180 101
5 270 110
10 270 111
How many different encodings can be sent with a 4-level amplitude? Give example diagram.  How many bits per baud? 
With a 4-phase shift? Give example diagram.  How many bits per baud? 
Combining both? Give example diagram.  How many bits per baud?  Give a possible encoding table.
Figure 9c illustrates the amplitude and phase shifts of 3 bit per baud QAM encoding for 7200 bits per second at 2400 baud. For example, interval 2 has amplitude of A1 and phase shift of 90 degrees to send the 3 bits of 010 at each change or baud. At 2400 baud 7200 bps is sent. Interval 3 has a phase shift of 180 degrees and interval 8 a phase shift of 270 degrees.
Figure 9c

 
For interval 6: What is the phase shift? What is the amplitude?
For interval 7: What is the phase shift? What is the amplitude?

  • RS-232-C - A standard for low speed serial communications generally used for sending binary data to a modem. The specifications include the mechanical connection dimensions, number of pins (25), circuit definition (transmit, receive, request to send, ground, etc.), signal voltage level (+4 volts or greater is 0, -3 volts or less is 1, in between is undefined), data rates (up to 20,000 bps), and cable length (up to 15 meters). Higher data rates are possible over shorter distances.
2.5.4 Trunks and Multiplexing - Multiplexing in communications is the use of a single channel to carry multiple transmissions. The basic multiplexing categories are:
  • FDM - Frequency division multiplexing divides the frequency of a channel allowing multiple, simultaneous transmissions. If a channel has a bandwidth of 72 kHz., three 3000 Hz. transmissions could be carried by shifting the frequency of the first to occupy 60 kHz-63 kHz, the second to occupy 64 kHz-67 kHz, and the third to 68 kHz-71 kHz. The 1000 Hz. gap (guard band) between each reduces the probability of signal mixing. One weakness is the requirement for analog circuitry which requires signal amplification versus digital signaling which can be regenerated.

  • TDM - Time division multiplexing divides the time a transmitter has access to the channel. If a channel has a bandwidth of 3000 Hz., three 3000 Hz. transmissions could be carried, each occupying all of the channel bandwidth for 1/3 of the time. One TDM advantage is a fully digital implementation.

  • PCM - Pulse Code Modulation is a TDM method often used on phone trunk lines or to carry digital data point-to-point, a common implementation is the T1 carrier.

On the transmitting end of a T1, a codec (coder-encoder) samples the analog amplitude of 24 4000 Hz. voice lines each at 8000 samples per second (recall that the Nyquist theorem states that a a signal must be sampled at twice the signal frequency) or one sample every 1/8000=125 microseconds for each of the 24 lines. A total of 8000*24= 192000 samples per second are taken, converted from analog to a 7 bit digital value by the codec and one bit is added for signaling and the 8 bit number is transmitted (8 bits provides 256 different values with which to represent the transmitted voice digitally), for a total of 1,536,000 bps.
Figure 10 illustrates the format in which one group of 24 samples are transmitted 8000 times per second. In addition to the data bits an additional 8000 framing bits (one to separate each 24 sample group) is transmitted, giving a total gross transmission rate of 1,544,000 bps for a T1. At the receiving end, the 8 bit value is converted from digital to analog, and demultiplexed onto one of the 24 outgoing lines. Connecting computers over a T1 is fully digital data transmission and does not require the analog to digital and digital to analog conversion necessary for telephone conversations.
Figure 10 - T1 carrier (1.544 Mbps)

What is being sampled on a phone conversation?
Why sample a phone conversation at 8000 per second?

What is the maximum raw data rate of a single channel?

Assuming the input voltage range of the codec is -10 to 10 volts, what would be a reasonable 7-bit encoding for 10 volts? For -10 volts? For 0 volts?

  • Delta modulation - PCM sends 8 bits for each sample regardless of whether the sampled value changes. Delta modulation sends only one bit, indicating whether current sample is above or below the previous. While compact, as Figure 11 illustrates, when large changes occur in the sample delta modulation cannot keep up.
Figure 11 - Delta modulation

What is the likely effect of delta encoding on phone conversation when rapid volume changes occur?
Is this practical for data communications? Why or why not?
2.5.5 Switching -  Voice communication tends to be short duration but continuous. Computer communication tends to be bursty with long periods of no transmission.  Because of these differences, voice is often transmitted over a fixed, dedicated channel or circuit while data is normally transmitted in an occasional packet, as needed, over a temporary or shared channel. Figure 12 graphically illustrates the overall time required by three switching methods to transmit a message.
  • Circuit switching - Placing a phone call builds a physical path or circuit from your phone to the receiver's. When you hang up, the circuit is broken and intermediate channels are then available for other circuits to be built for other phone calls.
    • The circuit from sender to receiver is dedicated during the communication interval, so no intermediate storage is required.
    • However, the sender must wait for the circuit to the receiver to be constructed before transmission can start.
    • Delay is a function of the time required to acquire exclusive use of the channel.
  • Message switching - The communication channel is shared, with a message occupying the complete channel during transmission.
    • The entire message is sent at once to an intermediate switch so there is no wait for circuit construction all the way to the receiver.
    • However, the switch must be able to store and forward the entire message, placing an upper limit on the size of message that can be transmitted to the lowest switch capacity along the path.
    • Because a message occupies the complete channel during transmission, large messages can cause considerable delay for other users waiting to send messages.
    • Also, since errors occasionally occur and large messages are more likely to contain an error than small ones, handling errors by resending the message is potentially very costly.
  • Packet switching - The channel is again shared.
    • The message is broken up by the sender into smaller packets of a maximum size that can be handled by the intermediate switches.
    • The switch stores each packet and forwards to another switch along the way or to the receiver if directly connected.
    • Switches can receive and send packets simultaneously, unlike message switching which must receive the entire message before forwarding. This reduces the overall time required to receive the complete message since initial packets can be sent on the communications channel without waiting for the complete message.
    • When errors occur only the bad packet must be corrected (usually by resending) rather than the complete message.
    • Since the channel is shared, no one user has exclusive control, other users packets can be multiplexed onto the same channel, small packets reduce the delay for other users sharing the channel.
Figure 12 - Timing of events in a) circuit switching, b) message switching, c) packet switching

Crossbar switch - Used for circuit switching and conceptually simple, a crossbar switch consists of n intersecting input and output lines. At each intersection is a switch that can be closed to form the connection. Normally only one switch is closed in any row or column though closing all switches would broadcast all transmissions. For line 3 to connect to line 2 the switch at row 3, column 2 must be closed. If the connection is full duplex (both directions) there is no need to close the row 2 column 3 switch. In fact only half the switches as possible connections are required.  The main problem is that the number of connecting switches grows at roughly n2 or exponentially.
What are the connected station numbers?
What is the total number of switches needed for full interconnectivity when half-duplex is used? Full duplex?
Time division switches - Used for switching digital data channels such as a T1 that use time division multiplexing.
  • The connection table array holds 1 in position 2 for the connection from 1 to 2.
  • Received data is buffered in memory in order it arrives.
  • The buffer contents is then sent out in order specified in connection table with line 1 data going out in the 2 position, on line 2.
The array tables in TDSs grows linearly with the number of lines but are limited primarily by the access speed of memory used to store connection table and received data.
  • The data is accessed twice, it is stored when received and retrieved when sent, for PCM one frame arrives every 125 microseconds.
  • The time available to process a frame has an upper limit of 2nT = 125 microseconds where
    • n is the number of lines
    • T is the memory access time
    • n = 125/2T.
  • With memory access time of 70 nanoseconds
    • n=125*10-6/2*70*10-9=125/140*10-3 = 125/.14 <=  892 lines could be supported.
Assuming the diagram above is used for switching 4800 bps RS-232 communications of 10 bits per character, what is the memory access speed required? Hint: Consider 4 lines with 10 bits of new input arriving on each line 480 times per second. 
Narrowband ISDN - Integrated Services Digital Network is a fully digital, circuit switched phone system designed to provide end-to-end digital service, integrating voice and non-voice services. Voice services would be digital also, a digital phone might use PCM. Other services would be digital data communication for networking or connecting to other customer digital devices (alarms, imaging, etc.).
ISDN System Architecture - Current phone system is analog from customer to carrier office, ISDN would bring a digital bit pipe to most customers using the existing phone wire, an important financial consideration. The pipe supports multiple channels. The basic rate is two B channels (a 64  kbps channel similar to a single PCM voice channel that requires 8000 per second 8 bit samples) and one D channel (a 16 kbps channel for signaling: dial tone, dialing numbers, etc.). The basic rate is designed to replace the current analog system to homes. The primary rate is essentially a T1 line consisting of 23 B channels and 1 D channel, designed for businesses to connect digital PBX, networking, etc.
Broadband ISDN and ATM (Asynchronous Transfer Mode) - Broadband ISDN would increase the bandwidth over narrowband ISDN (to 156 Mbps) but require new local loop cabling (Category 5 or fiber) and use ATM (of packet switching rather than current circuit switching).
Virtual Circuits versus Circuit Switching - Broadband ISDN provides connection oriented service that is implemented internally using packet switching.
  • Circuit switching - A connection is physically established from sender to receiver and all transmissions follow that path. All transmissions have full use of the channel bandwidth for the duration of the connection.
  • Virtual circuit - Using virtual circuit network like ATM, a connection establishes a route through switches (routers) from sender to receiver and all transmissions will follow that same route. When packets arrive, the switches can immediately route the packet to the next switch on the route to the receiver. Note that once the connection is made by establishing the route, subsequent packets do not require source and destination addresses, a substantial savings for small ATM packets.
Transmission in ATM Networks - Contrast ATM with a T1 carrier.
  • T1 - Synchronous, one T1 frame generated every 125 microseconds governed by master clock. Each frame contains 24 one byte slots arranged in order (recall that this is a requirement for TDM switches). If a sender has no data, an empty byte is still sent. There is no overhead other than a framing bit.
  • ATM - Asynchronous, one ATM cell contains 53 bytes occurring in any order. If a sender has no data, a special idle cell is sent. The cell format is not standardized but is specified for different carriers such as T1, T3, SONET, etc. All links are point-to-point and unidirectional, for full-duplex two parallel links are needed.


No comments:

Post a Comment