PDA

View Full Version : Trying to extract the TIME from the GPS module



BasicMike
02-07-2010, 10:14 AM
Hello, I'm trying to extract the time from Parallax's GPS module to display onto a 7 segment display in·hours/mins/seconds.·
Does anyone know how hard it would be to pull the time from the GPS module?· Is there already some code out there that I can't find??
I don't need the GPS part because the module will be stationary.
I will·essentially be an alarm clock, without the alarm.·
My background is in electronics, however my code skills are pretty weak as I just got my stamp a couple months ago.· Any help would be appreciated.
Thanks!

sylvie369
02-07-2010, 11:21 AM
No mysterious code - time is the first part of the $GPGGA string, sent out by most GPS units.

http://home.mira.net/~gnb/gps/nmea.html


eg1. $GPGGA,170834,4124.8963,N,08151.6838,W,1,05,1.5,28 0.2,M,-34.0,M,,,*75

http://forums.parallax.com/attachment.php?attachmentid=74088

Do a SERIN with a WAIT for $GPGGA, then SKIP one byte (the comma), and then read the 6 bytes of time. No problem, even with a BS2.

upand_at_them
02-07-2010, 11:25 AM
Did you try looking at the GPS demo program?