Librem 5 GPS/Location Tracking

If someone wants to investigate this in serio, here you can fetch the hardware manual of the chip and where and how it’s antenna should be located:

2 Likes

I don’t exactly know but these files need to be updated periodically.

i let it run for 8h (problem here is that the battery doesnt last that long, so it was inside under a roof window).

mine shows alot of satellites but at most a ss for 3. values are mostly below 10, the largest i saw was 17.

i found that tool quite buggy (and implemented my own script for that duty), i would expect that both files are saved on shutdown of gnss_share. anyway the data from those files should speed up the tff (time t first fix) because that data isnt read from the satellites which takes up to 20 minutes once a sat is “visible”.

Which tool and what are the bugs? Can you share your script?

Could you try the same experiment(s) by having the phone turned display-side down?
This would give a better indicator if it is indeed a ground plane problem due to antenna construction, or mainly a line-of-sight issue due to the characteristic pattern of the antenna.

Another experiment to try would be to figure out if there might be RF interference due to the other radios, which could be easily tested by turning the radios off (Bluetooth, WiFi, and Cellular).

1 Like

i always do testing with display down.

today i added rfkill to all radio emission of the device to my script (which means it switches off wifi and disables network-access this way).

The script i implemented is this:

start in a terminal as root using a small font :wink: - the console works best. it uses curses to just display the status of the gps module, the sats seen, the time, the location if available.

2 Likes

Thanks. I run it and it shows the above screen. Will it show a fix?

yes, second line if a fix is there.the china position (which has no fix=true) will not be shown. you see the ss values are above 20 for 3 satellites - that’s by far better than with my device. i would guess it could get a fix inbetween 20min or so.

my script does not save the almanac & ephimeris data, so the tff will be again 20min next time.

I don’t think “inside” is viable, although it might depend on the construction of your house.

20 minutes outside should be enough to download the needed data for the initial fix. (Wikipedia says 12½ minutes but that might be in ideal conditions so 20 minutes allows a margin.)

Once the almanac data and ephemeris data are downloaded by and stored on the GNSS chip, going outside again should lead to getting a fix in under a minute. Maybe 20 to 30 seconds.

i live in a roof flat with roof windows - there is a window pane only between l5 and sky. should not be a problem. visibility is good, not much is covered by the roof itself. point is: i have power inside and can keep the phone running for hours.

nevertheless i tried it outside (but not so long) with exactly the same behaviour.

I did tests with the phone display down and display up. The results are amazing:


tests with:

sudo guru/gnss_test.py

1. test

date: Di.  7 Dez. 2021 10:26:58 CET
conditions: cloudy, a bit snowing, L5 display down on table, table 2cm snow
TTFF: 9.4 secs

GPS 0.3
--------------------------------------
longitude      xx.62258417
latitude       xx.05257883
altitude (m)   574.87
accuracy       2.5
fix            3D
View sats
S09:41.0 S07:32.0 S06:36.0 S30:34.0 S02:35.0 S20:33.0 S04:17.0
Solution sats
S09:41.0 S07:32.0 S06:36.0 S02:35.0 S20:33.0
timestamp      2021-12-07 09:27:47.05
Fix time       1638865667.000
TTFF           9.4

===========================================================================

2. test

Di.  7 Dez. 2021 10:37:44 CET
conditions: cloudy, a bit snowing, L5 display up on table, table 2cm snow
TTFF: none

no satellites seen after 10 minutes


===========================================================================

3. test

Di.  7 Dez. 2021 10:46:15 CET
conditions: cloudy, a bit snowing, L5 display down on table, table 2cm snow
TTFF: 7.6 secs

GPS 0.3
--------------------------------------
longitude      xx.62252017
latitude       xx.05258783
altitude (m)   588.48
accuracy       2.5
fix            3D
View sats             
S20:35.0 S30:37.0 S05:33.0 S07:29.0 S02:33.0 S06:33.0
Solution sats             
S20:35.0 S30:37.0 S07:29.0 S02:33.0 S06:33.0 
timestamp      2021-12-07 09:45:41.13
Fix time       1638866741.000
TTFF           7.6

3 Likes

It looks like the antenna is shielded by something (electronics?). Can you repeat this experiment as follows:

  • metal plate (~twice the size of the phone) on the table
  • the cardboard basket from earlier experiment on top (~10cm high)
  • L5 up on top of the basket
    If this gives good results: still doubtful antenna connection. Ground plate reflection provides antenna gain (snow may have the same effect)

I did so. See photo. Btw: the basket is made of thin wood, if this does any matter. With display in direction sky no satellite visible at all. WIth display down, a 3D fix within ~68 secs:

...
fix            3D
View sats
S06:26.0 S11:22.0 S19:26.0 S09:27.0 S02:29.0 S20:23.0
Solution sats
S06:26.0 S19:26.0 S09:27.0 S02:29.0 S20:23.0
timestamp      2021-12-08 08:15:19.26
Fix time       1638947719.000
TTFF           67.8

I did the same yesterday on top of my car. Display down gets a fast fix.

Does this mean that the antenna of the GNSS chip is located wrong in the device?

3 Likes

I have generally been outside holding the phone so that I can read the screen i.e. neither directly down nor directly up (but probably more up than down).

PS What’s all that white stuff all over the place? :joy:

1 Like

it proves that it’s a good idea to have a heating device in your pocket. that’s why purism doesnt solve the power consumption problem until spring! :wink:

5 Likes

Yes, possibly enforced by bad connection (earth). With a good connection the signal should be enough in almost every direction.


The picture shows the possible ground reflection when the L5 is about 10cm above surface. This could clarify the good reception when “up” about 1/2 lambda (~10cm) above earth. But I expected this good reception also with a metal plate. (what is the black thing under the basket? It changes the distance. In the Ghz frequencies distance between antenna and reflector is very sensitive ).

4 Likes

This black thing is a metal plate of 20x20cm (as you said I should put below the basket), material is perhaps iron with Teflon cover (some plate from a grill). Should I test something else or bigger?

It should be a bigger area, I forgot the distance. Think of 1m x 1m. You can use aluminum folio or similar metallic cover with good conductivity. It’s a bit like the reflector of a yagi antenna without directors. (or a satellite disk with infinite radius).

By the way it should not be like this. In good condition the GPS antenna should function in almost all directions by directly (not indirectly due to reflection) receiving the satellite signals. The 10cm box was just a lucky accident (unless you deliberately choose this distance based on knowledge of the GPS frequency)

Thanks, I will do it the other day, it’s snowing today here. The basket was just taken by accident because I didn’t wanted to put the L5 on the earth. And also by accident it is exactly 10cm high.

Interestingly enough, after upgrading gnss-share (and then removing it and reverting back to the python version) my gps does not work anymore.

grep -a ‘GSV’ /dev/gnss0

returns nothing even in clear sky after a couple of hours. Starting gnss-share and pure-maps I never get a fix, and running gpsd and xgps (which used to display the available satellites) reports nothing.

cat /dev/gnss0

returns something, so the gps chip seems to be working, no idea what could have happened. Anybody?