yashsingh1/xdaforums huggingface dataset:
[Touch CDMA General] myn:
Tested it today with google nav. (Compass disabled in maps via Spare Parts). It seems to work for awhile than it looses GPS signal and regets it again.

"Lost GPS Signal"..

Other than that. It's pretty golden :)

Thanks so much
[Touch CDMA General] Shidell:
Thank you very much, srwalter--it's great to have this functionality!

I tested it on the way home after christmas (200 miles in Wisconsin) and had a few quirks to report. I'm not sure if this is anything you work on-related, or if this is ROM-related. For reference, I'm using Plemen's latest AOSP 1.6 build on NAND.

To note, I do get the GPS lock, and actual "Navigation" does initialize and work. However, I'm always on "Unnamed road", it can never update Nav with the correct road. Also, the distance to my next turn/lane change is shown, but the actual lane change/turn icons/graphics are not displayed. (Probably ROM-based?)

Of real curiosity however is the GPS itself; at times my Navigation would do a complete 180, and despite traveling at well over 50 MPH down a street, the Nav would flip in reverse and my arrow would "Backtrack" down the road (in the correct location). Additionally, sometimes the arrow would be sideways, making it appear as if I'm "sliding" down the street. Of course, Nav rotates behind the arrow automatically, so this made for some comical situations as I drove.

Is this perhaps related to the driver(s) you've written or libraries you've written, or is this something I should ask Plemen about?
[Touch CDMA General] hellovx7600:
I too was testing it out in Wisconsin :) I was trying to see if my speedometer was right but the gpsinfo app was saying I was doing over 110 mph. I tried a different rom and Navigation does the drifting thing and shows I'm on an unnamed road. Maybe it's the cold weather and the snow throwing it off :P
[Touch CDMA General] bri3d:
My navigation app works just fine, icons and all (except the speech synthesis getting clipped sometimes - audio drivers) so I think it's ROM related.

I do occasionally get the 180 degree rotation though, and things are iffy when stopped - there should probably be a "dead zone" for bearing calculation rather than just seeing if the lat/lon are the same as prior and ignoring the bearing in that case.
[Touch CDMA General] tatnai:
I think the "unamed road" at the top is the name of the next street (not the current street), which for me always says unamed as well. It does register my current street in the bottom right corner correctly. It sometimes puts my direction as wrong (points arrow backward or at a right angle for a mile or two at a time), but other than funky arrow stuff it's working alright - definitely a huge step up. The voice notification works for me, happens right at the time of the turn instead of in advance, but hey, it's happening, I'm just stoked about that.
[Touch CDMA General] drewden123:
I can't get a lock...this vogue is a new replacement for my old one. Should I have flashed the latest verizon radio (or a certain version of the verizon radio), not let customizations run, and then flashed to android with this new rootfs? I'm just getting the "waiting for location"
[Touch CDMA General] plemen:
I believe the "unnamed road" issue has to do with using the international hacked version. If you are in the US download the latest Google maps / navigation from the market and try again.

Specifically, here are the known issues with the hacked international nav:

- No street name at the top

- No arrow indicating next turn direction

- Voice guidance is delayed, if at all present
[Touch CDMA General] hexto:
Well its happened again. Just went to use GPS and it just keeps searching but no locks. I don:(t get it. My GPS never works for more than a day. Outside with a ckear view to the sky. I think my phone is shot.
[Touch CDMA General] berardi:
Yeah I am having this same issue - it is making the Nav portion unusable so I am back to regular Maps. Travels sideways, backwards, 180s, it makes it look like I drive like Michael Jackson dances!
[Touch CDMA General] tatnai:
all the weird stuff is related to the international nav gps hack - see here ( http://xdaforums.com/showthread.php?t=583123 ). if you live in the US you should use a rom without this hack, and you should not experience these problems - hopefully nav will work just fine. if you live outside the US and want to use google nav, sorry, them's the dice for now. i'm going to ask plemen if he will release a US version of his rom for US users if he has the time.
[Touch CDMA General] bri3d:
The missing road names and icons are probably caused by the International hack - I'm running a stock Donut with Maps+Nav straight off the market and I don't have that problem - I see and hear the next street and get icons just fine.

However, the sudden weird direction changes are 100% a property of the driver's interpolation and not the system - it's got some bugs.
[Touch CDMA General] Shidell:
That explains most of it. Thanks Plemen. :)
[Touch CDMA General] berardi:
Is there any way to remove the hack? I saw some instructions in the post you linked to, and attempted them in "better terminal" but it gave me a message "are you root?" and I wasn't sure of how to proceed. I don't mind doing it myself, just really unsure of how to actually do it, since it doesn't appear to be an option to just remove it from the usual manage applications page in settings.

Thanks for the tip!

EDIT: I saw Plemen's post to redownload the latest Google Maps / Navigation. I installed the latest Nav Launcher over the previous. Google maps, I'm not sure how to do this because a new version does not exist yet. I tried doing a Route, and it still was showing me the "unnamed road" at the top. I'm guessing removing the hack is more in depth than I've attempted.
[Touch CDMA General] drewden123:
I cannot get a lock for the life of me:

Donut AOSP 242b

Verizon radio 3.37.78

kernel 17-12-09

rootfs linked in this thread with the new lib.gps.so

Thanks for any help
[Touch CDMA General] polyrhythmic:
Those of you who can't get a lock, I recommend downloading GPS Test from the Market. It will give you a readout of satellite number and strength (similar to the HTC GPS Status app for WM) so you can see if your GPS is not working or if you are just having a hard time due to trees/position/etc. There are other GPS info apps, but GPS Test is the only one that works for me on all builds, even at 240x320.
[Touch CDMA General] drewden123:
Thank you very much
[Touch CDMA General] tatnai:
in better terminal, first type

su

which will give you superuser. you can carry out the commands in the linked post to uninstall the hacked gps nav I think, however you have to be using nand or ext2 to be able to uninstal google maps because it is part of the system. I could accomplish everything except for uninstalling google maps as I run standard from the SD card.

plemen said he would release a US version with stock google maps and the hacks removed. I would assume you can keep your data file, might want to run

su
mount -o remount,rw /system
find /system /data -name \*google\*maps.apk\* -o -name Maps.apk -delete

to remove old cache.

if you are running from ext2 or nand, you should be able to remove the cache, and uninstal google maps, then re-instal from the market or from sd card (search google, you'll find 3.3.1 maps). someone smarter than me may reserve the right to correct any of this . . .
[Touch CDMA General] berardi:
Thanks! I am running from NAND

with the su, it worked but when I got to the step:

"pm uninstall com.google.android.apps.maps" it gives me just the word "Failure" and Maps is still there.

The other steps seem to work - they don't give an error.
[Touch CDMA General] plemen:
Also execute this command after the other find command:

find /system /data -name \*google\*maps3.3.1-by-directions-root-2.apk\* -o -name maps3.3.1-by-directions-root-2.apk -delete
[Touch CDMA General] drewden123:
I have followed every instruction to the tee nd can't get this to work. It always just says my location is temporarily unavailable.
[Touch CDMA General] berardi:
Success

Plemen you are the best! Thanks!
[Touch CDMA General] vilord:
afaik, the verizon 3.37 radio is GPS locked... in winmo you can only get GPS with the valhalla hack, right? This won't work in android, you need to downgrade to a pre-GPS radio, then put on the Bell radio (be vewy vewy caweful, you don't want to fwash a non-vewizon PRL, make suwe to follow instwuctions elsewhea).
[Touch CDMA General] bchi49:
This is great!!!! It works better inside the building as well near window.
[Touch CDMA General] vilord:
also, the sudden direction changes and such will require a little more code work to fix... srwalter and I chatted about this a bit, and one of these days, one of us will try out the approach we discussed to see if it works better or causes the whole thing to self-destruct :D
[Touch CDMA General] bchi49:
lol. I haven't test it outside yet, but I did see the sudden direction changes in the building.
[Touch CDMA General] drewden123:
On winmo I had the stock Verizon 3.37.78 radio and gps w/o Valhalla. Also, whenever I look for the bell rom every link is dead except ones for an sd card flash which I can't use with a 4gb card
[Touch CDMA General] joetrisman:
http://justpctech.com/PPC/Roms/Vogu..._4350_BM_WWE_3.08.666.1_Radio3.42.50_Ship.exe ;)
[Touch CDMA General] Bang3r:
Successfully Removed Hacked Version of Maps, and installed from Market

Flashed to NAND just so I could accomplish this. Removing the hacked version of Maps was tedious using Better Terminal, but worth it (don't have adb on this machine). I then downloaded the Market version, and navigation actually works on my Sprint Touch now. Still getting a little (but less) of the "directional spin," but voice guided nav seems to still work, even if the screen is going crazy at times. It's still a lot beter than using the included hacked version for a U.S. user, IMHO. And, the street names are displaying properly at the top, instead of "Unnamed Road."

Thanks for the hard work everyone.
[Touch CDMA General] Shidell:
ahaha, rock on. :)
[Touch CDMA General] berardi:
Yeah I'm experiencing the same, mostly I am driving sideways or doing the moonwalk :)
[Touch CDMA General] tatnai:
US users who run plemen's AOSP donut, or other US users looking for a newer donut build without the international map hack, see here.
[Touch CDMA General] bchi49:
where can I find out how to setup ext2?
[Touch CDMA General] tatnai:
http://xdaforums.com/showthread.php?t=584707
[Touch CDMA General] xoltrix2000:
Thanks for the great work guys.

I'm running into one problem, after removing the maps using the posted command lines, it still won't install Maps, saying it's incompatible. When I tried to install manually, this is what i get on screen:

C;\sdk\tools>adb install Maps.apk (this is the latest one from the Market
484KB/s (2830052 bytes in 5.706s)
(pkg: /data/local/tmp/Maps.apk
Failure [INSTALL_FAILED_UPDATE_INCOMPATIBLE]

I also tried copying the maps.apk file and running from the SD card, i get a "Maps could not be installed on this phone."

I ran the following code multiple times but still cannot install.

su
mount -o remount,rw /system
find /system /data -name \*google\*maps.apk\* -o -name Maps.apk -delete

and this

find /system /data -name \*google\*maps3.3.1-by-directions-root-2.apk\* -o -name maps3.3.1-by-directions-root-2.apk -delete

I checked but maps is no where to be found on the phone, so I'm not sure why it's not installing.

I'm running plemen's Donut AOSP v242b Eclair themed - international Nav build.

Thanks again.
[Touch CDMA General] jamezelle:
some things dont play nicely with "adb install". so dont play nicely back delete the maps in plemens build then do:

mount -o remount,rw /system
adb shell stop
adb push ./Maps.apk /system/app
adb shell start

that should do it
[Touch CDMA General] tatnai:
try what jamezelle said, if that does not work, read here:

http://xdaforums.com/showthread.php?p=5009423#post5009423
[Touch CDMA General] bchi49:
Thanks! :)
[Touch CDMA General] xoltrix2000:
Thanks for the reply fellas, unfortunately it still doesn't work, I still get the the incompatibility error msg, and those instructions just copy the file into the system/app folder, but still does not install the app, even if I run the Maps.apk file right from Astro.

Does this have to do with me using 320x480 160lcd?
[Touch CDMA General] Bang3r:
Map/Directional Rotation Getting Better

I'd strongly advise starting with one of Plemen's new "No Map" system.sqsh's for U.S. users (have not yet, personally), or force removing the hacked version of maps in adb or the terminal (what I did). I've been tinkering more with the nav, on the market version, it seems like it's getting better on its own at not doing the spinning/side-sliding thing as I drive around. Seems, the longer that the nav program runs, maybe the gps fix, gets better??? Honestly, I'm experiencing very little random rotation anymore. Nearly flawless. Keep using it folks.

:D
[Touch CDMA General] xoltrix2000:
I found a way to install the maps by running the Nav program, once attempt to navigate, it will prompt you to download and install some latest version from some android website (i'll post it when i get home), which successfully installs. What's wierd though is that it still have the "unnamed road" issue.
[Touch CDMA General] bchi49:
I installed fresh using ext2 setup w/AOSP Android 1.6 no map and new data, it's running very fast, I haven't tried google map yet. Thanks!
[Touch CDMA General] Shidell:
I was skeptical of this when I first read it, but I've been doing the same, and I'll be damned if it doesn't appear to be getting better.

So.. what's happening here? Has some combination of Dzo's Bootloader/Kernel with Srwalter's GPS driver and Plemen's AOSP 1.6 build transformed my Vogue into a neural-net processor--a learning computer? :eek:

:D
[Touch CDMA General] berardi:
Mine starts out whacko, gets better, lasts for a while, and eventually it starts going sideways or backwards again. Same thing happens for each time I run Google maps
[Touch CDMA General] polyrhythmic:
As y'all can tell, it's much easier to install maps than to include it in a build. Maps is always available from the market so I am no longer releasing builds with Maps included. If you use Nav Launcher to install Maps it will install the hacked int'l version - which has the "unnamed road" bug. If instead you install normal Maps, Nav Launcher works with that also.
[Touch CDMA General] stopthebus:
I can't install the map from the market either. Is there any other way?

Tried many times always install unsuccessful.

Using Plemen's 242b without map.
[Touch CDMA General] xoltrix2000:
Hello there. Plemen uploaded a no-map version of the sqsh (updated on his first post) http://xdaforums.com/showthread.php?t=591104

Uninstall maps if u haven't done so, copy these files to your sdcard: systemfstonand, rootfstonand, updated roofs with enchanced gps and the no-maps sqhs file, reboot normally and it will automatically install.

If you have done any modification to your resolution like have (320x480 LCD density 160), you will have to adb the modifications again.

Now you can download the maps off the market, but I warn you, it does not work with the Nav Launcher. Only the hacked version, which still doesn't work properly in North America.

You'll have to the guys who made this stuff work (jamezelle, Zen, DZO and srwalter, and whole bunch of peeps here). They are awesome.
[Touch CDMA General] tatnai:
actually, it does work with the nav launcher. you just have to download google maps from the market before you launch the nav launcher.
[Touch CDMA General] xoltrix2000:
Hmm... it is odd. I did downloaded maps from the Market. When I use Directions option in the Maps, there is no more "Navigate" option, just "Show on map" even though I have Nav Launcher installed from before. I even tried redownloading Nav Launcher and still does not have that option. I also tried Launcher and attempt to navigate too, get an error saying "No route found", even though Maps is installed and working.

I did a search on the forums and the only answer is that Nav launcher does not work with US version of the maps.

If you have found a way to get this to work, that would be totally like awesome!
[Touch CDMA General] vilord:
I finally got the opportunity to test this out, as I forgot to download the out-of-state maps to by regular GPS...

I'm seeing the same thing, sideways and backwards, had to mute sounds so it'd stop telling me to drive southwest when I already was.

I also tried using it with copilot live (which I bought about 8 months ago and could never use). That worked fine for about 10 miles, then got confused and stuck...

I think we're almost there, just need to get the compass direction wonkiness cleared up and maybe get it to update more often (every half second instead of every second) if possible and we'll be set.

Maybe if someone else hasn't done it in the next couple weeks and I've got some free time I'll take a stab at it.
[Touch CDMA General] tatnai:
I assume you are in the US. I used plemens heroblend donut build that has Nav launcher already installed but does not have maps installed. I created a new data file. I downloaded maps from the market. running maps alone gives me the "navigate" option. then, i can also just run Nav Launcher that is already installed, and it takes me directly into the navigation mode without a problem. I have streen names and arrows, and voices ahead of time.
[Touch CDMA General] Shidell:
I would love to help with this project, but I feel like there's so much to overcome before I could actually assist that it'd be finished by someone else first. I feel like I have more knowledge that most, but even still, I'd need to learn *nix, get a compiler for ARM, and then learn how to write drivers (over the simple C projects I make right now.)

Unless I'm over-complicating things for myself?

I hope this doesn't sound like whining. One thing is for sure, it really does make a person appreciate what you guys do.. the knowledge you have is insane.
[Touch CDMA General] vilord:
you don't necessarily need to learn *nix to do these changes...

If you're decent at coding/algorithms, you should be able to walk through the source code here: http://github.com/srwalter/libgps-vogue

and here: http://linuxtogo.org/cgi-bin/gitweb...rm/mach-msm/gps/gps.c;hb=refs/heads/htc-vogue

and you can see what it does.

The changes we'd like to make would be to save a previous lat/long set in addition to posting the current set. Then, with a data update, if the new lat/long is equal to the previous lat/long, it can just reuse the previous lat/long against current for calculating speed and direction.

What happens now is that if it gets an update where the lat/long hasn't changed, the velocity and direction will drop to zero (at least that's how it looks)

Also, right now it is getting updates at an autogenerated frequency based on how often android is asking for the updates. To follow what a "normal" gps does, we should be getting updates either every second or twice per second, and eliminate the autogenerated frequency code.
[Touch CDMA General] jnadke:
I mentioned the accuracy / speed changes in an ealier thread:

http://xdaforums.com/showthread.php?p=5125179#post5125179

The problem currently is, as I've looked at the code, is he's calculating lat/lon using a square formula, when it's really more of a trapezoid. This leads to some errors in the bearing. He should really be doing something more like this:

dLon = lon2 - lon1

y = sin(dLon) * cos(lat2);

x = cos(lat1)*sin(lat2) - sin(lat1)*cos(lat2)*cos(dLon);

bearing = atan2(y, x);

Also, he's using atan. atan2 above will take care of the corner cases in calculating the atan (if android clib has atan2).

In addition, as you said, a condition should be used to check if the user is going faster than a certain amount (~0.75 m/s), to calculate the bearing, otherwise use an old bearing.

Secondly, a 2nd or 3rd order butterworth filter should be added to smooth out the bearing. GPS is notoriously noisy (and susceptible to multipath -- especially in these cheap GPS units).

Between noisy GPS, and the innacurate bearing calculation, the instantaneous bearing may be swinging around.

In all, this would be much easier if we had access to GPS velocity information, which is more accurate, and is normally used for calculating bearing.

If someone can give me a link of where I can get a cross-compiler and set up the android build environment, I'll make the changes myself.
[Touch CDMA General] vilord:
here is where you'll want to start:

http://source.android.com/download

for the cross-compiler, i use armeabi... the link I used to get it is at home, I'll dig that up if someone hasn't already when I get there
[Touch CDMA General] Shidell:
Thanks for the information, Jesse--I'm looking at it right now.

EDIT: Further investigating makes it appear that we need a GNU compiler with ARM support to build the source output (.so) file necessary from the header and source files. Looking for a good Windows option that doesn't require cygwin..

EDIT 2: In looking at the source, am I right in understanding the correction_factor is initialized to nothing (presumably NULL?)--it's later referenced in assignment statements (in method send_position_data, location.latitude /= correction_factor; and location.longitude /= correction_factor;), is this correct without defining a value for the correction_factor?
[Touch CDMA General] vilord:
well when I said that you didn't need to learn linux, i didn't mean you could compile it in windows :) still needs to be compiled in linux, but you don't need to learn the whole thing, just enough to get a window to pop up that you can run repo, cp, and make

correction factor comes from the kernel side:

correction_factor = info.correction_factor;
[Touch CDMA General] Shidell:
Alright, I need to work on getting an *nix machine running.

I'm tinkering with the source right now. Would you mind trying a test-compile for me a little later with some (probably catastrophic) results? :)
[Touch CDMA General] bzo:
I use a virtual linux setup myself. A lot more convenient than dedicating a machine or dual booting. There are a number of good options, but one that works well for me is vmware player (free) and ubuntu linux. adb actually works a lot better and with less fiddling in the virtual linux environment than in native windows.
[Touch CDMA General] jnadke:
Speaking of which, I have no clue how they arrived at that correction factor (or why they implemented it the way they did). Did they just guess? Is it documented anywhere?

I assume it's a fudged scale factor.

It's fixed at 1.035631. However there's an additional factor of 180,000.

What gives? Something tells me the scale factor is actually 3600 (milliradians).
[Touch CDMA General] Shidell:
Yeah, that's a good call. I'm setting up a VMWare session with Ubuntu 9.10 right now. :)

I don't even know where you found that information, lol. :D

This is the function you're going to modify to use atan2, assuming it's available?

location.bearing = atan(location.bearing) * 360 / (6.282);

Just curious where the other values you mentioned (lon2-lon1), etc. are going to come from. I only see last_lat and last_lon.. but then again, I'm pretty much as green as can be. :)