I am developing a MIDlet which uses (must use) GPS. I am using J2ME (JSR 179 Location API) on Nokia 6210 Navigator. I have 2 problems regarding turning on and off the GPS.
1. Turning off the GPS seems to be impossible. I use and have tried several combinations of:
locationProvider.setLocationListener( null,... );
locationProvider = null;
2. Turning on the GPS seems to be difficult with a call to
locationProvider.setLocationListener( this,... );
(this is an object implementing LocationListener)
The MIDlet or another MIDlet must use
locationProvider.getLocation() first to get
the GPS going.
When I say difficult I mean that it sometimes turns on, sometimes not.
Has anyone solutions on these problems or at least seen them?
(I think has something to do with threads inside LocationProvider)
Best regards, J