FORUMS
Remove All Ads from XDA

[GPS/AGPS] REAL solution analysis thread (Jupiter Tweaks) - v006! - Froyo JI6

686 posts
Thanks Meter: 938
 
By CLShortFuse, Retired Recognized Developer on 22nd September 2010, 04:14 PM
Post Reply Email Thread
Here's that donate button you guys were looking for. >_>
https://www.paypal.com/cgi-bin/websc...=7ELH2CPLUZLQY



ANECDOTAL EVIDENCE IS NOT REAL EVIDENCE!!!
Get My Tracks from Google Market and post your GPS trip.

My first Froyo 2.2 test:

http://maps.google.com/maps/ms?ie=UT...2c10ac25693114

Jupiter.XML
Jupiter.XML is not a Samsung specific file.

Jupiter mods
I've been modifying some information from the Jupiter XML to get different results. After installing a new jupiter.XML, got to LBSTestMode and select Delete GPS Data.
They can be installed by:
Code:
adb push jupiter.xml /system/etc/jupiter.xml

or (if permission denied)

adb push jupiter.xml /sdcard/jupiter.xml
adb shell
su
busybox cp /sdcard/jupiter.xml /system/etc/jupiter.xml
rm /sdcard/jupiter.xml

I made some changes to Jupiter (hopefully) enabled low noise amplification and remove a lag while trying to regain a hot fix.
Jupiter-v001.zip

Here's a v002 without ANY AGPS data. Because of a theory that AGPS is causing inaccuracy problems, I've disabled it completely. The fix will take longer, but maybe it'll be more accurate. With AGPS off, you won't get signal indoors. Remember that please and this is for the sake of testing.
AGPS doesn't have anything to do with accuracy. Stick with v001
Removed
You should also disable AGPS within Android
You can disable AGPS this way

Code:
adb shell
su
cd /dbdata/databases/com.android.providers.settings
sqlite3 settings.db
update secure set value="0" where name = "assisted_gps_enabled";
.quit
reboot
v003 has AGPS again. Make sure you enable AGPS in android provider settings (see above). I also switched the SUPL to supl.google.com:7576 instead of spirent. I changed the FrqPlan to match the Blackberry devices FrqPlan.
Jupiter-v003.zip

v004 is based on XWJP4 from a i9000 build.
I changed a lot. I made my changes to jupiter.xml (disabled the LNA for testing) and I'm using unstable 300ppb (even though I think ppb are meaningless since ppm are more important). It has LBS data enabled from this firmware. Also, I put the new drivers and forced SUPL to supl.google.com in both jupiter and gps.conf
pulled for more testing

v005 are tweaks from XWJP4. I couldn't get the new libgps.so to work on our Captivates (crashes on boot). gps.conf goes in (/system)/etc
Jupiter-v005.zip

v006 is JI6 compatible. JI6 (the Froyo build) uses the same GPS driver structure as i9000 XWJP4, so we might be able to swap files. This also means it's compatible with i9000 devices. This is mostly playing with SUPL to point to Google and remove a possible fix lag.
/system/etc/jupiter.xml
/system/etc/gps.conf
/data/gps/secgps.conf
Jupiter-v006.zip

Jupiter Research
It's a interface configuration file for GLGPS from Broadcom. If Samsung messed up, IT'S HERE

These are Samsung's settings (with OH7 OTA)
LogPriMask="LOG_DEBUG"
LogFacMask="LOG_GLLAPI | LOG_DEVIA | LOG_NMEA | LOG_RAWDATA | LOG_DEVMS | LOG_ASIC_IO | LOG_BBTEST | LOG_DEVET | LOG_MESM | LOG_DEVKF | LOG_DEVJG | LOG_DEVMR"
FrqPlan="FRQ_PLAN_26MHZ_2PPM_26MHZ_300PPB_UNSTABLE "
RfType="GL_RF_4751_DANUBE"
BrcmRFwildBase="0x1E2D6409"
BrcmRFclkDiv="21"
BrcmRFclkRefHz="26000000"
pps-enable="false"
pps-offset-ms="0"
pps-width-ns="100"

THIS IS WHAT WE SHOULD PLAY WITH!

I'm done some research and these are values for FrqPlan:

The TCXO has to be accurate +/- 2.0 ppm.
The number after FRQ_PLAN_ describes the type of TCXO used, for example,
FRQ_PLAN_13MHZ_2PPM is a 13MHz reference clock.
FRQ_PLAN_13MHZ_2PPM
FRQ_PLAN_16_8MHZ_2PPM
FRQ_PLAN_26MHZ_2PPM
FRQ_PLAN_10MHZ_2PPM_10MHZ_50PPB
FRQ_PLAN_20000_2PPM_13MHZ_50PPB
FRQ_PLAN_27456_2PPM_26MHZ_50PPB
FRQ_PLAN_33600_2PPM_26MHZ_50PPB
FRQ_PLAN_19200_2PPM_26MHZ_100PPB

RfType values:
GL_RF_PALS7
GL_RF_BARRACUDA
GL_RF_2075_LN22
GL_RF_2075_BRCM
GL_RF_PALS7_BRCM
GL_RF_BARRACUDA_BRCM
GL_RF_BARRACUDA_EXT_LNA

I found this info here:

http://openembed.com/files/pdk15_imx35__Linux_RM.pdf

Captivate Settings from OTA OH7:
Code:

I stripped everything else because we don't need it. We're not debugging. In fact, that might be a reason for the lag (all that unnecessary debugging).

This is the HTC Legend's XML file
Code:

See a difference? NO debugging and different FRQPlan (different chip anyway)

I FOUND SOMETHING WORTHWHILE!!!
Blackberry device that uses the same chip. Here are the settings for gl1
Code:

Blah blah blah! Re-education part

I think a lot of you are playing with options, not knowing what you're doing. I've written some GPS applications for WinMo (check my post history) and have taken a look at this issue. I'm currently working on a project that uses the GPS and Android phones. I negotiated a deal with AT&T to get 50 Samsung Captivates (@ $150 each) with 2GB/mo ($25/mo) for a client and I think I'm going to cancel that.

I don't think many of you understand what's going on with the phone or what AGPS does. AGPS is basically GPS support with cell towers. There are different levels of cell tower support.

MS-Based usually just uses the cell tower's location (not yours) to figure out where you are. This will allow you to go online, and get the cell tower number and find out it's GPS location. From there, the GPS using satellite charting data to find and keep a fix. GPS almanac data (says where the satellites are in the sky) can be supplied by the cell tower (the point of MS-Based), downloaded over the internet or downloaded from GPS signals (the last of the 3 being the slowest). Getting a fix without having any satellite data or positioning is known as a cold fix.

MS-Assisted does what you guys would already figure is happening. It uses the cell tower positioning and cell tower signal central to triangulate your position. In WinMo this would disable your data connection but it seems that's not the case in Android. Regardless it might slow down your internet. Obviously the accuracy here is poor.

SUPL just tells you the lat/long position of the cell towers so changing servers does nearly nothing. Google may have faster SUPL servers than spirent but the data should be the same. Once you have that data, it should be cached locally (but who knows, this is Samsung we're talking about.)

The problem is, technically speaking, the GPS should work even without AGPS. I have a couple of GPS devices with SIRFIII and it works beautifully, no AGPS needed. It should be able to download the almanac, ephemeris and time from the GPS satellites without any cell towers. That's how you know the issue isn't your settings.

Disable AGPS and you'll realize you have no options to play with. You're all playing with AGPS settings which aren't really hardware based GPS (and thus inaccurate). AGPS is not accurate. It was never meant to replace hardware GPS (which is why they put hardware GPS in phones). Hardware GPS has much more accuracy but the fact is, hardware GPS is NOT working on the Samsung Captivate. That's the baseline problem. Forget your AGPS settings. AGPS should only help you with almanac data and getting faster fixes but after that it should be running on standalone hardware and only fall back to the inaccurate AGPS when you lose a clear view of the sky (like when you're in a tunnel).

I notice little issue when I'm standing still. It's when I'm moving that the accuracy dies. With further investigation, it seems the GPS literally stops updating the location after a couple of seconds. You don't notice if you're standing still since you're in the same spot, but when you're driving you'll see it. The GPS freezes for about 20 to 30 seconds.

The question is: Why is it not working?
Here are my hypotheses.

1) There's a function running that borks the GPS and makes the GPS driver crash or lag. The GPS driver quietly reboots and then it gets a fix. This could be the reason why, after disabling and enabling GPS, it grabs a hot-started fix of a location it was struggling to get before. You manually reset the GPS driver. I've tested it with Google Maps/Navigation. The GPS doesn't move for 30 seconds. It freezes, but when I close (disable GPS) and open the app (enable GPS) it gets a hot started fix in 5 seconds. Had I not disabled and enabled the GPS, it would have lagged there. This could be a software issue.

2) The GPS isn't using the almanac data. The almanac data says where the GPS satellites are now and where they will be. The GPS uses this to track. If this isn't used, it needs to get a fix again every so often.

3) Cell towers are actually messing you up because their times are desynchronized or almanac data is outdated. (and we all would love to blame AT&T)

As for my project, I'm ready to change my order from 50 Captivates to 50 Xperia X10 phone. The X10 actually has a WORKING GPS (meaning my app works fine and isn't the cause). I have both phones that AT&T gave me to develop my application. I wis
 
 
22nd September 2010, 04:23 PM |#2  
malfuncion's Avatar
Senior Member
Flag Norman, OK
Thanks Meter: 63
 
More
Thank you for the info. I am eagerly awaiting a true fix
22nd September 2010, 04:25 PM |#3  
Member
Flag Texas
Thanks Meter: 14
 
More
makes sense, let us know of your future findings
22nd September 2010, 04:34 PM |#4  
Junior Member
Thanks Meter: 0
 
More
I just want to say this is an excellent post and very informative. Thanks for writing it. Unfortunately, I'm seriously debating returning my Captivate over this whole fiasco. The OTA hotfix that's pushing out today does nothing to fix this issue and I some how doubt this will be resolved any time soon.
22nd September 2010, 04:51 PM |#5  
Senior Member
Thanks Meter: 10
 
More
There are two test ROMS that were leaked, JH2 and JH3, that already have GPS logging enabled by default. We've been turning it off since the data isn't useful to us and it fills up the phone's storage quickly. Would those logs be useful to you?
22nd September 2010, 04:57 PM |#6  
OP Retired Recognized Developer
Thanks Meter: 938
 
Donate to Me
More
I have a Captivate, so I don't need the logs really. What are your experiences with Dynamic Accuracy off? I feel like that could be the issue. I know the GPS disables after 120 seconds with Dynamic Accuracy off, but when it does work, how well does it work for you guys?

Also, is the GPS issue for ALL Galaxy S devices? (Vibrant/Captivate/i9000)
22nd September 2010, 05:19 PM |#7  
Member
Flag Texas
Thanks Meter: 14
 
More
I just got my captivate so i havent been around long, but i know for sure it affects all the US versions of the Galaxy S series (Fascinate, epic 4g, captivate, vibrant), im not sure about the European i9000
22nd September 2010, 05:27 PM |#8  
Senior Member
Thanks Meter: 258
 
More
It affects all Galaxy S phones regardless where you bought them. And the issue is with BroadCom (the GPS chip maker). There is a faulty driver and/or faulty chip firmware. From what I gather, BroadCOM gave Samsung the updated driver at the end of the August which our latest JH7 probably doesn't have.
22nd September 2010, 05:28 PM |#9  
compuguy1088's Avatar
Senior Member
Flag NoVA
Thanks Meter: 98
 
More
Quote:
Originally Posted by faspalma

I just want to say this is an excellent post and very informative. Thanks for writing it. Unfortunately, I'm seriously debating returning my Captivate over this whole fiasco. The OTA hotfix that's pushing out today does nothing to fix this issue and I some how doubt this will be resolved any time soon.

According to Engadget, the latest update being pushed by AT&T "fixes" the gps issues: http://www.engadget.com/2010/09/22/s...ions-wait-pat/
22nd September 2010, 05:40 PM |#10  
Senior Member
Thanks Meter: 258
 
More
Quote:
Originally Posted by compuguy1088

According to Engadget, the latest update being pushed by AT&T "fixes" the gps issues: http://www.engadget.com/2010/09/22/s...ions-wait-pat/

Engadget is full of it.
22nd September 2010, 05:42 PM |#11  
compuguy1088's Avatar
Senior Member
Flag NoVA
Thanks Meter: 98
 
More
Quote:
Originally Posted by foxbat121

Engadget is full of it.

I think it is more that samsung "is full of it", because they are stating the gps is fixed. Engadget is just relaying what Samsung is saying....
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes