Abstract:
A maximum distance from zero-crossing demodulation method for MSK or OK-QPSK signals is disclosed which utilizes the zero-crossing information for establishing a bit edge reference and an optimum sampling point situated essentially midway between the zero-crossings of the higher of the two incoming signalling tones. This method is able to provide improved noise immunity over other known methods by at least an additional 10 degrees of phase margin while conserving processor steps during the phase detection process.

Description:
BACKGROUND OF THE INVENTION 
     The present invention relates generally to coded signal demodulators, and more particularly to a minimum shift-keyed and offset-keyed quadrature-phase-shift-keyed signal demodulator that may be advantageously utilized in data communication systems. 
     A type of frequency-shift-keying commonly referred to as minimum-shift-keying (MSK) is particularly well suited for use in radio communications systems since the spectral energy is more easily contained within the limited bandwidth available than other binary frequency or phase-shift-keying modulations. An MSK signal is a continuous-phase-frequency-shift-keying (CPFSK) between one signalling tone and another signalling tone depending upon the value of a binary digit or bit. For example, a mark or binary one may be characterized by modulation with a 1200 Hz signalling tone, and a space or binary zero may be characterized by modulation with an 1800 Hz signalling tone. The continuous phase in CPFSK indicates that the phase-frequency changes between the two signalling tones are continuous; i.e., a signalling tone begins at the same phase as that which the previous signalling tone ended. 
     Also, to be MSK, the deviation ratio of the CPFSK must be equal to one-half. The deviation ratio is the frequency difference between the two signalling tones divided by the rate of transmission of the bits expressed in bits per second. In the above example of CPFSK with signalling tones of 1200 Hz, the transmission speed would be 1200 bits per second to be MSK. 
     Since MSK is a member of the frequency-shift-keying (FSK) family, the bits can be recovered from the MSK modulated signal by using any FSK signal detector or demodulator. In binary FSK one of two signalling tones are transmitted to indicate one of two possible values for a binary digit or bit. Any device which discriminates between the two signalling tones can be employed as a signal detector, such as a frequency discriminator, the error voltage from a phase lock loop, or a delay differential detector. All three methods are in common use as MSK signal detectors. 
     Better signal detectors can be constructed for MSK which advantageously exploit its unique characteristics; i.e., continuous phase and deviation ratio equal to one-half. These two properties result in phase characteristics usually found in a certain type of phase-shift-keying (PSK) modulation called offset-keyed quadrature-phase-shift-keying (OK-QPSK). Although OK-QPSK modulation encodes the data bits as phase shifts of the signal at bit boundaries relative to a reference carrier rather than a frequency of the signalling tone as in FSK, a relationship between the two methods exists. Because of this characteristic, coherent OK-QPSK signal detectors are also commonly used as signal detectors for MSK. Coherent signal detectors achieve more reliable signal detection than the three non-coherent detectors described earlier. This is because coherent detectors use knowledge of the exact phase of the signalling tones to detect the transmitted bits. As such, this type of demodulator usually consists of two parts; a device which extracts the bit clock in thephase of the signalling tones, and a detector which uses the extracted signal phase. A detector which uses knowledge of the signal phase is commonly implemented by a device called a matched filter. 
     All of these MSK demodulators can be built with varying amounts of hardware. The more reliable coherent demodulators usually require much more hardware than the simpler non-coherent demodulators. Some of the demodulators can be implemented using digital or discrete-time techniques. However, the faster the transmission rate or the more complex the demodulator, the higher the cost of implementation. As a result, a coherent demodulator, capable of accommodating data transmission speeds over several hundred bits per second and performing other supervisory functions (as is commonly required in a mobile radio), cannot be effectively implemented using a single low-cost microcomputer with existing techniques. 
     SUMMARY OF THE INVENTION 
     Accordingly, it is an object of the present invention to provide a reliable and relatively inexpensive MSK and OK-QPSK data signal demodulator that is easily adaptable to accomodate different modulating tones and baud rates. 
     It is another object of the present invention to provide a reliable MSK and OK-QPSK data signal demodulator that need only operate at discrete times coinciding with zero crossings of the data signal. 
     It is yet another object of the present invention to provide a reference carrier recovery process and extraction apparatus for MSK and OK-QPSK data signals that can operate at discrete times at baud rates of several thousand bits per second. 
     It is also an object of the present invention to provide a reliable coherent MSK and OK-QPSK data signal detector that operates at the same discrete times, given the phase of the incoming data signal. 
     It is yet another object of the present invention to provide the same reliable demodulation for either MSK or OK-QPSK modulated signals. 
     It is yet another object of the present invention to provide a reliable coherent MSK and OK-QPSK data signal demodulator that minimizes microcomputer processing time and improves the noise immunity during the data signal detection process. 
     According to an embodiment of the present invention, a demodulator is provided which is responsive to zero crossings of a data signal modulated according to MSK or OK-QPSK for recovering the binary data contained therein. Each bit of the modulated data signal consists of one of two signalling tones having a frequency difference that is one-half of the bit rate. In the inventive demodulator, the data signal is filtered and limited transforming the zero-crossings into transitions between binary states of a limited data signal. A microcomputer is responsive to each transition of the limited data signal for initiating the inventive subroutine of the present invention and samples the sign, or polarity, of the phase of the incoming data signal to demodulate and thereby recover the original data stream. Given the unique properties of a data signal modulated according to MSK or OK-QPSK, a judicious choice of steps to establish an optimum sampling point minimizes the time required for decoding the incoming data signal and provides an improvement in the demodulation process in the presence of surrounding noise. 
     Upon initiating the interrupt caused by the zero-crossing of the incoming data stream, the microcomputer measures the interval between the present zero-crossing and a previous zero-crossing to determine whether to update either one of two phase locked loops internal to the microcomputer. Next, it establishes a sampling point as half-way between 1800 Hz zero-crossings. Then it checks to see whether this sample point has occurred and is optimally located. If it has occurred, then it adjusts the sample point forward a portion of the data bit time period depending upon whether the absolute difference between the sample point and the bit edge is within 70°. If the difference in absolute value is greater than 70°, it adjusts the sample point forward by means of a coarse adjustment equal to 360° plus or minus 120° depending on the sign of the difference. Given that the absolute difference between the sample point and the bit edge is less than 70°, the routine then performs a fine adjustment which reduces the difference--in this case by a factor of 3/4ths. These adjustments having taken place, the microcomputer then merely samples the sign, or polarity, of the incoming data signal to arrive at the properly-recovered data bit delayed by one data bit time period. 
     As a result, the present invention utilizes the necessary steps to establish the optimum point in time with which to sample incoming data signal. It then recovers the incoming data bit by recognizing the positive half cycle of the incoming data signal as a logic one, and the negative half cycle of the incoming data signal as a demodulated logic zero. This leaves the microcomputer free to perform other tasks once the optimum sampling point has been established, as the demodulating process occuring at the optimum sampling point may be accomplished by a simple storage register. The present invention not only encompasses an inventive process for recovering MSK and OK-QPSK signals, but also an inventive apparatus for an MSK and OK-QPSK signal demodulator utilizing the inventive process, which performs well in a noisy environment. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     FIG. 1 is a block diagram of a radio which may advantageously utilize the demodulator of the present invention. 
     FIG. 2 represents a waveform comprising alternating high and low tones forming a given incoming data signal stream. 
     FIG. 3 shows a portion of the waveform in FIG. 2 with specific timing intervals identified. 
     FIG. 4 is a phasor diagram useful in understanding an important aspect of the present invention. 
     FIGS. 5a and 5b are software flowcharts indicating the various steps utilized in the demodulating process of the preferred embodiment of the present invention. 
     FIG. 6 illustrates a communications system employing the demodulator depicted in FIG. 1 to recover an OK-QPSK data signal. 
     FIG. 7 illustrates a communications systems employing the demodulator depicted in FIG. 1 to recover an MSK data signal. 
     FIG. 8 illustrates another communications system employing the demodulator in FIG. 1 to recover a pre-coded MSK data signal. 
    
    
     DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENT 
     Referring now to the drawings, a preferred embodiment of the present invention, as depicted in FIG. 1, may exist in radio 100. Here, the demodulator consists of filter 101, driving limiter 102 feeding an interrupt port of microcomputer 103, as well as a further data input port of microcomputer 103, as shown. While the demodulator of the present invention may include a timer 104, it does not utilize the timer to drive a data input port. Instead, the demodulator of the present invention decodes the incoming data signal directly by sampling the signal at an essentially optimum point maximally distanced between zero-crossings. Receiver 105, driven by RF antenna 106 provides the input data signal, while microcomputer 103 has its own dedicated clock 107 . The elements comprising this maximum distance demodulator are depicted at 120 in FIG. 1. 
     In practicing the present invention it is instructive to consider a typical waveform timeline showing the incoming data signals being pre-encoded according to a predetermined sequence of bits. At 200 in FIG. 2, a sequence of data bits 201 is shown which is pre-coded by an exclusive-OR operation using adjacent bits 202 to generate an alternating sequence of low and high tones 203. In between these tones are shown bit edges 204 by means of dashed lines which indicate the transition from a low to a high tone or vice versa. Very closely approximate to these bit edges are arrows indicating sample points 205 which represent the optimum sampling point for recovery of each respective data bit. Beneath these sample points the actual receive data bits 206 as recovered by the maximum distance demodulator of the present invention are shown, and each appears delayed by one bit cycle. In FIG. 3, an expanded waveform 300 is shown indicating one full cycle of a 1200 Hz tone 302 followed by a 11/2 cycle segment of the higher 1800 Hz tone 304. These are occurring at the bit rate of 1200 bits per second or 1200 baud. 
     Beneath FIG. 3 is a corresponding phasor diagram 400 shown in FIG. 4. Using the bit edge 401 as a reference point on this circular time chart, one observes that, as one proceeds counter clockwise around the circular chart, line segments are encountered which indicate a corresponding zero-crossing for a particular one of the two signalling tones. So, in this example, if one proceeds counter-clockwise around the chart, this corresponds to a time progression from the bit edge reference point to the right on the corresponding waveform 304 shown in FIG. 3. Thus, the first zero-crossing 402 of the 1800 Hz tone occurs at 80°, the second 403 at 200°, and the third 404 at 320°. And similarly, moving from the bit edge reference point on FIG. 3 to the left on waveform 302 indicating decreasing time, one encounters similar zero-crossings when circulating on the chart of FIG. 4 in clockwise fashion. Thus the most recent zero-crossing 405 of the 1200 Hz tone occurred at 300°, and the zero-crossing 406 prior to that at 120°. 
     It is important to note that, given this particular phase relationship of the 1200 Hz signal with respect to the 1800 Hz signal, an optimum sampling point 407 can be defined, and in this example, it is shown on the circular chart of FIG. 4 as being at 20° with respect to the bit edge reference 401. This is the result of the embodiment of the present invention advantageously exploiting the unique characteristics of an MSK or OK-QPSK signal. That is, given the properties of continuous phase and deviation equal to one-half, the algorithm or apparatus of the present invention first determines the time location of the optimum sampling point and then seeks to co-locate it with the bit edge reference by minimizing the time or phase difference between them. First, a determination is made whether a coarse adjustment of 360°±120° is needed based upon the difference in absolute value exceeding 70°. Theoretically, only 60° is needed, but 10° of reserve was added to minimize phase jitter. Then, if a coarse adjustment is unnecessary, a fine adjustment is made by reducing the difference (less than 70° in absolute value) by a factor of three-fourths. Unity could have been used, but the extra steps needed to implement a 4/3 scaling were undesirably long. By so doing, the maximum distance demodulator of the present invention seeks and maintains the sampling points as far from the zero-crossings of the MSK data signal as possible and affords ±60° of phase margin against noise-induced errors in the demodulator data. This is evident from the relationship between sample point 407 and 1800 Hz zero-crossings 402 and 404 as depicted in FIG. 4. The closest prior art demodulator, U.S. Pat. No. 4,414,675 assigned to the assignee of the present invention, could only achieve plus or minus 50 degrees of phase margin. Moreover, the microcomputer time for executing the task is reduced as a result of the simplified demodulation routine. The preferred embodiment of the present invention is given in the form of a software flowchart depicted at 500 in FIGS. 5a and b. 
     The flowchart 500 of FIGS. 5a and b is executed by microcomputer 103 in FIG. 1 whenever an interrupt is generated in response to a transition or zero-crossing of the hard limited data signal from limiter 102. Thus begins a 4-step process of the present invention; first, synchronize the phase locked loops; second, establish an optimum sampling point; third, demodulate the data bit; fourth, determine if correction is needed by use of coarse and fine adjustment limits. 
     Having initiated interrupt routine 501, microcomputer 103 first synchronizes the phase locked loops by first adjusting timer control status register by block 503, followed by a change time resolution via block 505 for the zero-crossing information. Then, by measuring the time interval between the zero-crossing and the data bit reference, and comparing it with 300° in decision block 507, the routine determines which one of the two phase locked loops to update. This update is accomplished by comparing the zero-crossing information with that of the proper phase locked loop in step 509A and 509B, determining whether these are within 10 counts in step 511A or 511B, incrementing or decrementing the DOS (data operated squelch) counter as shown in steps 513A or 513A&#39; and 513B or 513B&#39;, and finally correcting this synchronization of the phase locked loop in step 515A or 515B. Moreover, the DOS counter is so named because it provides a useful output for a data operated squelch (DOS) for muting the voice audio in a mobile radio application. 
     Second, microcomputer 103 establishes an optimum sampling point by using the zero-crossing information obtained above and provides for the occurrence of the sampling point once per bit cycle. Next, it establishes a sampling point as half-way between 1800 Hz zero-crossings at block 516. Then, microcomputer 103 determines if the sample point has occurred at decision block 517. If it has not, as could be the case during start-up, the microcomputer returns to the initial point 501 and waits for a new interrupt. If the sample point has occurred, the process follows YES path to block 519 to demodulate the data bit. 
     Third, the microcomputer 103 demodulates the data bit at the sample point at 519 by detecting the data bit as a logic 1 if the sign or polarity of the signal phase is positive, and as a logic zero if the sign or polarity of the signal phase is negative. The appropriately demodulated data bit is then stored in a register at block 521. 
     Fourth, microcomputer 103 determines if a correction is needed in the sample point before the next data bit is demodulated. This is accomplished by having the routine calculate a bit edge reference and then compare the bit edge reference with the location of the sample point so as to minimize their difference. The bit edge reference is based upon the phase relationship of the two phase locked loops and is calculated as the following equation: 
     
         bit edge=3 theta.sub.1800 -2 theta.sub.1200 
    
     where theta 1800  is the phase of the 1800 Hz phase locked loop and theta 1200  is the phase of the 1200 Hz phase locked loop in this example. The routine uses this information in decision block 523 to determine if: delta is less than -70°, where delta equals sample point-bit edge. If the result of decision block 523 is true then YES path is taken to block 525 which adjusts the sample point forward (360°+120°). Finally, the data bit reference is adjusted via block 527 before returning to the initializing point. If, however, the result of decision block 523 is false, then NO path is taken to decision block 529 which determines if delta is greater than or equal to +70°. If this determination is true, then YES path is taken to block 531 which adjusts the sample point forward (360°-120°). Then, the data bit reference is adjusted via block 527 before returning to the initializing point. However, if the result of decision block 529 is false, then NO path is taken to block 533 which performs a fine adjustment by reducing delta by a factor of 3/4th. The above process is repeated at the baud rate, which facilitates initial synchronization as well as adaptation to distortion caused by the communications link. 
     FIG. 6 shows the maximum distance demodulator of the present invention utilized in an OK-QPSK data system for recovering the binary data in the presence of noise. The communication channel or link is depicted as block 802, which includes but does not show any necessary transmitter and receiver pair. The data signal is encoded by means of OK-QPSK modulator 804 and the data is recovered by maximum distance demodulator 220 of the present invention. 
     FIG. 7 shows the maximum distance demodulator of the present invention utilized in an MSK data system for recovering the binary data in the presence of noise. The communication channel or link is depicted as block 802, which again includes but does not show any necessary transmitter and receiver pair. Here the data signal is encoded by means of MSK modulator 806 and the data is recovered by maximum distance demodulator 220 of the present invention. 
     FIG. 8 shows the maximum distance demodulator of the present invention utilized in a precoded MSK data system by taking the exclusive-OR of adjacent data bits in the data signal before MSK encoding to further facilitate recovering the binary data in the presence of noise. The communication channel or link is depicted as block 802, which again includes but does not show any necessary transmitter and receiver pair. Here the data signal is first pre-coded by delay stage 808 in conjunction with exclusive-OR gate 810 before encoding in MSK modulator 806. The data is then recovered by maximum distance demodulator 220 of the present invention. 
     In summary, the above-mentioned process for demodulating an FSK or OK-OPSK signal is able to accomplish the demodulation of the data signal stream with a minimum amount of errors by maximizing the distance between zero-crossings by synchronizing to the best 1/3rd portion of the bit cycle occurring at the baud rate. This affords the demodulator a plus or minus 60° phase margin to noise-induced errors and, because it simplifies the overall demodulation algorithm by judiciously choosing the time occurrence of the optimum sampling point, it frees the microcomputer to do other tasks rather than merely overseeing the above demodulation process. 
     Although the maximum distance from zero-crossing demodulation process of the present invention fully discloses many of the attendant advantages, it is understood that various changes and modifications not depicted herein are apparent to those skilled in the art. Therefore, even though the form of the above-described invention is merely a preferred or exemplary embodiment given with a practical alternate embodiment, further variations may be made in the form, construction, or arrangement of the process (or equivalent apparatus) without departing from the scope of the above invention. 
     APPENDIX 
     The following program has been coded from the flowcharts in FIGS. 5a and 5b in BASIC programming language, which is described in the book entitled Basic BASIC, by James S. Coan, published by the Hayden Book Co., Inc. Rochelle Park, N.J. 1970. The program is included to demonstrate that the flow charts in FIGS. 5a and 5b may be readily coded into any suitable progamming language. 
     All arithmetic operations are performed modulo B. This can be performed naturally if Log 2  B is the number of bits used to express each variable, i.e., eight-bit variables and B=256. Since B is 28, any suitable eight-bit microcomputer can be utilized. On any machine modulo B arithmetic may be simulated by restricting all arithmetic results in a range of size B. In the following example in BASIC, an arithmetic result may be restricted to the range (B/2&gt;x≧-B/2) by the lines: 
     x=x+y: arithmetic operation 
     if x≧B/2 then x=x-B: or 
     if x&lt;-B/2 then x=x+B: restrict result. 
     It can be seen that the result of adding or substracting two numbers within the range (B/2&gt;x≧-B/2) can result in an answer outside the range. When this occurs, it is called arithmetic overflow. The occurrence of overflow can be easily determined in BASIC with the following program: 
     overflow=0 
     x=x+y: arithmetic operation 
     if x≧B/2 then overflow=1: or 
     if x&lt;-B/2 then overflow=1: detect overflow. 
     An overflow condition like this is usually detected in a condition code register of most conventional microcomputers. 
     The following program assumes that arithmetic operations are restricted to the range B/2&gt;x≧-B/2 and that an overflow is detectable. Line numbers have only been assigned to lines of the following program which correspond to blocks of the flow charts in FIGS. 5a and 5b. 
     
         ______________________________________ZERO CROSSING ROUTINE100     READ TIMER   REF = -REF   LAST 2 = LAST 1   LAST 1 = LAST   LAST = TIMER   IF (LAST - LAST 2) &gt; -43 THEN 117   TEMP = 3 * LAST 1   ERROR = TEMP - PL1800109     IF ERROR &gt;0 THEN 111   PL1800 = PL1800 + K18   GO TO 112111     PL1800 = PL1800 - K18112     IF ABS (ERROR) &gt; 10 THEN 115   DOSCNT = DOSCNT + 1   GO TO 116115     DOSCNT = DOSCNT -1116     GO TO 127117     TEMP = 2* LAST 1118     ERROR = TEMP - PL1200   IF ERROR &gt;0 THEN 122   PL 1200 = PL1200 + K12   GO TO 123122     PL1200 - PL1200 - K12123     IF ABS (ERROR) &gt; 10 THEN 126   DOSCNT = DOSCNT + 1   GO TO 127126     DOSCNT = DOSCNT -1127     IF (TIMER - SAMPNT) &lt;0 THEN RETURN   GO TO SAMPLE POINTER ROUTINESAMPLE POINTER ROUTINE200     READ SAMPNT   BITEDGE = PL1800 - PL1200   ERROR = SAMPNT - BIT EDGE   IF ERROR &gt; 0 THEN 208   IF ERROR &lt;-43 THEN 212 (-60°)   REF = -REF   *SAMPNT = SAMPNT + 341   GO TO 215208     IF ERROR &gt; 43 THEN 212 (+60°)   REF = -REF   *SAMPNT = SAMPNT + 171   GO TO 215212     TEMP = 3* SAMPNT   ERROR = TEMP - (PL1800 + 128) (+180°)   *SAMPNT = SAMPNT + 256 + (3/4) *ERROR215     DEMOD = 2 * DEMOD   IF REF &lt;0 THEN 219   DEMOD = DEMOD +1219     RETURN______________________________________ *NOTE: Each line so denoted above is NOT modulo arithmetic.