Home
login

Electronics

Playing with GPS

GPS azimuth elevation chart with pygtk
GPS azimuth elevation chart with pygtk
GPS satellite azimuth elevation chart
GPS satellite azimuth elevation chart
I must have spent too much time hearing the other Elecraft K3 owners talk about fancy precision oscillator stuff because when the idea got into my head that I could make a really 'simple' embedded NTP server with the bonus side-effect of a GPS disciplined oscillator, I could not get the idea out of my head. So that is my latest project. I started by reading loads of hardware spec sheets and looking at various required components. Then after I had a pretty good draft of what the plan was, I started ordering engineering samples. The hope was to do this with purchasing as little as possible in the way of parts. So far, I have acquired a good portion of the parts and hope to get a few more before I have to go get the rest on my own.

GPS satellite azimuth elevation with traces
GPS satellite azimuth elevation with traces
One of the things I DID purchase was a GPS device. I didn't want any old GPS receiver, I wanted one that had a 10kHz output that is in sync with the 1 PPS output. Really this meant that I had to go with an older (used) model. But because they are a bit rare these days, that didn't really save me much in the way of money. I was giddy when it came in the mail. I started poking at it. Documentation was scarce. Finally I figured out that it has an Oncore GPS core in it, which finally led me to some more detailed documentation about the serial interface. After that, it was just a matter of whipping up some software to read and write the necessary packets. Then the fun started. I started logging data and learned how to make use of some of it. I have a handful of commands that I use to set it up and receive location updates, satellite position, and leap second information.

After looking at the location information that the receiver was providing, I moved on to the GPS location. Then I decided to make a tool to visualize the satellite positions. First I did this using ASCII art in the shell (which turned out surprisingly well). Then I added the traces of the satellite positions over the last 24 hours. This showed me some interesting things. First of all, it showed me that I had my plot wrong. (I had the north pole over in the east.... Ooops). Second, it was more a general coverage plot, since characters aren't quite so precise as pixels. This convinced me to move on to a pixel-based plot, using pygtk. This one started out simple, but got fancier as I realized that it would be easy to add a feature here and a feature there. The gtk version lets you mouse over a satellite and it shows more detail about that satellite, like the ID number, lock status, azimuth and elevation, etc. It also shows the trails of the satellites in dots that are color matched to the squares that represent the satellites. If the satellite is locked, then there is also a circle around it. The plot updates in real time with the changes in the log file from the GPS device.

RF Probe

A quick test of my SWR meter that I have been working on for the past few weeks told me that something was awry. It is a slight modification of that circuit, adding a couple of capacitors and replacing the two ammeters with an Atmega8 microcontroller's ADC unit. I figured if I could stabilize the voltages sufficiently, the ADC could read them and directly calculate the SWR. So I am sure that at least half the problem is that I made some assumption in SPICE that does not account for or some newbie error like that.

I looked at the DC levels and all the connections. I double checked the schematic. I don't have a low-frequency (<150MHz) signal source, so I just went whole hog and plugged in my radio. Pretty much no matter what I used for the load (short, open, 50 ohms, etc.) I could not get anything other than the full reflection voltage. But my silly multimeter doesn't do 150MHz. I need an oscilloscope. Or whatever they used before oscilloscopes. An RF probe. So I built one.

RF Probe
RF Probe
After poking around on the internet, I found N5ESE's classic RF probe, which seems to have been duplicated in many places, even as as kit from Hendricks QRP Kits. I rounded up the parts and put it together. I had the bright idea of stuffing it into a small bit of 1/4" copper tubing to shield it. I ground down the end of a small allen wrench to be the tip of the probe. I put it all together, added a bit of epoxy and some heat-shrink tubing.

Disappointment must be my lot in life because the RF probe was not working right either. Measuring the voltage across a 50-ohm dummy load (three 3-watt 150-ohm resistors in parallel), yielded 30+ volts when my radio was set to 1/2 watt. Just for reference, 1/2 watt over 50 ohms is 5 volts. If I bumped my radio up to 5 watts, the probe said 250+ volts. My multimeter was not happy about that.

I built another one on a spare breadboard. It worked like a champ. Even with the extra capacitance of the breadboard (or maybe because of it???). And when I say it worked fine, I mean it worked fine at 150MHz. I tore the first probe apart and tested the components. If it really was putting out 250 volts, the diode and capacitor should be dead. The multimeter says they are both fine. I test the probe out of its container. It is fine. I build a new container, this time fitting the copper tubing into a pen tube. No epoxy. I test it again and this time it works. Hooray!!! The picture above is my final product.

Now I need to put it to work debugging my broken SWR meter. Maybe if I can assemble these simple circuits, I can graduate to a real project like the MMR40 transceiver.