Homework #1 – Signal Acquisition 
J. H. Won 
INHA University, Incheon, S. Korea 
Description:  There are mainly three different types of signal acquisition methods in GNSS 
signal processing; 1) conventional time-frequency space search, 2) parallel frequency space 
search, and 3) parallel time space search. In this home work you will implement and test two of 
them by using the received signals as well as the simulated signals.  
The result of all the tasks should be described in a proper way.  
Deliverable:  HW#1 Report (including the answers to Task-1 to 6, and the relevant descriptions 
by yourself)   
Deadline:   
Attachment: IncomingIF.mat  - Matlab MAT-file  
Task-1: Implement a sampled C/A code generator with a given code delay  
Argument 
name 
PRN 
Description  
1) Write a Matlab function “code=CA(PRN)” to generate the 1023 chips C/A Gold code 
sequence for any of the PRNS 1 to 32.   
In/Out 
[input] 
Pseudo random noise number for a 
satellite (1 to 32) 
Unit/Dimension 
[unitless] 
1-by-1 
[output] 
code 
C/A Gold code sequence (+/-1) 
[unitless] 
1023-by-1 
Argument 
name 
Ts 
Description  
2) Write a Matlab function “sampled_code=SampledCA(PRN,Ts)” to generate the sampled 
C/A code sequence.  
In/Out 
[input] 
Unit/Dimension 
Sampling interval of ADC 
[sec] 
(e.g. Ts = 1/5.714x106 sec) 
[output] 
sampled_code Sampled C/A code sequence (+/-1) 
with sampling rate of fs Hz (=1/Ts) 
Duration is 1 msec 
1-by-1 
[unitless] 
1-by-5714  
1 
Capstone Design of Autonomous Navigation 
Systems 
Argument name 
J. H. Won 
INHA University, Incheon, S. Korea 
3) Write a Matlab function “shifted_sampled_code=ShiftedSampledCA(PRN,Ts, 
code_delay)” to generate the sampled C/A code sequence with delay.    
In/Out 
[input] 
Description  
code_delay 
Code delay  
Unit/Dimension 
[chips] 
1-by-1 
[output] shifted_sampled_code Shifted sampled C/A code 
sequence (+/-1) with 
sampling rate of fs Hz (=1/Ts) 
and with a code delay 
[unitless] 
1-by-5714  
Duration is 1 msec 
4) Plot the auto-correlation function of CA code (PRN#1) .  
5) Plot the cross-correlation function of CA codes (PRN#1 and PRN#2). 
6) Plot the auto-correlation function of sampled CA code (PRN#1).  
7) Plot the cross-correlation function of sampled CA codes (PRN#1 and PRN#2)    
Note: The correlation function here should be defined as a circular correlation for a defined 
time duration.  
Task-2: Read the data file 
1) Read the data from “IncomingIF.mat”. This is a 1.0 sec received incoming IF sequence 
sampled at 1/Ts Hz. The data was aligned in 1000x5714 array which means 1000 rows 
of 1 msec IF samples. Save the first 1 msec IF samples into an array variable 
“incoming_1ms_IF”.   E.g., incoming_1ms_IF = IncomingIF(1,:); 
2) Plot the time series.  
3) Plot the Power Spectral Density (PSD).  
Hint: you have to carefully manage the x-axis (frequency) in FFT operation.   
Task-3: Conventional acquisition method (Time-Frequency space search) 
1) Read the data from “IncomingIF.mat” and save the first 1ms samples into 
“incoming_1msIF”. 
2) Generate a carrier waveform sin/cos(2π(fIF+fd)tk) for 1 msec. fIF = 4.3 MHz, fd=Doppler 
frequency (+/-10 KHz, 250 Hz or smaller Doppler bin), tk = 0 … 1msec with the 
increment of Ts. 
2 
Capstone Design of Autonomous Navigation 
Systems 
J. H. Won 
INHA University, Incheon, S. Korea 
3) Generate sampled C/A code sequence (Use Task-1) for 0 to 1023 with 0.5 chip (or 
smaller) code delay.  
4) Correlate 1) with 2) and 3), and after then sum Inphase (I) and Quadrature (Q) after 
squared (=I2+Q2) for all PRNs (cold start).  
Hint: three “for-loop” states 
for sv=1:32 
for code_delay=0:d:1023 
for Doppler=-10K:DopBin:10K 
test .....  
end 
end 
end 
5) Plot the 2-dimensional acquisition function (i.e., code delay and Doppler) for a searched 
PRN.  
6) Make a selection logic with a threshold value K. You should assume a value of K with a 
proper knowledge on the basis of detection and false alarm probabilities.  
Task-4: FFT-IFFT acquisition method (Parallel time space search) 
1) Read the data from “IncomingIF.mat” and save the first 1ms samples into 
“incoming_1msIF”.  
2) Apply FFT to the data to generate X(N).  
3) Generate a carrier waveform sin/cos(2π(fIF+fd)tk) for 1 msec and for Doppler frequencies. 
4) Generate sampled C/A code sequence (Use Task-1).  
5) Apply FFT to 3)x4) to generate H(N) 
6) Apply IFFT to X(N)xH*(N).         
Hint: Use Matlab functions “fft.m” and “ifft.m”.  
* represents complex conjugate.  
Task-5: Implement a signal simulator    
1) Generate a carrier waveform cos(2π(fIF+fd)tk) for 1 msec with a given Doppler frequency. 
e.g., Doppler frequency setting = +3 KHz.  
2) Generate sampled C/A code sequence (Use Task-1) with a given code delay.  
e.g., code delay setting = 201.3 chip    
3 
Capstone Design of Autonomous Navigation 
Systems 
Argument name 
J. H. Won 
INHA University, Incheon, S. Korea 
3) Write a Matlab function noise=AWGN(mean,std,num) to generate Additive White 
Gaussian Noise (AWGN) sequence.  
In/Out 
[input] 
Description  
mean 
Mean  
Unit/Dimension 
[unitless] 
1-by-1 
std 
Standard deviation 
[unitless] 
1-by-1 
[output] noise 
Noise output 
[unitless] 
1-by-num  
Here, use a Matlab m-function “rand.m” to generate a uniformly distributed random 
numbers, and consider Central Limit Theorem (CLT).  Or you can directly use a Matlab 
m-function “randn.m” to generate a normally distributed random numbers.  
4) Write a Matlab function “received_signal=RcvSigGen(code_delay, init_carrier_phase, 
Doppler,CN0)” to generate received signals.  
Hint: r(tk) = sqrt(2*P)*D(t-τ)*CA(t- τ )*cos(2π(fIF+fd)tk + φ0)    
Hint: Use the appropriate values for tk, fIF, P. (D = 1)  
In/Out 
Argument name 
Description  
[input] 
code_delay 
code delay 
Unit/Dimension 
[chips] 
1-by-1 
Init_carrier_phase Initial carrier phase  
Doppler 
[cycles] 
Doppler  
CN0 
[Hz] 
Carrier-to-noise ratio 
[output] 
[dB-Hz] 
received_sigal 
Received signal 
Duration is 1 msec 
[unitless] 
1-by-5714  
5)  Save the generated received signals in 4) into a one-dimensional array variable 
“GeneratedIncomingIF”, and repeat Task-4.  
4 
Capstone Design of Autonomous Navigation 
Systems 
Task-6: Acquisition time analysis on Galileo signals    
J. H. Won 
INHA University, Incheon, S. Korea 
1) Fill-out the following table of the cold start acquisition time for a cell for GPS L1CA and 
Galileo OS signals. Describe the impact of BOC-like signals on the acquisition time with 
a special attention on the size of code bin. More specifically, describe the impact of 
sidelobe peak in case of BOC signals, and the methods to mitigate this impact. You 
need to do the literature survey.   
Option  
Code rate 
[Mcps] 
Code length 
[chips] 
Code 
duration 
[ms]  
Data rate 
[sps] 
Required CNo  
[dB-Hz] 
Size of search 
space 
(ΔTxΔf)  
Size of 
search grid 
(δTxδf)  
Tacq for one 
SV [s]  
GPS 
L1-C/A 
1.023 
1023 
1 
50 
Galileo 
OS-E1 
4 
(To be defined later) 
References 
[1]  J. H. Won, Signal Acquisition, Lecture Presentation at ESPACE-TUM, 2013.  CAN YOU DO THIS HOMEWORK FOR ME?