Topics

QCX-SSB: SSB with your QCX transceiver


Jerry Gaffke
 

I assume most errors will result from how fast Guido can update the si5351, and how accurately
and quickly he can adjust voltage into the final.  Those errors could be improved upon
considerably at little cost, as suggested in post 30871.

Whether the power FET's can remain linear enough at low supply voltages, I don't really know.
Though doesn't seem to be a problem when key shaping on CW rigs.
My guess is that IMD and such gets worse as a percentage of the instantaneously emitted signal,
but remains acceptable as a percentage of the peak emitted signal.

Jery



On Thu, Jan 31, 2019 at 08:18 AM, Kārlis Goba wrote:
Guido's method is not much simpler in terms of generation (due to probable source of many errors that might jeopardize TX quality beyond what is allowed for a SSB signal on air), but rather a neat hack of existing hardware. What it stands out is that it allows for a simple and efficient amplification.


ajparent1/KB1GMX
 

On Thu, Jan 31, 2019 at 08:44 AM, Jerry Gaffke wrote:
But Guido's method does away with the dual mixers of the SDR approach, and requires only one DAC.

Actually SDR only requires 1 DAC.  If the DAC is fast enough you can do direct synthesis
without frequency change. If you cannot do it super fast then at some lower frequency like
30 or 100khz and do a simple up-conversion like many of the current DSP SSB radios. 
FYI Guido uses two a PWM to simulate a DAC so it has its limitations (about 5-6bit resolution).
A real DAC even 8bit would likely improve the result but it has to be reasonably fast.

The problems with MOSFets at low power is driving them, the gate is very capacitive and 
eats current on transitions.  But I've run small mosfets at 13.56 mhz with 90% PAE to 5W out.
The drive in that case was the TI 5111 chip and power cost was 200mW to drive the mosfets.
Class e is switch mode so there is no IMD, only harmonics. Once you modulate the amp
you can get trash from the modulator but that is controllable too. so they tend to be unusually
clean.  The big economy is when you shoot for 100 or 300W full carrier!

As to class E (and class D) most of the efficient AM transmitters are one or the other
and usually use class D for the modulator as well.    Hams around here have had that
for years and There was at least one kit (Retro-75 from Small Wonder Labs in 2010)
that did QRP power class E on 75M.

So doing AM with a QCX would be dirt simple the the power level would be in the 
1.25W to 2.5W (carrier) range for 5W PEP.

Allison


Jerry Gaffke
 

>  The IQ quadrature still can't go below 3 or was it 3.5 mhz

The Si5351 "Phase Offset" registers as described in SiLabs AN619 
are 7 bits, one for each of the three clocks, step size of 1/4 of a VCO period
VCO goes down to 600 mhz, so max phase offset is  (2**7)/(4*600e6) = 53.333333 ns.
For quadrature clocks, we need to delay one clock by 1/4 of the period of the target freq,
so minimum freq for quadrature clocks using an Si5351 phase offset register is
    1/(4*53.333333e-9) = 4.687500mhz
But Hans has found that the VCO's in the Si5351 can reliably go well below the spec'd 600mhz,
low enough to cover all of 80 meters.

Guido is able to transmit on 160 meters. 
A 74AC74 as used on the SoftRock to create quadrature clocks is trivial enough,
and costs $0.10 in quantity.  Use that if you wish quadrature clocks for 160 meters.
Current QCX code is easily hacked a wee bit further, that would be
the least of my worries if implementing SSB with Guido's method.

Guido's code is there to demonstrate SSB on a QCX.
It is not an attempt to finalize production firmware that also supports CW.

Jerry, KE7ER



On Wed, Jan 30, 2019 at 01:39 PM, ajparent1/KB1GMX wrote:

The IQ quadrature still can't go below 3 or was it 3.5 mhz.  I'm puzzled by Guidos
comments on that.  If the IQ VFO is not 90 degrees then the  RX still works but
as a simple DCRX without image rejection.  There are ways around that but
none trivial or compatible with current QCX code.


ajparent1/KB1GMX
 

part B
>>>I assume most errors will result from how fast Guido can update the si5351, and how accurately
and quickly he can adjust voltage into the final.<<<

The process of updating the 5351 has its own cost to the signal  quality as every time you change
the frequency its a small jump and you get non-coherent spikes and that is a form of noise
modulation. Some could likely well out of band.  One source of error, the other is the coarseness
of the change and the more coarse the greater the discontinuities.

>>>Whether the power FET's can remain linear enough at low supply voltages, I don't really know.
Though doesn't seem to be a problem when key shaping on CW rigs.<<<

Cw keying is fairly simple as your rise time and fall times need to be controlled to avoid
creating clicks or instantaneous modulation but not all that hard as its a milliseconds
level event (ie fairly slow).

First linearity for that is, power out vs Drain voltage as they are operating as switch.  If
the gate is driven sufficiently hard it is quite linear.  Since its easy to plot the V-P curve 
you can correct any errors my measuring the output.  That allows one to "predistort"
to get a linear output.  However, power mosfets being designed for switching use
are ideal as we can get.  There are GaN,  mosfets using Galium nitride that are both
fast and efficient switches with on resistance in the sub 70 milliohm on range.
I've used them and the do perform, but for practical hams power mosfets are good.

>>My guess is that IMD and such gets worse as a percentage of the instantaneously emitted signal,
but remains acceptable as a percentage of the peak emitted signal.<<

There are many contributors, like rounding and truncation of the input signal in the CPU being
an 8bitter.   The input DAC is at best 10 bits and likely only 8-9 bits used.  To get this to work
we need to extract two components of voice one being simply frequency and the other is
amplitude the former is a bit math intensive the, latter is fairly simple. The  relationship of
amplitude to phase of the RF for faithful reproduction.  The greater the processing delay
the more difficult to get a near real time result.  Also if the processing delay is too great
the sampling may be corrupted.  There are other factors like time to update the 5351,
granularity of the update, power setting delay (Q6 driving the class E amp) and the
granularity of the update ( current is maybe 64 steps or 5bits) and that has its effects
both in the frequency domain and in the amplitude domain. Minimally it would make
the signal sound like the radios compression is turned to max.  Also the amplitude has
the limitation of rate of change as you can create side bands and too slow you
have phase errors.  To say there are a lot of interrelated factors is an understatement.
It is in the place I've called hoary complex math required.

Allison


freefuel@...
 

Hi Hans, how close is the circuit in your 5W HF PA kit to the circuit in the QCX? 

-Justin N2TOH 


Jerry Gaffke
 

> The process of updating the 5351 has its own cost to the signal  quality
> as every time you change the frequency its a small jump and you get
> non-coherent spikes and that is a form of noise modulation.
I looked hard at the si5351 output when driven with the si5351bx code
while updating every 100ms with 1hz increments in output frequency.
Unexpectedly smooth, no runt pulses, no dirt visible at all on the scope
at the time of the transition, a pure tone as it slowly crept through the
audio bandwidth of a receiver.


Any discontinuities could be reduced by using burst mode writes
(with auto-increment on the register address)
and upping the i2c clock rate if possible.

There might be a bit of noise injected by the i2c bus activity,
but I didn't hear it.

Yes, the ATMega328P ADC is 10 bits, I was wrong to suggest it was 8. 

>  what about with the key shaping amp and the DSP/PWM firmware?

That is what Guido is successfully doing, though I suspect it is not ideal.
For one, Q6 is fundamentally an integrator.  So the new state you put it into 
will depend on the previous state.  Listening to the current state with an ADC
might help considerably.  I'd be a lot happier just driving it with a 12bit DAC
if that was available.

Jerry, KE7ER


Kārlis Goba
 

Actually if think about the envelope generation, it becomes clear that driving Q6 in a linear fashion (from a DAC or integrator) wastes any gain of efficiency there was from using the FETs in switch mode whatsoever. Pretty likely the Q6 will need heatsink due to linear mode. In order to retain efficiency, Q6 needs to work in switch mode as well with a PWM signal. The current can be filtered with an inductor (Buck converter stage).

--
Karlis YL3JG


John VA7JBE
 

Great discussion so far.  From what I can understand at least some of the issues raised might be addressed by swapping in a $12 TeensyLC board, which has a cortex-M0+ processor and would provide 12bit ADC/DAC as well as a 48 MHz clock speed.  Though I'm still interested to see some performance measurements from the atmega328.

https://www.pjrc.com/teensy/teensyLC.html

Cheers,
John VA7JBE


Jerry Gaffke
 


They are quite different.
I suggest you read the circuit descriptions in the assembly manuals up on qrp-labs.com

Both are non-linear, so suitable for CW or FM.
The QCX amp is class E so more efficient but covers a single band, envelope shaping through the Q6 integrator, final is three BS170's
The 5W amp is class C, covers all of HF, includes a novel circuit for envelope shaping under the control of the uP, final is one IRF510.
Very different!

Jerry


On Thu, Jan 31, 2019 at 10:08 AM, <freefuel@...> wrote:
Hi Hans, how close is the circuit in your 5W HF PA kit to the circuit in the QCX? 


Jerry Gaffke
 

Correct.
But Guido is demo'ing this novel approach to generating SSB
using what's available on the QCX.  
An SSB transceiver using this method would likely have a number of changes.


On Thu, Jan 31, 2019 at 10:38 AM, Kārlis Goba wrote:
Actually if think about the envelope generation, it becomes clear that driving Q6 in a linear fashion (from a DAC or integrator) wastes any gain of efficiency there was from using the FETs in switch mode whatsoever. Pretty likely the Q6 will need heatsink due to linear mode. In order to retain efficiency, Q6 needs to work in switch mode as well with a PWM signal. The current can be filtered with an inductor (Buck converter stage).


ajparent1/KB1GMX
 

On Thu, Jan 31, 2019 at 09:58 AM, Jerry Gaffke wrote:
Guido is able to transmit on 160 meters. 
A 74AC74 as used on the SoftRock to create quadrature clocks is trivial enough,
and costs $0.10 in quantity.  Use that if you wish quadrature clocks for 160 meters.
Current QCX code is easily hacked a wee bit further, that would be
the least of my worries if implementing SSB with Guido's method.<<<<

Hacking the code to go lower as quadrature would likely require forcing the 5351 VCO
to a greater extent.  

Yes, he can transmit but the receive below 80m is a simple DC RX rather than Image
rejecting RX.  Is that a great loss not really as it just means some one at the opposing
image will be interfering.

I hinted at the 7474 fix (divide by 4) but for QCX original code it is not a compatible mod.
Adding that with the board layout may be a bit hairy to do cleanly. 

There are other RX mods like the 200hz CW filter that needs to be switched out or SSB
will sound bad.  The Analog processor it optimized for CW and for SSB there are more
optimum values.

The bigger issue is that you long run out of program space as Guido code eats 13kbytes
from teh arduino compiler of the possible 32K and less than a 1/3rd is likely common like
encoder and LCD driver.  So I'd bet that hacking QCX code to fit that in is out of the
question without giving up some features like internal DVM, CW decode, and/or other modes. 
At the other end Guido's code does not do CW, and many other things it pretty bare save of VOX.

Its interesting to try.

Allison
 


ajparent1/KB1GMX
 

Jerry,
>>>Any discontinuities could be reduced by using burst mode writes 
(with auto-increment on the register address) 
and upping the i2c clock rate if possible.<<<<

There are two forms of discontinuity one being the rate of update
and the other is the frequency increment.  And they interact as 
there is finite sped to do an update and calculate the next update and 
the overhead of transmitting it to the 5351.

>>>>For one, Q6 is fundamentally an integrator.  So the new state you put it into 
will depend on the previous state.  Listening to the current state with an ADC
might help considerably.<<<

You have to or every step change produces the same modulation as key clicks.
Since its happening at something higher than audio rate you can have
sidebands of that as a modulation.  A 10 or 12bit DAC makes for finer control
but each bit change needs to have some high frequency filtering or you will
get a bunch of tones at the output that have hard to understand by inspection
relationship to the primary signals.  That is impacted by the update rate of
the DAC/PWM and the granularity (# of bits) as well.  Simple way to say
it is you need to change the DC to the amp fast, but not too fast.

I plan to scope it and SA it as I suspect that activity can produce close
in and far sidebands.  With the level of compression I expect the two tone
to be very unpretty but hopefully only inside the audio bandwidth.

Allison


Jerry Gaffke
 

I doubt the QCX will ever be a clean SSB rig.
Looking forward to measurements of the transmitted signal, I could be wrong.
And I really don't care about 160m, and won't insist on 80m.
A single band 40m SSB rig with a class E final would be very cool.

But the QCX is a fine vehicle for probing the waters with Guido's method,
since that is what many in the forum happen to have on hand.

Building a rig from scratch for this, it could use a switcher to regulate voltage to the final,
have an ARM uC with 12 bit ADC's and DAC's, and lots of memory.
And a $0.10 7474 if you want 160m.

Yes, a single DAC can transmit SSB if it can update at RF rates,
so 3 or 4 orders of magnitude faster.  And much more expensive.

Or the single DAC can drive a mixer as you say, but then you are adding the mixer
and a local oscillator.  That seems a reasonable alternative.

But neither gives the efficiency of a class E final.

Jerry


ajparent1/KB1GMX
 

>>>Both are non-linear, so suitable for CW or FM.
The QCX amp is class E so more efficient but covers a single band, envelope shaping through the Q6 integrator, final is three BS170's
The 5W amp is class C, covers all of HF, includes a novel circuit for envelope shaping under the control of the uP, final is one IRF510.
Very different!<<

Actually the UP doing envelop shaping for CW is very much the core of EER.  The difference
is the envelope is from a processed microphone.  And that specific MPU is optional.

From the perspective of SSB via EER class C,D, E, and F are all useable and the difference
is topology and potential efficiency.   So Class C works and can run 70% vs highly tuned
class E in the 90%+ range.  None of them are which are broad band do to the need for
output filtering..  There may be yabuts as class C is usually not as linear to power vs DC
applied but its good enough if the gate driven sufficiently hard.

The 5W amp however is not complete enough to generate the RF so you would need to u3S
or the VFO either of which running new code to do that and also drive the output control of
the 5W amp sans its key-shaping  MPU.  It would be more wires and likely messier.  Also
more experimental.

I've already played some TX only using a simple Arduino, encoder, LCD, 5351, and a
Pin diode attenuator.  The power is 12dbm peak but the attenuator control input is
linear otput for linear control inputt for about 55db using a 0 to 5V input where
5V is about -1db loss and 0, is near -55Db .  The trick with that is it was usable
without any tuning for the 5351 range as the attenuator works from 1mhz to
over 100mhz.  The result sounded like SSB across the room to the 6M station
but that means nothing.  Test and measure. 

The whole TeensyLC thing is reaching the edge of doing it full SDR using a STM32F4
and that we know can be very clean.  Its the gap of throwing more at it and gaining
less to the limits of the technique where the next step up can offer much higher
performance for the effort.

FYI: first principles.  Modulation of a power amp is still the same thing as mixing
so signals in beget sidebands out.

Allison


Steven Weber
 

A friend lent me his QCX to check out and then told me about this mod. I just had to give it a try, seeing the QXC transmitter is a design I have been producing for over 15 years, starting with the first ATS multi-band, DDS tuned rig in an Altoids tin. Dan Tayloe borrowed the design for the original NORCAL 4020 rig the QCX is based on. Anyway, enough history. 

I was amazed but it actually works. Sort of. At first it didn't seem to, but then I remembered the keying slope mod which was done to the keying circuit. I removed the big cap across the base resistor and I started to see modulation. It kind of looks like a SSB signal on the Scope, but it sounds horrible on a near-by receiver. That might not be entirely fair as it's hard to listen to yourself on another radio, but I couldn't really tune it in quite right. 

That's as far as I got, just to see if it did anything. I think I'll play around with the keying circuit to make it work better with the PWM. For starters, replacing the PNP with a P-MOSFET for better linear integration. I need to see how it deals with a single tone. It should reproduce that tone's frequency in the receiver. 

The next step is to try and figure out how the sketch works. I suspect this scheme is better suited for AM modulation since it would only have to follow the voice envelope. I would like to try and turn off the frequency modulation and just do the envelope modulation. Oh, and it could used some AGC on the mic. It's easy to start clipping and then it really sounds bad. 

73, Steve KD1JV 


Hans Summers
 

Hi Steve

You are very welcome here! I will be very interested to hear about your performance measurements with the SSB code. 
 
A friend lent me his QCX to check out and then told me about this mod. I just had to give it a try, seeing the QXC transmitter is a design I have been producing for over 15 years, starting with the first ATS multi-band, DDS tuned rig in an Altoids tin. Dan Tayloe borrowed the design for the original NORCAL 4020 rig the QCX is based on. Anyway, enough history. 

I just wanted to clear up any misconceptions over the heritage of the QCX. Whilst it is true to say that we stand on the shoulders of giants, and it would be foolish to try to reinvent all the wheels that go into a transceiver, and so it is natural that bits and pieces of a design are often found elsewhere too... the QCX transceiver is NOT based on the ATS nor the NC2030. The ATS is a superhet using SA602 mixers so I don't see any similarity there anyway. The NC2030 is more similar but 90% of the radio is different. I have been experimenting with phasing-method direct conversion since 2002. The Quadrature Sampling Detector first came to my attention through reports of Dan Tayloe N7VE's implementation of the QSD, in the RadCom (monthly journal of the RSGB) Tech Topics column by Pat Hawker G3VA (SK, RIP). 

The QCX radio uses the 90-degree audio phase shift circuit of the NC2030, which is to say, IC6 and IC7 op-amps. This is the only commonality between QCX and NC2030. Both are direct-conversion phasing method receivers but they are not alone, there are others out there too. The CW filter in QCX comes from the superb Hi-Per-Mite design by David Cripe NM0S. The key-shaping is inspired by Don W6JL's page https://www.qrz.com/db/w6jl though as he said the circuit has been in use for many years. The Low Pass Filter designs come from Ed W3NQN's 1983 articles, used all over the place ever since. Everything else in QCX, and the way it is put together and firmware controlled, is my own. 

Just wanted to be clear: QCX is not a copy or a modification or a simplification or extension of an earlier radio :-) 

73 Hans G0UPL





Kelly Jack
 

I dont understand much about how signal processing works so have been looking for info on ssb generation from phase modulation. Came across this paper which shed some light on things but I dont understand half of it and none of the maths. Much seemed to be made of coordinating the phase component with the envelope but in there somewhere it said their isnt much information in the envelope so I was thinking why bother if a constant envelope signal is "perfectly intelligible".

https://www.google.com.au/url?sa=t&source=web&rct=j&url=http://stars.library.ucf.edu/cgi/viewcontent.cgi%3Farticle%3D1070%26context%3Drtd&ved=2ahUKEwjokv-inJrgAhVPTn0KHRnZDXA4KBAWMAJ6BAgHEAE&usg=AOvVaw2U6UUrZJsBRSFzxgE4B0o1


Erik Kaashoek
 

The document also mentions the noise associated with constant envelope and the "click" when starting/stopping the constant envelope. Solving this may be of similar complexity as using the envelope
--
Erik@Home


Jerry Gaffke
 

I have an ATS3A from 2006, a very nice CW rig with an excellent user interface.
It's well documented, extremely small yet is multiband through plug in coils.
In spite of being 14 years old, the the ATS3A would still be an excellent choice
if planning an extended hiking trip, especially given the 35ma receive current.
Steve's MTR line follows in that tradition, is currently available from LNR Precision. 

The primary similarity with the QCX is the transmit class E final,
with a logic gate driving three small FET's.
Logic gates driving FET's did not originate with the ATS, nor did class E.
Otherwise, hard to imagine a more different architecture from the QCX for a QRP CW rig.
I see more similarities between the ATS/MTR rigs and the prior '602/612 superhets
than I do between he ATS/MTR and the QCX.  

Jerry, KE7ER


On Thu, Jan 31, 2019 at 09:54 PM, Steven Weber wrote:
seeing the QXC transmitter is a design I have been producing for over 15 years, starting with the first ATS multi-band, DDS tuned rig in an Altoids tin.


Steven Weber
 

 

 

Okay, played around with this some more this morning.

 

The frequency output definitely follows at single tone. And repeats above 3 Khz, then above 6 kHz, etc, so it could use an anti-aliasing filter. Some frequencies sound a little squirrely too.

 

One issue I noticed which needs to be addressed is the PWM stays active after coming out of transmit.  I’m also not getting anywhere near 5W out, it peaks out at about 1.5 watts.

 

So, I put the original QCX chip back in to see what kind of power it should put out and now there is no power out at all. It doesn’t seem to be switching to transmit when I key. I hear side tone and the display shows what I’m keying, but the BS170 aren’t even getting a signal. The receiver is deafer then a paper mill worker  (I live near a former big time paper producing town).

 

I guess I have other issues to address first. Guess it’s time to  “RTFM”.

 

73, Steve KD1JV