I have to compute the relative pseudo-range for my student job, unfortunately, nobody can help me because they are not read into the topic enough. So I'm asking here:
My receiver has to have a 1500 bit buffer, so all 5 subframes are found and decoded. This works just fine. I have a buffer counter (
num_bits_buffered), which counts after all subframes are decoded until 1500 new bits are found in the buffer.
Another module provides the code phase of the signal.
The Receiver has a function
get_TOT(decoder, code_phase) providing the corrected time of transmission.
And here, my first problem occurred: the toc and toe of one satellite were one bit lower - causing the satellite to have a completely different time (16 sec difference). Therefore, it was useless for pseudo-range computing. Do I have to correct the clock time for the pseudo-range computing too?
Now to the main part: I tried the following formula for pseudo-range computing (All variables unitless):
T_s = TOW * 6 + num_bits_buffered_s / DataFrequency(GPSL1) + code_phase_s / CodeFrequency(GPSL1) P_s = (T_s - T_1) * c
I get values close to the real ones(+- 2 km), compared to the measure of the distance between my provided position and the computed satellite positions (the one SV with other toc excluded). If I use my PVT algorithm on the pseudo-range data, I'm 1.5km off in a different directions.
Is anybody here seeing my mistake?