


































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Digital data, digital signals: The simplest form of digital encoding of ... There is another set of coding techniques, grouped under the term biphase, that.
Typology: Lecture notes
1 / 42
This page cannot be seen from the preview
Don't miss anything!



































SIGNAL ENCODING TECHNIQUES
5.1 Digital Data, Digital Signals
5.2 Digital Data, Analog Signals
5.3 Analog Data, Digital Signals
5.4 Analog Data, Analog Signals
5.5 Recommended Reading
5.6 Key Terms, Review Questions, And Problems
Even the natives have difficulty mastering this peculiar vocabulary. — The Golden Bough , Sir James George Frazer
KEY POINTS
In Chapter 3 a distinction was made between analog and digital data and analog and digital signals. Figure 3.14 suggested that either form of data could be encoded into either form of signal. Figure 5.1 is another depiction that emphasizes the process involved. For digital signaling , a data source g ( t ), which may be either digital or analog, is encoded into a digital signal x ( t ).The actual form of x ( t ) depends on the encoding technique and is chosen to optimize use of the transmission medium. For exam- ple, the encoding may be chosen to conserve bandwidth or to minimize errors. The basis for analog signaling is a continuous constant-frequency signal known as the carrier signal. The frequency of the carrier signal is chosen to be compatible with the transmission medium being used. Data may be transmitted using a carrier signal by modulation. Modulation is the process of encoding
spectrum, can share the same transmission medium. This is known as frequency division multiplexing. We now examine the techniques involved in each of these four combinations.
5.1 DIGITAL DATA, DIGITAL SIGNALS
A digital signal is a sequence of discrete, discontinuous voltage pulses. Each pulse is a signal element. Binary data are transmitted by encoding each data bit into signal elements. In the simplest case, there is a one-to-one correspondence between bits and signal elements. An example is shown in Figure 3.16, in which binary 1 is repre- sented by a lower voltage level and binary 0 by a higher voltage level. We show in this section that a variety of other encoding schemes are also used. First, we define some terms. If the signal elements all have the same algebraic sign, that is, all positive or negative, then the signal is unipolar. In polar signaling, one logic state is represented by a positive voltage level, and the other by a negative voltage level. The data signaling rate , or just data rate , of a signal is the rate, in bits per second, that data are transmitted.The duration or length of a bit is the amount of time it takes for the transmitter to emit the bit; for a data rate R, the bit duration is 1/ R. The modulation rate , in contrast, is the rate at which the signal level is changed.This will depend on the nature of the digital encoding, as explained later. The modulation rate is expressed in baud, which means signal elements per second. Finally, the terms mark and space, for histori- cal reasons, refer to the binary digits 1 and 0, respectively. Table 5.1 summarizes key terms; these should be clearer when we see an example later in this section. The tasks involved in interpreting digital signals at the receiver can be summa- rized by again referring to Figure 3.16. First, the receiver must know the timing of each bit. That is, the receiver must know with some accuracy when a bit begins and ends. Second, the receiver must determine whether the signal level for each bit position is high (0) or low (1). In Figure 3.16, these tasks are performed by sampling each bit position in the middle of the interval and comparing the value to a thresh- old. Because of noise and other impairments, there will be errors, as shown. What factors determine how successful the receiver will be in interpreting the incoming signal? We saw in Chapter 3 that three factors are important: the
Table 5.1 Key Data Transmission Terms
Term Units Definition
Data element Bits A single binary one or zero Data rate Bits per second (bps) The rate at which data elements are transmitted Signal element Digital: a voltage pulse of That part of a signal that occupies the shortest constant amplitude interval of a signaling code Analog: a pulse of constant frequency, phase, and amplitude Signaling rate or Signal elements per second The rate at which signal modulation rate (baud) elements are transmitted
signal-to-noise ratio, the data rate, and the bandwidth. With other factors held constant, the following statements are true:
Table 5.2 Definition of Digital Signal Encoding Formats
Nonreturn to Zero-Level (NRZ-L)
Nonreturn to Zero Inverted (NRZI)
Bipolar-AMI
Pseudoternary
Manchester
Differential Manchester Always a transition in middle of interval
B8ZS Same as bipolar AMI, except that any string of eight zeros is replaced by a string with two code violations HDB Same as bipolar AMI, except that any string of four zeros is replaced by a string with one code violation
1 = no transition at beginning of interval
0 = transition at beginning of interval
1 = transition from low to high in middle of interval
0 = transition from high to low in middle of interval
1 = no line signal
0 = positive or negative level, alternating for successive zeros
1 = positive or negative level, alternating for successive ones
0 = no line signal
1 = transition at beginning of interval
0 = no transition at beginning of interval 1 one bit time 2
1 = low level
0 = high level
(^1) The BER is the most common measure of error performance on a data circuit and is defined as the probability that a bit is received in error. It is also called the bit error ratio. This latter term is clearer, because the term rate typically refers to some quantity that varies with time. Unfortunately, most books and standards documents refer to the R in BER as rate.
a separate clock lead to synchronize the transmitter and receiver. The alterna- tive is to provide some synchronization mechanism that is based on the trans- mitted signal. This can be achieved with suitable encoding, as explained subsequently.
- Error detection: We will discuss various error-detection techniques in Chapter 6 and show that these are the responsibility of a layer of logic above the signaling level that is known as data link control. However, it is useful to have some error detection capability built into the physical signaling encoding scheme. This per- mits errors to be detected more quickly. - Signal interference and noise immunity: Certain codes exhibit superior perform- ance in the presence of noise. Performance is usually expressed in terms of a BER. - Cost and complexity: Although digital logic continues to drop in price, this fac- tor should not be ignored. In particular, the higher the signaling rate to achieve a given data rate, the greater the cost. We shall see that some codes require a signaling rate that is greater than the actual data rate. We now turn to a discussion of various techniques.
The most common, and easiest, way to transmit digital signals is to use two different voltage levels for the two binary digits. Codes that follow this strategy share the property that the voltage level is constant during a bit interval; there is no transition (no return to a zero voltage level). For example, the absence of voltage can be used to represent binary 0, with a constant positive voltage used to represent binary 1. More commonly, a negative voltage represents one binary value and a positive volt- age represents the other. This latter code, known as Nonreturn to Zero-Level (NRZ-L), is illustrated^2 in Figure 5.2. NRZ-L is typically the code used to generate or interpret digital data by terminals and other devices. If a different code is to be used for transmission, it is generated from an NRZ-L signal by the transmission sys- tem [in terms of Figure 5.1, NRZ-L is g ( t ) and the encoded signal is x ( t )]. A variation of NRZ is known as NRZI (Nonreturn to Zero, invert on ones). As with NRZ-L, NRZI maintains a constant voltage pulse for the duration of a bit time. The data themselves are encoded as the presence or absence of a signal transi- tion at the beginning of the bit time. A transition (low to high or high to low) at the beginning of a bit time denotes a binary 1 for that bit time; no transition indicates a binary 0. NRZI is an example of differential encoding. In differential encoding, the information to be transmitted is represented in terms of the changes between suc- cessive signal elements rather than the signal elements themselves. The encoding of the current bit is determined as follows: If the current bit is a binary 0, then the
(^2) In this figure, a negative voltage is equated with binary 1 and a positive voltage with binary 0. This is the opposite of the definition used in virtually all other textbooks. The definition here conforms to the use of NRZ-L in data communications interfaces and the standards that govern those interfaces.
current bit is encoded with the same signal as the preceding bit; if the current bit is a binary 1, then the current bit is encoded with a different signal than the preced- ing bit. One benefit of differential encoding is that it may be more reliable to detect a transition in the presence of noise than to compare a value to a threshold. Another benefit is that with a complex transmission layout, it is easy to lose the sense of the polarity of the signal. For example, on a multidrop twisted-pair line, if the leads from an attached device to the twisted pair are accidentally inverted, all 1s and 0s for NRZ-L will be inverted. This does not happen with differential encoding. The NRZ codes are the easiest to engineer and, in addition, make efficient use of bandwidth. This latter property is illustrated in Figure 5.3, which compares the spectral density of various encoding schemes. In the figure, frequency is normalized to the data rate. Most of the energy in NRZ and NRZI signals is between dc and half the bit rate. For example, if an NRZ code is used to generate a signal with data rate of 9600 bps, most of the energy in the signal is concentrated between dc and 4800 Hz. The main limitations of NRZ signals are the presence of a dc component and the lack of synchronization capability. To picture the latter problem, consider that with a long string of 1s or 0s for NRZ-L or a long string of 0s for NRZI, the output is a constant voltage over a long period of time. Under these circumstances, any drift between the clocks of transmitter and receiver will result in loss of synchronization between the two. Because of their simplicity and relatively low frequency response characteris- tics, NRZ codes are commonly used for digital magnetic recording. However, their limitations make these codes unattractive for signal transmission applications.
B8ZS, HDB
NRZ-I, NRZI
AMI, pseudoternary
Manchester, differential Manchester
Normalized frequency ( f / R )
0.2 0.4 0.6 0.8 1.0 1.2 1.4 1.6 1.8 2.
0.
0.
0.
0.
1.
1.
1.
Mean square voltage per unit bandwidth
(^) AMI alternate mark inversion B8ZS bipolar with 8 zeros substitution HDB3 high-density bipolar—3 zeros NRZ-L nonreturn to zero level NRZI nonreturn to zero inverted f frequency R data rate
Figure 5.3 Spectral Density of Various Signal Encoding Schemes
There is another set of coding techniques, grouped under the term biphase , that overcomes the limitations of NRZ codes. Two of these techniques, Manchester and differential Manchester, are in common use. In the Manchester code, there is a transition at the middle of each bit period. The midbit transition serves as a clocking mechanism and also as data: a low-to-high transition represents a 1, and a high-to-low transition represents a 0.^4 In differential Manchester , the midbit transition is used only to provide clocking. The encoding of a 0 is represented by the presence of a transition at the beginning of a bit period, and a 1 is represented by the absence of a transition at the beginning of a bit period. Dif- ferential Manchester has the added advantage of employing differential encoding. All of the biphase techniques require at least one transition per bit time and may have as many as two transitions. Thus, the maximum modulation rate is twice that for NRZ; this means that the bandwidth required is correspondingly greater. On the other hand, the biphase schemes have several advantages:
- Synchronization: Because there is a predictable transition during each bit time, the receiver can synchronize on that transition. For this reason, the biphase codes are known as self-clocking codes. - No dc component: Biphase codes have no dc component, yielding the benefits described earlier.
(^100) 7
10 ^6
10 ^5
10 ^4
10 ^3
10 ^2
10 ^1
1 2 3 4 5 6 7 8
Probability of bit error (BER)
( Eb / N 0 ) (dB)
9 10 11 12 13 14 15
AMI, pseudoternary, ASK, FSK
NRZ, biphase PSK, QPSK
3 dB
Figure 5.4 Theoretical Bit Error Rate for Various Encoding Schemes
(^4) The definition of Manchester presented here is the opposite of that used in a number of respectable textbooks, in which a low-to-high transition represents a binary 0 and a high-to-low transition represents a binary 1. Here, we conform to industry practice and to the definition used in the various LAN stan- dards, such as IEEE 802.3.
- Error detection: The absence of an expected transition can be used to detect errors. Noise on the line would have to invert both the signal before and after the expected transition to cause an undetected error. As can be seen from Figure 5.3, the bandwidth for biphase codes is reasonably narrow and contains no dc component. However, it is wider than the bandwidth for the multilevel binary codes. Biphase codes are popular techniques for data transmission. The more com- mon Manchester code has been specified for the IEEE 802.3 (Ethernet) standard for baseband coaxial cable and twisted-pair bus LANs. Differential Manchester has been specified for the IEEE 802.5 token ring LAN, using shielded twisted pair.
When signal-encoding techniques are used, a distinction needs to be made between data rate (expressed in bits per second) and modulation rate (expressed in baud). The data rate, or bit rate, is where duration. The modulation rate is the rate at which signal elements are generated. Consider, for example, Manchester encoding. The minimum size signal element is a pulse of one-half the duration of a bit interval. For a string of all binary zeroes or all binary ones, a continuous stream of such pulses is generated. Hence the maximum modulation rate for Manchester is This situation is illustrated in Figure 5.5, which shows the transmission of a stream of binary 1s at a data rate of 1 Mbps using NRZI and Manchester. In general,
log 2 M
2/Tb.
1/Tb , Tb = bit
5 bits 5 s
1 bit 1 signal element 1 s
1 signal element 0.5 s
1 bit 1 s
NRZI
Manchester
Figure 5.5 A Stream of Binary Ones at 1 Mbps
Two techniques are commonly used in long-distance transmission services; these are illustrated in Figure 5.6. A coding scheme that is commonly used in North America is known as bipolar with 8-zeros substitution (B8ZS). The coding scheme is based on a bipolar-AMI. We have seen that the drawback of the AMI code is that a long string of zeros may result in loss of synchronization. To overcome this problem, the encoding is amended with the following rules:
Bipolar-AMI
B Valid bipolar signal V Bipolar violation
(odd number of 1s since last substitution)
Figure 5.6 Encoding Rules for B8ZS and HDB
pulses since the last violation is even or odd and (2) the polarity of the last pulse before the occurrence of the four zeros. Figure 5.3 shows the spectral properties of these two codes. As can be seen, neither has a dc component. Most of the energy is concentrated in a relatively sharp spectrum around a frequency equal to one-half the data rate. Thus, these codes are well suited to high data rate transmission.
5.2 DIGITAL DATA, ANALOG SIGNALS
We turn now to the case of transmitting digital data using analog signals. The most familiar use of this transformation is for transmitting digital data through the public telephone network. The telephone network was designed to receive, switch, and transmit analog signals in the voice-frequency range of about 300 to 3400 Hz. It is not at present suitable for handling digital signals from the subscriber locations (although this is beginning to change). Thus digital devices are attached to the net- work via a modem (modulator-demodulator), which converts digital data to analog signals, and vice versa. For the telephone network, modems are used that produce signals in the voice-frequency range. The same basic techniques are used for modems that pro- duce signals at higher frequencies (e.g., microwave). This section introduces these techniques and provides a brief discussion of the performance characteristics of the alternative approaches. We mentioned that modulation involves operation on one or more of the three characteristics of a carrier signal: amplitude, frequency, and phase. Accord- ingly, there are three basic encoding or modulation techniques for transforming dig- ital data into analog signals, as illustrated in Figure 5.7: amplitude shift keying (ASK), frequency shift keying (FSK), and phase shift keying (PSK). In all these cases, the resulting signal occupies a bandwidth centered on the carrier frequency.
In ASK, the two binary values are represented by two different amplitudes of the car- rier frequency. Commonly, one of the amplitudes is zero; that is, one binary digit is rep- resented by the presence, at constant amplitude, of the carrier, the other by the absence of the carrier (Figure 5.7a).The resulting transmitted signal for one bit time is
ASK s 1 t 2 = e (5.2)
A cos 12 pfct 2 binary 1 0 binary 0
Table 5.4 HDB3 Substitution Rules
Number of Bipolar Pulses (ones) since Last Substitution Polarity of Preceding Pulse Odd Even
Figure 5.8 shows an example of the use of BFSK for full-duplex operation over a voice-grade line. The figure is a specification for the Bell System 108 series modems. Recall that a voice-grade line will pass frequencies in the approximate range 300 to 3400 Hz and that full duplex means that signals are transmitted in both directions at the same time. To achieve full-duplex transmission, this bandwidth is split. In one direction (transmit or receive), the frequencies used to represent 1 and 0 are centered on 1170 Hz, with a shift of 100 Hz on either side. The effect of alter- nating between those two frequencies is to produce a signal whose spectrum is indi- cated as the shaded area on the left in Figure 5.8. Similarly, for the other direction (receive or transmit) the modem uses frequencies shifted 100 Hz to each side of a center frequency of 2125 Hz. This signal is indicated by the shaded area on the right in Figure 5.8. Note that there is little overlap and thus little interference. BFSK is less susceptible to error than ASK. On voice-grade lines, it is typically used up to 1200 bps. It is also commonly used for high-frequency (3 to 30 MHz) radio transmission. It can also be used at even higher frequencies on local area networks that use coaxial cable. A signal that is more bandwidth efficient, but also more susceptible to error, is multiple FSK (MFSK), in which more than two frequencies are used. In this case each signaling element represents more than one bit. The transmitted MFSK signal for one signal element time can be defined as follows:
(5.4)
where
To match the data rate of the input bit stream, each output signal element is held for a period of seconds, where T is the bit period (data ). Thus, one signal element, which is a constant-frequency tone, encodes L bits. The
Ts = LT rate = 1/T
L = number of bits per signal element
M = number of different signal elements = 2 L
fd = the difference frequency
fc = the carrier frequency
fi = fc + 12 i - 1 - M 2 fd
MFSK si 1 t 2 = A cos 2pfi t, 1 … i … M
1070 1270 2025 2225 Frequency (Hz)
Signal strength Spectrum of signal transmitted in one direction
Spectrum of signal transmitted in opposite direction
Figure 5.8 Full-Duplex FSK Transmission on a Voice-Grade Line
Time
Frequency
Data 1 1 11 0 1 10 0 0 0 0 1 1
fc Wd fc fd fc fd
fc 3 fd
fc 3 fd
T (^) s
T
Figure 5.9 MFSK Frequency Use 1 M = 42
EXAMPLE 5.2 Figure 5.9 shows an example of MFSK with An input bit stream of 20 bits is encoded 2 bits at a time, with each of the four possible 2-bit combinations transmitted as a different frequency. The display in the figure shows the frequency transmitted ( y -axis) as a function of time ( x -axis). Each column rep- resents a time unit in which a single 2-bit signal element is transmitted. The shaded rectangle in the column indicates the frequency transmitted during that time unit.
Ts
In PSK, the phase of the carrier signal is shifted to represent data.
binary digits (Figure 5.7c) and is known as binary phase shift keying. The resulting transmitted signal for one bit time is
Because a phase shift of 180° is equivalent to flipping the sine wave or multiplying it by - 1,the rightmost expressions in Equation (5.5) can be used. This
1 p 2
BPSK s 1 t 2 = e
A cos 12 pfct 2 A cos 12 pfct + p 2
= e
A cos 12 pfct 2 binary 1
EXAMPLE 5.1 With and we have the following frequency assignments for each of the eight possible 3-bit data combinations:
This scheme can support a data rate of 1/T = 2 Lfd = 150 kbps.
f 7 = 375 kHz 110 f 8 = 425 kHz 111
f 5 = 275 kHz 100 f 6 = 325 kHz 101
f 3 = 175 kHz 010 f 4 = 225 kHz 011
f 1 = 75 kHz 000 f 2 = 125 kHz 001
fc = 250 kHz, fd = 25 kHz, M = 8 1 L = 3 bits 2 ,
total bandwidth required is It can be shown that the minimum frequency sep- aration required is Therefore, the modulator requires a bandwidth of Wd = 2 Mfd = M/Ts.
2 fd = 1/Ts.
2 Mfd.
Figure 5.11 shows the QPSK modulation scheme in general terms. The input is a stream of binary digits with a data rate of where is the width of each bit. This stream is converted into two separate bit streams of R /2 bps each, by taking alternate bits for the two streams. The two data streams are referred to as the I (in-phase) and Q (quadrature phase) streams. In the diagram, the upper stream is modulated on a carrier of frequency by multiplying the bit stream by the carrier. For convenience of modulator structure we map binary 1 to and binary 0 to Thus, a binary 1 is represented by a scaled version of the carrier wave and a binary 0 is represented by a scaled version of the negative of the carrier wave, both at a constant amplitude. This same carrier wave is shifted by 90° and used for modulation of the lower binary stream. The two modulated signals are then added together and transmitted. The transmitted signal can be expressed as follows:
Figure 5.12 shows an example of QPSK coding. Each of the two modulated streams is a BPSK signal at half the data rate of the original bit stream. Thus, the combined signals have a symbol rate that is half the input bit rate. Note that from one symbol time to the next, a phase change of as much as 180° is possible. Figure 5.11 also shows a variation of QPSK known as offset QPSK (OQPSK), or orthogonal QPSK. The difference is that a delay of one bit time is introduced in the Q stream, resulting in the following signal:
Because OQPSK differs from QPSK only by the delay in the Q stream, its spectral characteristics and bit error performance are the same as that of QPSK.
s 1 t 2 =
I 1 t 2 cos 2pfct -
Q 1 t - Tb 2 sin 2pfct
1 p 2
QPSK s 1 t 2 =
I 1 t 2 cos 2pfct -
Q 1 t 2 sin 2pfct
fc
R = 1/Tb , Tb
P /
Carrier Binary oscillator input (^) Signal out s ( t )
R /2 bps
I( t ) a (^) n 1
Q( t ) b (^) n 1
R /2 bps
2-bit serial-to-parallel converter Phase shift
OQPSK only
Delay T (^) b
R (^) T^1 b
cos 2 P fc t 2
sin 2 P fc^ t 2
Figure 5.11 QPSK and OQPSK Modulators
From Figure 5.12, we can observe that only one of two bits in the pair can change sign at any time and thus the phase change in the combined signal never exceeds 90° This can be an advantage because physical limitations on phase modulators make large phase shifts at high transition rates difficult to perform. OQPSK also provides superior performance when the transmission channel (including transmit- ter and receiver) has significant nonlinear components. The effect of nonlinearities is a spreading of the signal bandwidth, which may result in adjacent channel inter- ference. It is easier to control this spreading if the phase changes are smaller, hence the advantage of OQPSK over QPSK.
two at a time. It is possible to transmit bits three at a time using eight different phase angles. Further, each angle can have more than one amplitude. For example, a stan- dard 9600 bps modem uses 12 phase angles, four of which have two amplitude val- ues, for a total of 16 different signal elements. This latter example points out very well the difference between the data rate R (in bps) and the modulation rate D (in baud) of a signal. Let us assume that this scheme is being employed with digital input in which each bit is represented by a constant voltage pulse, one level for binary one and one level for binary zero. The data rate is However, the encoded signal contains bits in each sig- nal element using different combinations of amplitude and phase. The modulation rate can be seen to be R /4, because each change of signal element com- municates four bits. Thus the line signaling speed is 2400 baud, but the data rate is
R = 1/Tb. L = 4
1 p/2 2.
Bit number 2
P /
3 P /
3 P /
P /
P /
P /
value 1
Input signal
I( t )
Q( t )
Q( t Tb )
Phase of output signal
Phase of output signal
Figure 5.12 Example of QPSK and OQPSK Waveforms