Related
Just wondering if anyone has discovered how to speed up the GPS lock time.
I am running shubCRAFT CM6RC2/Froyo/Themed V1.1 and while the GPS works the lock time is upto a few minutes.
In windows I will raise an eyebrow after 10 seconds.
I have seen the posts regarding both the latest libgps.so and updating the GPS file but not sure if thats the issue.
Is the GPS using GPSa?
From what I understand the QuickGPS is a map of satellite locations. The idea is once a single satellite is located then the GPS knows what other ones are in the area instead of blindly looking for all of them its just looks for a few. Still slow to find the first satellite.
GPS-a uses a local cell site to tell the GPS where it is. It can then use the QuickGPS to discover what satellites should be overhead and only looks for those. Nice quick lock times.
Are we using GPS-a?
The fix is not to update your gps.conf file and to use local NTP server settings. Whilst it is ideal to use local time servers this does not impact your phones retrieval of the GPS-A data. The time retrieved from the states is exactly the same as Australia.
UPDATE : The Fix
It looks like there maybe an issues with the way Android on HD2 downloads the GPS-A Data. If you download a Tool from the market place called GPS Status. You can use it to download the GPS-A data manually. BAMM. Fresh GPS locks in 3 seconds versus minutes before hand.
Not sure if this process logs any messages and assume it is a cron job but ideally needs some investigation.
Thanks
this has been covered already
Miyagi said:
Install "File Manager" and "Text Edit" (both are free from the market), then open "File Manager", go to "My Phone", (press Ok on warning), the go to /system, /etc and touch on "gps.conf", Open as, Text, and select "Text Edit".
Edit and use your country direction (pool.ntp.org), save and thats all.
Click to expand...
Click to collapse
songokussm said:
i did not for for me at first. you need to use one of the following servers.
server 0.us.pool.ntp.org
server 1.us.pool.ntp.org
server 2.us.pool.ntp.org
server 3.us.pool.ntp.org
Click to expand...
Click to collapse
I tried this yesterday and it works great. Change your NTP server to one of the following, if not in the US, look up your country.
Have questions.
Why is changing the time server improve the GPS lock speed. Both the existing server and the new server will provide the same results. Only difference is the reponse time in milliseconds?
Also can edit the file however cannot save it. File is read only.
Can you confirm the Text edit and File manager. There are mulitples in the market. Who are the authors?
Hmm. Readonly file system is going to cause an issue. Back to question 1
What rom are you using? I'm running mattc leo 1.4
File Manager by Adao Team
Text Edit by Paul Mach
I didn't have a problem saving, others reported issues. Try a different text editor.
As far as lock times, before I couldn't get any lock at all. After applying the update I walked outside, instant lock, tried inside, 3-4 second lock.
Thats the difference. I do get a lock but its slow.
I have just queried the north-america.pool.ntp.org server and compared the output to the query from 1.au.pool.ntp.org.
The results are the same. Changing the ntp server won't make a difference.
Now checking if there is some sort of other issue. Noticing dns does not work at console.
dusty_nz said:
Thats the difference. I do get a lock but its slow.
I have just queried the north-america.pool.ntp.org server and compared the output to the query from 1.au.pool.ntp.org.
The results are the same. Changing the ntp server won't make a difference.
Now checking if there is some sort of other issue. Noticing dns does not work at console.
Click to expand...
Click to collapse
did you fill in 1 of the 4 below?:
server 0.us.pool.ntp.org
server 1.us.pool.ntp.org
server 2.us.pool.ntp.org
server 3.us.pool.ntp.org
You just choose one, for example: "0.us.pool.ntp.org"
Not "north-america.pool.ntp.org"
I had the exact same problem with super slow GPS lock, but i changed the ntp server to point to Canada (since i live in Canada) and my GPS lock was seconds.
I personally think it made a huge difference
**edit
Oh, and i used "Text Edit" and "Linda Manager" to do the changes.
I got the same error saying it was read-only, but it still saved the changes. You need to reboot into Android after you make the changes. After you reboot, just go back in with the File Manager and check if your changes are still there (they should be, even though you get the read-only error)
Then try your GPS lock again.
I use Google maps with Google Navigator and it locked in about 5 seconds.
You can also check your in Android "Settings" - "Location and Secrutiy" to have both "Use Wireless Networks" and "Use GPS Satellites" checked off
Gone further.
Installed a ntp client on the phone and tested both north-america.pool.ntp.org and 1.au.pool.ntp.org and both work and give the same response.
I am in australia so the au one is the pick. Using the shubCRAFT rom and the whole file system is readonly.
Need a windows tool to edit the img files. Any recommendations?
Still confused why the au one os better than the north american one. Both work. They are just time servers.
for some reason my gps.conf is blank. Can someone please post their content of this file for me? (Northeastern US region)
Many thanks
norman505 said:
for some reason my gps.conf is blank. Can someone please post their content of this file for me? (Northeastern US region)
Many thanks
Click to expand...
Click to collapse
Check/Read this thread: http://ip208-100-42-21.static.xda-developers.com/showthread.php?p=7410015
Update. See first post.
If GPS Status actually works to get AGPS going then that's great news. Having more accurate times by using local NTP servers does help lock times slightly, but real, working AGPS is the answer we want, and despite the SIPL setting in gps.conf, it doesn't look like it's working by default on the HD2.
EDIT: It looks like GPS Status grabs the AGPS data on launch for me, so all you need to do is setup Tasker to launch GPS Status whenever GPS is turned on and you should have instant lock. I'll test it out tomorrow when I get outside.
dusty_nz said:
Just wondering if anyone has discovered how to speed up the GPS lock time.
I am running shubCRAFT CM6RC2/Froyo/Themed V1.1 and while the GPS works the lock time is upto a few minutes.
In windows I will raise an eyebrow after 10 seconds.
I have seen the posts regarding both the latest libgps.so and updating the GPS file but not sure if thats the issue.
Is the GPS using GPSa?
From what I understand the QuickGPS is a map of satellite locations. The idea is once a single satellite is located then the GPS knows what other ones are in the area instead of blindly looking for all of them its just looks for a few. Still slow to find the first satellite.
GPS-a uses a local cell site to tell the GPS where it is. It can then use the QuickGPS to discover what satellites should be overhead and only looks for those. Nice quick lock times.
Are we using GPS-a?
The fix is not to update your gps.conf file and to use local NTP server settings. Whilst it is ideal to use local time servers this does not impact your phones retrieval of the GPS-A data. The time retrieved from the states is exactly the same as Australia.
UPDATE : The Fix
It looks like there maybe an issues with the way Android on HD2 downloads the GPS-A Data. If you download a Tool from the market place called GPS Status. You can use it to download the GPS-A data manually. BAMM. Fresh GPS locks in 3 seconds versus minutes before hand.
Not sure if this process logs any messages and assume it is a cron job but ideally needs some investigation.
Thanks
Click to expand...
Click to collapse
It does help in my case, always under 30 seconds lock using MotoNav.
In my experience, if you succesfully lock ones without GPS Status, you should lock on the your GPS quickly again as long as you don't restart your phone. M2C's
Gps status works. Fix is very fast. It even works indoors if you are near the window and there is no big building in front of you.
I wrote about this some time ago.
http://forum.xda-developers.com/showthread.php?p=8366121&highlight=gps+status#post8366121
and
http://forum.xda-developers.com/showthread.php?p=8366105&highlight=gps+status#post8366105
(I provided the links so you can check other posts in two similar threads)
new version of gps status downloads sat data directly on app startup. Or you can use quickgps in winmo and download the data and then android will also fix faster. Both software downoload gps sat data valid for 7 days. I think the downloaded data is also input to the gps chip. (not only just downloaded to internal memory/sd card)
I live in Turkey and ntp servers doesn't matter for me. Even us or north-america works fine. apgs data is needed for fast fix. Some people have empty gps.conf file. gpsonxtra lines are needed for downloading sat data.
This is my gps.conf file: (in /system/etc)
NTP_SERVER=europe.pool.ntp.org
XTRA_SERVER_1=http://xtra1.gpsonextra.net/xtra.bin
XTRA_SERVER_2=http://xtra2.gpsonextra.net/xtra.bin
XTRA_SERVER_3=http://xtra3.gpsonextra.net/xtra.bin
SUPL_HOST=supl.google.com
SUPL_PORT=7276
You can change your ntp server to us.pool.ntp.org or north-america.pool.ntp.org or yourcountrycode.pool.ntp.org
I went through the entire process.
Changed the NTP server to a local server. Tested the settings using the NTP client. Checked the download link worked. Data seemed valid.
Still would take over 1-3 minutes to get a lock. A second lock within 1/2 hour was quicker but after a few hours it was slow again.
Using GPS status. Sitting in my car. Powered on the phone. Fireed up Google and bank. 2-3 seconds it had my location.
Really happy.
Lock inside 10 sec, downloading agps data with Gps Status. Thx man!
Sent from my HTC HD2 using XDA App
dusty_nz said:
Just wondering if anyone has discovered how to speed up the GPS lock time.
I am running shubCRAFT CM6RC2/Froyo/Themed V1.1 and while the GPS works the lock time is upto a few minutes.
In windows I will raise an eyebrow after 10 seconds.
I have seen the posts regarding both the latest libgps.so and updating the GPS file but not sure if thats the issue.
Is the GPS using GPSa?
From what I understand the QuickGPS is a map of satellite locations. The idea is once a single satellite is located then the GPS knows what other ones are in the area instead of blindly looking for all of them its just looks for a few. Still slow to find the first satellite.
GPS-a uses a local cell site to tell the GPS where it is. It can then use the QuickGPS to discover what satellites should be overhead and only looks for those. Nice quick lock times.
Are we using GPS-a?
The fix is not to update your gps.conf file and to use local NTP server settings. Whilst it is ideal to use local time servers this does not impact your phones retrieval of the GPS-A data. The time retrieved from the states is exactly the same as Australia.
UPDATE : The Fix
It looks like there maybe an issues with the way Android on HD2 downloads the GPS-A Data. If you download a Tool from the market place called GPS Status. You can use it to download the GPS-A data manually. BAMM. Fresh GPS locks in 3 seconds versus minutes before hand.
Not sure if this process logs any messages and assume it is a cron job but ideally needs some investigation.
Thanks
Click to expand...
Click to collapse
Purely outstanding! What a day! It appears there is a fix for the data connection issue and now this fix!
i am trying to make tasker run gps status and update agps data when the phone turns on and boots into android. ideally i'd like this operation to happen in the background and silently.... what are the steps to program tasker to operate in this way? i've never used tasker before.
is downloading the agps data on android boot really worth it, or should i just continue running gps status before i use navigation?
Sadly, I have never gotten compass or quick GPS lock working. I have tried these things as well (changing NTP server, installing GPS Status), several times, on several builds, on 3 different HD2's. Never worked.
On one HD2 I would get a GPS lock after 2-5min. On the other I could not get a lock at all.
Maybe someone in the US can post the contents of their gps.conf?
Tapping "reset" first in gps status app's manage agps settings then tapping download seems to work much better.
Sent from my HTC HD2 using XDA App
Tried. Failed.
Edited the text, now it's blank and I can't re-edit it or copy over my back-up.
EDIT: Let gps lock on. The file is now back to normal, but I can't edit it.
Hi,
A lot of people here have a very long GPS fix.
I propose you to post here your android nand or SD version, rom radio, average, max, min fix time and gps.conf file content.
To have pertinent results, I propose you the following procedure :
- Disable 3G and Wifi
- Make a cold restart
- Use gpsfix from Android Labs available in the market.
- make the test during one week each morning and afternoon at the same place (if possible)
I don't know if my thread will have success but i try.
I start
Android : NAND - prj Clean Desire v0.3.2 [Kernel: prj v0.4]
http://forum.xda-developers.com/showthread.php?t=897191
Radio : 2.15.50.14
Fix : Average 2mn30sec, Max : 7min, min 1min.
gps.conf content :
I've tested a lot of configuration so there are a lot of lines commented and uncommented
NTP_SERVER=fr.pool.ntp.org
NTP_SERVER=europe.pool.ntp.org
#XTRA_SERVER_1=http://xtra1.gpsonextra.net/xtra.bin
#XTRA_SERVER_2=http://xtra2.gpsonextra.net/xtra.bin
#XTRA_SERVER_3=http://xtra3.gpsonextra.net/xtra.bin
#XTRA_SERVER_1=0.europe.pool.ntp.org
#XTRA_SERVER_2=1.europe.pool.ntp.org
#XTRA_SERVER_3=2.europe.pool.ntp.org
#XTRA_SERVER_4=3.europe.pool.ntp.org
# DEBUG LEVELS: 0 - none, 1 - Error, 2 - Warning, 3 - Info
# 4 - Debug, 5 - Verbose
DEBUG_LEVEL = 3
# Intermediate position report, 1=enable, 0=disable
INTERMEDIATE_POS=0
# Accuracy threshold for intermediate positions
# less accurate positions are ignored, 0 for passing all positions
ACCURACY_THRES=5000
# Report supl ref location as position, 1=enable, 0=disable
REPORT_POSITION_USE_SUPL_REFLOC=0
################################
##### AGPS server settings #####
################################
# FOR SUPL SUPPORT, set the following
#SUPL_HOST=supl.google.com
#SUPL_PORT=7276
# FOR C2K PDE SUPPORT, set the following
# C2K_HOST=c2k.pde.com or IP
# C2K_PORT=1234
################################
# EXTRA SETTINGS
################################
#CURRENT_CARRIER=common
#DEFAULT_AGPS_ENABLE=TRUE
#DEFAULT_SSL_ENABLE=FALSE
# Wiper (wifi positioning), 1=enable, 0=disable
ENABLE_WIPER=0
very nice idea, i'll post my results later today hopefully.
I would suggest to also add the approx age of your phone (recent, old etc...) and, very important, a lo.
you can save logs using alogcat (search for it in android market).
Here is what works best for me ..
Here is what works best for me ..
NTP_SERVER=north-america.pool.ntp.org
XTRA_SERVER_1=0.north-america.pool.ntp.org
XTRA_SERVER_2=1.north-america.pool.ntp.org
XTRA_SERVER_3=2.north-america.pool.ntp.org
XTRA_SERVER_3=3.north-america.pool.ntp.org
SUPL_HOST=lbs.geo.t-mobile.com
SUPL_PORT=7275
DEFAULT_AGPS_ENABLE=TRUE
DEFAULT_SSL_ENABLE=FALSE
ENABLE_WIPER=0
Get A Lock Very Quick ..
Cold Start:15-45 Secs
After:5-15
Give it a try.
WarlockW said:
Here is what works best for me ..
NTP_SERVER=north-america.pool.ntp.org
XTRA_SERVER_1=0.north-america.pool.ntp.org
XTRA_SERVER_2=1.north-america.pool.ntp.org
XTRA_SERVER_3=2.north-america.pool.ntp.org
XTRA_SERVER_3=3.north-america.pool.ntp.org
SUPL_HOST=lbs.geo.t-mobile.com
SUPL_PORT=7275
DEFAULT_AGPS_ENABLE=TRUE
DEFAULT_SSL_ENABLE=FALSE
ENABLE_WIPER=0
Get A Lock Very Quick ..
Cold Start:15-45 Secs
After:5-15
Give it a try.
Click to expand...
Click to collapse
It works !!! (i have the same response time as yours and i detect 10 satelites instead of 6/7 before) but i can't understand why.
1 - I'm in france and your file uses a ntp server in america.
2 - Xtra server must point to a file and you use an url to another ntp server
3 - my 3g and wifi are disabled so i can't contact neither the ntp server, neither xtra server, neither the supl host
Why does it work ?
I want to say you a big thanks but you will have to wait until tomorrow evening after another day test
What file are you guys editing to "change" the settings?
htc-hd2 said:
What file are you guys editing to "change" the settings?
Click to expand...
Click to collapse
gps.conf in system/etc
To modify it you have to use a soft like 'root explorer' on android or adb or 'DroidExplorer' on PC.
http://forum.xda-developers.com/showthread.php?t=939385
NTP_SERVER=europe.pool.ntp.org
XTRA_SERVER_1=0.europe.pool.ntp.org
XTRA_SERVER_2=1.europe.pool.ntp.org
XTRA_SERVER_3=2.europe.pool.ntp.org
XTRA_SERVER_4=3.europe.pool.ntp.org
SUPL_HOST=supl.google.com
SUPL_PORT=7276
Click to expand...
Click to collapse
RADIO: 2.15.50.14
ROM: MDJ's CyanogenMod 7 v. 2.6
Fix: 5 - 10 min. Sometimes 5-10 seconds, sometimes - never.
htcvidi, better for you to minimize the gps.conf file. You can remove all lines starting with: #
When the row starts with #, that means that this exact row is ignored.
So your gps.conf will look like:
NTP_SERVER=fr.pool.ntp.org
NTP_SERVER=europe.pool.ntp.org
DEBUG_LEVEL = 3
INTERMEDIATE_POS=0
ACCURACY_THRES=5000
REPORT_POSITION_USE_SUPL_REFLOC=0
ENABLE_WIPER=0
Click to expand...
Click to collapse
...sorry, just in case.
WarlockW said:
Here is what works best for me ..
NTP_SERVER=north-america.pool.ntp.org
XTRA_SERVER_1=0.north-america.pool.ntp.org
XTRA_SERVER_2=1.north-america.pool.ntp.org
XTRA_SERVER_3=2.north-america.pool.ntp.org
XTRA_SERVER_3=3.north-america.pool.ntp.org
SUPL_HOST=lbs.geo.t-mobile.com
SUPL_PORT=7275
DEFAULT_AGPS_ENABLE=TRUE
DEFAULT_SSL_ENABLE=FALSE
ENABLE_WIPER=0
Get A Lock Very Quick ..
Cold Start:15-45 Secs
After:5-15
Give it a try.
Click to expand...
Click to collapse
The GPS fix was very quick yesterday with your config but, unfortunately, today i have the same trouble : GPS fix time is random.
However, i remarked that when the fix is long (2 minutes or more) if i switch on/off 3g or plane mode, i have very often a fix after few secondes.
I had been having lots of problems with GPS but now after installing the latest Hyperdroid NAND rom (3.0), all seems to be well!
Getting a fix at around 10 seconds now which seems normal.
I have a feeling that the gps in the HD2 is not very sensitive, or somehow the android builds do not have the sensitivity set right?
I think this purely because it seems ok in wide open area, but even in the top room of my house where it is fine in Windows mobile, it is either slow or fails to lock on android.
htcvidi said:
gps.conf in system/etc
To modify it you have to use a soft like 'root explorer' on android or adb or 'DroidExplorer' on PC.
Click to expand...
Click to collapse
i cannot move, delete, or edit the file. ive tried various file explorers such as astro etc etc.
Ive tried searching but All i find is the same question being asked, but no real answer.
I assume I need root access, but considering this is a rom, wouldn't I already have root?
If not, what do I need, and need to do?
Wingnutt said:
i cannot move, delete, or edit the file. ive tried various file explorers such as astro etc etc.
Ive tried searching but All i find is the same question being asked, but no real answer.
I assume I need root access, but considering this is a rom, wouldn't I already have root?
If not, what do I need, and need to do?
Click to expand...
Click to collapse
You need to mount your system as read/write. By default its on read/only. R/W lets you make changes to the files and be able to save them after the changes.
mattfmartin said:
You need to mount your system as read/write. By default its on read/only. R/W lets you make changes to the files and be able to save them after the changes.
Click to expand...
Click to collapse
Can you tell me how it's done?
I'm having this same issue as many other people here. I'm unable to edit the GPS.conf file whatever I do. I've tried Astro, ES File Explorer, Super Manager, Android Mate, etc. Every single program has the same issue. They are unable to edit the GPS.conf file. I've read dozens of topics about this, but nobody has written any clear instructions.
My phone is HD2 with "Stock" NAND Android 2.3. And what I've read, it's already rooted, but I still don't have the right permissions.
Some people say, I should use Root Explorer, but is there any free solutions to this problem? All I want, is to edit the GPS.conf file in order to get the GPS working.
If you want a free solution and have a PC, try DroidExplorer.
It looks like a file explorer but for your android.
With it , you will be able to copy to your pc the gps.conf file, and 'push' it again to android.
htcvidi said:
If you want a free solution and have a PC, try DroidExplorer.
It looks like a file explorer but for your android.
With it , you will be able to copy to your pc the gps.conf file, and 'push' it again to android.
Click to expand...
Click to collapse
Tried it, didn't work. I was able to edit the file, but when I copied the new file back, it seemed to work, but when I opened the file, it still contained the old info. I tried to copy the file many times and even rebooted the device, but no success. So the issue still remains. It seems that the problem is not with the editing software, I just don't have the right permissions to edit, delete, or replace the file.
Esaj2 said:
Can you tell me how it's done?
I'm having this same issue as many other people here. I'm unable to edit the GPS.conf file whatever I do. I've tried Astro, ES File Explorer, Super Manager, Android Mate, etc. Every single program has the same issue. They are unable to edit the GPS.conf file. I've read dozens of topics about this, but nobody has written any clear instructions.
My phone is HD2 with "Stock" NAND Android 2.3. And what I've read, it's already rooted, but I still don't have the right permissions.
Some people say, I should use Root Explorer, but is there any free solutions to this problem? All I want, is to edit the GPS.conf file in order to get the GPS working.
Click to expand...
Click to collapse
If you have ES File Explorer, open the app go to Settings by pressing the middle button and you will see a Root and Mount option, click both. Then you will be able to edit the gps.conf file like I do.
htcvidi said:
Hi,
A lot of people here have a very long GPS fix.
I propose you to post here your android nand or SD version, rom radio, average, max, min fix time and gps.conf file content.
To have pertinent results, I propose you the following procedure :
- Disable 3G and Wifi
- Make a cold restart
- Use gpsfix from Android Labs available in the market.
- make the test during one week each morning and afternoon at the same place (if possible)
I don't know if my thread will have success but i try.
I start
Android : NAND - prj Clean Desire v0.3.2 [Kernel: prj v0.4]
http://forum.xda-developers.com/showthread.php?t=897191
Radio : 2.15.50.14
Fix : Average 2mn30sec, Max : 7min, min 1min.
gps.conf content :
I've tested a lot of configuration so there are a lot of lines commented and uncommented
NTP_SERVER=fr.pool.ntp.org
NTP_SERVER=europe.pool.ntp.org
#XTRA_SERVER_1=http://xtra1.gpsonextra.net/xtra.bin
#XTRA_SERVER_2=http://xtra2.gpsonextra.net/xtra.bin
#XTRA_SERVER_3=http://xtra3.gpsonextra.net/xtra.bin
#XTRA_SERVER_1=0.europe.pool.ntp.org
#XTRA_SERVER_2=1.europe.pool.ntp.org
#XTRA_SERVER_3=2.europe.pool.ntp.org
#XTRA_SERVER_4=3.europe.pool.ntp.org
# DEBUG LEVELS: 0 - none, 1 - Error, 2 - Warning, 3 - Info
# 4 - Debug, 5 - Verbose
DEBUG_LEVEL = 3
# Intermediate position report, 1=enable, 0=disable
INTERMEDIATE_POS=0
# Accuracy threshold for intermediate positions
# less accurate positions are ignored, 0 for passing all positions
ACCURACY_THRES=5000
# Report supl ref location as position, 1=enable, 0=disable
REPORT_POSITION_USE_SUPL_REFLOC=0
################################
##### AGPS server settings #####
################################
# FOR SUPL SUPPORT, set the following
#SUPL_HOST=supl.google.com
#SUPL_PORT=7276
# FOR C2K PDE SUPPORT, set the following
# C2K_HOST=c2k.pde.com or IP
# C2K_PORT=1234
################################
# EXTRA SETTINGS
################################
#CURRENT_CARRIER=common
#DEFAULT_AGPS_ENABLE=TRUE
#DEFAULT_SSL_ENABLE=FALSE
# Wiper (wifi positioning), 1=enable, 0=disable
ENABLE_WIPER=0
Click to expand...
Click to collapse
Though I am in the US, I am working with AngelDeath, another user on XDA, on creating a very fast GPS solution for the Cmylxgo Stock Desire HD(2) build we are on. I would change your NTP_SERVER command line and add all the servers available for you in France. So instead of you having the "generic" fr.pool.ntp.org line. Go with NTP_SERVER=0.fr.pool.ntp.org, and do it again for servers 1-3. That way you will be accessing all the servers. I would also enable your INTERMEDIATE_POS command line and use the =1 and not =0. Seems to reduce the lock time for me. Do the same for the REPORT_POSITION_USE command line. Also add below the SUPL_PORT=7276 command line SUPL_SECURE_PORT=7275. This helps non-TMOUS carrier users to lock faster as well. I have quite a few changes to the gps.conf file and get cold starts under 25 seconds with relocks in 4-7 seconds. Using nav apps such as Car Home, I am able to get locks within three GPS pulses after first fix. But of course, the command lines I am using are now very specific to my region of the US.
slbenz said:
Though I am in the US, I am working with AngelDeath, another user on XDA, on creating a very fast GPS solution for the Cmylxgo Stock Desire HD(2) build we are on. I would change your NTP_SERVER command line and add all the servers available for you in France. So instead of you having the "generic" fr.pool.ntp.org line. Go with NTP_SERVER=0.fr.pool.ntp.org, and do it again for servers 1-3. That way you will be accessing all the servers. I would also enable your INTERMEDIATE_POS command line and use the =1 and not =0. Seems to reduce the lock time for me. Do the same for the REPORT_POSITION_USE command line. Also add below the SUPL_PORT=7276 command line SUPL_SECURE_PORT=7275. This helps non-TMOUS carrier users to lock faster as well. I have quite a few changes to the gps.conf file and get cold starts under 25 seconds with relocks in 4-7 seconds. Using nav apps such as Car Home, I am able to get locks within three GPS pulses after first fix. But of course, the command lines I am using are now very specific to my region of the US.
Click to expand...
Click to collapse
I'm still confused with all different settings. I'm on tmous, what settings do you recommend for tmous users? I tried to replace gps.conf from Cmylxgo over my ROM but problem still exist.
Okay, if everyone would just give me few days, I am going to open a thread about this and explain what I have learned about the GPS, I know alot of people are having trouble, or even some better people then me have come up with solutions, but it seems that something was over looked when it came to GPS, in the last 3 days I have figured out how all this plays together, and part of me doesnt understand why delevopers (Not talking about rom dev or cookers) did this, its seems at least for the last 3 years we have been going about this all the wrong way.
If everyone would just give me till the end of the week, I will open a thread and explain all this in length, but I also have promised Cmylxgo that if his upcoming rom isnt going to be too far long, then I would hold off until after his release, but I hope to find that out very soon.
Just as a teaser, In the USA region I have now accomplished for the east coast first locks in under 20s and all reboots and reloads to a majority of 3s relocks. At this point I consider this instantaneous and cannot get any faster locks. I also plan to make 6 region files:
USA
Europe
UK
Asia
Oceania
South America
Africa
All the ones for all other countries will not have as extensive commands as the US, for 2 reasons: 1) I dont live in those locations, and two, the servers are not as vast, but I am quite sure it will be better then what anyone has currently running.
slbenz said:
If you have ES File Explorer, open the app go to Settings by pressing the middle button and you will see a Root and Mount option, click both. Then you will be able to edit the gps.conf file like I do.
Click to expand...
Click to collapse
Tried that, but I had problems. When I go to settings and try to activate the Root option, it tells me that this is an experimental feature and when I click "YES", It gives me two choices: Select ROM: 1. Cyanogen Mod / 2. HiAPK. No matter which I choose, it says to me "Sorry test failed, this feature cannot run on your phone". So is there any alternative way of fixing this or any other program, which I could use? Or is there any way to get the gps.conf file writeable?
Could this problem being caused by the custom NAND ROM? I have THIS ROM.
ES file explorer wont work ,says its incompatible with my phone, regardless of which mod (neither of which I have) I select. No surprise.
trying to use droid explorer, but it keeps timing out when saying "downloading tools" and force closing..
Typical, you have a problem, find out what (may) be the solution.. try to get that app/program to fix your original problem, only to fin out the program needed to fix your problem is broke, so now you have to skew off in an entire different direction to try and fix the problem with the program you need to fix your problem.
I love this ****.
I posted this in the v1.3 thread but no replies in like nearly 10 pages, so here it is.
Every time I install a new ROM (I never update) I remove a lot of system apps I don't use to save space like the live wallpapers, email.apk, exchange.apk etc. I've been wondering, just because, is it possible to remove these (see below) .apk's safely just since I don't think I need them anymore.
BackupRestoreConfirmation.apk
ChromeBookmarksSyncAdapter.apk
OneTimeInitializer.apk
SetupWizard.apk
VpnDialogs.apk
WAPPushManager.apk
It would be nice to know what these apps do. From when I had my SE u20i OneTimeInitializer.apk was used to download mobile data settings at first boot, is that correct? So I would assume that is obsolete now?
VpnDialogs.apk I don't think I need as I don't use a vpn, correct?
SetupWizard.apk I assume is for setting up a google account? If I've already done that do I really need this as I'm not going to delete it?
ChromeBookmarksSyncAdapter.apk If I don't use Chrome, on my HD2 or my laptop or desktop do I really need this? I'm assuming it is the sync of bookmarks to my google account?
The other two I have no idea about. Also, if any apps, these included can be removed before flashing the ROM to save space on /system it would be nice to know that was well.
If someone could please help me with is or point me in the right direction of info, that would be greatly appreciated.
Btw I have searched. (Just in case someone tries to tell me to do that)
Cheers,
Evil.
These apps are core system apps. You can't remove them. Yes, there are some which can be removed but not these.
That's not entirely true vpndialogs isn't a core system app but I just really want to know what they do and then if they are crucial to first boot or not. I guess alot of testing can tell me if they are crucial, but I still don't know what they do????? And that's the main point of me starting this question thread.
evilbarcode said:
That's not entirely true vpndialogs isn't a core system app but I just really want to know what they do and then if they are crucial to first boot or not. I guess alot of testing can tell me if they are crucial, but I still don't know what they do????? And that's the main point of me starting this question thread.
Click to expand...
Click to collapse
BackupRestoreConfirmation.apk (dunno...but freezing it instantly after fresh flash..save)
ChromeBookmarksSyncAdapter.apk (sync's your bookmarks from pc chrome if installed...deleted this one before flashing...save)
OneTimeInitializer.apk( seemes it cinfigures your provider setup...but doesn't really know. So try to freez and change SIM-card...if you get errors on next startup, you are sure!)
SetupWizard.apk (initialize first setup after fresh flash...needed only this time. After that it is save to delete or freeze. BUT it is needed for first boot otherwise you get bootloops!)
VpnDialogs.apk (dunno...doesn't use VPN)
WAPPushManager.apk
* The WapPushManager service is implemented to process incoming
* WAP Push messages and to maintain the Receiver Application/Application
* ID mapping. The WapPushManager runs as a system service, and only the
* WapPushManager can update the WAP Push message and Receiver Application
* mapping (Application ID Table). When the device receives an SMS WAP Push
* message, the WapPushManager looks up the Receiver Application name in
* Application ID Table. If an application is found, the application is
* launched using its full component name instead of broadcasting an implicit
* Intent. If a Receiver Application is not found in the Application ID
* Table or the WapPushManager returns a process-further value, the
* telephony stack will process the message using existing message processing
* flow, and broadcast an implicit Intent.
Click to expand...
Click to collapse
(just leave it!)
icke said:
BackupRestoreConfirmation.apk (dunno...but freezing it instantly after fresh flash..save)
ChromeBookmarksSyncAdapter.apk (sync's your bookmarks from pc chrome if installed...deleted this one before flashing...save)
OneTimeInitializer.apk( seemes it cinfigures your provider setup...but doesn't really know. So try to freez and change SIM-card...if you get errors on next startup, you are sure!)
SetupWizard.apk (initialize first setup after fresh flash...needed only this time. After that it is save to delete or freeze. BUT it is needed for first boot otherwise you get bootloops!)
VpnDialogs.apk (dunno...doesn't use VPN)
WAPPushManager.apk (just leave it!)
Click to expand...
Click to collapse
This was a big help thank you.
As I understand it, the wappushmanager.apk is only useful when sending and receiving sms push msgs??
So if that is correct I wouldnt need it as I don't send or receive push msgs (i dont even think my carrier supports it), unless every sms is handled as a push msg, in which case the wappushmanager.apk is necessary.
I will do some testing and post back here with my findings.
The reason I want to know all this info is because I'm going to start a thread for people with small sdcards, so they can reduce the size of the system before flashing to save space for data instead of a data script.
Thank you for your help,
Evil.
evilbarcode said:
I will do some testing and post back here with my findings.
Click to expand...
Click to collapse
So, did it work?
Hello all, I've been searching the forums for a similar thread but didn't find anything, so I'm going ahead and posting my advice, hope it can be useful to HD2 fellow owners. I came into possession of an euro HD2 one month ago (my mom didn't use it, it's practically new, lucky me), installed straight away an Android ROM, Tytung's "NexusHD2-JellyBean-4.1.2-CM10 V1.3a" (at http://forum.xda-developers.com/showthread.php?t=1930240).
Cool stuff, I was only pretty disappointed with the GPS fix times.
Then I learned about the gps.conf file, went on to open it, and was very surprised to find out that in this ROM it is very basic and short. I don't know about the situation with other ROMs and other Android versions, but the problem could possibly concern many HD2 users.
So I went for a search on XDA and on the general internet, got educated a bit on the matter, then I started experimenting and finally put together a file that's working very well for me - I'm getting cold fixes in under a minute, and warm fixes in seconds flat (all of this indoors, standing by a window). It was a long trial-and error work.
Hint: gps.conf is to be found in /system/etc directory. You'll need a rooted device to access it, and possibly to change permissions to the file to be able to modify it, I don't even remember if I did the latter :laugh:
Here's my take on the code:
#NTP_SERVER=ru.pool.ntp.org
NTP_SERVER=0.ru.pool.ntp.org
NTP_SERVER=1.ru.pool.ntp.org
NTP_SERVER=2.ru.pool.ntp.org
#NTP_SERVER=3.ru.pool.ntp.org
#NTP_SERVER=europe.pool.ntp.org
NTP_SERVER=0.europe.pool.ntp.org
NTP_SERVER=1.europe.pool.ntp.org
#NTP_SERVER=2.europe.pool.ntp.org
#NTP_SERVER=3.europe.pool.ntp.org
XTRA_SERVER_1=http://xtra1.gpsonextra.net/xtra.bin
XTRA_SERVER_2=http://xtra2.gpsonextra.net/xtra.bin
XTRA_SERVER_3=http://xtra3.gpsonextra.net/xtra.bin
DEFAULT_USER_PLANE=TRUE
DISABLE_AGPS_WHEN_ROAMING=true
REPORT_POSITION_USE_SUPL_REFLOC=1
AssistMethodType=1
AgpsUse=1
AgpsMtConf=0
AgpsMtResponseType=1
AgpsServerType=1
AgpsServerIp=3232235555
DEFAULT_SSL_ENABLE=FALSE
INTERMEDIATE_POS=1
QOS_ACCURACY=60
QOS_TIME_OUT_AGPS=120
QOS_TIME_OUT_STANDALONE=180
SUPL_HOST=supl.google.com
SUPL_PORT=7276
SUPL_SECURE_PORT=7275
SUPL_NO_SECURE_PORT=3425
CURRENT_CARRIER=common
ENABLE_WIPER=1
I'll explain a little: NTP URLs are for getting the precise time from a special server, this is necessary for the A-GPS because location is tracked by estimating the time to reception of the satellite's signal (I'm no expert but I shouldn't be much off the mark). So you want to download the time with the shortest network ping (delay) or it will not be accurate, and in order to do this you need to choose a NTP server as close to you as possible. In fact, of all the code I posted, the only part you should personalize to your needs is the lines regarding the NTP servers. I live in Russia, so I have the letters "ru" in the domains. To find the active servers closest to you, go to:
http://www.pool.ntp.org/en/
Also, I added the European servers as a backup (because they are not too far away from Russia), as some people suggest, and I verified that in some cases they get used by my device, possibly because of an excessive delay in receiving an answer from the earlier-listed addresses.
So why did I comment out some of the servers in the code? Well, looks like a failure in receiving an answer from a server can lead to a waste of time because of longish timeouts. In any case, I found out that by using only three servers from my area (and a couple from Europe, not more) I'm getting better fix times. So I left out the others but did not erase them for good, in order to stress the fact that I found a difference from those who suggest to add some eight NTP addresses or more.
So to recap, say you're from Japan, you could use:
NTP_SERVER=0.jp.pool.ntp.org
NTP_SERVER=1.jp.pool.ntp.org
NTP_SERVER=2.jp.pool.ntp.org
and immediately below (optional):
NTP_SERVER=0.asia.pool.ntp.org
NTP_SERVER=1.asia.pool.ntp.org
Then there's the Xtra servers needed to get the satellites' updated position in a format recognized by our Qualcomm chip. One size fits for all, no need to change anything here. The Agps engine relies on them, or in case of necessity falls back on the SUPL hosts (in this case, google.com).
I found out that the SUPL TLS hosts are useless for me, so I erased the following lines, that some people included and some others say are malformed:
SUPL_TLS_HOST=FQDN
SUPL_TLS_CERT=/etc/SuplRootCert
Also, the much advertised C2K host, and the following lines of code, did not work for me:
C2K_HOST=c2k.pde.com
C2K_PORT=1234
The last line,
ENABLE_WIPER=1
determines the persistence of the (AGPS?) position established by WIFI. It is not clear to me,though, if this is related to the AGPS data unloaded by WIFI, or the geographic position extrapolated by Google from a WIFI networks database (the fix you get when your WIFI is on even without GPS of AGPS). Anyway, 0 stands for inactive, as expected, and 1 for active. I believe modifying this line should not have any negative influence, make your tests.
I recommend you to:
1 - verify that you successfully saved the modified gps.conf file.
2 - reboot the phone (some say one should even turn it off, remove the battery and leave it off for minutes, in order to clean the cache) then use the app "GPS Status" to flush the Agps data and reload said data (and of course wait 1-2 min. the first time). Only then will the effects be visibile.
3 - needless to say, check that your data connection is active.
Also I recommend you not to use programs, like FasterGPS, that work by overwriting the contents of the gps.conf file, or you will have to start anew.
That's it. Please let me know how is your mileage, thanks for your attention.
March 5 edit:
The edited file described above works well until the ephemerides expire (after 2-3 hours from a cold fix). After that, fix times tend to rise, until the 6th hour from the last AGPS data download, at which point (at least on my phone) fresh data get downloaded as per GPS Status app settings (under "download GPS data at start"). My feeling is, since the script does not provide for a routine for assessing data age, and this JB ROM does not include a gpsconfig.xml file, this routine must be missing for good - so the phone tries a warm GPS start using data that are not valid anymore, thence the longer fix times (I may be totally wrong in my diagnosis, so commentaries from more tecnically savvy users are very welcome). I'm going to try and use chunks of a gpsconfig.xml from some other ROM, and see if the newly included gpsconfig.xml file gets recognized at all, to try and include a routine for discerning old from fresh data. Going to update this post further in case of progress.
March 7 note: this problem may be overcome by modifying the already mentioned option "download GPS data at start" choosing the suboption "download if data are older than one hour" under settings in the "GPS Status" app.
This solution is not very elegant from a developing standpoint, plus it involves using the network (and to have it available) more often than the normal ephemerides' expiry term, plus it forces you to use an external app, so I'm looking for a better solution anyway.
March 7 edit: slight modifications to the code. Also, erased the sentence "Important: if you use the app "GPS Status", remember to choose "weak" or "no filter" under "Sensors filter" in the settings" (as this seems to exert little influence with the use of QoS in the code).
Great info
Thanks a bunch, Luther. This helped for me as well. need to see if my cold fix times increase as you mention at the end. Good luck with the xml file development. Hope it works.
gprash said:
Thanks a bunch, Luther. This helped for me as well. need to see if my cold fix times increase as you mention at the end. Good luck with the xml file development. Hope it works.
Click to expand...
Click to collapse
You're welcome, Sir. Please check out the latest amendment to the code.
Hallo everbody,
im writing a background service to get informations like the time an active app (not my app) is running.
With this information i can show the user a list of the most used apps depending on the time.
The methods of the ActivityManager-class are useless, because the received informations aren't reliable.
So i thought, because the Android-System is based on a Linux-Kernel, i can use the internal structure to get these informations.
So i read out the pseudo proc-filesystem to get the process informations and for the 2nd time i thought
thats the right place for me to get what i want.
I read out the stat-file in every single process-directory to get the starttime(in clock_ticks) of the process.
I dynamic calculate the HZ USER_HZ value and use it to get the real starttime but this time never changes.
It's more like a timestamp of the first start on the system after boot.
The user-code-time and kernel-code-time seems to be too short and the values are updated too irregular.
So i just got a time value, that tells me the time when the app was first started after system boot
but i want a timestamp or anything else i can get from a currently running app to calculate the time this app is active.
Long life services and background services are not my goal.
Now i'm here because i don't know if i just miscalculate the values from this pseudo filesystem or
if i'm absolutely wrong where i get my informations from.
My Questions:
1. Do i read the wrong values files filesystem (if yes, where can i find these informations in the system structures)
2. Do i misunderstand some of the values i read out
3. Why do the files in the process directories become updated so irregular or once in a lifetime (just if im in the right filesystemfile)
I hope u can help me. *-*
Well, interesting approaches. :good:
The only way I see is running a background service and storing the launch time yourself.
I'm sorry but I don't know the answers to your questions.
You could
a) use su to get the active process list
b) get to /proc/??? folder (where ??? is the apppropriate process you enquire, for example /proc/80/)
c) get the /proc/80/sched text file and look for exec_runtime or vruntime or what ever works for you
carbonpeople said:
You could
a) use su to get the active process list
b) get to /proc/??? folder (where ??? is the apppropriate process you enquire, for example /proc/80/)
c) get the /proc/80/sched text file and look for exec_runtime or vruntime or what ever works for you
Click to expand...
Click to collapse
Oh, getting the currently running tasks can even be done much easier and doesn't require root. This is what I use:
Code:
ActivityManager am = (ActivityManager) getSystemService(ACTIVITY_SERVICE);
List<ActivityManager.RunningAppProcessInfo> processInfoList = am.getRunningAppProcesses();
carbonpeople said:
You could
a) use su to get the active process list
b) get to /proc/??? folder (where ??? is the apppropriate process you enquire, for example /proc/80/)
c) get the /proc/80/sched text file and look for exec_runtime or vruntime or what ever works for you
Click to expand...
Click to collapse
that seems to be exactly what i need!
but there are the next questions:
what is the unit of the "se.sum_exec_runtime"-field? is it in nano-secs?
what does the point do in the value? does it indicates a floating-point value?
im kinda confused and didnt really find something meaningful about the unit (*-*)
and im not very handy with the kernel code from "lxr.linux.no"
nikwen said:
Oh, getting the currently running tasks can even be done much easier and doesn't require root. This is what I use:
Code:
ActivityManager am = (ActivityManager) getSystemService(ACTIVITY_SERVICE);
List<ActivityManager.RunningAppProcessInfo> processInfoList = am.getRunningAppProcesses();
Click to expand...
Click to collapse
Following Note can be found in the android-doc:
"this method is only intended for debugging or building a user-facing process management UI."
And the "RunningAppProcessInfo"-class (given by the Method) doesnt provide any infos about the running time of a process.
So i think it's more reliable for me to read out the process-infos directly in the proc-filesystem.
Dalorikai said:
Following Note can be found in the android-doc:
"this method is only intended for debugging or building a user-facing process management UI."
And the "RunningAppProcessInfo"-class (given by the Method) doesnt provide any infos about the running time of a process.
So i think it's more reliable for me to read out the process-infos directly in the proc-filesystem.
Click to expand...
Click to collapse
1) True.
2) That's why I wrote this:
nikwen said:
The only way I see is running a background service and storing the launch time yourself.
Click to expand...
Click to collapse
3) But if the other method works and if you don't care about root rights as a requirement, it might be better. :good:
Dalorikai said:
what is the unit of the "se.sum_exec_runtime"-field? is it in nano-secs?
what does the point do in the value? does it indicates a floating-point value?
im kinda confused and didnt really find something meaningful about the unit (*-*)
and im not very handy with the kernel code from "lxr.linux.no"
Click to expand...
Click to collapse
replying to my own post i think the point in the value of the field indicates the milli-secs.
just an idea - im not sure but would be plausible if the unit is nano-secs.
what do u think or possibly know? ^^