Interfacing PAM-7Q GPS Module with Propeller Mini
jayrodalbert
Posts: 2
in Propeller 1
Hi,
Any ideas on what it would take to interface the PAM-7Q GPS Module with a Propeller Mini? Specifically, I am attempting to design and build a "invisible fence" type dog collar. How difficult might it be to perform logic based on coordinate readings from this module? What types of input can I expect? I assume there probably is interfacing code somewhere? I would need the finished system to continuously check coordinates (accuracy does not need to be precise in my application) and perform actions based on direction and position (such as dog whistle if the dog goes out of bounds etc).
Any ideas on what it would take to interface the PAM-7Q GPS Module with a Propeller Mini? Specifically, I am attempting to design and build a "invisible fence" type dog collar. How difficult might it be to perform logic based on coordinate readings from this module? What types of input can I expect? I assume there probably is interfacing code somewhere? I would need the finished system to continuously check coordinates (accuracy does not need to be precise in my application) and perform actions based on direction and position (such as dog whistle if the dog goes out of bounds etc).
Comments
the gps-module sends continuously out some nema-sentences over serial.
so it is quite easy to interface.
you just need to pick out current latitude and longitude out of that stream of data. There are multiple objects in the OBEX able to do that.
Luckily you stated that accuracy is not sooo important because gps coordinates tend to swing around about +-10feet.
Since your dog will not move far enough to be affected by the curvature of earth you can use the coordinates of lat and long as absolute coordinates in a square grid.
subtract some home-coordinates and the values you get are now relative to your home position and easy to handle as long integers instead of float.
checking the boundary might be tricky since your place might not be square and aligned to the gps-grid.
imagine a chess board with your home position somewhere in the middle.
you now have to define boundaries depending of your wanted invisible fence.
if latdiff< -20 and longdiff< -10 do something.
interesting project, but easy to handle with a prop.
Enjoy!
Mike
I like your idea. I have been thinking about something similar, with Prop mini, GPS, but also with a LoRa radio modem to transmit the dog's location to me. LoRa can easily do many miles, is not dependent on a mobile phone network, and is cheap on power consumption. Progress so far: the parts are sitting on my shelf. The missing 'how-to' is plotting the location or alternatively displaying relative direction and distance at the receiving end.
Erlend
So the Dog has to carry a GPS and Battery and some local Tx too ? Sounds like it gets large and heavy ? Hopefully he is a large Dog?
I think you may need a local base GPS too, to allow more like differential GPS, and it also simplifies the design, as now you do not care where in the world you are - you just convert both the strings to suitable integers, and subtract in native units.
http://forums.parallax.com/discussion/140890/diy-differential-gps-no-but-maybe-something-better
-Phil
http://forums.parallax.com/discussion/118830/propeller-based-reverse-geo-cache-birthday-present-project
If you modify the antenna so the cable isn't so long, you could also use the VPN-1513 Board since it already has the Propeller. I have one done so the cable is only 5". Modify the end that is inside the antenna magnet as it's easy to unsoldered.
https://www.parallax.com/product/28510
and yet commercial systems seem to do exactly this ?
One link there claimed
"The successive positions typically differ by 100 microns or less (over 3 km baseline!) and during the 1/2 hour run the position drifted 2-3 mm. "
So it seems the model of GPS matters, and I can imagine quite some variation in models, as many vendors will simply stop when they are 'consumer grade'. These days Power consumption seems to trump precision.
How do the 2017 models, compare with the earlier tests ?
Are they better, or 'built to a price' better, which means they have worse correlation ?
https://en.wikipedia.org/wiki/Differential_GPS
One big issue with my approach was that there's no guarantee that both GPS receivers are using the same set of satellites. So there's no guarantee that the position errors between the two stations are correlated.
-Phil
That wiki link you give says
"The baselines represent a three-dimensional line drawn between the two points occupied by each pair of GPS antennas. The post-processed measurements allow more precise positioning, because most GPS errors affect each receiver nearly equally, and therefore can be cancelled out in the calculations."
-Phil
Yes, hence my question above about if newer GPS units are better/same/worse in that respect ?
Do sales features like faster updates, mean they lop a few bits off the floating point convergences, for example ?
"Hey, which satellites are you using?"
"I'm using these twelve: ..."
"Good, I'm also using these nine of yours: ... I know your real position. So give me your computed position based on just those nine; I'll do the same and correct accordingly."
-Phil
https://forums.adafruit.com/viewtopic.php?f=19&t=113482&p=567151&hilit=GPS+accuracy#p567151
Claims 1~3m using their "GPS module Adafruit Ultimate GPS Breakout - 66 channel w/10 Hz updates - Version 3."
which I think is what I have here, for the 1pps timebase calibration.
Of course, tracking a Dog means you cannot take too long to make decisions, or average.
It may need a green/orange/red zone approach, and maybe some inertial navigation can do shorter term variations at 'dog speed' from a more stable longer term average ?