It takes usually some 40-120 seconds for Freerunner GPS to get the first fix (TTFF = Time To First Fix) after powering on the GPS (and starting gpsd?). Some months ago I heard about AGPS or Assisted GPS which basically means that the current location of GPS satellites is downloaded from a server over GPRS. So I added AGPS in my Openmoko Ideas/Wishlist – if commercial phones can do it, why couldn’t Freerunner :)
Today I saw agps package released at opkg.org and I had to try it. This it how you can make it work on 2008.12
- Make sure your GPS & GPRS work. Kustomizer will install all required packages for this on a clean 2008.12.
- Register for an agps account by emailing: agps-account@u-blox.com – no worries, it’s free
- Install AGPS package on your Freerunner: http://www.opkg.org/package_127.html
- Edit /usr/bin/agps on Freerunner. Let’s add some required information:
- Find the coordinates where you live at Openstreetmap (scroll to your place , click ‘permalink’ and copy the coordinates from the url: http://openstreetmap.org/?lat=60.976&lon=25.6942&zoom=12&layers=B000FTF turns into -la 60.97 -lo 25.6942
- Google the approximate height of the place where you live, in meters. -a 40 for 40 meters
- Decide the precision ie. the radius of the area (in kilometers) in where you want to use agps. The smaller the radius,the better the precision. -p 150 for 150km radius, 300km diameter.
- Check your email for agps user information. Your username is your e-mail address and they give you a password, for example qw3rtY. This gives you -u email@address.com -k qw3rtY
- To get the full information from the server, we use -c full
- Change the agps-onlinec -line to something like this:
/usr/bin/agpsc-onlinec -c full -u email@address.com -k qw3rt -la 60.976 -lo 25.6942 -al 40 -p 150 - If you want, you can add gpsdcontrol.py in the beginning of the file to start gpsd when agps is run
- That’s it!
Start GPRS, run AGPS, run Tangogps. Agps downloads about 4k of satellite information from ublox servers and Tangogps starts to show you that it sees about 13 satellites (even if you’re inside :). On my first trial it took 19s to get a good fix, including starting of gpsd. Nice :)
Enjoy your freedom!
Thanks to Joseph Reeves for the package!
Related posts:
- GPS-reitin piirtely fillarilenkkiä varten / Babelfish Kuinka suunnitella reitti fillarilenkkiä varten, luoda sille GPX-jälki ja muokata...
Since several months, there are python and perl scripts on the wiki doing exactly the same – why does it need someone writing a C port of those before AGPS gets any attention?
@TheSane: I don’t think it requires a C port but an opkg package makes it a lot easier to try and see that it works :)