Shop OBEX P1 Docs P2 Docs Learn Events
$PGRMF - GPS NMEA Sentence...Any examples???? — Parallax Forums

$PGRMF - GPS NMEA Sentence...Any examples????

DShannonDShannon Posts: 26
edited 2005-07-12 03:18 in BASIC Stamp
has anybody out there read a Garmin $PGRMF sentence into BS2??? I cannot find the format ANYWHERE, such as:

'00000000001111111111222222222233333333334444444444555555555566666666667777777777888
'01234567890123456789012345678901234567890123456789012345678901234567890123456789012
'$PGRMF,1023.x,604799.x,ddmmyy,hhmmss,xx.x,ddmm.mmmm,c,dddmm.mmmm,c,c,c,x.x,x.x,c,c*hh

I need to use a statement such as:
SERIN 2, 16884, 1500, NO_DATA, [noparse][[/noparse]WAIT("PGRMF,"), SKIP 7, DEC Word1, DEC Word3, SKIP 1, BY1, DEC Word3, DEC Word4, SKIP 1, BY2, SKIP 1, DEC GPS_STATUS, SKIP 8, DEC Wrd5]

but need to know how many to "SKIP", etc. Any ideas???

THANKS!

Comments

  • Jon WilliamsJon Williams Posts: 6,491
    edited 2005-07-12 02:42
    If you don't know the format of the $PGRMF sentence, how do you know it will be useful?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Jon Williams
    Applications Engineer, Parallax
  • DShannonDShannon Posts: 26
    edited 2005-07-12 03:04
    I know what information is in this sentence. I just don't know the lengths of the various components coming back.

    From the NMEA spec:

    $PGRMF,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15*HH
    1 = GPS week number
    2 = GPS seconds in current week
    3 = UTC date, ddmmyy format
    4 = UTC time, hhmmss format
    5 = GPS leap second count
    6 = Latitude, dddmm.mmmm format
    7 = Latitude hemisphere, N or S
    8 = Longitude, dddmm.mmmm format
    9 = Longitude hemisphere, E or W
    10 = Mode (M=Manual, A=Automatic)
    11 = Fix type (0=No fix, 1=2D fix, 2=3D fix)
    12 = Speed over ground, kilometres / hour
    13 = Course over ground, degrees true
    14 = PDOP (Position dilution of precision), rounded to nearest integer
    15 = TDOP (Time dilution of precision), rounded to nearest integer
    HH = Checksum
  • ForrestForrest Posts: 1,341
    edited 2005-07-12 03:18
    Just connect your GPS to your computer's serial port, open HyperTerm, set the serial rate and capture the data from your GPS. You should be able to figure out the lengths from the capture.
Sign In or Register to comment.