×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    Jan 2008
    Posts
    19

    How to check if GPS request for position information is sucessful

    I developed an application tt can geotag photos. However, I want my camera application not to capture an image if GPS information such as longitude and latitude cannot be retrieved sucessfully. I have read through the APIs but I still not sure how I can do so. Which is the variable or method that actually tells you that a GPS request is not sucessful(which I think is caused by when GPS sattelites cannot be detected)? Please help. Thank you.

  2. #2
    Nokia Developer Moderator
    Join Date
    Sep 2004
    Location
    Tampere, Finland
    Posts
    11,359

    Re: How to check if GPS request for position information is sucessful

    Location info is retrieved asynchronously and in active object's RunL method you will have yo check whether iStatus.Int() is KErrNone or something else (note that not everything else means a real error).

    Aside from that you can also check the returned Latitude and Longitude values and if they are not NaN the all is OK.
    -- Lucian

    If you are not yet a DVLUP member it is time to correct that mistake :) Click here to join: http://www.dvlup.com/lucian/Invite

  3. #3
    Regular Contributor
    Join Date
    Jan 2004
    Location
    Braunschweig, Germany
    Posts
    345

    Re: How to check if GPS request for position information is sucessful

    In your RunL menthod where you are notified updates of the coordinates you will also get a error code KPositionQualityLoss in the iStatus member variable when the GPS fix is lost.

    Othewise checking the long/lat values for KNaN should be sufficient in most cases, like ltomuta said.

    Bernd

Similar Threads

  1. GPS on N95
    By kvr0 in forum Symbian
    Replies: 0
    Last Post: 2007-05-11, 10:22
  2. Prototype SDK 2.0 setup problem
    By jackmcardle in forum Mobile Java Tools & SDKs
    Replies: 4
    Last Post: 2007-01-09, 16:21
  3. GPS Information needed
    By swapnilgp in forum Mobile Java Tools & SDKs
    Replies: 1
    Last Post: 2006-05-01, 15:07
  4. GSM/GPRS Drivers check FAILED
    By hblume in forum Multimodecards
    Replies: 3
    Last Post: 2004-01-28, 21:37

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×