Join Today
+ Reply to Thread
Page 1 of 2 12 LastLast
Results 1 to 10 of 15
Like Tree1Likes

Thread: J2ME GPS - half solution

  1. #1

    Default J2ME GPS - half solution

    I recently bought an A780 (german version) and tried to access the JSR-179 Location API.

    I got it working, but ONLY if copilot software is running as a background process! The J2ME API returns correct location information, but seems to be unable to activate/synchronize the GPS. Thats currently the job of copilot in the background.

    Not a nice solution, but enough to play with it

    To access/compile Location API you need to include this lib into your project:
    C:\Programme\Motorola\SDK v5.2.1 for J2ME\EmulatorA.3\lib\stubclasses.zip

    Code example:
    // init
    Criteria c = new Criteria();
    c.setPreferredPowerConsumption(Criteria.POWER_USAGE_HIGH);
    LocationProvider lp = LocationProvider.getInstance(c);

    // automatic update of location
    lp.setLocationListener(this, 5, 5, 5);

    OR

    // manual request
    Location l = lp.getLocation(5);
    OR
    Location l = LocationProvider.getLastKnownLocation();

    QualifiedCoordinates qc = l.getQualifiedCoordinates();
    qc.getLatitude();
    qc.getLongitude();
    qc.getAltitude();

    Happy hacking!
    pastitomex likes this.

  2. #2

    Default Re: J2ME GPS - half solution

    lapisrv is the GPS Location API Service on A780, seems it will be up when run CoPilot.

    Have you tried to use MOTO's J2ME Location API?
    import com.motorola.location.*;

    A program (with source file) which uses it can be found from:
    http://per.nitro.dk/

    Where to find motorola location package com.motorola.location.* :
    http://www.jroller.com/page/newm4n/20050513

  3. #3

    Default Re: J2ME GPS - half solution

    Motos Location API is not included in the SDK download. No way to access it

  4. #4

    Default Re: J2ME GPS - half solution

    Quote Originally Posted by kiu112
    Motos Location API is not included in the SDK download. No way to access it
    The way is here:
    www.jroller.com/page/n...n/20050513

  5. #5

    Default Re: J2ME GPS - half solution

    I am too dumb to read your post

    Sorry, trying the moto api soon

  6. #6

    Default Re: J2ME GPS - half solution

    The result using Motos Location API from the A925 is as expected, immediate crash while starting the app on the phone. In the source nothing is done, except GUI stuff. Probably it didnt like the imports...

  7. #7

    Default Re: J2ME GPS - half solution

    Moto Location API ws locked by motorola like another special API. they need Moto certificated file to make it work.

    But sime guy at ccmove can make it work by replaced a permfile.txt after install midlet.

    I was try to create midlet to access file system. Midlet cant start until i replace a new permfile.txt. Could you try this permfile.txt with your gps midlet?
    Attached Files Attached Files

  8. #8

    Default Re: J2ME GPS - half solution

    The permfile looks like the one included with the snowboard game.
    After replacing my permfile with yours there are no differences, still immediate crash

  9. #9

    Default Re: J2ME GPS - half solution

    May be this permfile.txt is for Moto file access API only. so we still looking for permfile.txt for Location API.
    Visit my Blog here.http://my.opera.com/eakrin

  10. #10

    Default Re: J2ME GPS - half solution

    I can not access the location API on my A780, also not if Copilot runs in the backround. I tried also to replace the Permfile witout success. Is there any solution to run GPS-midletes on the A780?


 
+ Reply to Thread
Page 1 of 2 12 LastLast

Similar Threads

  1. half touchscreen not working
    By PIYUSH.ROCKER in forum E6 General Chat
    Replies: 5
    Last Post: 11-18-2009, 10:13 AM
  2. Replies: 1
    Last Post: 07-19-2008, 02:36 PM
  3. Motorola to Split in Half
    By admin in forum News
    Replies: 0
    Last Post: 03-26-2008, 01:10 PM
  4. GPS solution (to dream anyhow)
    By TheSin in forum A1200 General Chat
    Replies: 1
    Last Post: 04-27-2007, 12:47 AM
  5. Replies: 2
    Last Post: 07-13-2005, 02:38 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Single Sign On provided by vBSSO

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1