This is only a preview of the January 2024 issue of Practical Electronics. You can view 0 of the 72 pages in the full issue. Articles in this series:
Items relevant to "Active Mains Soft Starter":
Items relevant to "ADVANCED SMD TEST TWEEZERS":
Items relevant to "Active Subwoofer For Hi-Fi at Home":
Articles in this series:
|
Create Fantastic Electronic systems
using
VERSION 10
10% off your first Flowcode purchase using code: EPE20
Use code at checkout: flowcode.co.uk/buy
• NOW FREE FOR HOBBYISTS •
The Fox Report
Barry Fox’s technology column
Project challenges for inventive PE readers
T
his month, I humbly offer creative readers
two practical test problems which are crying out
for DIY project solutions.
The suggestions flow from my recent experience of
rebuilding a home AV system, by replacing the main
amplifier. This involved ripping out and re-connecting a
jungle of wires, while simplifying the set-up by removing
redundant components.
Check cables
Flat digital HDMI and Ethernet cables are now available. They hide neatly under rugs, but they love to twist
themselves and treading on the twist can cause faults. A
£10/20 battery-powered two-part continuity tester is an
essential tool for checking if a digital cable has gone bad.
Avoid the ‘touch’ test
Rebuilding any AV system is a lot easier if you follow a
few simple practical guidelines, not all of which will be
as egg-suckingly obvious to others as they are to some.
Some of these guidelines date back to invaluable tech
training I received in the RAF.
Optical SP/DIFs can be identified by looking for the telltale red laser light. Checking and identifying low-voltage
audio cables can of course be done by touching to induce
mains hum. But if the amplifier volume is up, there’s a
risk of blowing speaker cones. Touching wires is always
best avoided. You never know when a dangerous voltage
may have crept through.
Take your time – one labelled wire at a time
Build a cable tester
Wherever possible, disconnect only one wire or pair of
wires at a time. Identically label each end of each wire.
There are not enough colours in the rainbow to colour
code every connection path. I use a Dymo label computer
printer with Dymo software (but cheaper compatible
label cartridges bought on line) to print simple stick-on
labels for each end of each cable run.
Connecting a meter to small phono and coax plugs is
tricky and for years I have been happily using an analogue
cable test kit from Vision Products of Northampton. This
uses a low-voltage transmitter and receiver that plug into
cable ends to show a red LED for short circuits and beep
for successful connection. These handy testers came with
an assorted collection of plugs and sockets that connect
to almost every imaginable analogue cable.
That’s the good news – the bad news it that Vision
Products informed me that unfortunately these kits are
no longer available, and I can’t find any other source.
Perhaps someone would like to make this a construction
project? It shouldn’t too difficult.
A few simple rules...
Use cable ties – gently
Modern ‘handcuff’ cable ties are great for tidily binding
cables together, to stop self-tangling. But don’t over tighten
or you won’t be able to identify troublesome wires by gently
tugging one end and watching for movement elsewhere.
(left) Testing
a flat cable;
these are
vulnerable
to folding/
kinking, so lay
them carefully
(right) Using
the excellent,
but sadly
discontinued
Vision Test
Kit to check
AV cables
and plugs –
can clever
PE readers
come up
with a viable
alternative?
16
Practical Electronics | January | 2024
Failing OLEDs
Whole batches of radios and
Internet radios (for example,
from British DAB pioneers
Pure and Roberts) were built
with OLED displays which
are now failing. Without a
means to see the settings and
tuning options, otherwise
perfectly good radios become
unusable. This frustration
is compounded by the fact
that ‘simply’ replacing the
display turns out to be tricky,
expensive and more trouble
than it is worth.
However, by chance I discovered that pointing a smartphone camera at the failing
OLED display provides a
much more readable image on
the smartphone screen. With
so many old smartphones
now languishing in drawers,
perhaps someone might rise
to the challenge of designing
an ageing-OLED viewer for
equipment troubleshooting?
NEW!
5-year
collection
2017-2021
All 60 issues from Jan 2017
to Dec 2021 for just £44.95
PDF files ready for
immediate download
See page 6 for further
details and other great
back-issue offers.
Ethernet testers are not just for computer/network
troublshooting. Ethernet crops everywhere,
including home AV systems. Make sure you have
one of these handy testers to check cables.
Purchase and download at:
www.electronpublishing.com
tekkiepix pic of the month
Mavica – Sony’s pioneering digital camera
standard for ‘electronic still video’.
Based on the NTSC TV standard. It
gave either 25 fully interlaced picture
frames, or 50 half-scan pictures of
lower resolution. But the technology
remained too expensive to rival film,
so most companies shelved the idea.
Beaten by Fuji
Sony’s pioneering digital SLR Mavica
offered a range of lenses.
S
ony obviously liked the
name Mavica. In 1974 the company announced the Mavica
video recorder, which captured moving pictures on flexible magnetic cards
that measured 15 by 20cm, and curved
slowly past a scanning video head.
Each card could store 10 minutes
of colour TV with stereo sound. Sony
promised higher density cards with
increased recording time, but Mavica
was killed by the arrival of Sony’s own
Betamax, with several hours recording
time from a small cassette.
Practical Electronics | January | 2024
Each Mavipak 5cm floppy disc stored up
to 50 colour pics.
A sony digital first
In 1981, Sony dusted off the name and
shocked the photographic world by
demonstrating a camera, which looked
like a conventional SLR (single-lens
reflex), but contained an electronic
image sensor and miniaturised computer disk recorder. The SLR Mavica
recorded analogue TV stills on a 5cm
floppy disc coated with pure metal
powder and spinning at 3,600 rpm. The
pictures replayed through a home TV.
In July 1988, 42 electronics and
photographic companies agreed a
In December 1988, Sony tried to go it
alone, launching a consumer version
of Mavica in Japan. The full kit cost
around £500 and it bombed. By then
Fuji had developed a prototype digital camera which used a solid-state
memory card instead of disc, which
is of course the way modern digital
cameras work.
However, since memory cards were
still expensive, Sony moved on to using a standard 9cm PC floppy to store
40 digital images at very low cost.
Practical Electronics is delighted to be
able to help promote Barry Fox’s project
to preserve the visual history of pre-Internet electronics.
Visit www.tekkiepix.com for fascinating
stories and a chance to support this
unique online collection.
17
We’ve published numerous
LC meters that can
measure inductance and
capacitance, but you
might need to know the
quality factor (Q) of an
inductor, not just its
inductance. This Q Meter
uses a straightforward
circuit to measure the
Q factor over a wide
range, up to values of
about 200.
Q Meter
T
he history of Q Meters goes
back to 1934, when Boonton
developed the first Q Meter.
The Q Meter is a somewhat
neglected piece of test equipment
these days. Hewlett Packard bought
Boonton in 1959 and produced
revised versions of their Q Meter.
Does anyone still manufacture them?
It seems not. You can find a few on
the second-hand market; but they
fetch prices up to $3000. The HP
4342-A is an excellent unit and is a
more modern version of the original
Boonton design.
My Q Meter design can’t come near
the quality or accuracy of HP equipment. It is not designed as a laboratory instrument, but it will give Q
measurements up to a value of about
200 with an accuracy of about 10%.
Q&A
So, what is Q, and why do we need
to measure it? It is a measure of
the dissipative characteristic of an
inductor. High-Q inductors have low
dissipation and are used to make
Fig.1: a real inductor does not just
have pure inductance; it also has
parasitic series resistance (Rl)
and parallel capacitance (Cp).
18
finely-tuned, narrow-band circuits.
Low-Q inductors have higher dissipation, resulting in wideband performance. It can be expressed as:
Q = 2π × (Epk / Edis)
Where Epk is the peak energy stored
in the inductor and Edis is the energy
dissipated during each cycle.
Let’s consider two passive components, an inductor and a capacitor. The reactance of the inductor
is Xl = +jωL.
Here, j = √-1, Xl is in ohms and ω
= 2πf (f is the frequency). For example, a 10µH coil at 10MHz will have
a reactance of +j628W.
A capacitor has a reactance of the
opposite polarity, ie, Xc = 1/−jωC.
To resonate at 10MHz, the capacitor needs a reactance of −j628W,
which equates to 25.3pF.
By Charles Kosina
But inductors and capacitors are
not perfect. A practical inductor
can be approximated as an ideal
inductor with a series resistor. The
coil winding will also add a small
capacitance across the inductor, as
shown in Fig.1. The capacitor is also
not perfect but generally has a much
smaller inherent resistance, so for
this calculation, we can assume it is.
The inductor’s Q is defined as Q
= Xl/Rl and the -3dB bandwidth of
such a tuned circuit is BW = f/Q.
So, a tuned circuit with a 10µH
coil and a Q of 100 would have a -3dB
bandwidth of 100kHz at 10MHz.
The Q is important if you’re trying
to design something like a bandpass
or notch filter.
In Fig.2, we have a series-tuned
circuit fed by a variable frequency
source with frequency f, voltage VS
Fig.2: we can calculate an unknown inductor’s Q (quality factor) using this
circuit. It is connected in a series-tuned circuit with a capacitance, and that
circuit is excited by a sinewave from a signal generator via a known source
resistance. Measuring the input and output AC voltages and calculating
their ratios allows us to compute the inductor Q, assuming the Q of the
capacitance is high.
Practical Electronics | January | 2024
and source resistance Rs. At resonance, Xl = −Xc; in effect, a short
circuit, so the load on the generator
is Rs + Rl.
By having a generator with source
resistance Rs much lower than Rl,
the voltage measured at Vin will
be close enough to VS. The current
through the circuit will be Is = VS/Rl.
Therefore the voltage at the junction of the inductor and capacitor
is Vout = Xl × Is. By measuring Vin
and Vout, the Q can be calculated as
Ql = Vout / Vin. That assumes that
the capacitance has been adjusted
to achieve peak resonance with the
inductance, ie, Xl = −Xc. That can
be done by sweeping the capacitance
until the peak Vout voltage is reached.
The first design challenge is to
have an extremely low generator
source resistance. If we have a 10µH
coil with a Q of 100, at 5MHz, the
effective Rl is 3.14W (314W/100). If
our source resistance is 0.1W, that
will give an error of about 1%. But
at 1MHz, Rl becomes 0.628W, and
this error blows out to 15%.
So using a higher frequency will
generally result in a more accurate
Q measurement.
Low source resistance
Boonton solved the source resistance problem by having the generator heat a thermocouple using a
wire with a very low resistance, as
shown in Fig.3. The voltage generated by this thermocouple was measured by a DC meter which indicated
how much current was applied to
a 0.02W resistor in series with the
external inductor.
I have a Meguro MQ-160 Q Meter,
essentially a 1968 version of the original Boonton 260-A design, using
such a thermocouple and resistor. No
transistors in this one; it’s all valves!
But for our design, a thermocouple
is not practical. The HP design eliminated the thermocouple and instead
used a step-down transformer. The
Practical Electronics | January | 2024
transformer is fed by a low impedance source, as shown in Fig.4.
If our source resistance is 50W, like
the output of a typical signal generator, and the turns ratio is 50:1, the
effective source resistance is 0.02W
(50W/502), exactly what we want.
Unfortunately, it is not so simple
as it implies a perfect transformer.
Losses in the transformer core plus
winding resistance conspire against
us and push up the source resistance value.
We can improve this by feeding
the transformer’s primary from the
output of an op amp, which has an
impedance close to zero. In this case,
a turns ratio of 10:1 is adequate as
the resultant 100:1 impedance ratio
will give an acceptable load to the
op amp.
This is what I have used in my
design. The transformer is a ferrite
toroid of 12mm outside diameter.
The primary is 10 turns of enamelled
wire, while the ‘one turn’ secondary
is a 12mm-long tapped brass spacer
through the centre of the toroid. The
effective RF resistance of this spacer
is extremely low, and the source
resistance is then mainly a function
of the ferrite material and the primary winding resistance.
Table 1 – frequency versus
signal source impedance/spacer
Frequency
Brass
Steel
0.1-1MHz
~0.00W
0.02W
2MHz
not tested
0.016W
5MHz
0.03W
0.13W
10MHz
0.07W
0.20W
15MHz
0.09W
not tested
20MHz
0.15W
0.22W
25MHz
0.10W
0.17W
Circuit description
The full circuit of my Q Meter is
shown in Fig.5. We require a signal
generator with an output of about
0dBm (1mW into 50W or 225mV
RMS). You can use just about any RF
signal generator. There didn’t seem
to be much point in building the
generator into the Q Meter since, if
you’re building a Q Meter, you likely
already have an RF signal generator.
I’m using my AM/FM DDS Signal
Generator that was described in the
May 2023 issue of PE.
The generator feeds a sinewave
into CON1, which is boosted by op
amp IC2a. This is a critical item in
the design, as it needs to have a high
gain bandwidth (GBW) and slew rate,
as well as the capability to drive a
low impedance.
The Texas Instruments OPA2677
has a GBW of 200MHz, a slew rate of
1800V/µs and can drive a 25W load,
which gives us enough output voltage swing up to 25MHz.
The toroidal transformer core is a
critical part of the design. I tested a
Fair-rite 5943000301 core which is
readily available from several suppliers. I wound it with 10 turns of
0.3mm-diameter enamelled copper
wire. A heavier gauge (up to about
0.4mm) may be slightly better, but
there has to be enough room in the
centre for the spacer to pass through.
I then calculated the source
impedance by measuring the no-load
output voltage followed by a 1W load.
I did this for several frequencies,
and the results are shown in Table 1.
Below 1MHz, there was no measurable difference between no load
and a 1W load, so the source impedance must be well below 0.01W. Core
losses likely account for the higher
source resistance as frequency
increases, but the results are quite
adequate. Brass spacers are recommended (and will be supplied
in kits) due to their superior performance here, at least for the one
through the toroid.
The DC output of op amp IC2a is
zero or very close to zero, so why do
Fig.3: one method of measuring
Q involves current sensing via
monitoring the temperature of a
resistance wire. It has the advantage
of keeping the source impedance
low, and no complicated shuntsensing circuitry is required.
Fig.4: we need an RF signal
source with an extremely low (but
known) source resistance for our
Q Meter. Since that is difficult
to achieve by itself, feeding the
signal through a low-loss stepdown transformer greatly reduces
the actual source impedance, as
seen by the load.
19
Digital
Q Meter
Fig.5: eight relays switch capacitors in parallel to vary the resonant circuit capacitance from around 40pF (the stray
capacitance) to 295pF. The signal from the RF generator is amplified by op amp IC2a and fed through step-down
transformer T1 to the resonant circuit. The input signal level is monitored via precision rectifier IC2b while the output
signal is rectified using D3 and amplified by IC3a.
we need a 10µF capacitor in series
with the transformer? Since the DC
resistance of the primary is a fraction of an ohm, the slightest offset
20
voltage in the op amp output could
send a high direct current through
the toroidal transformer primary and
overload the output. IN this design,
that possibility is eliminated with
AC coupling.
The tuning capacitor is another
essential part. My Meguro MQ-160 Q
Practical Electronics | January | 2024
Meter has a 22-480pF variable capacitor, typical of the tuning capacitors
used in valve radios. They are available on sites like eBay, but they do
Practical Electronics | January | 2024
tend to be rather large and can be
surprisingly expensive.
The only easy-to-get variable
capacitor is the sort with a plastic
dielectric for AM radios. But once
you get above the broadcast band,
they are very lossy, with a poor Q,
and entirely unsuitable.
So instead, I designed a ‘digital
capacitor’ with eight relays switching in capacitors with values in a
binary sequence of 1, 2, 4, …..128pF.
As these are not standard values,
some are made up of two capacitors in parallel. For example, 32pF
is 22pF in parallel plus 10pF. Combining these allows the capacitance
to be adjusted in 1pF steps from 0pF
to 255pF.
The measured stray capacitance
due to the tracks, relays and so on
amounts to 40pF, so the tuning range
is 40-295pF. My LC meter shows that
it tracks reasonably accurately.
All capacitors are not created
equal, so I have used somewhat
expensive high-Q RF capacitors,
available from element14, Mouser,
Digi-Key and other good suppliers.
Not all these capacitors have a close
tolerance; some are ±2%, which
detracts from the accuracy. So it
isn’t a ‘real’ variable capacitor but
it has the advantage of not needing
a calibrated dial and a slow-motion
vernier adjustment.
Rather than measuring the very
low voltage on the secondary side
of the transformer, it is more practical to measure the primary side,
and for the Q calculation, divide this
by 10. I verified this assumption by
checking that the voltage ratio corresponded to the turns ratio within
measurement accuracy from 100kHz
to 25MHz.
A precision half-wave rectifier is
formed using op amp IC2b in the
classic configuration. By placing
the rectifier diodes in the negative
feedback network of the op amp,
their forward voltages are effectively
divided by the (very high) open-loop
gain of the op amp.
On positive excursions of the output pin of IC2b, the 330nF capacitor
at TP3 is charged up through diode
D1. The extra diode (D2) is needed
becuae without it, negative excursions would saturate the op amp
and lead to slow recovery, limiting
its frequency range. Both diodes are
1N5711 types for fast switching.
The output of IC2b is amplified by
IC3b, and the resulting filtered DC
voltage at TP4 is about 1.9V.
The secondary voltage of the transformer is typically 200mV peak-topeak or about 70mV RMS. With a
Q of 100, the voltage output at the
junction of the inductor and tuning
capacitor would be 20V peak-to-peak
or 7V RMS.
21
Fig.6: the PCB uses mostly SMD components for compactness, although
none are particularly small. The orientations of the following components
are important: all relays, ICs and diodes, plus the Arduino Nano. ZD1, IC4,
CON3 and associated parts form the optional debugging interface.
That is not a suitable voltage to
apply to the input of an op amp!
So I used schottky diode D3 as a
half-wave rectifier feeding a high-
impedance (10MW/1.5MW) voltage
divider. The voltage drop in the
diode only introduces a small error
in the measurement.
The voltage at the junction of this
divider is buffered and amplified
by IC3a, a TSV912 op amp with an
extremely high input impedance –
the input bias current is typically
1pA. Switch S1 changes the gain of
this op amp for the low and high Q
ranges, with the low range giving a
gain of 8.3 for Q values of up to 100.
22
On the high range, the gain of this
stage drops to 1.7.
Power supply and control
A MAX660 switched capacitor voltage inverter (IC1) provides a nominally −5V supply to the OPA2677
(IC2). This is needed for proper operation of the half-wave precision rectifier ( IC2b) since the voltage at its
input can swing below ground.
The MAX660 is not a perfect voltage inverter, and with the current
drain of the OPA2677, its output is
about −3.6V, but that is adequate.
The rest of the circuit operates
from a regulated +5V DC fed in
externally – for example, using a
USB supply.
An Arduino Nano module is used
as the controller. This is a readily-
available part from many suppliers
at a reasonable price. Two analogue
inputs are used for measuring the
voltages, eight digital outputs switch
relays, the two I2C serial lines drive
the OLED, and there are inputs for
the control rotary encoder and LOW/
HIGH switch sensing.
The rotary encoder (EN1) is used
to adjust the ‘digital capacitor’ value;
its integral pushbutton switch toggles between steps of 1pF and 10pF.
As usual with my designs, I have
added a simplified RS-232 interface
using hex schmitt-trigger inverter
IC4 to aid code debugging. IC4, ZD1
and the two associated resistors can
be left out unless you want to use the
debugging interface.
Eight 2N7002 N-channel MOSFETs (Q1-Q8) drive the relay coils,
while eight diodes across the relay
coils (D6-D13) suppress any switching transients.
The resonant frequency tuning
is done by selecting an appropriate
frequency from the external signal
generator and adjusting the variable capacitance value. Ideally, the
peaking should be done with an analogue meter, but I have provided an
onboard LED (LED1), the brightness
of which depends on the Vout voltage. It’s a simple enough procedure
to adjust the capacitance to achieve
maximum brightness.
The third line of the OLED also
shows the output voltage of IC3a,
which can be used to accurately
achieve resonance too.
Connector CON5 drives an
optional external 0-5V moving-coil
meter. You can add such a meter if
a larger-than-specified enclosure is
used to house the PCB.
The power supply is a standard
5V USB charger. I have not included
reverse polarity protection, but an
off-board 1A schottky diode (eg,
1N5819) could be added in series
if desired.
Construction
The construction uses two PCBs (see
Figs.6 and 7). The main one has all
the electronics while the other has
the screw terminals for the DUT and
external capacitor. It is also used as a
front panel and has a rectangular cutout for the OLED, holes for the controls and lettering. It is designed to fit
in a RITEC 125 × 85 × 55mm enclosure
(for example, one sold by Altronics as
H0324, but plenty of other vendors
will have similar boxes).
Practical Electronics | January | 2024
The top board/front panel is 98 ×
76mm and fits snugly into the recess
in the clear lid of the enclosure. This
board could be used as a template
for accurately drilling the holes in
the clear lid. But other enclosures
may be used as long as they have the
same or slightly greater dimensions
as the H0324.
For those wishing to add the 0-5V
moving-coil meter, this requires an
additional width of 45mm. A suitable 158 × 90 × 60mm enclosure is
available from AliExpress suppliers
at a reasonable price, but do remeber that delivery can take quite a
few weeks.
Most components on the PCB are
surface-mount types, but there are
no fine-pitch ones, which simplifies
construction. Solder the four SOIC
chips first, then all the passives,
which are mostly M2012/0805-size
devices (2.0 × 1.2mm).
The relays take a bit of care to
ensure they are square on the board
so that it looks neat. On the opposite
side of the board are eight 1N4148
equivalent diodes; ensure they are
installed with the correct polarity,
with the cathode stripes to the side
marked ‘K’.
After the SMDs, add the throughhole diodes, which have a 7.6mm
(0.3-inch) pitch, then the rotary
encoder, switch and LED. Use a 5mm
plastic spacer for the LED, so it is
flush with the back of the front panel.
Wind ten turns of the specified
enamelled copper wire onto the
toroidal core, taking care that the
turns are equally spaced around the
circumference, to the extent possible, and the ends line up with the
two pads marked PRIM on the PCB.
Carefully attach the toroid so that
it is centred on the mounting hole.
Attaching the spacer to the board
makes that easier.
It may be anchored in place by
an insulated wire across the two
pads on the opposite side. It is not
a shorted turn because only one
side of this wire is connected to the
ground plane.
I recommend fitting socket strips
for mounting the Arduino Nano
module as they make replacing a
faulty module easy (I have blown
up a couple in the past!). The OLED
screen also plugs into a 4-pin socket
strip and is held in place by two
15mm-long M2 or M2.5 screws
through 8mm untapped spacers.
Carefully slide off the plastic strip
on the four pins of the OLED so that
it sits lower.
The board must be thoroughly
cleaned with board cleaner. There are
Practical Electronics | January | 2024
high impedances throughout the circuit, so be aware that leakage through
flux residue would affect its operation
– you must remove that residue.
Testing
Once the board has been fully assembled, cleaned and inspected, but
before it is mounted in the case,
attach the four 12mm spacers –
but not the front panel board – and
connect the 5V supply. The OLED
should show an initial message with
the firmware version number.
Using a coax cable, feed in a sinewave from a signal generator at about
1MHz. An oscilloscope probe on TP1
should show a clean sinewave, with
an output of about 2V peak-to-peak.
If the output of the signal generator
is too high, you will get flattening on
the negative half cycle. In that case,
back off the level for a clean sinewave.
Transfer the ‘scope probe to the
top of the spacer that passes through
the toroid, and the voltage should be
one-tenth of that measured at TP1.
Measure TP4 using a DC voltmeter;
Only the Arduino Nano, headers and eight diodes are on the underside of
the Q Meter PCB. Note how the windings for T1 are spaced evenly around it.
23
|