Skip to main content

February 9, 2024. Quadrature LO (VFO)

Fair and Balanced so back to Digital LO's (VFO). Our last several blog posts have been about rigs that had an Analog  VFO. Obviously at the heart of this piece is the Si5351.

BUT this time I want to share how I turned a single LO output (typically CLK0) into a Quadrature Output meaning the same signal is coming from both CLK0 and CLK2 but they have a 90 Degree Phase Difference.

Yawn this has been done before with an Arduino so what is the Big Deal.  Well I have done it with a Seeed Xiao, RP2040. 

Lets back up in the sewer and ask why have a Quadrature LO signal. You could start way back with the work of Rick Campbell, KK7B and his famous Phasing Receiver (R2) and Phasing Transmitter (T2). Both projects used a multi pole op-amp audio phase shift network and a phased LO for the RF which was not digital. His piece stated it was a 1-500 MHz project. 
 
A basic phasing approach shows the  90 Degree Phased Shifted Audio (op-amps) and the 90 Degree Phase shifted LO (now with a Seeed RP2040). The Combiner to produce SSB can be a Ferrite Core transformer like in the Soft Rock Transceivers
 
 

 
 
 
Thus a today built Quadrature LO would give a frequency readout and with the Si5351 good through 220MHz. 
 
Several years ago, I Kludged together a SDR transceiver that used a Si570 that was controlled by software at 4X the operating frequency and then with a D Flip Flop converted that to a Quadrature Signal. That worked well except the 74HC74 D Flip Flop maxed out at about 100 MHz so that meant the Quadrature magic stopped at 12 Meters. I believe there are some who did a divide by 2 and got quadrature but have not tried that approach.

In our ever get to the chase approach here is the 14.2 MHz output from CLK0 and CLK2 with a phase shift. Now because of a press for time these days, I did not set up the scope to use a XY input and look at the Lissajous Figure which I will do but if the phase shift is a perfect 90 degrees you will see a circle appear on the scope.
   

90 Degrees with Audio Sine Wave, KK7B Board
Well not exactly 90 Degrees but not too far off.


What I said previously about a perfect circle would be absolutely true for a SINE wave.But I did look at an XY plot of the Si5351 and it was not a circle but a lopsided square. Then it hit me the Si5351 is a PLL and the output is more like SQUARE wave. See the link below.
 
 
 

 
  

This matches the 1st line in the graphic from the link publication. 1:1 signal level frequency with a phase shift of Pi/2 (90 Degrees). The frequency was 14.2 MHz
 


A test you can run at home with your DSO and that is clip the Channel 1 and Channel 2 Probes to the calibration port, turn on the XY Plot function and you will see a line at 45 Degrees from the lower left through 0 and proceeding to the upper right. That is the 1st graphic -- 1 to 1 signal, square wave and 0 Degrees of shift.

There was a journey to get here and I will briefly describe that journey. The first trick was to get the Xiao to operate as a standard LO/BFO like the Arduino Nano. I got some great help from Todd K7TFC. 

Caution the transition is not a simple plug in but you must use the Rotary Library from Bill Buxton and the Si5351 from Etherkit (Jason Mildrum NT7S). Pin Identification is not D2 and D3 (encoder) but 28u and 27u. Todd wrote some code so you can have an automatic decoder ring built in and then you can use either form.
 
Then there is W9RAN, Bob Nickels who has a website RAN Technology and he provided "seed" code (not seeed code) for a quadrature test generator using the Arduino. It is a basic sketch that creates the quadrature signals and with a loop counter advances the frequency a fixed amount. Thus looking at the serial monitor you can watch the frequency increment by the fixed amount specified in the sketch.
 
Now armed with the W9RAN code snippet I had two problems. The first is how to convert his code into something that will work with the Seeed Xiao RP2040 (versus Arduino) and two, since W9RAN was clear that turning this into a working quadrature LO was up to you. So how to embed that in the earlier work with the plain vanilla LO/BFO Seeed Xiao RP2040 code was the challenge and gorilla in the room.
 
For the anal retentive BTE the test setup looks like this as mess works best. BTW there is an OLED display on the prototype board --have not been able to get that to play with the RP2040.
 


That is how we got here.

I suspect that the RP Pico with the RP2040 chip might work but have not tried it or have knowledge that it has been done.

73's
Pete N6QW

Popular posts from this blog

December 8, 2024. Why do things fail?

December 7, 2024. Pearl Harbor Day ~ a day of infamy!

December 10, Common Threads

12/4/2024. The 12GE5 Ouput Network Simulation!

December 11, 2024. We take things for granted.

2019 ~ What is the simplest homebrew SSB Transceiver that can be built?