J2ME-style Location API on BUG

by kengilmer

Recently while wrangling with an internal project that required some basic location functionality, I became pretty intimate with the BUG location API.  While the basics of retrieving location information from the GPS device is pretty straightforward using the existing API, other use cases are not so easy.  Additionally, the API seems to leak more NMEA complexity that is really necessary.  So, I decided to make it better. This is when I discovered openlapi, a FOSS JSR-179 “like”* implementation.  The code was clean, the license was compatible, and the project looked to be in reasonable health.  “Perfect!  Who wants yet another Location API?”  I said to myself.  After a few days of shoe-horning (*2), I can say that a preliminary version of openlapi runs on BUG 1.4.3.  Preliminary means that it passes the non UI test suites provided by openlapi.  Look for it to show up in our extras repo in the near future!

* In a classic “Open source Java” tactic, the sources are open but the test suite is locked up.  So, the implementation may or may not be 100% compatible.

*2 Some of the API relies on some J2ME MIDP APIs that are not in our production JVM, PhoneME Advanced.  Minimal implementations of these APIs needed to be written.