Basic4ppc - Windows Mobile Development  

Go Back   Basic4ppc - Windows Mobile Development > Main Category > Questions & Help Needed
Home Register FAQ Members List Search Today's Posts Mark Forums Read

Questions & Help Needed Post any question regarding Basic4ppc.


GPS.Status


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 11-09-2007, 12:25 PM
alfcen's Avatar
Basic4ppc Veteran
 
Join Date: Apr 2007
Location: Okinawa, Ryukyu
Posts: 425
Awards Showcase
Beta Tester 
Total Awards: 1
Default GPS.Status

Hi
I process GPS data further whilst GPS.Status is "A". Upon hardware interruption or after switching off an external GPS unit, GPS.Status remains "A" (also after GPS.GPSBuffer=""). I know GPS.Status is read-only, but I need to clear that "A". Any work-around in town?
Thanks & Cheers
Robert
Reply With Quote
  #2 (permalink)  
Old 11-09-2007, 01:32 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 3,335
Default

The GPS properties (all properties) are only updated after a GPSDecoded event.
You should only check these values inside the GPSDecoded event.
The GPS tutorial handles hardware interruptions: GPS application - Part I
Reply With Quote
  #3 (permalink)  
Old 11-09-2007, 02:17 PM
alfcen's Avatar
Basic4ppc Veteran
 
Join Date: Apr 2007
Location: Okinawa, Ryukyu
Posts: 425
Awards Showcase
Beta Tester 
Total Awards: 1
Default

Hi Erel

Thanks a lot for your warp speed response.

>The GPS properties (all properties) are only updated after a GPSDecoded event.

That is exactly my problem. The properties are updated as GPS data is streaming in while the last received data remains after interruption or GPS power-off.

It would be great to have something like a GPS.Clear command that would, amongst others, set GPS.Status to "V" or "". In the pipeline?

Cheers
Robert
Reply With Quote
  #4 (permalink)  
Old 11-09-2007, 05:44 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 3,335
Default

I think that GPS.Clear will make the GPS library more complicated.
Instead of calling GPS.Clear you can use a global variable that holds the custom validity status.
Reply With Quote
  #5 (permalink)  
Old 11-09-2007, 06:25 PM
Junior Member
 
Join Date: Oct 2007
Posts: 18
Default

As I understand gps lib has nothig to do with gps hardware so it can't check status. But maybe there could be some flag for timeout? So I can see that decoded data is too old for processing and I shouldn't use it (or use it "at own risk").
Reply With Quote
  #6 (permalink)  
Old 11-09-2007, 07:19 PM
Erel's Avatar
Administrator
 
Join Date: Apr 2007
Posts: 3,335
Default

See the GPS tutorial for a timeout implementation.
The GPS library just parses the data.
Reply With Quote
  #7 (permalink)  
Old 11-10-2007, 01:42 AM
alfcen's Avatar
Basic4ppc Veteran
 
Join Date: Apr 2007
Location: Okinawa, Ryukyu
Posts: 425
Awards Showcase
Beta Tester 
Total Awards: 1
Default GPS.Status

Erel, I am a fool, GPS.New1 added to the interruption routine does the job formidably.

Sorry for bothering you. I might be a good idea to sleep a night over before crying out for help
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Status serial2.dll + HTC + WM6? ClarkVent Questions & Help Needed 25 08-11-2008 05:50 AM
Battery Status, New Version. FAFILI Share Your Creations 0 10-15-2007 10:30 AM
Smartphones - what is the status? ericliang Questions & Help Needed 15 07-07-2007 08:05 PM
Reading status of CTS Paul Questions & Help Needed 2 06-19-2007 09:34 AM
Charger status Alex812 Questions & Help Needed 1 05-29-2007 05:39 AM


All times are GMT. The time now is 07:53 PM.


Powered by vBulletin® Version 3.6.12
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.1.0