GPS Helper -- What Features Would You Like To Have?
Jon Williams
Posts: 6,491
A project of mine that is about to get a lot of attention is a GPS "helper" chip for BASIC Stamp modules.· What it will do is receive and buffer GPS data and then let the Stamp ask for the elements it wants as required.· The "helper" will be an SX28 programmed in SX/B (with almost no assembly -- only as absolutely needed) and when the project is working I will make the schematic and code freely available to whomever wants it (actually, we're going to put it into the SX/B help file).
So... my question is: What GPS fields are you using that you would like to get from the GPS helper?· To keep the chip compatible with other Parallax products, I will use our AppMod serial protocol.· An exchange between the Stamp and the helper might look like this:
· SEROUT Sio, Baud, [noparse][[/noparse]"!GPS", GetLatD]
· SERIN· Sio, Baud, [noparse][[/noparse]latDegrees]
Where "GetLatD"·would be·predefined constant for retrieving the latitude [noparse][[/noparse]whole] degrees field.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
So... my question is: What GPS fields are you using that you would like to get from the GPS helper?· To keep the chip compatible with other Parallax products, I will use our AppMod serial protocol.· An exchange between the Stamp and the helper might look like this:
· SEROUT Sio, Baud, [noparse][[/noparse]"!GPS", GetLatD]
· SERIN· Sio, Baud, [noparse][[/noparse]latDegrees]
Where "GetLatD"·would be·predefined constant for retrieving the latitude [noparse][[/noparse]whole] degrees field.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Had a momentary time warp due to lack of coffee, and hit "reply" to your post like back in the old days instead of coming here.
So, is full time data including DST possible? Another question is my GPS units can all refine their position by taking a lot of readings and averaging the data. Would it be possible to access this info, or does that change from unit to unit? If full sattelitte data is unavailable, is the number of sats. possible, and maybe which ones?
Thanks for all you do!
Jonathan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
How about user defined fields....
So if a string looks like this:
$GPRMC,023042,A,3907.3837,N,12102.4684,W,0.0,156.1,131102,15.3,E,A*36
Then number each individual field in binary...so:
$GPRMC,023042,A,3907.3837,N,12102.4684,W,0.0,156.1,131102,15.3,E,A*36
···· 1·········· 2···4··· 8········· 16...etc...
Then have the user send one INIT string to the SX that defines the wanted fields.· I know this is more overhead than you wanted....but it sure kills all the discussions about 'this field is better than that field'....
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
·
Steve
"Inside each and every one of us is our one, true authentic swing. Something we was born with. Something that's ours and ours alone. Something that can't be learned... something that's got to be remembered."
I could certainly add a feature that would allow the user to enter a time-zone offset; that way the time reported back would be localized instead of UTC.·· The way I'm looking at things now I will probably just look at the $GPRMC and $GPGGA strings; the latter provides altitude and number of satellites.
Remember, this is supposed to be a *simple* program so that -- as with other Parallax demo code -- users can learn from it and expand on it.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
What I'd like to know is what people are *actually* using from their GPS units; in theory we can do anything but this a small project and I don't want to turn it into a big black hole by enabling every theoretical possibility.
I think that the Stamp will be able to make these requests:
· Hours
· Mins
· Secs
· Time -- returns three bytes
· Month
· Day
· Year
· Date -- returns three bytes
· latitude degrees -- two bytes; signed word
· latitude minutes -- two bytes
· longitude degrees -- two bytes; signed word
· longitude minutes -- two bytes
· heading -- two bytes (unsigned word)
· altitude -- two bytes (signed word in meters)
This is a lot to implement for a *quickie* project and should provide a good template for others.· Thoughts?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Post Edited (Jon Williams (Parallax)) : 11/9/2005 5:25:26 PM GMT
I'll quit working on mine, I was doing the same thing, trying to do the appmod protocol and monitor the GPS sensor using two interrupt driven serial ports. Was going to populate a fix length fields so BS2's or whatever would not have too much trouble reading the receiver values and acting upon them.
I would like to see the code and schematic when your done, would like to modify it to work with the boat load of Axiom receivers that I have!
Mike
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"OEM NMEA GPS Module" Now available on ebay for only $19.99
Product web site: http://www.allsurplus.net/Axiom/
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
I think the time is important....lots of ppl are after that for syncing other things.
I'd prefer the Julian date over MM/DD/YY....unless you're logging things, you might want to know the year.· MM/DD would be fine.
ACtually...going over your list....I'd think those are all useful.· I don't know the difference between MM/DD/YY and DATE....but one or the other would probably be all that's needed!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
·
Steve
"Inside each and every one of us is our one, true authentic swing. Something we was born with. Something that's ours and ours alone. Something that can't be learned... something that's got to be remembered."
Jonathan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
To make things super easy for beginners, I'm going to allow the module to return the time and date elements individually, or as a packet.· So, you could get just the hours element by doing this:
· SEROUT Sio, Baud, [noparse][[/noparse]"!GPS", GetHours]
· SERIN· Sio, Baud, [noparse][[/noparse]hours]
or...
· SEROUT Sio, Baud, [noparse][[/noparse]"!GPS", GetTime]
· SERIN· Sio, Baud, [noparse][[/noparse]hours, minutes, seconds]
Make sense?· I could, in the end, toss the individual time/date element retrieval but for the moment I'm going to leave it in.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
The buffer part is the bonus!
how much would it buffer before the stamp would have to get the data before loss?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
·
Steve
"Inside each and every one of us is our one, true authentic swing. Something we was born with. Something that's ours and ours alone. Something that can't be learned... something that's got to be remembered."
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Distance traveled (maybe that is post processed)
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Ken
This·is probably outside the scope of what you are trying to do, but I'll mention it anyway.
I use GPS mostly for robot navigation. Two of the things that take a lot of overhead are finding direction and range ·between a ·current location and an arbitrary target location.
my needs are short range (tens or hundreds of feet) so computing great circle routes, etc. aren't necessary.Simple trig does it.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Charlie
$GPVTG,054.7,T,034.4,M,005.5,N,010.2,K where: VTG Track made good and ground speed 054.7,T True track made good 034.4,M Magnetic track made good 005.5,N Ground speed, knots 010.2,K Ground speed, Kilometers per hour
That combination would give me precisely what I need (alt, vector speed, lat/lon, time).
How about it?
-dave
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
This is not a sig. This is a duck. Quack.
Post Edited (Dave Paton) : 11/14/2005 3:44:35 PM GMT
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Mike
"Don't always think outside the box, sometimes thinking inside the box is more pratical and simple."
·
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
That's about all I'd need. Something to sit between the GPS and my SX, parse some data to a more usable form, and spit it out on a serial line. 2 wires, no waiting. I like it.
Here's another random idea...put a pulse on a pin to signal new data is ready. It would be similar to the GPS 1PPS signal, but it could tie in to an interrupt so the user would never ever miss the data, no matter how busy the proc is. Just answer the ISW, stuff the data into some variables, and go.
How fast are you thinking of making the serial output? Getting a 9600 or (preferably) faster dump is better for me. Less time in an ISR or waiting for a DSR signal,
-dave
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
This is not a sig. This is a duck. Quack.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
I would keep the helper chip as simple and reliable as possible.
Didn't see the Status listed in the list of available parameters. I think it would be a good idea to include this. Also it will need to be decided what to do with the data in the other variables depending "A" or "V". If Status is "V" then you could do one of two things, clear the variable array or leave it populated so it could be used as a "Lost Known" location.
Mike
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"OEM NMEA GPS Module" Now available on ebay for only $19.99
Product web site: http://www.allsurplus.net/Axiom/
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Realizing that this is going to be a GPS then the Helper then a microcontroller. What if the microcontroller wanted the unedited string from the GPS once in a while? I've never used GPS's in a project but would there be a situation where you use the helper chip for the routine stuff and then if this particular gps has some fancy options to it, you could just request the raw data and decode it in your microcontroller?
Again, I've never used one so if I am WAY off base, I apologize.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
John J. Couture
San Diego Miramar College
you might want to split off the output of the GPS...one goes to the helper which is input to the stamp on pin X, and then the other wire off the GPS goes straight to the GPS (22kohm resistor in series of course) to pin Y.
Then it's just a matter of telling your program to look at pin Y to get a RAW sample.
Just a thought!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
·
Steve
"Inside each and every one of us is our one, true authentic swing. Something we was born with. Something that's ours and ours alone. Something that can't be learned... something that's got to be remembered."
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
John J. Couture
San Diego Miramar College
How's the helper chip code coming? Finally got around to ordering a PDB and a rail of 28s today. Itching to play with your code!
Mike
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"OEM NMEA GPS Module" Now available on ebay for only $19.99
Product web site: http://www.allsurplus.net/Axiom/
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax