Monday, October 18, 2010

Android Eclipse unable to replay mock GPX file

How exasperating it can be to go through the ropes of learning a new technology. This
post is an account of how after wasting several hours of being unable to replay a mock GPX or KML file through the Android emulator, I finally found a solution on an online forum, which I am re-posting here for others to benefit from. While this post helped me load a mock GPX file, I still haven't found a way to load a mock KML file yet. DDMS continues to crash while loading KML file while when I go through Eclipse (Window, Show View, Other, Emulator Control), nothing happens. Anyways, here is what you need to do to be able to replay a GPX file:


"It seems that DDMS only supports GPX 1.1 files. GPX 1.0 seems deprecated and the NS URL returns 301: http://www.topografix.com/GPX/1/0
Files with GPX 1.0 won't load in DDMS, but GPX 1.1 files will load fine. The workaround consists of changing the schema URL in the root node: From: http://www.topografix.com/GPX/1/0
" xsi:schemaLocation="http://www.topografix.com/GPX/1/0
http://www.topografix.com/GPX/1/0/gpx.xsd
"> To: http://www.topografix.com/GPX/1/1
" xsi:schemaLocation="http://www.topografix.com/GPX/1/1
http://www.topografix.com/GPX/1/1/gpx.xsd
">

Android: How to replay mock GPX files from within Eclipse or How to replay a series of location co-ordinates through the Emulator

Open Eclipse, then go to Window, Show View, Other and finally click on Emulator Control. Seems that this Emulator Control feature can now be run from within Eclipse itself without having to go through the DDMS.

Saturday, October 9, 2010

On setting Android development environment

My recent experience while installing development environment: relatively easy to install Android SDK, good documentation. and equally smooth to set up Eclipse environment. The only snag I faced was in an unexpected place. I wanted to play with an open source code from google code repository. Google code repository can only be accessed from Mercury or Git (CVS like code version control systems). That's where the fun began. There is relatively no documentation on how to download that code from within Eclipse. First, I installed a plugin for Mercury from within Eclipse by going to the Install New Software portion and providing a URL for where MercuryEclipse plugin can be downloaded from. Then I hit another roadblock. I still didn't know how to download the code from googlecode. Absolutely no documentation could be found about this, not even from Googlecode's help. The only recourse looked to be - reading up the entire Eclipse documentation. In search for a shorter route without doing a full blown research on how to use Eclipse, I discovered the "Import" button. On clicking that I discovered Mercury existed as an option besides CVS, and then on entering the URL for the Googlecode's project I was interested in, I was done!

T entire thing took me one day of hard work to set up - disappointing given that there are so many different software IDEs, version control systems, etc., now, however, there is so little literature on how to integrate across them all.