×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    May 2009
    Posts
    4

    Question Location API - accuracy- on nokia 5800

    Hello
    I'm having trouble witch trace location: I can't get the 'accuracy' value.
    Phone: nokia 5800XM - so I'm using Platform Services 1.0 - (2.0 seems not to be suported)

    ...
    begin trace
    ...
    var updateoptions = new Object();
    updateoptions.PartialUpdates = false;
    updateoptions.UpdateTimeOutv = 15*1000000;
    updateoptions.UpdateInterval = 1*1000000;
    updateoptions.UpdateMaxAge = 0;

    var criteria = new Object();
    criteria.LocationInformationClass = "GenericLocationInfo";
    criteria.Updateoptions = updateoptions;

    var result = so.ILocation.Trace(criteria, callback1);

    ...
    and int callback:
    ...
    result.ReturnValue.Latitude;
    result.ReturnValue.Longitude;
    result.ReturnValue.Altitude;


    by the way how to get Position Update every minute?

  2. #2
    Registered User
    Join Date
    Mar 2010
    Location
    Zaandam, Holland
    Posts
    71

    Re: Location API - accuracy- on nokia 5800

    Hi ranma,

    What you could do is check for result.ReturnValue.HorizontalAccuracy in each and every one of the calls to the callback. There's no way to be sure all data is ever returned except for lat & lon, but eventually it usually does.
    If you would set UpdateMaxAge to a somewhat higher value, the probability of more data being returned would significantly increase, according to my testing.

    Finally, getting a positionupdate just once a minute, could be done by just increasing UpdateInterval to the value of 60 seconds, (6000000). Ofcourse your timeout should be way higher then too.

    If you really never do get HorizontalAccuracy -ever- -ever- please drop a line, I have a gps widget which would malfunction on 5800 if it really never does, and would need me to look into.

    Good luck,
    Jasper


    Quote Originally Posted by ranma1988 View Post
    Hello
    I'm having trouble witch trace location: I can't get the 'accuracy' value.
    Phone: nokia 5800XM - so I'm using Platform Services 1.0 - (2.0 seems not to be suported)

    ...
    begin trace
    ...
    var updateoptions = new Object();
    updateoptions.PartialUpdates = false;
    updateoptions.UpdateTimeOutv = 15*1000000;
    updateoptions.UpdateInterval = 1*1000000;
    updateoptions.UpdateMaxAge = 0;

    var criteria = new Object();
    criteria.LocationInformationClass = "GenericLocationInfo";
    criteria.Updateoptions = updateoptions;

    var result = so.ILocation.Trace(criteria, callback1);

    ...
    and int callback:
    ...
    result.ReturnValue.Latitude;
    result.ReturnValue.Longitude;
    result.ReturnValue.Altitude;


    by the way how to get Position Update every minute?

Similar Threads

  1. Python S60 Emulator
    By NAYSAMBO in forum Symbian
    Replies: 25
    Last Post: 2009-04-08, 10:22
  2. Infra-red capability
    By Symbian_Challenge_0412 in forum General Development Questions
    Replies: 1
    Last Post: 2005-08-16, 18:24

Posting Permissions

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