PART » History » Version 14

COLIN, Tony, 03/02/2016 08:47 PM

1 2 COLIN, Tony
h1. PART 2 : GPS signals generation.
2 2 COLIN, Tony
3 3 COLIN, Tony
{{>toc}}
4 3 COLIN, Tony
5 3 COLIN, Tony
p(. In order to design a software-defined single frequency GPS receiver it is necessary to know the characteristics of the signal and data transmitted from the GPS satellites and received by our GPS receiver antenna. In this part an overview of the GPS signal generation scheme and most important properties of the various signals and data are presented.
6 2 COLIN, Tony
7 2 COLIN, Tony
---
8 2 COLIN, Tony
9 5 COLIN, Tony
h2. 1 - GPS signals.
10 2 COLIN, Tony
11 12 COLIN, Tony
The GPS signals are transmitted on two radio frequencies in the UHF band. The UHF band covers the frequency band from 500MHz to 3GHz. These frequencies are referred to as L1 and L2 and are derived from a common frequency _f_0=10.23MHz_ : 
12 12 COLIN, Tony
_f_L1=154xf_0=1575.42MHz_ and _f_L2=120xf_0=1227.60MHz_.
13 13 COLIN, Tony
14 1 COLIN, Tony
The signals are composed of the following three parts : 
15 9 COLIN, Tony
16 9 COLIN, Tony
- _Carrier_ : The carrier wave with frequency f_L1 or f_L2
17 9 COLIN, Tony
18 9 COLIN, Tony
- _Navigation Data (D)_ : The navigation data contain information regarding satellite orbits. This information is uploaded to all satellites from the ground stations in the GPS Control Segment (Cf. Part1 - 5). The navigation data have a bit rate of *50bps*.
19 9 COLIN, Tony
20 9 COLIN, Tony
- _Spreading sequence (C)_ : Each satellite has two unique spreading sequences or codes. The first one is the coarse acquisition code (C/A), and the other one is the encrypted precision code (P(Y)). The *C/A* code is a sequence of *1023 chips*, with a chip corresponding to a bit. The code is *repeated each ms* giving a chipping rate of *1.023 MHz*. The P code is a longer code with a chipping rate of 10.23 MHz and will not be taken into account in this project.
21 9 COLIN, Tony
The C/A code in only modulated onto *L1 carrier* while the P(Y) code is modulated on both L1 and L2 carrier.
22 13 COLIN, Tony
The figure shows the three parts forming the signal on the L1 frequency. The C/A code repeats itself every ms, and one navigation bit lasts 20ms. Hence *for each navigation bit, the signal contains 20 complete C/A codes.*  
23 1 COLIN, Tony
24 13 COLIN, Tony
p=. !2.png!
25 13 COLIN, Tony
26 13 COLIN, Tony
The figure shows the Gold code C, the navigation data D, the modulo-2 added signal C⊕D and the carrier. The final signal is created by binary phase-shift keying (BPSK) where the carrier is instantaneously phase shifted by 180° at the time of a chip range. When a navigation data bit transition occurs (about one third from the right edge), the phase of the resulting signal is also phase-shifted 180°.
27 13 COLIN, Tony
28 13 COLIN, Tony
p=. !3.png!
29 13 COLIN, Tony
30 1 COLIN, Tony
---
31 1 COLIN, Tony
32 1 COLIN, Tony
h2. 2 - Navigation Data.
33 1 COLIN, Tony
34 1 COLIN, Tony
The navigation data are transmitted on the L1 frequency with the earlier mentioned bit rate of *50 bps*. This section describes the structure and contents of the navigation data. The figure shows the overall structure of an entire navigation message.
35 13 COLIN, Tony
36 13 COLIN, Tony
p=. !7.png!
37 13 COLIN, Tony
38 13 COLIN, Tony
p=. !39.png!
39 13 COLIN, Tony
40 9 COLIN, Tony
The basic format of the navigation data is *1500-bit-long* containing *5 subframes*, each having length *300 bits*. One subframe contains 10 words, each word having length 30 bits. Subframe 1,2 and 3 are repeated in each frame. The last subframes, 4 and 5, have 25 versions (with the same structure, but different data) referred to as index 1 to 25. With the bit rate of 50 bps, the transmission of a subframe lasts *6 s*, one frame lasts *30 s*, and one entire navigation message lasts *12.5 minutes*.
41 1 COLIN, Tony
42 1 COLIN, Tony
h3. a- Telemetry and Handover Words.
43 1 COLIN, Tony
44 9 COLIN, Tony
The subframes of 10 words always begin with two special words, the telemetry (*TLM*) and handover word (*HOW*) pair.
45 9 COLIN, Tony
TLM is the first word of each subframe and it is thus repeated 6 s. It contains an *8-bit* preamble followed by *16* reserved bits and parity. The preamble should be used for frame synchronization.
46 9 COLIN, Tony
HOW contains *17-bit* truncated version of the Time Of the Week (*TOW*), followed by two flags supplying information to the user of antispoofing etc. The next *3 bits* the *subframe ID* to show in which of the five subframes in the current frame this HOW is located.
47 9 COLIN, Tony
48 9 COLIN, Tony
b- Data in Navigation Message.
49 9 COLIN, Tony
50 9 COLIN, Tony
In addition to the TLM and HOW words, each subframe contains *8 words of data*. This will only be a cursory description of the data in the different words and not a complete description of all bits.
51 9 COLIN, Tony
_Subframe 1 - Satellite Clock and Health Data_ : The first subframe contains first of all *clock* information. That is information needed to compute at what time the navigation message is transmitted from the satellite. Additionally, subframe 1 contains health data indicating whether or not the data should be trusted.
52 9 COLIN, Tony
_Subframe 2 and 3 - Ephemeris Data_ : The *ephemeris data* relate to the satellite orbit and are needed to compute *satellite position*.
53 9 COLIN, Tony
_Subframe 4 and 5 - Support Data_ : As mentioned, the last two subframes repeat every 12.5 minutes, giving a total of 50 subframes. Subframes 4 and 5 contain *almanac data*. The almanac data are the ephemerides and clock data with reduced precision. Additionally, each satellite transmits almanac data for all GPS satellites while it only transmits ephemeris data for itself. The remainder of subframes 4 and 5 contain various data e.g. UTC parameters, health indicators, and ionospheric parameters.
54 9 COLIN, Tony
55 11 COLIN, Tony
*More details in PDF 2.4 - Navigation Data Message Stucture*
56 2 COLIN, Tony
57 2 COLIN, Tony
---
58 2 COLIN, Tony
59 9 COLIN, Tony
h2. 3 - C/A code : Spread Spectrum & Gold Sequence.
60 2 COLIN, Tony
61 8 COLIN, Tony
In this section, the spreading sequences used in GPS are described. We restrict ourselves to the C/A code sequences, as we deal only with L1 signals in this project. The spreading sequences used C/A codes in GPS belong to a unique family of sequences. They are often referred to as Gold codes or also as pseudo-random noise (*PRN*) sequences, because of their characteristics.
62 9 COLIN, Tony
63 9 COLIN, Tony
h3. a- Gold Sequence.
64 9 COLIN, Tony
65 1 COLIN, Tony
The PRN codes transmitted by the GPS satellites are deterministic sequences with noiselike properties. Each C/A code is generated using a tapped linear feedback shift register (*LFSR*). It generates a maximal-length sequences of *N=2^n-1* elements. 
66 1 COLIN, Tony
The Gold code is the *sum of 2 maximum-length sequences*. The GPS C/A code uses *n=10*. The sequence p(t) repeats every *ms* so the chip length is 1ms/1023=977.5 ns≈*1µs*, which corresponds to a metric length of 300m when propagating through vacuum of air.
67 9 COLIN, Tony
The autocorrelation function for this C/A code is 
68 2 COLIN, Tony
69 13 COLIN, Tony
p=. !42.png!
70 13 COLIN, Tony
71 1 COLIN, Tony
The sequence would 512 ones and 511 zeros, and these would appear to be distributed at random. Yet the string of chips so generated is entirely deterministic. The sequence is pseudorandom, not random. Outside the correlation interval the autocorrelation function of p(t) is -1/N=-1/1023 for the C/A code.
72 1 COLIN, Tony
The autocorrelation function can be expressed as the sum of this constant term and an infinite series of the triangle function r_x (τ). This infinite series is obtained by the convolution of  r_x (τ) with an infinite series of impulse functions that are phase-shifted by mNT_c : 
73 9 COLIN, Tony
74 13 COLIN, Tony
p=. !42-2.png!
75 13 COLIN, Tony
76 1 COLIN, Tony
The power spectrum of this PRN sequence is derived from Fourier transform of (R2) : 
77 13 COLIN, Tony
78 13 COLIN, Tony
p=. !43.png!
79 2 COLIN, Tony
80 2 COLIN, Tony
h3. b- Gold Sequence Generation.
81 2 COLIN, Tony
82 2 COLIN, Tony
The generation of the Gold codes is sketched in the following figure. 
83 13 COLIN, Tony
84 13 COLIN, Tony
p=. !5.png!
85 13 COLIN, Tony
86 2 COLIN, Tony
The C/A code generator contains 2 shift registers known as G1 and G2. These shift registers each have 10 cells generating sequences of length 1023. The 2 resulting 1023 chip-long sequences are modulo-2 added to generate a 1023 chip-long C/A code, only if the polynomial is able to generate code of maximum length.
87 1 COLIN, Tony
Every 1023rd period, the shift registers are reset with all ones, making the code start over. The G1 register always has a feedback configuration with the polynomial : 
88 1 COLIN, Tony
[Image 44]
89 9 COLIN, Tony
90 9 COLIN, Tony
meaning that state 3 and state 10 are fed back to the input. In the same way, the G2 register has the polynomial : 
91 9 COLIN, Tony
92 13 COLIN, Tony
p=. !45.png!
93 13 COLIN, Tony
94 9 COLIN, Tony
To make different C/A codes for the satellites, the output of the 2 shift registers are combined in a very special manner. The G1 register always supplies its output, but G2 register supplies 2 of its states to a modulo-2 adder to generate its output. The selection of states for the modulo-2 adder is called the *phase selection*. The next table shows the combination of the phase selections for each C/A code. It also shows the first 10 chips of each code in octal representation.
95 9 COLIN, Tony
96 14 COLIN, Tony
p=. !4.png!
97 13 COLIN, Tony
98 2 COLIN, Tony
................
99 2 COLIN, Tony
100 2 COLIN, Tony
h3. c- Correlation Properties.
101 2 COLIN, Tony
102 2 COLIN, Tony
The Gold codes are selected as spreading sequences for the GPS signals because of their characteristics. The most important characteristics of the C/A codes are their correlation properties.
103 1 COLIN, Tony
The 2 important correlation properties of the C/A codes can be stated as follows :
104 2 COLIN, Tony
105 2 COLIN, Tony
---
106 1 COLIN, Tony
107 2 COLIN, Tony
h2. 4 - Signal Scheme overview.
108 2 COLIN, Tony
109 14 COLIN, Tony
p=. !1.png!
110 2 COLIN, Tony
111 9 COLIN, Tony
The block diagram should be read from left to right. At the far left, the main clock signal is supplied to remaining blocks. The clock signal has a frequency of  f_0=10.23MHz. When multiplied by 154 and 120, it generates the L1 and L2 carrier signals, respectively. At the bottom left corner a limiter is used to stabilize the clock signal before supllying it to *P(Y)* and *C/A* code generators. At the very bottom the data generator generates the navigation data *D*. The code generators and the data generator are synchronized through the *X1* signal supplied by the P(Y) code generator.
112 13 COLIN, Tony
113 9 COLIN, Tony
After code generation, the codes are combined with navigation data through modulo-2 adders. The *C/A ⊕ data* and *P(Y) code ⊕ data* signals are supplied to the two modulators for the L1 frequency. Here the signals are modulated onto the carrier signal using *BPSK* method. Note that the two codes are modulated in-phase and quadrature with each other on L1. That is, there is 90° phase shift between the two codes. After the P(Y) part is attenuated 3dB, these two L1 signals are added to form resulting L1 signal. In our project, the so-called Standard Positioning Service (*SPS*) is based on C/A code signals alone.
114 2 COLIN, Tony
It follows that the signal transmitted from satellite k can be described as :
115 2 COLIN, Tony
116 13 COLIN, Tony
p=. !38.png!
117 1 COLIN, Tony
118 1 COLIN, Tony
[]http://www.navipedia.net/index.php/GPS_Navigation_Message