Building a homemade GPS receiver [draft]
I lost some data. My fault for not backing it up properly. The images are gone. I’m going to rework this page.
A few years ago I read the web page of Andrew Holme, specifically his excellent work on building his own GPS receiver. I highly recommend reading his work. Mr. Holme references a previous piece of work done several years ago by:Matjaž Vidmar, S53MV.
Both of these engineers are rare, in that they created their own GPS receivers. Matjaz also created a GLONAS receiver – the Russian answer to GPS. Designing and building a working GPS receiver is an exceptional accomplishment. It requires knowledge of:
- RF fundamentals
- Signal chain design
- Digital electronics
- Digital signal processing
- Math – calculus, trigonometry
I am working on creating my own GPS receiver in order to further my knowledge in the above skills. Most of what I’m doing will initially look like a copy of Andrew Holme’s work. I don’t mean to take credit for anything he’s done.
Preamp/gain block schematic
I somehow always start by looking at Mini-Circuits parts when designing an RF circuit. I think that’s because they make it easy to find what I want. However for this circuit their parts seem a bit overpriced and are decidedly hard to get (I can’t buy it from Digi-Key or Mouser, I’m sorry but that makes my life easier.)
The circuit starts with J1 providing pre-regulated +5v DC. This feeds the (not shown) external LNA which is embedded next to the antenna. In hindsight I realize it would have been useful to have an on/off switch for the DC power.
From the input the signal is AC coupled and presented to the input of the ADL5611 MMIC.
The ADL5611 is a wideband +22dB gain amplifier with relatively low noise figure of 2.1dB. The p1dB point is a very reasonable 21 dBm. The ADL5611 has gain all the way into the 6 GHz range. It is imperative to have excellent layout for this part. On my PCB I placed a ground plane on the top and bottom layers. I stitched the ground planes together with vias. The logical in-out topology of the SOT89 makes it easy to achieve desired layout characteristics.
Preamp 3D rendering
Local oscillator / signal generator schematic (click for larger view)
I’m trying out the LMX2581 (PDF datasheet) from TI. This is a wideband frequency synthesizer with integrated VCO. It’s a one-stop shop for generating a precise output given a reference signal. It’s so feature-fully integrated that I don’t have to piece together my own local oscillator. As fun as that can be (Andrew Holme, Frac7.)
On my LO circuit board I included a small PIC24 microcontroller which I will load with firmware that will program the LMX2581 on power-up. I resisted the urge to put a USB port on this board; it’s unnecessarily complex for this.
The board DOES have an IIC port and logic-level simple UART interface. I anticipate possibly using the IIC as a slave port to control the LO from a higher-level system controller.
The LMX2581 has two output drivers. On my board I made one output an SMA connector (J6) and the other connector a U.FL connector. Both have transformer baluns to convert the push-pull output to single-ended.
The board has space for a Connor-Winfield temperature controlled crystal oscillator. I attached an SPDT slide switch to the enable pin on the TCXO. When de-asserted, the output is tristated. This allows the auxiliary input (J4) to be used as an input. When asserted, J4 will be presented with the TCXO output which could be useful.
The output of the LMX2581 should provide more than enough power to drive the mixer block. The AD8342 which I anticipate using has an internal LO amplifier block thus requiring a reasonably low +0 dBm LO level.
Local oscillator 3D rendering: The large gray blocks are dummy models of screw-terminals.
This is basically the app-note schematic for the AD8342. It seemed like a perfect part for this. I like that it has an internal LO amplifier. I used a full-featured differential output with balun transformer. I believe this will give me the best possible output amplitude. The inductors L1/L2 are backups in case I decide to not use the balun.
Mixer 3D rendering:
The comparator is an LMH7220 high speed, low propagation delay (2.9 ns) device. The output is LVDS, conveniently. LVDS is important because it is a balanced signal. The data is transmitted as a current source on one line and a current sink on the other line. Why do I care? There should be no significant power coupled into the power supply rails by the comparator. Remember: this comparator is watching the zero-crossings of an ~22 MHz signal having an amplitude of around -20 dBm / 22mV into 50 ohms.
This circuit isn’t too complicated. R1 and R2 create a positive reference for the comparator. Several capacitors: C6, C7, C9, reduce the impedance of the positive reference node to a very low value. R3 is the termination for the input I.F. that comes in on J2 or J3 (J3 is the U.FL connector and is not actually an open stub.) C8 isolates the input from the DC bias.
Here’s a little simulation of the Vref vs. input:
I added a lot of extra power supply filtering on this circuit because I don’t want to couple any of the output signal back into the ultra-low power modules that are up the signal chain.
 GLOBAL POSITIONING SYSTEM STANDARD POSITIONING SERVICE SIGNAL SPECIFICATION