Showing posts with label android. Show all posts
Showing posts with label android. Show all posts

Wednesday, December 22, 2010

Android Unit Conversion

vConvertIt 0.9 (beta) is now available as a free App for your Android powered phone from the Android market place. Best of all vConvertIt is also ad-free.

vConvertIt Unit Converter is a basic unit conversion utility offering over 850 conversions in 12 different categories.

vConvertIt converts as you type, provides key filtering on both the category list and the units lists for quickly finding the unit you're looking for.

vConvertIt saves the most recent conversion in each category for fast lookup of the previous conversion and fast repeated
conversions of the same type.

UPDATE: Version 0.91 i snow up on the market. It fixes a bug in the input units field which caused the cursor to jump to the beginning of the number after each key press. Thanks so much to SMing for reporting this problem.

NOTE: this is a beta version, so if you have feedback, comments, or new units / categories you would like to see added don't hesitate to email me. I'm busy adding new units, new categories, and double checking the accuracy of each conversion prior to release 1.0.

Friday, August 14, 2009

Google Maps working on OpenMoko FreeRunner

Getting Google Maps working on my OpenMoko FreeRunner with Android

For some reason this took me a while to get working. The basic idea is described by Sangjin Yun here, although there were a few twists perhaps related to the particular version of Android I'm using - Michael Trimarchi's freerunner-cupcake-snapshot-v15.jffs2 and uImage-v22.bin from here.

I'll take the liberty of repeating Sangjin's instructions here along with my minor modifications just so it is easy to understand.

1. Get the Maps.apk and com.google.android.maps.jar from the emulator.
You should also grab com.google.android.gtalkservice.jar from the emulator
The Maps.apk depends on the gtalkservice.

2. Enter the shell of your device.

  • adb -d shell

3. Remount the system partition with read/write permissions.

  • mount -o rw -t yaffs2 /dev/block/mtdblock3 /system

For me the remount was a bit different. The following did the trick

  • mount -o remount,rw /dev/root /

4. Copy the files to the system directory.

  • adb -d push Maps.apk /system/app/
  • adb -d push com.google.android.maps.jar /system/framework/

I needed to install the files onto my moko a bit differently. Since Maps.apk depends on the two libraries it will not install first. Here is what I did:

  • adb push com.google.android.maps.jar /system/framework/com.google.android.maps.jar
  • adb push com.google.android.gtalkservice.jar /system/framework/com.google.android.gtalkservice.jar


5. Add the permission for maps.

I found it simplest just to adb pull platform.xml onto my host, edit it there, adding an entry for both maps and gtalkservice, and then adb push it back to the phone.

/etc/permissions/platform.xml

<permissions>

...


<!-- This is a list of all the libraries available for application code to link against. -->

<library name="android.awt" file="/system/framework/android.awt.jar">
<library name="android.test.runner" file="/system/framework/android.test.runner.jar">
<library name="com.android.im.plugin" file="/system/framework/com.android.im.plugin.jar">
<library name="com.google.android.maps" file="/system/framework/com.google.android.maps.jar">
<library name="com.google.android.gtalkservice" file="/system/framework/com.google.android.gtalkservice.jar">

</permissions>


6. At this point Maps.apk will still not load because the libraries are not yet registered. Restarting the device will allow the package manager to pick up and register the two new libraries. This can easily be done using

  • adb stop

  • adb start


Alex Buntu Reported that his version of adb does not support the stop and start command.
If you can't restart your device this way you can always resort the power cycling it.
Until the new libraries are properly registered you will get
Failure [INSTALL_FAILED_MISSING_SHARED_LIBRARY] when trying to install Maps.apk


7. Now we can install Maps.apk. You should use adb install instead of adb push. push simply copies a file while install registers the package and check dependencies.

  • adb install Maps.apk


8. Now you should be able to run Google Maps on your Android Freerunner.