Monday, April 15, 2019

Applying outboard AGC and filtering to RTL-SDR dongles to maximize usable dynamic range on HF


An AGC system for RTL-SDR "wideband" receivers
operating in "Direct" (Q-branch) mode.

 A quick description of RTL-SDR dongles:

Figure 1:
An"RTL-SDR.com" USB-based receiver - one of the better, "cheaper" options out there.
This unit has been programmed and marked with its own, unique (to the system) serial number.
Click on the image for a larger version.
The so-called RTL-SDR dongles are ubiquitous and versatile because they can cover (more or less) from a few hundred kHz to over 1.3 GHz using various on-device signal paths - but all of these signal paths have in common one important limitation - The A/D converter is only 8 bits.  Despite these limitations, they are attractive because they are cheap - from $4 for the "bottom end" and cheapest devices (which are far noisier than they could be) to well over $50 for units with frequency converters and a few other bells and whistles - including band-pass filters.  The devices that we are using are just $20 and are the RTL-SDR dongles sold by "RTL-SDR Blog":  These units have thoughtfully-designed circuit boards that minimize extraneous, spurious responses and include 1ppm TCXOs for decent frequency stability as well as providing separate signal branches for "direct" and "quadrature" signal paths for frequency ranges below 30 MHz and above around 60 MHz, respectively.

Ideally, the maximum range represented by an 8 bit A/D converter is around 48dB - and this is approximately what can be expected from these devices - but as with most things in the real world, the actual answer to the question of "what is the dynamic range" is more complicated.  In reality, noise considerations of the device reduce the number of usable A/D bits and thus the dynamic range, this noise coming from the device itself and other devices in the signal path - but due to what amounts to oversampling and the contribution of the noise that is always present on HF which can effectively "dither" the A/D converter, the apparent dynamic range can "seem" to be somewhat greater - perhaps well in the 50dB range, under some circumstances - but having 50 dB or so of usable dynamic range is not nearly enough for reasonable performance on the HF bands under a wide variety of signal conditions.
"But the Dongle already has an AGC!"

One advantage of using a dongle with an upconverter - a device that would, say, converter 0-30 MHz to the range of  125-155 MHz - is that it then places these signals within the range where the R820T chip can operate - and this chip does have RF filtering and a sort of AGC - at least by way of being able to have its gain adjusted by software.

Aside from the frequency drift issues related to this frequency up-conversion mentioned elsewhere, the problem with this is that the R820T chip really isn't that "strong" in terms of  its ability to handle widely disparate signal levels.  While the RTL2832 chip does have an AGC or sorts, the gain of both chips in the signal path must be carefully controlled to maximize performance.  Unfortunately, the precise nature of how these all work together isn't well documented and the general consensus seems to be that at HF, it doesn't work all that well.

While the built-in AGC can work, we decided to avoid combining the somewhat marginal performance of the R820T signal path and the unknown nature of the AGC operation with the already-marginal 8 bits of A/D conversion in favor of an external AGC system operating within the well-defined limits of the dynamics of these devices when they are operated in "direct" mode.


The problem:

In this specific case we are using the "Q" branch of the RTL-SDR dongle for direct reception of HF signals:  For the purposes of this discussion and to avoid the complication of a discussion about aliasing, we'll limit the frequency range to 30 meters (10.15 MHz) and lower - a range that encompasses what are, in the current sunspot cycle, the two most popular HF bands:  40 and 80/75 meters.

In some circumstances - and with careful adjustment of RF levels - the limited dynamic range of the RTL-SDR dongles is "almost enough" - but because HF conditions widely change the "optimal" amount of signal getting into the dongle goes all over the map:  During the daytime on 40 meters, noise can be very low and there are very few truly strong signals, but in the evenings or mornings there can be very strong signals from high-power shortwave broadcast stations.  These disparate situations cause some problems:
  • If one adjusts the signal level going into the dongle to optimize to hear weak signals during the day (e.g. the background noise of the band driving the A/D converter to 10-15% full scale indication) it is likely that strong nighttime signals - both amateur and broadcast - will (more or less) saturate the A/D converter (e.g. put it into the range of "clipping"), degrading performance considerably.
  • If one adjusts the signal level into the dongle to accommodate the very strong signals (which is only a "best guess" as such signals can vary by 10s of dB) then the input level to the dongle under "quiet" band conditions will be so low that sensitivity will suffer and spurious signals can appear everywhere as to few A/D converter bits are being "tickled" and.
As mentioned before, the A/D converter's 8 bits do provide roughly 50dB of overall signal-handling range, but using one of these devices on HF soon makes it clear that one must constantly adjust the input level to assure that that 50dB "window of usefulness" is in the right place.  Using 60 meters as an example again, a "quiet" band in a good location may yield around -107dBm of noise in an SSB bandwidth, but a powerhouse shortwave broadcaster's signal can be into the -35dBm range - nearly 70dB higher than the noise (and there may be more than one of these strong signals!) which represents a range of at least 70dB.  What's worse, taking into account the need to provide 10-15% of A/D deflection just on the background noise on a quiet band for the dongles to work properly (to avoid serious issues with quantization-related distortion) roughly half of the 50dB or so available to us is already "used"!


Applying an AGC (Automatic Gain Control):

Figure 2:
Inside the 4-channel filter and AGC gain block module.
The individual band-pass filters may be seen at the far end of the lid-mounted
PCB ground plane while the actual detection and control circuitry
is on the prototype boards in the foreground near the bottom of the picture.
Click on the image for a larger version.
Any RF-based digital direct-sampling (or analog!) receive system - to maintain optimal performance - must have its input levels constrained, which is to say that one must take into account both the lowest and the highest signal levels.  In some cases it is simply enough to amplify/attenuate the input levels so that the expected signals will always fall in that range - and this may be practical on VHF/UHF or microwave, but it is certainly not the case at HF.

Even if we were to use a higher resolution A/D converter, we would still want to do this to keep all of the input signals within the "sweet spot":  Direct sampling HF transceivers such as the Icom IC-7300 and IC-7610 must apply both "strong" band-pass filtering and input gain control to maximize their overall performance.  In general, the more signal we throw into the A/D converter, the better - as long as we don't overdrive it and cause (excessive) "clipping".

Such is the case with these RTL-SDRs:  For best performance, one must have BOTH "strong" input filtering centered around the frequency range of interest (the narrower the better!) and keep the signal levels in the "sweet spot":  A properly-designed AGC can do this.

In short, the signal path and method is like this:
  • The signal comes from the antenna.
  • Bandpass filtering for the band of frequencies is applied.  The narrower the bandwidth and "sharper" the filtering, the better.
    •  Important:  One should never connect a receiver - particularly one with limited dynamic range - to an antenna without a band-pass filter that limits the bandwidth of the applied signals to the range of interest. (In other words:  Don't waste your time trying to make an RTL-SDR dongle work on HF without a suitable HF bandpass filter for the frequency range of interest.)
  • On the output of the filter is an electronic attenuator.
  • The signal level on the output of the filter (which is also being applied to the dongle) is measured.
  • If the signal level exceeds a set threshold, the amount of attenuation is increased to cause it to remain at/near that threshold.
In short, the above system prevents the combination of all signals from getting to the dongle from consistently exceeding a pre-set level.  In this way, one can run a bit of "extra" gain to get the best weak-signal performance, but prevent the system from being hopelessly overloaded when very strong signals appear.

A practical implementation:

To maximize performance of the RTL-SDR dongles used for HF reception at the Northern Utah SDR, a "prototype" module consisting of four bandpass filters and four AGC gain blocks was constructed - see Figure 2.

Bandpass filters for 90-80 meters, 60-49 meters, 41-40 meters and 31-30 meters were constructed "Manhattan Style" pieces of glass-epoxy circuit board material as individual filter modules which were then secured to the main ground plane - a larger piece of PC board material mounted in the lid of a Hammond 1590D aluminum enclosure.  Three dividers - also made of circuit board material - provide shielding between each of the band modules.

Constructed on small pieces of phenolic prototype board are the circuits that detect the RF and derive a control current for the electronic attenuators.  These devices are mounted elevated above the ground plane and attached to the shield walls which provides good RF grounding and a DC return path:  Two smaller "walls" are located at the far ends to provide the two boards at the ends with solid attachment points.


Figure 3:
Schematic of the gain control block.
Click on the image for a larger version.
Circuit description:

Figure 3
shows the gain control block schematically.

The input signal passes through the band-pass filter (shown as a block) with its output connected to a doubly-balanced modulator module, U3.  These devices are nearly identical to standard diode-ring doubly-balanced mixers, except that they are optimized for operation as an attenuator or baseband modulator:  The attenuation through them is inversely proportional to the logarithm of the current applied to the "CTL" (control) port.  In this case I used the Mini-Circuits LRAS-2-75 modules, originally designed for 75 ohm systems, but they work just fine at 50 ohms as well - being chosen because they are some of the lowest-cost components of this type offered by Mini-Circuits Labs.  The "official" specifications of the LRAS-2-75 gives specifications down to just 10 MHz, but it works fine at 3 MHz with just an extra dB or two of insertion loss.

Figure 3 gives a list of other suitable devices - some of which are rated down to lower frequencies than the LRAS-2-75.  Figure 3 also mentions the use of a standard doubly-balanced mixer such as the Mini-Circuits SRA-1:  A standard mixer will also work "acceptably" in this role if that is what is available.  If a standard doubly-balanced mixer is used, make sure that it has a port that provides a direct connect to its internal diodes to which the bias may be applied:  While this is usually the "IF" port, some devices have this particular port otherwise designated.  The presence of the diodes can be easily checked by using the "diode" function of a DVM between the device ground(s) and the control pin, observing a 0.2-0.3 volt drop in both directions/polarities of the meter.

The output of the attenuator (U3) goes two places:  To the RTL-SDR dongle being used for reception, and to the input of U2, an Analog Devices AD8307 logarithmic amplifier.  This device's input impedance is quite high, so a 470 ohm series resistor (R6) is used to lightly "tap" the RF coming out of the U3 while causing minimal circuit loading.  Included across the input pins of U2 is a low-value capacitor - typically in the 33-56pF range (as noted on the diagram) that is connected very close to the device to quash its response at VHF/UHF while minimally affecting HF signals:  Without this capacitor, U2 can easily detect any local FM or VHF/UHF TV broadcast signal - or even local VHF/UHF amateur transmissions - and be somewhat "desensed".  Practically speaking, this may not be a problem - particularly when it is placed inside a shielded container, behind bandpass filtering - but this can be distracting when the circuit is on the workbench being tested.

The output of U2 is a logarithmic response of the total RF energy being applied to its input, the voltage increasing by approximately 250 millivolts for every 10dB of increase in signal:  If reasonable construction techniques are applied, signals well below -70dBm can be measured.  Because the maximum signal level (e.g. A/D converter clipping) of the "RTL-SDR Blog" dongle is in the range -40dBm, no additional RF amplification is necessary in front of U2.

Figure 4:
Two of the gain control modules with U2, the AD8307s being
partially obscured by the ferrite beads.  These
beads are used to decouple any stray RF from the
common 12 volt supply line powering the modules.
Click on the image for a larger version.
U1 mustbe an op amp capable of operating down to the negative rail in order for this circuit to function and the specified LMC660 is ideally suited.  The DC output of U2 is applied to U1a, one half of a dual op amplifier, wired as a unity-gain follower to set a low impedance point, and this DC signal is then applied, via R5, a 1 Megohm resistor to U1b, which is configured as an integrator by virtue of a 0.1uF capacitor placed in the feedback path with the threshold being set by R4, a 10 turn potentiometer.  If the integrated DC signal from U2 is above the threshold set by R4, the voltage output of U1b decreases, reducing the bias applied to attenuator U3 and increasing its loss, but if the signal is below the threshold, the voltage increases, decreasing the attenuation.  By this action, the combination of U1 and U2's action will prevent the average signal at the bandpass filter's output from exceeding the threshold level set by R4.

Whereas a typical AGC found in a receiver will have a fast "attack" and a slow "decay", we want this AGC to be comparatively slow to respond so that it will (hopefully) not be completely deafened by the occasional static crash.  In reality, allowing the A/D converter to hit full-scale on occasional peaks will have minimal apparent impact on reception.  In the absence of broadband static crashes, the cumulative power within the bandpass filter's range will change comparatively slowly over time and it is this that we wish to track.

In the DC path between the output of U1a and the "CTL" pin of U3 is a series LED which provides both a bit of logarithmic current response intrinsic to semiconductor diodes as well as providing a handy visual indication of the state of the circuit:  If the LED is lit, attenuation is low, but if it is very dim or turned off, more attenuation is being applied.  In testing, the photosensitivity of LEDs was simply a "non issue" and ambient light had no discernible effect on circuit operation.

Resistor R3 provides current limiting to the diode while R2 provides a current sink:  The combination of R1 and C1 (located very close to U3) terminate the "CT" port (at high frequencies) at the nominal impedance of the RF portion - in this case, around 50 ohms.  Also included is U4, a 5 volt regulator:  This supplies power for U2 as well as provides a stable reference voltage for R4, the RF threshold adjustment:  It need not be exquisitely stable with temperature as several dB change of the AGC threshold with varying temperature is of no importance in this application.

Under normal "quiet" conditions the RF level going into U2 will be too low to exceed the threshold, causing the output of U1b to go to maximum voltage, biasing U3 to set minimum attenuation - it is only in the presence of stronger signal(s) that the gain reduction will occur.

Circuit calibration:


To calibrate the circuit, a signal generator is required, the procedure being as follows:
  • Pre-set the wiper of R4 (the 10 turn pot) to ground (zero volts at U1b, pin 5)
  • Set a signal generator it to a frequency within the passband of the filter and an RF level of around -20dBm.
  • Connect the input of the dongle to the signal generator and tune it to the frequency of the generator using software of your choice.  Make sure that the "direct - Q" signal path is selected since we are not using an upconverter.
    • If using SDR-Sharp, tuning in the signal (using AM is best) "hovering" the mouse over it on the waterfall display should give a dBFS reading.
    • If using the "HDSDR" program, the "dBFS" reading will appear on-screen in the receiver control panel.
  • Using the software, monitor the level of the applied RF signal's "dBFS" (dB with respect to full-scale).  Ideally, a full-scale A/D indication would yield a dBFS reading of around -6dBFS, but it seems that the internal scaling of the signals from an RTL-SDR dongle aren't scaled, so the reading may be in the -30 to -50 dBFS range.  Monitor the "dBFS" from the dongle while increasing/decreasing the signal and note the highest value.  The goal here is to determine the reading given by the program.
    • Ideally, one would like to be able to see the "recent-highest" reading of the A/D converter of the dongle, but this may not be available in the programs used with the dongle.
    • If adventurous, one can use the "librtlsdr" tool called "rtl_sdr" and dump the results to a file or a display program to monitor the raw A/D values.
    • If you operate a WebSDR using the PA3FWM software there is a utility that will directly read out the number that we want to look at:  Contact me directly for details.
  • Having determined the maximum-displayed "dBFS" level, connect the signal generator to the input of the bandpass filter and the RTL-SDR dongle to the output (e.g. J2 in Figure 3.)
  • At this point the LED should not be illuminated and U3 will offer maximum attenuation.
  • Slowly increase R4 until the LED just starts to be illuminated.  Watching the "dBFS" reading, adjust R4 for a signal level that is about 6dB below the maximum reading that you'd previously obtained.  Ultimately, you will want to set the peak A/D output to between 1/4 and 1/2 of full scale which represents -12 to -6 dBFS, respectively.
  • If the circuit is working properly, any signal above that corresponding with the threshold should be limited at the set value by automatically setting U3's attenuation, but a total signal power level below the threshold should cause U3 to operate at minimum attenuation as indicated by maximum LED brightness.
    • If you are using a signal generator with a built-in "step" attenuator, changing signal levels may cause momentary "glitches" of high signal that may cause a momentary disruption in the A/D reading and slightly upset the AGC:  Simply wait for a few seconds after making an adjustment for the readings to settle after making a change.

Figure 5:
Two bandpass + attenuator (U3) modules.
The inductors/capacitors of the filter may be seen in the
middle of the individual boards while the attenuator (U3) is the
white object seen in the lower-right corner of each board.  U3 is wired
"dead bug" style in each case.
Click on the image for a larger version.

Observations in use:

So far, these devices seem to be working as intended.  Even with higher overall gain in the signal path than before (e.g. when band conditions are poor and/or there are no strong signals in the filter's passband) the RTL-SDR dongles have not been observed to show obvious signs of overload when extremely strong signals are present - this having been a problem previously.  Initially, the AGC threshold was set for -6dBFS (1/2 A/D scale) using a CW signal from a test generator.  In the weeks that followed, these receivers were monitored during high-signal conditions and it was noted that there had been no obvious problems.  The AGC threshold was later reset for -12dBFS (1/4 A/D scale) and an additional 6dB of RF applied to the receivers with no obvious degradation in performance in the presence of strong signals, but a slight improvement in weak-signal performance when the bands were "closed".

In looking at receiver stats, there are still instances of A/D "clipping" - but this is to be expected:  The AGC circuit integrates the level over time (perhaps a few seconds) and brief excursions well above the threshold level are to be expected, both from static crashes, but also coincident modulation peaks of several strong shortwave broadcast signals.  Because the "occasional" clipping typically has little apparent impact on the receive signals (particularly the narrowband signals on shortwave frequencies) this effect isn't noticed.

On some of the bands, a bit more RF signal is needed to optimize performance - that is, to "tickle" more A/D bits when signals are weak.  Previously, doing so would risk gross overload of that receiver when the band "opened" with strong signals, but the AGC block should minimize any such issues.

Not mentioned previously, this AGC system can skew the S-meter readings from the receiver somewhat.  In the presence of strong signals, the AGC will lower the overall system gain causing the readings to vary and appear low.  In theory, one could monitor the voltage being applied to bias the attenuator and relate this to the amount of attenuation and offset the S-meter readings, but this may be overkill in most situations!




The above article was posted (by me) as a technical article at the Northern Utah WebSDR (link).

While the circuitry could be integrated onto a small circuit board, this has not been done as the circuits are quite simple and easy to construct as depicted.

* * *

This page stolen from ka7oei.blogspot.com

[End]

Monday, March 11, 2019

Quieting an insanely (RFI) noisy LED floodlight

A friend of mine recently installed some inexpensive Chinese-made floodlights to illuminate his backyard, but was dismayed to discover that when they were on, his 80, 40 and 20 (shortwave - 3.5-14.5 MHz) reception "went away", replaced with a very strong noise that was "20 over" - a degradation of apparent sensitivity of much more than 20dB.  As it turned out, almost every frequency below and above this range he checked was also affected to a similar degree.
RF noise from "grow lights" - the same phenomenon

Several years ago, there was some noise (pun intended) in the Amateur press about LED power supplies being sold that caused a tremendous amount of RF interference - and many of these stories also included anecdotes of many of these interference sources having been tracked down and found to have been "grow" operations.  Later, some stories surfaced where law enforcement officers were able to locate some of these "grow ops" simply by finding the source of RF interference.
The LED power supply described on this page is of the same type that was found to cause these very high levels of RF interference.

Even though these lights aren't turned on very often, he decided that their flaws went firmly against his eternal crusade against RFI-generating devices at his house.  After all, when it comes to RF interference, one should remember this cardinal rule:

Most RFI begins at home!

To be sure, there are many cases in which there are noisy power lines or a neighbors plasma TV - just two in a long list of things that can cause interference, but the worst offenders in generating interference are likely in one's own house.   The main reasons for this are simple and (for the most part) obvious:
  • They are nearby.  If a noise generating device is in your house, it's very close-by - and the closer it is, the more your antenna is likely to intercept "grunge" from that device.
  • They are connected to the same wiring as everything else in your house.  There's nothing like a piece of copper to convey RF all over the place with minimal loss, and if a noise generator is powered from the mains, it's likely conducting much of that noise into the same mains connections that power your radios.
  • If you are like most amateurs, you probably have radiating feedlines on your HF antennas.  By their very nature, almost all HF antennas tend to radiate a bit of RF on their feedlines.  For some antennas (e.g. dipoles, yagis, loops) this is incidental - often due to inadequate balun design, but other antennas (offset-fed antennas like Windoms, end-fed antennas) this is often by nature or design.  If the feedline of your HF antenna isn't very well-balanced (often using a "current mode" choke) some of your "noise" from the devices in your house wiring is being conducted from your shack, onto the feedline and then into your antenna.  Fixing this problem certainly warrants a series of articles itself, but suffice it to say, "noisy" devices will seem worse because of this issue than they would normally be.
Figure 1:
The constant-current LED driver with added filtering.  This LED driver
is typical of what is seen in these devices:  A rather generic, potted module
of likely-questionable lineage and quality.
Click on the image for a larger version.
What are these things?


As is typical with these inexpensive LED lamps, the power supply is a constant current module that uses PWM/switching techniques to regulate the current applied to the LED array to some value.  As can be seen Figure 1, this is simply a box with two sets of wires:  The AC (main) input on one side and the DC output to the LEDs on the other.

Because these are constant current supplies, they can be used over a wide range of LED module voltages:  22 to 36 volts, according to its label of that in Figure 1.  Noting the official "50 watt" power rating, we can do the math and see that with a constant 1500mA, the power being delivered to the LED array can vary from 33 to 54 watts, depending on its actual operating voltage.  Depending on the design, these supplies may or may not have their DC outputs isolated from the mains input via an internal transformer, so it is best to assume that they are not isolated and that the DC outputs will be line-referenced and hazardous (even lethal!) to touch.

In this example, the red and black DC leads disappeared into the body of the case where it would connect to an LED module that is (presumably!) insulated from the lamp's case.  Because you can't be sure what to expect, one must always make sure that the safety ground of these lamp housings is actually connected to the case (the ground wires in these devices are often not connected to the case at the factory!) and that it is plugged into a GFCI-protected outlet.

How bad was it?

In the case of these LED floodlights, the only connection that they had to the rest of the universe was via their power connections, so it was clearly via its power leads that they were radiating their "grunge".  To determine in some quantitative way how noisy this device was, a simple test fixture was constructed to measure the energy imparted on the mains power lead, represented schematically in Figure 2, below:
Figure 2:
Test fixture to analyze the amount of RF being conducted from the LED's current supply to its mains leads..
"Ca" and "Cb" are 0.1 to 0.47 "X" class "safety" capacitors used for mains filtering and "La" is a bifilar mains choke of at least 1 milliHenry per winding, these constituting a filter to decouple noise already present on the mains from the test fixture:  One of the filters depicted in Figure 5 could have been used for this purpose.
RF coupling transformer "Ta" consists of a Mix 31 clamp-on ferrite choke with a single wire going to the "Device Under Test" as the primary and 6-8 turns of smaller wire as the secondary to couple RF from it.  The box marked "protection" is simply two back-to-back 5.1 volt Zener diodes in series to protect the analyzer from voltage transients caused by turn on/off transients.
Click on the image for a larger version.
In this circuit we see a common-mode line filter using Ca, Cb and La forming a circuit to attenuate noise that might already be on the mains.  The goal is that when we measure RF noise via coupling transformer Ta, we are (mostly) seeing the noise from the device being tested and not that which may already happen to be on the mains.

The result of this measurement can be seen in Figure 3, below, covering the range from nearly DC to 1 GHz, with the cyan trace being with the unit turned off and the yellow trace with it turned on:

Figure 3:
Noise from the power supply as seen from 0 to 1 GHz.  The blue trace is with the LED power supply powered down while the yellow trance shows it powered up.  As can be seen, it is a potent noise generator well into the UHF spectrum - but particularly at and below 100 MHz!
The various signals on the cyan trace are off-air signals, including AM, FM and TV broadcast and 800 MHz - plus some leakage from the noisy mains through the Figure 2 filter:  Ingress of these signals is the inevitable consequence of the rather simple lash-up and not conducting these tests inside an RF-screened room!
Click on the image for a larger version.
While this test fixture isn't perfect (e.g. some leakage from the mains through the filter, some couple of broadcast signals directly into the fixture over the air and the fact that the coupling coefficient is unknown because I didn't bother to determine it!) it did the job of giving a relative indication of how much "grunge" the LED's power supply put into the mains - and this same information would later be useful to get a general idea as to how much our mitigation efforts reduced this noise.  As can be seen, below 100 MHz the added noise (in a 3 MHz detection bandwidth) is nearly 50dB (100000 x) higher than the noise floor of the analyzer and the test fixture.

Refocusing on a smaller frequency range with different analyzer settings, let's take another look at how bad it is over the lower HF range:

Figure 4:
A re-done plot over the range of 0-100 MHz, this time with an 8 MHz resolution bandwidth.  The higher resolution bandwidth results in a higher reading from the QRM generator as its output is broadband noise.
Over much of this range, the base noise level (in cyan) is below the measurement sensitivity of the analyzer.
Click on the image for a larger version.
From the plot in Figure 4 we can start to get a picture of how bad the situation really is.  As can be seen at Marker #1, we measured a power level of about -3dBm - or 0.5 milliwatts within an 8 MHz bandwidth, but if we were to integrate this energy over the entire 0-100 MHz range we can see that there may be, perhaps a couple of 10s of milliwatts of noise being coupled into the mains:  We can only guess at the true amount of conducted RF owing to the comparative crudity of our test fixture and its unknown coupling coefficient across the RF spectrum, but we can be reasonably sure that what we see on this trace is but a fraction of the total energy present.

Figure 5:
Some board-mountable Shaffner mains filters from the Electronic
Goldmine, item G21844 (no longer available - sorry...)
Click on the image for a larger version.
As noted earlier, the entire purpose of these measurements was not to determine an absolute level of RF energy, but rather to have a means of repeatably measuring how bad things are - and also to be able to determine if our mitigation methods are having the desired effect.

"Fixing" the problem:

One solution to this problem (aside from not getting cheap, uncertified devices in the first place - but even then, one is never sure what one is really buying!) is to add known-to-be-effective filtering to the mains leads.

At about the time my friend brought these lamps to me, I noticed that the Electronic Goldmine had, on sale, some small, board-mount mains filters, so I suggested that he buy at least two for each of his three lights (for a total of six) - so he bought 10 of them.  These particular devices were attractive because they were relatively inexpensive, potted (helpful, because this will be mounted outdoors where moisture ingress could be a problem) and small enough to fit in the limited-space enclosure in the back of the floodlight.  Being that the lamps were only "50 watt", the 1.6 amp rating of these filters would be more than adequate.

Figure 6:
Another view of added filtering and their integration into the enclosure.
The Shaffner filters were mounted "dead bug" (leads up) and held in place
using both the ground wires and silicone (RTV) sealing compound.  The
lug at the lower-right was added to help make sure that this plate was
electrically bonded to the main body of the LED floodlight.
Click on the image for a larger version.
As can be seen in Figure 1 and Figure 6, two of these filters were installed "back to back" in the back of the lamp housing, using direct-soldered connections between the ground terminals of the filters and the metal plate itself with short pieces of heavy (8 AWG) copper wire to keep the impedance of these leads as low as possible:  Even a few inches/centimeters extra was found to significantly reduce the efficacy of these filters at VHF and higher frequencies.

You may notice something else about the layout:  The wires going in and out of the LED driver are bundled together with plastic wire ties and routed to the "far" side of the power supply, as distant from the mains filters and wires as possible - this to minimize the amount of RF energy that might be coupled from these "noisy" wires into the power cord - something that would surely "un-do" some of our hard-won efforts in minimize the amount of conducted RF noise.

The result:

The results of this effort can be seen in Figure 7, below:
Figure 7:
"Before" and "After" traces over the 0-10 MHz range.  The cyan trance is with the LED unit powered down, the yellow trance is without filtering and the magenta trace is including filtering.  Note the lower resolution bandwidth (91kHz) as compared to the other figures which will tend to reduce the apparent level of broadband noise from LED driver and accentuate those of "coherent" signals such as broadcast stations.
The strong signals at about 1.0-1.4 MHz are due to ingress of local AM broadcast stations into the lashed-up test figure, the level exceeding that of the leakage through the filter.
Click on the image for a larger version.
In Figure 7, above, we can see multiple traces - with the explanation below:
  • The Cyan (blue-ish) trace is our baseline measurement with the LED driver module powered down.  The signals below about 1.5 MHz are ingress from strong, nearby AM broadcast stations, some of which are nearly as strong as the noise at specific frequencies.
  • The Yellow trace is with no filtering of the LED driver module, showing the relative energy from the LED driver module over the 0-10 MHz range.
  • The Magenta (purple-ish) trace is with the LED driver module powered up with the added filtering.
"Could you have just snapped ferrites on the power cable?"

In reading this article, one might wonder if we could have solved the problem simply by putting snap-on ferrites on the power cord.

I doubt it.

Snap-on ferrite devices are very good about reducing the amount of RF conducted on wire, but with the extreme nature of the interference of these devices, it would never have been enough at HF.  The reason for this is that in order to adequately quash the QRM to the "point of undetectability" it would take at least several k-ohms of impedance on the power cable to solve the problem.
While it is possible that one can do this, it would take several large-ish cores (probably mix 31) with a dozen or more turns on each just to add that much reactance - but that material and winding topology would only work to the high end of the HF spectrum, so you'd need another core or two with windings on different materials - say 43 and 61 mix.

To make matters worse, you'd have to keep these chokes well-separated physically or else RF energy would be conducted around them - or even radiate directly from this rather large structure:  You certainly wouldn't have been able to easily fit it in the back side of the lamp's enclosure.

Self-contained filter modules like the ones used are specifically designed to quash RF over a very wide frequency range:  Not only are bifilar inductors used, but capacitors are also used to force the interfering energy to common mode so that the inductors can best do their job, plus there are other capacitors that do an excellent job of shunting RF to the case to "completely" contain that energy.

In other words:  In such an extreme case, you'd be far better off using an L/C filter like that depicted in Figure 5 without even bothering with ferrite chokes.
Interpreting these results we can see that over much of this range that the filtering reduced the amount of conducted noise to just above that of the cyan line, knocking the noise down by roughly 20dB over the range.  These filters start to lose their effectiveness below 1 MHz which is why, at very low frequencies (below 500 kHz) one starts to see more conducted energy - but these frequencies don't radiate very well, anyway so they are of generally less concern in most amateur stations.

When this plot was taken, the circuit depicted in Figure 2 was very close to the filter networks and it was believed that some energy was directly coupling into it from the LED driver module.   After the lamp was assembled (the cover put on and the power cord fitted) another test was done and no difference at all could be seen in the "on" and "off" traces - except at frequencies below about 1.5 MHz:  I somehow managed to omit capturing this trace.

Did it help?

Yes!

My friend reinstalled these lights and was happy to report that upon listening on various HF bands from 160 through 10 meters, he was unable to detect when the lights were on or off, indicating that the modification was successful.  It is possible that within a few feet/meters of these lights that some low-level direct radiation of noise could have occurred on VHF/UHF frequencies, but this energy was demonstrably not being conducted via the power cord, and emissions would not likely be detectable more than a few feet/meters away, anyway.

Would just a single  filter have done the job?

Probably - but since the lights were a bit of a pain to take down and put up again it was decided to use two of these filters just to avoid the possible hassle of having to take them down (and apart) again if just one filter hadn't been enough!

* * * * * * * * * * *

Links to other articles about power supply noise reduction found at ka7oei.blogspot.com:


This page stolen from ka7oei.blogspot.com

[End]

Thursday, February 14, 2019

A 2 meter and 222 MHz low-pass filter for the SocoTran ST-7900D

In an earlier post I described a "hilariously bad" radio - the Socotran ST-7900D (a.k.a. the QYT "KT-7900D").  This radio, right out of the box, could not legally be used by U.S. amateurs on three of its four "bands".


One of these bands - that which covered 350-390 MHz - was understandably off-limits as there is no U.S. amateur band in this frequency range but the other two, the 2 Meter and the 1-1/4 meter (a.k.a. 222 MHz band), also covered by this radio, had poorly-filtered harmonic content:  It was even possible to key up a fairly-distant UHF repeater when one transmitted on a 2 meter frequency at precisely one-third of its input frequency!

The article noted that as it was shipped, the only band that might be legally used was the 70cm band as the strongest harmonics of the other bands weren't properly suppressed - not at all, actually...  It was observed that this radio seemed to have a single low-pass filter in its transmit path that was designed to start cutting off energy in the 550-575 MHz range - but this sort of filter would have no effect at all on the 2nd and 3rd harmonics on 2 meters and the 2nd harmonic on 222 MHz - which was the problem.

Besides just being cheap, one reason why someone might have been attracted to this radio is its ability to operate in the 222 MHz band - and paying $75 or so for a  25 watt radio that could only do 222 MHz might be a reasonable thing to do - so what about making some sort of low-pass filter that would kill two birds with one stone:  A single filter that would allow legal operation on both 2 meters and 222 MHz without having to switch filters?

Designing the filter:

What I needed was a filter that would pass the 222-225 MHz band with little attenuation, but still knock out the 2 meter band's 2nd harmonics in the 288-296 MHz range.  This sort of filter would permit operation on both the 2 meter and 222 MHz band without needing to switch or change anything - but if would, of course, preclude operation on 70cm unless it were removed.

Curious to see if this could be done I fired up the Elsie program, a software tool that is free for "student", non-commercial use (aren't we all students in this world?).  Designing a filter that would both adequately attenuate 2 meter's 2nd harmonics and pass 222-225 MHz would require at least a slight amount of complexity, so I went to work.

Knowing that a simple Butterworth or Chebychev filter would never meet the need for "sharpness", I immediately picked a Cauer (a.k.a. "Elliptical") low-pass filter design and plugged in the numbers, coming up with this:

Figure 1:
 Low-pass filter, inductor-input topology shown.  This "same" filter could have been constructed using capacitors on the input/output, but this version uses fewer capacitors and more inductors - which are both extremely cheap to make and are very easily adjusted - unlike fixed capacitors.
Click on the image for a larger version.
When I plotted the predicted response of this filter, Elsie showed me this:
Figure 2:
The predicted attenuation of the filter.  Part of the design goal was to place the 2 meters' second harmonics in the first "notch" in the filter.  While only 40dB was theoretically needed, a filter with 50dB attenuation was implemented knowing full-well that the real-world implementation of the filter may not do quite as well.
Click on the image for a larger version.

While I needed "only" 40dB to make this radio "clean enough" it is often the case that real-world filters aren't quite as good as their simulated counterparts, so I inputted 50dB into the program as the minimum attenuation.  If you look closely, you'll see that at the top of the flat part - just before it "rolls off" - the attenuation at 232 MHz, comfortably above the 222 MHz band, is just under 1dB while there is a deep "notch" at around 290 MHz - which is right where the 2nd harmonics of the 2 meter band will lie.  If this filter was, in fact, "build-able", it would neatly solve the problem of the harmonics from the 2 meter and 222 MHz bands.

When it came to specific filter types I had two choices for the "same" filter:  A capacitor-input low-pass filter and an inductor-input low-pass filter.  Both are theoretically equal in performance, but because the capacitor input version had 7 capacitors and the inductor input version had just 3 capacitors, I chose the latter as seen in Figure 1:  Inductors - which are just a few turns of wire - cost practically nothing to make and are easily adjusted!

Being familiar with VHF/UHF construction techniques I knew, when I saw the inductor values, that they would be very small, but easy to make.  For example, when 20 AWG wire is wound on a 3/16" (4.76mm) diameter drill bit with very short leads, you can expect to start with something along the lines of:
  • 20-30nH:  2 turns
  • 30-40nH:  3 turns
  • 40-50nH:  4 turns
The precise value would then be obtained by squeezing/stretching the turns - or, possibly cutting a fraction of a turn off as necessary.  If you have ever looked at some commercially-made VHF/UHF gear you might have noticed that some of the coils look as though they were smashed or stretched, but this is a time-honored way of making fine adjustments to these circuits after assembly.

If one is constructing this using only small, surface-mount components the self inductance and stray capacitance of these tiny components on a well-designed board can almost be ignored at these frequencies - but I was going to use plain, old through-hole leaded disk ceramic capacitors, which would require a bit more consideration.

A good example of this is the first series-resonant section of the above filter - in the section marked "531.581M".  As you can guess, this is a series-tuned circuit that must be resonated at around 532 MHz using components of the approximate values shown.  Practically speaking, in this application one can "fudge" a bit on the values, so rather than trying to find a precision capacitor of about 17.5pF, I simply pulled a 18pF unit out of my capacitor bin with the idea that I would select the inductance to make it resonate somewhere in the area of 532 MHz.

But, there's a twist:  Noticing that resonating inductance is ideally 5.1nH, one may realize that even a rather short length of wire has a similar amount of inductance - and that is exactly what was done:   The capacitor's own lead - about 4 millimeters of it - plus the series inductance of the capacitor itself was enough to create a resonant circuit at the desired frequency.

What it takes to build this filter:

As you may have gathered, it is simply not possible to build this filter without some sort of test equipment at hand - and I used a spectrum analyzer with a tracking generator as I was building it.  In short, here's what I had to do:
  • Fuss with the series L/C circuits to get the stated series resonant frequencies as indicated by deep notches on the sweep.
  • Stretch/compress/adjust the other inductors as necessary to minimize the loss below the cut-off frequency
  • Repeat the above two steps until it makes no difference - usually taking about a half-dozen iterations.
During construction I didn't bother breaking out any capacitance or inductance measuring gear - but very small inductors (those lower than a few hundred nanoHenries) can be very difficult to measure, anyway.  Using only "known" values of capacitance, by adjusting the inductors in the manner mentioned above, I have found via experience that such filters often "take care of themselves" when one takes a bit of care during assembly and adjustment - particularly when setting the resonant frequencies of the "notch" elements.

Amazingly, the filter went together without too much trouble with the test equipment indicating less than 1dB of insertion loss at either 2 meters or 222 MHz.  The hastily-kludged prototype looks like this:
Figure 3:
Constructed prototype.  This was constructed on a scrap piece of copper-clad PC board material using small PC board islands for some component support.  This version was built for testing the concept:  A "real" implementation of this filter would be crammed into a small metal box with the input/output inductors and ground plane soldered directly to the in/out RF connectors.
A circuit board could be designed, but to be effective it would need to be built on (at least) a double-sided board with a large-as-possible ground plane on the top connected to the bottom plane using lots of vias.
Click on the image for a larger version.



Figure 3 shows the prototype, constructed on a small piece of copper-clad circuit board material.  The input/output connections were made via some N connectors that were pre-attached to UT-141 rigid PTFE coaxial cable, being were used because they were on-hand.  Because we would need to handle "only" 25 watts, 100 volt NP0/C0G disk ceramic capacitors are more than adequate.

As can be seen in Figure 3 the junctions where the series L/C portions are attached are held off the ground plane with small pieces of circuit board (the capacitive effects of these are negligible at these frequencies) while the attaching hardline's center conductors supported the in/out inductors.  Also apparent is what looks like haphazard stretching/compressing of the various inductors to achieve the resonant frequencies for the three elements - which I marked on the board.

Once I connected it to a transmitter I did a bit of final tweaking, "adjusting" the series coils for minimum loss (as indicated on an RF power meter) on both 2 meters and 222 MHz but leaving the "notch" adjustments alone:  Only slight adjustments were needed.

Can I make such a filter?

Yes, you can - if you are familiar with VHF/UHF circuit techniques and have access to a spectrum analyzer with a tracking generator or some sort of equivalent.

If you don't have access to this sort of gear - and you don't know anyone else who does - then it is (unfortunately) not possible to properly "tweak" this filter for both harmonic attenuation and also to make its insertion loss and added VSWR low enough to both allow transmit power to pass through it without damaging the radio.

(And no, I won't build one for you...  Remember:  It's a $75 radio!)

Does it work?

Amazingly enough, it works pretty much as predicted!

After final tweaking the measured insertion loss was under half a dB:  With 25 watts in, around 20 watts exited the filter on both 2 meters and 222 MHz - hardly enough loss to worry about on receive or transmit.  After about a minute of solid key-down at 25 watts input the hottest of the filter's components were barely warm - lower than body temperature in a "not hot/not cold" room.

The real test was to put the filter inline and check it again on the spectrum analyzer - and the plots below show the results for 2 meters:

Figure 4:
The harmonics on 2 meters, through the filter.  The analyzer has been adjusted to read actual power, so the 2 meter fundamental is at about +43dBm.  The second marker (#2) shows the location and amplitude of where the 2nd harmonic would be - and this trace shows that it is at least 79dB down well within the FCC part 97 rules and  probably "cleaner" than your average "good" radio!
Click on the image for a larger version.

And here is the result from the 222 MHz band:


Figure 5:
The operation of the radio on the 222 MHz band.  The "2" marker shows the second harmonic - and other spurious signals may be seen at a similar level on the plot.  Like the plot in Figure 4, this is scaled to show the actual transmitter power (+43dBm) and thus the harmonics and spurious signals are around 80dB below the carrier - well within FCC part 97 rules!
Click on the image for a larger version.

As can be seen, the harmonics and other spurious signals are all but undetectable!

"Sweeping" the filter:

Curious as to how the actual attenuation curve of the filter looks?  Figure 6, below, shows its response over the frequency range of 100 through 400 MHz.

Figure 6:
A "sweep" of the prototype filter from 100 through 400 MHz.  On this plot marker #1 has been configured so that the difference in amplitude being measured and this indicates that the depth of attenuation is a bit over 53dB - but the settings of the analyzer used to make this plot likely reduce the apparent depth.  Outside that null the depth of attenuation is at least 40dB - more than enough to suppress the harmonics to meet FCC part 97 regulations.  If I'd taken a bit more care in building the filter (e.g. more thoughtful layout, some shielding between sections) more attenuation might have been obtained - but as it was, it worked better than was necessary.  Because of the configuration of the test jig, the absolute level of the passband portion of the response is arbitrary.
Click on the image for a larger version.

As can be seen, the "depth" of the low-pass filter is at least 40dB, but where the first "null" is located (which happens to be around the frequencies of 2 meter 2nd harmonics) the depth is much greater.

As expected, the simulated filter's ">=50dB" attenuation above the designed cut-off frequency wasn't quite met over its intended range (likely due to the physical layout of the filter - not to mention the difference between simulated and real-world components) but it is more than capable of rendering this radio "legal" when it is operating on the 2 meter and 222 MHz bands.

Using the filter:

Some time in the near future it is likely that this page will show a version of this filter that is built into a small box with UHF connectors which will allow the radio to be used legally on 2 meters and 222 MHz by U.S. amateurs - but having this filter inline precludes its use on 70cm:  To do that, the filter would have to be manually removed.

If that is the case, one would consider this to be a "2 band" radio - and for around $75, it would to OK - aside from the possible tendency for its receiver to overload from nearby signals.

What about automatically switching the filter?

In theory, it should be possible to build into the filter a "bypass" circuit using some UHF-rated relays.

In poking about inside the radio I quickly found a circuit that was powered on only when the UHF (400 MHz) band was selected - and this could be used to "key" a relay to bypass such a filter.  In reality, one would want to design such switching so that when the relay was un-powered, the filter would be bypassed, but when the radio was powered up and not on UHF, use the absence of the aformentioned signal to pull in the relays in insert the filtering.

If we decide to do this, I'll post it here - but at some point, trying to make this radio do what it should have been capable of doing by design becomes an exercise of "turd polishing" when the time and money spent exceeds the gain.

Then again, the effort is sometimes worth the journey if the goal is to build and learn something!

(No, this filter won't help with the problem of this receiver being easily-overloaded by other signals in the same "band".)

* * * * * * * * * * * *

This page stolen from ka7oei.blogspot.com

[End]

Friday, February 1, 2019

A hiliariously bad multi-band radio: The SocoTran ST-7900D

Spoiler:  DO NOT get one of these radios.
 
and if you have one, don't use it!

(If you are of the "tl;dr" type, scroll down to the section titled "The Real Problem with this radio") 


A couple of days ago an "interesting" mobile transceiver crossed my path - the SocoTran ST-7900D.   (This radio is also sold under different brands and names, including the "QYT KT-7900D".)

I say "interesting" - but what I really mean is "scary" - for anyone who ends up using this radio unawares!

Note:  There is a follow-up to this article describing a 2 meter/222 MHz low-pass filter linked here.

Figure 1:
Tiny "quad band" radio - but not really a quad band radio as only three
of the ranges include valid amateur bands!
Can you spot which one of the frequencies shown on the display
is not in a U.S. amateur band?
(Answer at the bottom of the page.)
Click on the image for a larger version.
This radio is diminutive - a little tiny thing that, when you see the "<=25 watt" power rating, makes you wonder how much transmitting it would take to overheat it.  To be sure, it does have a cooling fan, but it is (literally) only slightly bigger than a postage stamp and is of dubious efficacy - but more on that later.  Also a bit alarming is that just sitting there, receiving, the radio gets quite warm - probably about 98 degrees F (37C) in a 70 F (21C) room.

This radio is billed as a "quad band" radio with its frequency coverage being listed as follows:
  • 136-174 MHz:  This includes 2 meters, plus lots of other things.
  • 220-270 MHz:  This includes the 1-1/4 meter band (a.k.a. the "222 MHz" band).
  • 350-390 MHz:  Used for military comms. - There are no U.S. Amateur bands in this frequency range.
  • 400-480 MHz:  This includes the 70cm amateur band.
 In reality, only three of its four "bands" are available to a law-abiding U.S. citizen... sort of!

Using the radio:

As is typical for inexpensive Chinese radios, the manual isn't very good - but it's "less bad" than many I've seen, but this isn't much help against the radio's shortcomings.

Problems with the menu system:

The menu system does not appear to be well thought-out.  Here are a few examples:
  • Similar items are not necessarily grouped together.  If you want to set transmit offset, subaudible tone, offset direction, power, etc. you must awkwardly jump around between 10s of menu items to do this.  On the test radio, the front-panel knob (the one on the right) didn't seem to reliably change the menu item number up/down so I had to use the up-down button on the microphone or look up the menu item in the manual and enter its number on the microphone.
  • The menu selection may not start at the current setting.  If you were to set the subaudible tone to 100.0 Hz and then later change it to, say, 123.0 Hz, you would go into the menu and see it at 100.0 Hz.  However, when you pressed the menu button again to allow the parameter to be changed it will start at 77.0 Hz - the "first" tone in the list, rather than where it had previously been set, requiring you to go through the list again.  For menu items with only a few selections this isn't too bad, but for something like the subaudible tone that has dozens of options this can be a pain!
  • Menu settings to not take effect until you enter them.  If you go to the squelch setting in the menu, you hit "menu" again and can change the setting - but it doesn't actually take effect until you press "menu" again to save it.  In other words, to try several squelch settings you have to go back-and-forth several times.
    Figure 2:
    The top side of the board.
    The brass cover hides a large, surface-mount transistor
    that is the power amplifier.  The filtering may be
    seen in the lower-right corner of the board.
    Absent seem to be individual low-pass filter sections for
    2 meters and the 222 MHz bands - or any
    means of switching these filters in/out.
    The cover plate for this radio is appears to be
    genuine unreinforced ABS plastic:  No annoying metal
    RF shielding here!  The potentiometer in the lower-left
    corner of the picture sets the radio's reference frequency.
    Click on the image for a larger version.
  • By strictly following the manual's instructions it does not seem possible to save a current frequency and its settings (tone, offset, etc.) into a memory.  Perhaps there is some permutation of buttons that allows this, but the manual is not helpful on this point.
In short:  If you insist on using this radio (if you read on, you'll see why you probably won't want to!) you are best-off using a program like Chirp to set it and its memories up.

Receive sensitivity and "desense":

Two radios were tested - we'll call them #188 and #198 - and the results were very consistent.  The sensitivity of this radio on the amateur bands was very good (probably "too good"):  At under 0.15 microvolts the received signal was at least 12dB SINAD - but this comes at a cost:  The receiver is easily overloaded by strong signals on the same "band".  Badly, as it so-happens.

This radio was put on the test bench and it was given the "two tone" test in which a signal, modulated with a 1 kHz tone with +/-3 kHz deviation, was fed from a signal generator, through a hybrid combiner and into the receiver at approximately 0.5 microvolts ("almost" full-quieting - approximately 20dB SINAD) and another signal, unmodulated (into the other port of the combiner) was made variable.  In this test the "other" (unmodulated) signal was increased until the SINAD of the desired signal dropped below 12dB SINAD - a very obvious degradation.  Before we started this test, the "other" signal was checked with a spectrum analyzer to make sure that it was the signal itself and not its noise floor that caused the degradation.

This testing was done with the "other" signal separated from the desired one by 40 kHz (approximately 2 "channels" away), 100 kHz, and 1 MHz - and checked again at 10 MHz.  In all cases it was observed that the 1 MHz and 10 MHz "desense" values were pretty much the same, likely indicative of the inherent dynamic range of the signal path.

The results of this testing are as follows:

2 meters, test signal at 146.5 MHz:
  • @40kHz separation:  >= -60dBm caused noticeable degradation
  • @100kHz separation:  >= -60dBm caused noticeable degradation
  • >=1 MHz separation:  >= -44dBm caused noticeable degradation
222 MHz, test signal at 223.9 MHz:
  • @40kHz separation:  >= -65dBm caused noticeable degradation
  • @100kHz separation:  >= -60dBm caused noticeable degradation 
  • >=1 MHz separation:  >= -40dBm caused noticeable degradation 
70cm, test signal at 445.5 MHz:
  • @40kHz separation:  >= -70dBm caused noticeable degradation
  • @100kHz separation:  >= -65dBm caused noticeable degradation
  • >=1 MHz separation:  >= -40dB caused noticeable degradation
Note:  The above values will likely vary +/- several dB from unit-to-unit.

Interpretations:

In this area, there are quite a few mountaintop repeaters and if such a hypothetical 2-meter repeater were to have an EIRP of 100 watts, it would yield a signal greater than -60dBm within a distance of approximately 20 miles line-of-sight when a receiver was connected to a unity-gain antenna.  At 222 MHz and 70cm, the signal levels are similar, the typical repeater antenna's gain compensating for frequency effects.  What this means is that if you are listening on a frequency to a weak signal and a repeater a couple of "channels" away were to key up, it is possible that the signal to which you were listening would "disappear" due to receiver desense.
Figure 3:
Another view inside the radio.  Note the blockage of
the cooling fan - and the lack of something else...
The small potentiometer above and to the right of the large
chip (near the center of the image) sets the "Low"
transmit power.
Click on the image for a larger version.

In the case of the ">=1 MHz separation" case, these radios have a very broad receive input filter for each "band" meaning that a 2 meter signal won't particularly bother a 222 MHz or 70cm signal (unless it is very strong) - but any signal in that receiver's "band" coverage can cause issues.  For example, if you are listening to a weak-ish signal on 2 meters and a nearby transmitter on 159 MHz were to key up with a strong signal (stronger than -44dBm or so) it would likely cause degradation.

What's worse, there may be several such signals within the radio's currently-selected "band" that could combine their energy.  In other words, several such signals anywhere in the 137-174 MHz range would add cumulatively for a total power that could be significantly higher than any single signal.

To be sure, many radios made by the "Big Three" overload easily, but this radio is particularly prone to doing so in an "RF busy" environment where there may be other transmitters within a few 10s of MHz - such as a parade or other public service event.

Finally, one will notice that the "@40kHz" specs degrade with frequency.  The reason for this is unclear, but it is suspected that this may be due to limitations in the "all in one" receiver chip related to local oscillator phase noise and/or differences in the dynamic signal handling of this chip's on-board circuitry with respect to frequency.

Remember that the entire receiver ("IF" filtering, amplification, limiting, demodulation) is all done in the digital domain, on the chip with the received signal being digitized at some point:  It is likely that signals in close proximity with each other are being handled by different hardware filter types on the chip than widely-spaced signals.
Figure 4:
Almost the smallest fan that I've ever seen - but
does it do any good?
Click on the image for a larger version.

So, how good is this receiver overall?  In terms of absolute sensitivity it is fine, but in terms of handling "other" signals it is rather poor.  It is likely that this receiver would actually perform better in the real world if it were NOT quite as sensitive.  In other words, there is too much gain in front of the receiver section causing even moderately-weak signals to be strong enough to degrade performance:  Losing 5-10dB of gain in the signal path (after its RF preamplifier) would likely improve receiver performance in congested areas.

Interestingly, rather than seeming to generate "intermod" with strong signals within the radio's RF passband where a "new" signal is created out of the combination of several, when overloaded this type of receiver (an all-in-one chip using DSP techniques) seems to just go deaf, so the casual user may not be aware that there is a problem at first.

Output power:

The power output was also pretty close to what it should be.  The specifications oddly states "<=25 watts" - and this seems to be true:  At 15 volts, the output power was, in fact, a bit over 25 watts, dropping to 10-15 watts at 10 volts, depending on frequency.  Aside from the obvious problem with harmonics (mentioned below) that makes the legal use of this radio rather dubious, this wide voltage range (possibly) makes it a useful candidate for battery-powered portable operation - again, if it were actually legal to use on most of its "bands".

The "cooling fan":

Mentioned several times now is the "cooling fan" - but it may not do much good.  Not only is this fan very tiny and incapable of moving much air (and amazingly loud for its size) - but there are some other problems:
Figure 5:
The tiny little fan is mostly blocked by the
aluminum casting and parts of the power amplifier that
are in the way.  With the fan's blades mere millimeters
away from solid objects, it gets amazingly loud for
something so small!
Click on the image for a larger version.
  • The fan sucks - which is to say that it is set up to draw air through the case and exhaust it out the back - if that were possible:  There aren't any vents or holes in the case to allow this.  Even if there were holes, drawing air from inside the radio is not the most efficient way to cool nearby components unless airflow is carefully regulated. 
  • As can be seen in figure 5, most of the hole for the fan is blocked by the aluminum casting and some of the power amplifier components.
In other words, the fan is largely ineffective (except at making lots of noise) and is probably there as much to make the user feel good when their radio gets too hot to touch.  There will be a very slight amount of air movement around the components at the back of the board near the fan opening, but this will more likely be due to blade turbulence than actual fan-induced air flow, something that contributes to the amount of noise that it makes. Clearly, the efficacy of the cooling fan would be better if air flow were directed over the fins of the heat sink rather than into an aluminum wall.
Initially, I thought that the fan was thermostatically controlled, but after testing on the work bench I realized that this may not actually be the case:  I'm thinking that the radio's computer simply winds up and down the fan speed slowly, depending on how long one transmits with it - but whether or not this is true remains to be seen.

Too much microphone gain?

While many inexpensive Chinese radios seem to have low transmit audio, this radio has quite the opposite problem:  Even holding the microphone about 2 feet (50cm) away from one's mouth and talking in a normal speaking voice caused the modulation to smash into the clipper pretty hard in both sample radios we tried.  (Clipping seems to be set to +/-4kHz when in the default FM "wide" mode.)

To be sure, having a bit too much audio is usually better than having too little, but the mic gain is so "hot" that your voice will sound a bit harsh and compressed - and everyone listening to you on the air will not only be able to hear everything that is going on in the room that you are in, but likely the bodily noises of any creature in your house as well.  In any but the quietest vehicle, road noise will be competing strongly with your voice causing challenges with intelligibility.

Unfortunately, there is no menu item to adjust microphone gain, but it should be possible to make a change in the microphone itself to reset the gain to something more sane.

The FM Broadcast receiver:

Like many of these Chinese radios it will also receive FM broadcast stations.  For this radio, connecting it to a typical amateur antenna in an area with fairly strong mountaintop transmitters located 15-20 miles (20-30km) away caused the (separate) FM broadcast receiver chip to be overloaded very badly, making it impossible to hear weaker "local" stations in the resulting muck:  It took about 30dB of RF attenuation to prevent the "FM broadcast" receiver from being clobbered and for the weaker signals to become audible leading us to believe that, like the main communications-band receivers, the designers likely put way too much gain in the front end.

Modes/situations in which this radio may not work:

This radio appears to be based on the same type of  "everything-in-one" chips that the Baofengs are based on - quirks and all.  Unfortunately, the nature of these chips - or at least the way that they are configured by the radio's processor -  preclude their use in a few situations/modes, such as:
  • In areas of very strong adjacent-frequency signals or multiple transmitters - due to easy receiver overload.
  • For packet operation - because of slow transmit/receive turn-around time.
  • For any sort of DF (Direction Finding) system that uses switched antennas - due to the variable audio phase/delay properties of the receiver - a known problem with the "all in one" receiver chips found on many inexpensive Chinese-made radios.
  • Any sort of high-duty cycle operation - due to the tiny heat sink which will get plenty hot, even at "low" power.
A "calibrated" S-Meter?

Interestingly, the "S" meter on the front panel  seems to indicate a 7-bit binary number - possibly from one of the chip's registers - that is proportional to the signal strength, each count being very close to 1dB, making it (potentially) more useful than a typical radios' S-meter.

Unfortunately its range (a bit more than 60dB) may not be entirely usable:  It doesn't start indicating meaningful values until the signal is about full quieting (between 0.5 and 1.0 microvolts) and it "pegs" at signal levels that would be commensurate with a transmitter several blocks away - and its update rate is fairly slow.

In other words, it's not useful for weak signals (you'd have to use your ear and listen for quieting for those) or moderately strong signals (e.g. a nearby transmitter) when it comes to direction-finding with a beam - although the latter could be mitigated with an outboard step attenuator.

(I am surprised that this thing doesn't also have a flashlight!)


* * * * * * * * * * * * * *


The real problem with this radio

Having buried the lead, the real problem with this radio is when you use it on-air:

If you transmit with this radio on 2 meters or 222 MHz, you are breaking the law!

This is (literally!) the worst commercially-made radio I have ever seen in terms of harmonic/spurious output!

With any inexpensive Chinese radio (or any radio, for that matter) my first inclination is to throw it on the workbench and see how it really performs - which includes checking things like its sensitivity, power output, microphone gain, and spectral purity - and it is this latter point that made us catch our breath - this lesson having been learned when very cheap Chinese radios first appeared on the U.S. market about a decade ago.

The real problem was the actual transmitter specifications:  The literature states that spurious and harmonic energy is ">60dB" down - but it is not!

For 70cm, this radio seems to be "Okay" - but for 2 meters the results for this particular radio (let's call it "#198") were terrifying:  The 2nd and 3rd harmonics measured both as being as high as -23dBc - the precise values varying quite a bit with supply voltage.
Figure 6:
What appears to be the main CPU clock crystal:  "If it
doesn't fit, just cram it in there!" - but hey, what do
you expect for around $70?
Click on the image for a larger version.

Putting this into other numbers:  For an output power of 25 watts at 2 meters, this means that the harmonics are approximately 125 milliwatts each - roughly as much power as many handie-talkies produce when set to low power!

As an experiment we did something that we probably should not have done with this radio:  We connected this radio to an antenna that is designed for both 2 meters and 70cm and transmitted.

In this case we transmitted on a 2 meter frequency that was 1/3rd of a local UHF amateur repeater located about 20 miles (30km) away on a mountaintop.  The result was that the 3rd harmonic was full quieting into that repeater!

If one peruses the FCC rules you will spot FCC §97.307(e).  According to that rule, on a 2 meter transmitter of this power class we are allowed no more than 25 microwatts of spurious emission:  This radio exceeds that by a factor of approximately 5000 (about 37dB).

Remember:  This was the 3rd harmonic of 2 meters which, if you are operating within the 2 meter amateur band, will always land somewhere in the 70cm band - but what about the 2nd harmonic - which is just as strong as the 3rd?  This would land somewhere in the 288-296 MHz range which is used for military communications - including aeronautical mobile.  What this means is that it is possible that your 2 meter transmissions made with this radio could be heard from, perhaps up to 100 miles away by an aircraft in line-of-sight.

What about 222 MHz?

The situation there isn't quite as bleak as the second harmonic was between 42 and 50dB down - the precise level varying wildly with power supply voltage.  Fortunately, any harmonic due to operation in the U.S. 222 MHz band (which covers 222-225 MHz) will land in the 70cm band, but its level will also be a bit high:  With 25 watts out on, say, 224.0 MHz the signal at twice this (448.0 MHz) will be around 1.5 milliwatts.

This may not sound like much, but this signal would be easily audible via line-of-sight at a distance of 10-20 miles (15-20km) - and it still can exceed the FCC rules by a factor of 63 (about 18 dB).

* * * * * * * * * * *

"Are they all this way?"

(Updated 4 February, 2019)

Without testing each unit as it comes from the factory this question is impossible to answer, but I was able to obtain another unit (we'll call it "#188") and it was almost as horrifying (e.g. "slightly less terrible") in terms of its spurious output.  Because of minor component variations, one can expect an (essentially) unfiltered RF power amplifier to exhibit different properties in terms of spurious output - and these also vary based on temperature and power supply voltage.

I was able to put this radio on the RF bench, connecting it via a 40dB power attenuator (known to be flat within +/-1dB from <1 MHz to 1 GHz) and record spectrum analyzer plots, shown below with comments.

The spectrum analyzer had been calibrated to take the attenuator into account and in the plots below the power of the signals can be read directly as dBm, with "50dBm" (100 watts) being the top line with 10dB vertical divisions.

Testing on the 2 meter band:

Figure 7:
Radio #188 - which isn't as bad as #198, transmitting at 144.625 MHz, and 289.25 and 433.875 MHz - all with enough RF energy to be heard over line-of-sight distances of 10s of miles!
In this plot, the level indicated in the upper-right corner is that of the 4th harmonic.
Figure 7 shows the output of this sample transmitting at its out-of-the-box default frequency of 144.625 MHz with a transmit power of 25 watts (approximately +44dBm) with markers 2, 3 and 4 on the 2nd, 3rd and 4th harmonics, respectively.  The measured output level of these spurs are:
  • 2nd harmonic @ 289.25 MHz:  +16 dBm (40 milliwatts)  41dB above FCC §97.307(e)
  • 3rd harmonic @ 433.875 MHz:  +11 dBm (13 milliwatts)  36dB above FCC §97.307(e)
  • 4th harmonic @ 578.5 MHz:  -2dBm (0.63 milliwatts)  23dB above FCC §97.307(e) (This frequency falls within off-air TV channel 32)
While these numbers aren't as bad as those of the first radio tested, the levels of the 3rd harmonic are still capable of bringing up a line-of-sight UHF repeater from 10s of miles away!

Not mentioned previously is the 4th harmonic which, in this case, lands in the UHF TV band.  What this means is that transmitting with this radio will likely disrupt nearby off-air viewing of whatever digital TV channel is on that frequency. (Affected off-air TV channel frequencies include channels 31-34 depending on the 2 meter frequency being used.)

How about the top end of the 2 meter band at 148 MHz?

Figure 8:
Radio #188, transmitting at 148.0 MHz as well as 296.0 and 444.0 MHz.
As mentioned previously, a signal of the amplitude shown in the UHF range is more than enough to key up a repeater!
In this plot, the level indicated is that of the 4th harmonic.
Translating the above:
  • 2nd harmonic @ 296.0 MHz:  +16 dBm (40 milliwatts)  41dB above FCC §97.307(e)
  • 3rd harmonic @ 444.0 MHz:  +15 dBm (32 milliwatts)  40dB above FCC §97.307(e)
  • 4th harmonic @ 592.0 MHz:  -5dBm (0.32 milliwatts)  20dB above FCC §97.307(e)  (This frequency falls within off-air channel 34.)
In this case the 3rd harmonic is actually worse than at 144.825 MHz while the 4th harmonic is 3dB weaker - but these differences are insubstantial in terms of legality.  It's worth noting that the 4th harmonic is at a frequency where the low-pass filter is just starting to have its effect - which is why the higher-order harmonics are not really visible.

Again, we have significant energy in the UHF TV spectrum.

Testing on the 222 MHz band:

Figure 9:
Radio #188 being tested at 224.0 MHz.  The second harmonic is quite high, but at least it lands in an amateur band!  The 3rd harmonic - which lands in the UHF TV band - is probably strong enough to "blank out" reception on that channel in the immediate vicinity.  Even though the marker says "450 MHz", it is reading the power of the 2nd harmonic at 448:  The 3 MHz RBW and granularity of the wide sweep account for the offset.
Translating the above:
  • 2nd harmonic @ 448.0 MHz:  -2 dBm (32 milliwatts)  23dB above FCC §97.307(e)
  • 3rd harmonic @ 672.0 MHz:  -20 dBm (0.01 milliwatts)  5dB above FCC §97.307(e)
As with the other radio, the harmonics are lower than they were on 2 meters with the low-pass filter having a significant effect at the 3rd harmonic - but we can see that it is still 5dB above where it should (legally) be.  In this case the 3rd harmonic lands in the middle of the public safety band - but its "not terribly far from being legal" level is not likely to cause much of a problem.

On 70cm:

Here we have 430 MHz:

Figure 10:
Radio #188 again:  As you might expect, the harmonics from 70cm are farther down - but still "there".



Translating the above:
  • 2nd harmonic @ 860.0 MHz:  -16 dBm (25 microwatts)
Oddly,  FCC §97.307(e) doesn't list spurious/harmonic requirements for transmitters operating above 225 MHz so this is technically not illegal, but it's worth noticing that this power level is about 9dB above where it would be were the rules for the other bands to apply - and it also lands in the "800 MHz" cell/mobile band.

Going to the top of the 70cm band we see this:

Figure 11:
Radio #188 operating at 450 MHz.  Interestingly enough, the 2nd harmonic is worse here than at 430 MHz.
Translating the above:
  • 2nd harmonic @ 900.0 MHz:  -13 dBm (50 microwatts)
It's interesting that the 2nd harmonic is twice as strong on this frequency.

If we were to presume that the power amplifier's "natural" 2nd harmonic energy is -30dBc (and that's being generous!) this tells us that the radio's low-pass filter is attenuating this harmonic by roughly 30dB - not really a very good filter.

But wait - there's more!

While testing the radio at 70cm, I noticed something else:  When the radio was keyed up, it would briefly output a wide spectrum of spurious signals all over the place.  This lasted, perhaps, 50 milliseconds - but it was definitely observable, as this "max hold" plot shows:


Figure 12:
Radio #188 transmitting at 450 MHz, this "flash" of spurious signals was briefly output at key-up by the ST-7900D.
This plot was captured using the "max hold" feature of the analyzer with several, repeated "key-ups".  This "feature" did not seem to be present on the 2 meter or 222 MHz bands.
The spectrum plot in Figure 12 looks frightening - particularly the brief "spur" at marker #2 which landed in the middle of the UHF TV spectrum (or in the public safety band in some parts of the U.S.) with a power level of nearly 100 milliwatts!  Also visible is a sprinkling of other signals - including a rather strong-ish signal in the 360 MHz area that has a power output of roughly +8dBm (approximately 6 milliwatts) - in the middle of the military comms band.

Practically speaking, such a brief "burst" isn't likely to cause much of a problem and quite a few older VHF/UHF transceivers made by "reputable" companies did this - but it is interesting nonetheless.

Comment:  No transmit testing was done in the "300 MHz" range as we have no intention of using it there.

* * * * * * * * * * *

"But there's an FCC logo on the radio!"

If you look at the radio and its packaging, you will find an FCC logo:  If you think that this automatically means that the radio is "OK to use", you would be wrong.

No matter what the radio's specs say, what the reviews say, or what others say, if you are using a radio that, for some reason, does not meet the legal requirements - YOU are responsible, even if you didn't know that it doesn't pass muster!

Why is this?  Because you agreed to this when you got your license.

In other words, the onus is ultimately on you to make sure your gear is working properly - not the manufacturer - and if you happen to buy something that doesn't meet specs and get into trouble, it's ultimately your fault.  Now that you have read this, if you use one of these radios on 2 meters or 222 MHz, you have no excuse at all.

Practically speaking, the FCC certification does not mean that amateur gear is actually checked to see if its transmitter has spurious outputs or not:  If a piece of gear is checked at all it's usually just to see if it meets FCC Part 15 rules which typically cover spurious radiation caused by the receiver, its computer, or other circuitry - but not the transmitter, which is covered by Part 97, and being that amateurs are licensed under part 97, you are ultimately responsible for making sure that the gear that you are using is in compliance.

Having said that, anyone could make something and simply slap an FCC logo on it!

After pointing out the terrible harmonics produced by this radio someone commented to me: "Wow!  It's a tri-bander any time you key up on 2 meters!"


Why did they do this?

It's cheaper, of course!

In "older" radios it was common to have a separate power amplifier for each band - each with its own filter - but with today's inexpensive power RF MOSFETs a single amplifier like the one in this radio can work over a very wide range of frequencies - but this means that you must switch the appropriate filter inline for the band being used.

This switching is typically done with RF PIN diodes and/or relays - but either one of these options (particularly PIN diodes) gets to be pretty expensive (adding a couple of dollars to the bill of material) when you get into the 10s of watts at UHF frequencies.  Because this radio was "built to a price" it is almost inevitable that something was left out - and among those things that was omitted was proper low-pass filtering of the transmitter!



* * * * * * * * *

"I got one of these radios - can I modify it to make it legal"

The quick answer is NO, not if you use it anywhere other than the 70cm band.

The problem with this radio is that it seems to have only one low-pass filter after its (single) power amplifier.  On other radios (e.g. Yaesu, Kenwood, Icom) there would be a separate filter for each amateur band after the power amplifier to remove the harmonics for that band - but this radio seems to have just one - and it doesn't seem to have too much of an effect below roughly 550 MHz.

What this means is that this low-pass filter does absolutely nothing for any harmonics or spurious signals below roughly 500 MHz - and this is why the 2nd and 3rd harmonics of the 2 meter band and the 2nd harmonic of the 222 MHz band is way out of compliance!

What if you continue to use this radio, anyway?  At least on 2 meters, the 2nd and 3rd harmonic signals are quite potent and may be heard from a great distance line-of-sight.  There is good news:  Because this is an FM radio, when someone using this radio IDs, their callsign will be clearly heard on these same spurious signals, so they should be easy to identify.


Work-arounds:

If you have one of these radios and wish to operate it legally on 2 meters or 222 MHz, you would need to do the following:
  • For 2 meters, you use an outboard low-pass filter that will attenuate the 2 meter 2nd and 3rd harmonics by at least 40dB.
  • For 222 MHz, you use an outboard low-pass filter that will attenuate the 222 MHz 2nd harmonic by least 30dB.
What this means is that you would not be able to use this radio for transmitting on more than one band without having to swap out low-pass filters.

Note:  There is a follow-up to this article describing a 2 meter/222 MHz low-pass filter linked here.

In short:

You cannot legally transmit with this radio "as is" on
the 2 meter or 222 MHz bands.

* * * * * * * * *

"I got one of these radios - what should I do?"

I would suggest that you not use it on other than 70cm without the use of an outboard low-pass filter.

If this isn't what you had in mind when you got the radio I suggest that you consider getting a refund from the seller as it is "not suitable for its intended use."

* * * * * * * * *

Answer to the question in Figure 1:  Actually, two of the frequencies shown - 245.625 and 350.025 MHz are not amateur frequencies!

 * * * * * * * * *


This page stolen from ka7oei.blogspot.com


[End]