[G1 Android Development] ERamseth:
How to get nav (or get nav back) directly from phone without adb

I noticed a lot of people Having trouble with this, but I found it to be fairly simple. I just wanted to post an update and more clear instructions.

I upgraded to CM 4.2.4 this morning and lost nav. I followed the procedure quoted above and got it back.

(I think the reason this happens is that upgrading the ROM will over-write or re-build build.prop and build.trout.prop as well as re-build the files in /system/dalvik-cache)

All done via phone without ADB.

Here is a streamlined/more descriptive process:

***Confirmed working on G1 with CM 4.2.4***

***Should work on any ROM based on Android 1.6 on any phone***

***NOTE: WHEN YOU ARE IN THE ROOT CONSOLE, IF YOU DO SOMETHING I DO NOT LIST HERE OR SIMPLY MIS-TYPE ANYTHING IN AN UNLUCKY WAY YOU COULD SERIOUSLY MESS UP THE INTERNALS OF YOUR OS AND COULD NEED TO WIPE OR AT LEAST RE-FLASH YOUR ROM***

***DISCLAIMER: BY FOLLOWING THIS PROCEDURE YOU ACKNOWLEDGE THAT I (ERAMSETH) AM NOT RESPONSIBLE, NOR IS XDA-DEVELOPERS FORUM FOR YOUR ACTIONS OR THE RESULT OF YOUR ACTIONS (MESSING UP YOUR PHONE OR STARTING A THERMONUCLEAR WAR, ETC.)***

via USB, transfer the Maps.apk to somewhere on your phone that you can find easily (/sdcard works just fine)

open ConnectBot (or any other terminal program to get a local shell on your phone)

get root

[B]$[/B] su

remount /system as read-write

[B]#[/B] mount /system -o rw,remount

edit /system/build.trout.prop with vi and make the necessary modifications... comment out (first character on the line needs to be "#") the existing line that start with "ro.build.fingerprint=" and add a new line directly below that that reads "ro.build.fingerprint=verizon/voles/sholes/sholes:2.0/ESD20/17572:user/ota-rel-keys,release-keys" (make sure to save the file)

[B]#[/B] vi /system/build.trout.prop

***NOTE: if you don't know how to use vi, I suggest looking it up because it is not like notepad or nano or anything else... I would say to use nano but it doesn't work right on the phone for whatever reason.

reboot

[B]#[/B] reboot

(after reboot) open ConnectBot (or any other terminal program to get a local shell on your phone)

get root

[B]$[/B] su

remount /system as read-write

[B]#[/B] mount /system -o rw,remount

remove all existing maps files

[B]#[/B] rm -rf /system/sd/app/*maps* /system/sd/app/*Maps* /system/app/*maps* /system/app/*Maps* /system/sd/dalvik-cache/*maps* /system/sd/dalvik-cache/*Maps* /sdcard/google_maps_navigation

locate the Maps.apk file that you transferred to your phone and install it. The easiest way to do this is to use Astro or another file manager, find the file, click it, and open it in the package installer.

edit /system/build.trout.prop with vi and reverse the changes you made earlier... find the line you commented out (should start with "#" followed by "ro.build.fingerprint=") and un-comment it (remove the "#" at the beginning of the line and make sure the first character of the line is "r"). Then comment out (add "#" to the very beginning of the line) or delete the line you added that reads "ro.build.fingerprint=verizon/voles/sholes/sholes:2.0/ESD20/17572:user/ota-rel-keys,release-keys" (make sure to save the file)

[B]#[/B] vi /system/build.trout.prop

enjoy nav!

I have confirmed that sed (aka stream editor... a command line program in linux) is available on the busybox built into CM ROMs. If it becomes clear that this process needs to be repeated a lot, I will make a shell script that automates all of this using sed... If anyone else is up to the challenge, though, please go right ahead.

Like before, I won't check back on this thread unless my nav stops working and I need to find out how to fix it. If you really want to ask me a question, get me on twitter @eramseth .