Android GPS degree format

by msurrow » Fri, 07 May 2010 00:47:31 GMT


Sponsored Links
 Does any one know what the degree format of the GPS fixes one get from
the LocationManager is? It looks like DD, but I can't find any
documentation specifying this.

DMS Degrees:Minutes:Seconds (4930'00"N, 12330'00"W)
DM Degrees:Decimal Minutes (4930.0', -12330.0'),
(49d30.0m,-123d30.0')
DD Decimal Degrees (49.5000,-123.5000), generally with 4-6 decimal
numbers.

Thanks

--



Android GPS degree format

by TreKing » Fri, 07 May 2010 02:10:10 GMT


 



I can't back this up, but I'm fairly certain it's decimal degrees. Seems
like the only format that's easily represented by a single double value.

-------------------------------------------------------------------------------------------------
TreKing - Chicago transit tracking app for Android-powered devices
 http://sites.google.com/site/rezmobileapps/treking 

--


Sponsored Links


Android GPS degree format

by cellurl » Fri, 07 May 2010 23:23:34 GMT


 yea its definitely degrees. No minutes, no seconds, just degrees and
fractional degrees.
DD Decimal Degrees (49.5000,-123.5000)








>



Other Threads

1. Timeout using apache DefaultHttpClient not working when port is closed

I have a simple piece of code that allows a user to specify a URL,
port, username, and password to grab a frame from a network camera.
An exception is thrown properly if the url can't be resolved, or if
the authentication fails.  However, I can't seem to throw an exception
in a reasonable amount of time if the server is available but the port
is closed (or the user entered the wrong port number).  It just seems
to sit and wait for a *long* time...

HttpParams params = new BasicHttpParams();
HttpConnectionParams.setConnectionTimeout(params, netConnectTimeout);
HttpConnectionParams.setSoTimeout(params, netReadTimeout);
DefaultHttpClient httpclient = new DefaultHttpClient(params);
httpclient.setHttpRequestRetryHandler(new
DefaultHttpRequestRetryHandler(0, false));
UsernamePasswordCredentials credentials = new
UsernamePasswordCredentials(username + ":" + password);
httpclient.getCredentialsProvider().setCredentials(new AuthScope
(hostName,port),credentials);
HttpGet method = new HttpGet(cameraUrl);
HttpResponse response = httpclient.execute(method);

(netConnectTimeout & netReadTimeout are both set to 10000)

After doing a substantial amount of reading, I believe I understand
why netConnectTimeout and netReadTimeout have no effect on this
particular problem.  After discovering "HttpRequestRetryHandler" I
believed I had found the solution.  However after applying what I had
found to my code (line 5 above), it had no effect.  The connection
still sits and waits far longer than 10 seconds when the incorrect
port is specified in the prefs.

Can anybody help?

--~--~---------~--~----~------------~-------~--~----~

2. Best way to add 100.000 words to database

Hi,
I am developing an application that, as the first thing, puts all
lines from a txt-file to a sqlite database. There is about 100.000
words that should be added to the database, and this takes almost an
hour to do.
Is there a better way to do this, fx. to have a database in the res/
raw resources if it is possible.
This is my currently way to do it:

public void getWords(final Context context, final InputStream aFile) {
        try {
                  InputStreamReader reader = new InputStreamReader(aFile,
Charset.forName("UTF-8"));
                  BufferedReader input =  new BufferedReader(reader);
                  try {
                        DB = context.openOrCreateDatabase(DATABASE_NAME, 1, 
null);
                        DB.execSQL("DELETE FROM english");
                    String line = input.readLine();
                    int i = 0;
                    while (( line = input.readLine()) != null){
                        try {
                                DB.execSQL("INSERT OR IGNORE INTO english(word) 
VALUES
('" + line + "')");
                        }
                        catch (Exception e) {
                                Log.e("kaloer", e.getMessage());
                                        }
                        if(i % 100 == 0) {
                                                Log.d("progress", 
Integer.toString(i));
                                                try {
                                                        Thread.sleep(100);
                                                        } 
catch(InterruptedException e) {
                                                        }
                        }
                        i++;
                    }
                  } catch (IOException e) {
                                e.printStackTrace();
                        }
                  finally {
                         try {
                                        input.close();
                                } catch (IOException e) {
                                        e.printStackTrace();
                                }
                         DB.close();
                        }
                }
        return;

    }


Thank you very much,
//Kaloer
--~--~---------~--~----~------------~-------~--~----~

3. Outlook Synchronization (Possible?)

4. 1.5 rebuild issue with emulator

5. OpenGL garbage collection (with direct ByteBuffers)

6. The building instruction maybe broken

7. ADB server didn't ACK, cannot bind tcp...