Parallax GPS Smart Mode
So I'm thinking that if this is smart then I am failing. [noparse]:([/noparse]
Ok so I am trying to get the "Smart mode" to work
So I am trying to get the Lat data from GPS unit.·It says its 5 bytes. Deg, Min, Sec(word), Direction
So the directions say send "!GPS" then the command you want.
But I dont seem to be getting anything that makes sense.
I think that I am recieving the outbound as the inbound.
Any Ideas suggestions?
Thanks always
TJ
Ok so I am trying to get the "Smart mode" to work
So I am trying to get the Lat data from GPS unit.·It says its 5 bytes. Deg, Min, Sec(word), Direction
So the directions say send "!GPS" then the command you want.
Fd.start(16, 16, 0, 4800) Repeat FD.Str(String("!GPS")) FD.tx($05) Repeat i from 0 to 4 OLED.FTEXT(0,0, 2, 255,255,255, string("Repeating"),0) LAt[noparse][[/noparse]i] := Fd.Rx Repeat i from 0 to 4 OLED.FTEXT(0,i, 2, 255,255,255, Lat[noparse][[/noparse]i],0) Delay.Pausesec(1) OLED.erase
But I dont seem to be getting anything that makes sense.
I think that I am recieving the outbound as the inbound.
Any Ideas suggestions?
Thanks always
TJ
Comments
I had the same problem, and it wasn't until digging
into the guts of the serial duplex object that I
discovered the importance of ... mode bits!
In your line of code
Fd.start(16, 16, 0, 4800)
try %1100 instead of 0.
What's happening is you're not ignoring the Tx echo
on the Rx line, and I believe the GPS line might be
an open drain/source tx as well.
Also, the third chunk of data (the word sized one)
is not seconds, but fractional minutes. For example,
you might get something like 1234 for this portion.
If your minutes were something like 8, then your overall
minute specification would be 8.1234. You can
certainly convert this value to seconds, using the fact
that 60 seconds = 1 minute.
Hope this helps!