SHR Unstable

Joel Newkirk freerunner at newkirk.us
Mon Jan 26 22:09:12 CET 2009


On Mon, 26 Jan 2009 09:36:56 -0800 (PST), Chris Syntichakis
<chris at c-64.mobi> wrote:
> 
> Hi,
> 
> How can I activate the GPS with the SHR?
> 
> I open the tangoGPS but I got no info if the gps is on or getting data..
> 
> Chris

The line of text across below the map view (above the Map|Trip|Track etc
tabs) shows GPS info as does the Trip display.  Of particular interest on
the map view is the last group of characters - 0/0/0.0 when first started. 
On mine (SHR-unstable+updates) it changes to "12/0/0.0" after about 10-15
seconds.  The "12" is referring to 12 satellites for which it thinks it has
positions.  The second number is the number of those satellites it is
actually tracking.  For me that stays at zero (no fix until 3-4 sats
tracked) for anywhere from 45 secs to 5 mins depending on sky visibility,
at which point I almost always pick up 3-5 sats at once and have first fix.

With SHR the GPS is handled by frameworkd, with fso-gpsd acting as a
backward-compatibility layer for things (like TangoGPS) that can talk to
gpsd but not dbus+frameworkd.

But what happens is that frameworkd "feeds the kitty" at startup of GPS
(when something - including fso-gpsd - requests the GPS resource, it starts
it) and sends the GPS some assistance data.  The problem I had for a time
(haha) was that if the clock on the FR is way off it will NEVER get a GPS
fix, likely due to frameworkd stuffing thoroughly-invalid data into it at
the start.  (I'd always presumed that 'worst-case' it would take much
longer to get a fix, IE as long as completely unassisted)

Make sure the clock on the FR is both correctly and accurately set.  Check
/etc/timezone - the default setting is "Europe/London" IIRC.  you /should/
be able to use anything under /usr/share/zoneinfo. I emphasized "should"
because I could never get it to work correctly with EST5EDT, but it works
with America/New_York. (same timezone - I also wasted time & effort trying
to make /etc/timezone a symlink to the appropriate zoneinfo file, the
'standard' zoneinfo usage, rather than putting the name of the chosen zone
in /etc/timezone)  Once that's set up, reboot and check the clock.  The
date command tells you the configured timezone as well as what it believes
to be local time.  Assuming that's correct, make sure you have pretty clear
view of at least most of the sky (for first tests at least) and fire up
TangoGPS.  Hopefully you'll see some activity pretty quickly.  If that
first number changes away from zero fut the second one never does, then
likely you have insufficient visibility.  If they both stay at zero then
I'd take a look again at the clock...

Oh, and you may need some touchscreen or Aux-button activity periodically
to make sure it doesn't suspend while waiting for first fix.

On my SHR-powered FR, indoors, I just fired up TangoGPS as I was writing
this, and it got a fix in about 2 mins, lost it when I moved the phone
elsewhere on my desk, then regained it in another 4 mins or so, my numbers
for reference are 12/4/2.1.  These are the relevant lines from my
/var/log/frameworkd.log:

2009.01.26 15:44:46 ogspd.gpsdevice INFO     enabling
2009.01.26 15:44:46 ogpsd    WARNING  (could not write to
'/sys/bus/platform/devices/neo1973-pm-gps.0/pwron': [Errno 2] No such file
or directory: '/sys/bus/platform/devices/neo1973-pm-gps.0/pwron')
2009.01.26 15:44:50 ogpsd    WARNING   UBX packet ignored
"\xb5b\x01\x04\x12\x00\x80@\x9a\t\x0f'\x0f'\x0f'\x0f'\x0f'\x0f\x00'\x0f'\xf4\xf8"
2009.01.26 15:44:51 ogpsd    WARNING   UBX packet ignored
'\xb5b\x01\x12$\x00\x80@\x9a\t\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'
2009.01.26 15:52:44 ogpsd    WARNING   UBX packet ignored
'\xb5b\x01\x04\x12\x00\x00\xb1\x8b\xa1\t%\x01\t\x01}\x00d\x00\xf5\x00\x90\x00\xc7\x00Z.'
2009.01.26 15:52:44 ogpsd    WARNING   UBX packet ignored
'\xb5b\x01\x12$\x00\xb1\x8b\xa1\t\x0e\x00\x00\x00\x05\x00\x00\x00\x84\x94'

Just so you know that those warnings are NOT a failure, despite them it has
accurately located me at the back of my house... The first warning ("no
such file") I believe arises because frameworkd hits both sysfs locations
for GPS power - 2.6.24 and 2.6.28 kernel variations, knowing that one will
work and the other will cause no grief.

j

-- 
Joel Newkirk
http://jthinks.com      (blog)
http://newkirk.us/om (FR stuff)





More information about the community mailing list