1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-09-28 15:08:51 +00:00

Smoother grid plot

This commit is contained in:
Antonio Ramos 2018-01-25 10:32:40 +01:00
parent 313e73532b
commit 3270debac7

View File

@ -35,7 +35,7 @@
path = '/home/aramos/signals/GNSS-IN-THE-SPACE/CAPTURES SPIRENT/acq/'; path = '/home/aramos/signals/GNSS-IN-THE-SPACE/CAPTURES SPIRENT/acq/';
file = 'acq'; file = 'acq';
sat = 32; sat = 9;
% Signal: % Signal:
% 1 GPS L1 % 1 GPS L1
@ -47,7 +47,7 @@ sat = 32;
signal_type = 1; signal_type = 1;
%%% True for light grid representation %%% True for light grid representation
lite_view = true; lite_view = false;
%%% If lite_view, it sets the number of samples per chip in the graphical representation %%% If lite_view, it sets the number of samples per chip in the graphical representation
n_samples_per_chip = 4; n_samples_per_chip = 4;
@ -79,12 +79,12 @@ freq = (0 : n_dop_bins - 1) * doppler_step - doppler_max;
delay = (0 : n_fft - 1) / n_fft * n_chips; delay = (0 : n_fft - 1) / n_fft * n_chips;
figure(1) figure(1)
if(lite_view == false) if(lite_view == false)
surf(freq, delay, grid) surf(freq, delay, grid, 'FaceColor', 'interp', 'LineStyle', 'none')
ylim([min(delay) max(delay)]) ylim([min(delay) max(delay)])
else else
delay_interp = (0 : n_samples_per_chip * n_chips - 1) / n_samples_per_chip; delay_interp = (0 : n_samples_per_chip * n_chips - 1) / n_samples_per_chip;
grid_interp = spline(delay, grid', delay_interp)'; grid_interp = spline(delay, grid', delay_interp)';
surf(freq, delay_interp, grid_interp) surf(freq, delay_interp, grid_interp, 'FaceColor', 'interp', 'LineStyle', 'none')
ylim([min(delay_interp) max(delay_interp)]) ylim([min(delay_interp) max(delay_interp)])
end end
xlabel('Doppler shift / Hz') xlabel('Doppler shift / Hz')