Professional Documents
Culture Documents
Practical Electronics 2022 9
Practical Electronics 2022 9
Electronics
The UK’s premier electronics and computing maker magazine
Circuit Surgery Audio Out Make it with Micromite
Mastering electronically Using audio Small displays and using
controlled resistance transformers infrared to synchronise time
WIN!
Microchip
PIC32CM LS60
Curiosity Pro
Evaluation Kit
WIN!
Preamplifier
with Digital Touchscreen
Tone / Volume Controls
PLUS!
Sep 2022 £5.49
Techno Talk – What’s in a name? 09
Cool Beans – Mechanical control with a servo
9 772632 573023
Net Work – Li-ion battery fires, Win 11 and What3Words
www.electronpublishing.com @practicalelec practicalelectronics
Certified SIL 2/3 Self-Test Library for
Industrial Safety
Simplify Your System Development and Certification
Industrial safety is critical in the field of industrial controls, robots, sensors, gas detectors and smoke
detectors, making the IEC 61508 Industrial Safety Standard a pre-requisite for these applications.
Our broad portfolio of 32-bit SAM and PIC32 Microcontrollers (MCUs) and dsPIC33C Digital
Signal Controllers (DSCs) offers TÜV Rheinland-certified diagnostic libraries (self-test
libraries) for designs targeting up to SIL 3, IEC 61508 FMEDA and/or safety manuals, which
are available in a complete package.
Utilize the comprehensive set of documentation and certified software libraries to simplify and accelerate
your system development while saving certification cost and time.
Electronics Contents
Projects and Circuits
Touchscreen and Remote Digital Preamp with Tone Controls – Part 1 16
by Nicholas Vinen and Tim Blythman
his rea has the est o oth orlds the enefits o digital control together
ith the lo noise and distortion o an analogue design.
Micromite to Smartphone Connector via Bluetooth by Tom Hartley 26
his ro ect de onstrates ho to use a icro ite as the heart o an o nternet
o hings device y connecting a icro ite to your ndroid s art hone.
20A DC Motor Speed Controller by John Clarke 30
his s all ut o er ul s eed controller has a rating and is ac ed ith
eatures. t suits a ide range o a lications and is si le to uild and use.
USB-PD Triggers, Decoys and Testers by Jim Rowe 40
ollo ing on ro the article last onth on charging odules e ll no
e a ine so e o the any lo cost trigger decoy and tester odules.
Volume 1 and Volume 2 cover transmitters Volume 4 covers clandestine, agent or ‘spy’
and transceivers used between 1932-1948. radio equipment, sets which were used by
An era that starts with positive steps special forces, partisans, resistance, ‘stay
taken to formulate and develop a new behind’ organisations, Australian Coast
series of wireless sets that offered great Watchers and the diplomatic service. Plus,
improvements over obsolete World War I selected associated power sources, RDF and
pattern equipment. The other end of this intercept receivers, bugs and radar beacons.
SUBSCRIBE NOW!
Practical Practical Practical Practical Practical
Electronics Electronics Electronics Electronics Electronics
The UK’s premier electronics and computing maker magazine The UK’s premier electronics and computing maker magazine The UK’s premier electronics and computing maker magazine The UK’s premier electronics and computing maker magazine The UK’s premier electronics and computing maker magazine
Circuit Surgery Audio Out Wind turbine Electronic Building Blocks Circuit Surgery Audio Out Make it with Micromite Circuit Surgery Audio Out Make it with Micromite Circuit Surgery KickStart Make it with Micromite Circuit Surgery Audio Out Make it with Micromite
Exploring the Vocoder final Small-scale Building a budget Distortion and Designing a practical Code for an iButton-based Simulating distortion Using transformers in Installing MMBASIC on a Using distortion and Exploring DACs and MMBASIC + RPi Pico + display Mastering electronically Using audio Small displays and using
Royer oscillator assembly garden set-up electronic stethoscope distortion circuits de-thump circuit Electronic Door Lock and distortion circuits audio electronics Raspberry Pi Pico distortion circuits microcontrollers = PicoMite Backpack! controlled resistance transformers infrared to synchronise time
WIN! WIN!
Microchip WIN!
Microchip Microchip
SAM C21 SAM V71
Xplained Ultra PIC32CM LS60
Xplained Pro Curiosity Pro
Evaluation Kit Multi-purpose Battery Evaluation Kit
WIN!
Evaluation Kit
WIN! WIN!
Manager
Completing Retro gaming
our impressive Introducing the 8/14/20-pin PIC Introduction to
Programming Helper with Nano Pong!
Analogue Vocoder Raspberry Pi Pico linear actuators 20A DC Motor Speed Controller
01202 087631
WIN! Single-Chip Silicon
WIN! Microchip
Labs FM/AM/SW Adding small
Digital FX Explorer 8 SAM E54
Curiosity Ultra
displays to
Unit Development Kit High-current Development Digital Radio Receiver Controlling a Flowcode
from Microchip
Battery Balancer
Board
linear actuator the PicoMite
WIN! Digital Clock Micromite to
Simple Flowcode Design Smartphone
MIDI
C
Bluetooth Link
Toot toot! void interrupt(void)
{ if (intcon & 4)
{
clear_bit(intcon, 2); Assembly
Preamplifier
EF10000
:10001000040EF2000A0
EF300BA110A122928352
86C
www.electronpublishing.com @practicalelec practicalelectronics www.electronpublishing.com @practicalelec practicalelectronics www.electronpublishing.com @practicalelec practicalelectronics www.electronpublishing.com @practicalelec practicalelectronics www.electronpublishing.com @practicalelec practicalelectronics
Take out a one-year subscription and save more than £10 over the year.
Even better – save over £1 per issue if you subscribe for two years – a total saving of £26.
Electronics
Rest of the World £41.99 (Airmail)
1 Year: UK £54.99, Europe £63.99 (Airmail),
Rest of the World £77.99 (Airmail)
2 Years: UK £104.99, Europe £119.99 (Airmail),
SUBSCRIPTION PRICES Rest of the World £149.99 (Airmail)
Subscriptions for delivery direct to any address in: To: Practical Electronics Subscriptions
PO Box 6337
UK: 6-months £29.99, 12-months £54.99, 24-months £104.99 Bournemouth BH1 9EH
Europe Airmail: 6-months £33.99, 12-months £63.99, United Kingdom
24-months £119.99 Tel: 01202 087631
Email: pesubs@selectps.com
Rest Of The World Airmail: 6-months £41.99, 12-months
£77.99, 24-months £149.99 I enclose payment of £ ..............
(cheque/PO in £ sterling only)
Cheques (in £ sterling only) payable to Practical Electronics payable to Practical Electronics
and sent to: Practical Electronics Subscriptions, PO Box 6337,
Please charge my Visa/Mastercard
Bournemouth BH1 9EH, United Kingdom
My card number is: .......................................................................
Tel: 01202 087631 Please print clearly, and check that you have the number correct
Email: pesubs@selectps.com
Card Security Code .................. Valid From Date........................
Also via our online shop at: www.electronpublishing.com (The last 3 digits on or just under the signature strip)
Subscriptions start with the next available issue. We accept Card Ex. Date ......................................
MasterCard or Visa.
Name ............................................................................................
(For past issues see the Back Issues page.)
Address ........................................................................................
9 771030 266001
12
11
$ 50* NZ $1290
INC GST INC GST
SMD
Trainer
and how to solder surfac
e-mount parts
The small but powerful
Hummingbird
Amplifier
Hands-on with the
Raspberry Pi Pico
The smallest Raspberry
Pi yet!
1 year 0
0 USB Cable Tester;
November 2021
80 8
2 years 0 00
8
• Combined subscriptions include both the printed magazine and online access.
• Prices are in ustralian dollars ( ) unless otherwise s ecified Hummingbird Amp;
• Prices listed are for everywhere in the world except Australia and New Zealand. December 2021
View siliconchip.com.au/Shop/SubRates for a full list of current prices.
• Price estimates are just that and should only be used as a guide, we primarily
take payment in the form of Australian dollars.
Raspberry Pi Pico;
Try our Online Subscription – now with PDF downloads! December 2021
An online issue is perfect for those who don’t want too much
clutter around the house and is the same price worldwide.
Issues can be viewed online, or downloaded as a PDF.
Electronics Editorial
Editorial offices
Practical Electronics Tel 01273 777619 Digital preamp
Electron Publishing Limited Mob 07973 518682 There are two things we know PE readers like – you ask for
1 Buckingham Road Fax 01202 843233
Brighton Email pe@electronpublishing.com
them regularly – Hi-Fi projects and coverage of digital control
East Sussex BN1 3RA Web www.electronpublishing.com systems and techniques. So, it’s surprising how rarely we put
these two topics together. This month, we buck that trend with
Advertisement offices the start of a two-month project that combines the fidelity of
Practical Electronics Adverts Tel 01273 777619
1 Buckingham Road Mob 07973 518682
an analogue design with the flexibility of digital control and a
Brighton Email pe@electronpublishing.com touch-screen interface. It includes Baxandall tone controls and
East Sussex BN1 3RA uses a Micromite BackPack, so despite being low in cost it is
Editor Matt Pulzer
high in features. We think you’ll love it!
General Manager Louisa Pulzer
Digital subscriptions Stewart Kearn Tel 01202 880299 The power of batteries… and a warning
Online Editor Alan Winstanley I wrote last month about the importance of the new generation
Web Systems Kris Thain
Publisher Matt Pulzer of battery technologies and the related issue of correct
charging. So, it is only right that this month Alan Winstanley
Print subscriptions reports on what can go wrong if a Li-ion battery is misused,
Practical Electronics Subscriptions
or fails through poor design, overuse or damage. The resulting
PO Box 6337
Bournemouth BH1 9EH Tel 01202 087631 pyrotechnics can be spectacular for all the wrong reasons. Like
United Kingdom Email pesubs@selectps.com many of you, I have a variety of DIY tools that run off a common
battery system. The official branded versions of the rechargeable
Technical enquiries Li-ion batteries that power these tools are pricey, but it is
We regret technical enquiries cannot be answered over the
telephone. We are unable to offer any advice on the use, purchase, becoming ever clearer that low-cost, third-party bargains could
re air or odification o co ercial e ui ent or the incor oration be a very foolish purchase. This is one area where it definitely
or odification o designs u lished in the aga ine. e cannot pays to think in the long term and to ask yourself what am I
provide data or answer queries on articles or projects that are
ore than five years old. really saving with cheap batteries, what am I risking and how
would I put out a battery fire? Do you have a fire detector, fire
Questions about articles or projects should be sent to the editor blanket and a fire extinguisher? They aren’t expensive, but if
by email: pe@electronpublishing.com
you need one in a hurry there is no substitute.
Projects and circuits
All reasonable precautions are taken to ensure that the advice and Web issues and solutions
data given to readers is reliable. We cannot, however, guarantee We have had a few web issues this summer and we really
it and we cannot accept legal responsibility for it.
appreciate the patience of those of you who have been affected.
A number of projects and circuits published in Practical Electronics The good news is the PDF subscription website has been
employ voltages that can be lethal. You should not build, test, completely rebuilt and now runs smoothly and safely.
modify or renovate any item of mains-powered equipment unless
you fully understand the safety aspects involved and you use an
RCD (GFCI) adaptor. For digital subscribers there is more good news. When the PDF
subscription system was launched it made sense to include
Component supplies digital security features, but 10 years on all they do is annoy
We do not supply electronic components or kits for building the
projects featured, these can be supplied by advertisers. We legitimate purchasers and provide very little protection to
advise readers to check that all parts are still available before the publisher. Therefore, we have removed the irritating
commencing any project in a back-dated issue. watermarking and PDF password protection.
Advertisements
Although the proprietors and staff of Practical Electronics take Matt Pulzer
reasonable precautions to protect the interests of readers by Publisher
ensuring as ar as ractica le that advertise ents are ona fide
the magazine and its publishers cannot give any undertakings
in respect of statements or claims made by advertisers, whether
these advertisements are printed as part of the magazine, or in
inserts. The Publishers regret that under no circumstances will
the magazine accept liability for non-receipt of goods ordered, or
for late delivery, or for faults in manufacture.
Transmitters/bugs/telephone equipment
We advise readers that certain items of radio transmitting and
telephone equipment which may be advertised in our pages
cannot be legally used in the UK. Readers should check the law
e ore uying any trans itting or tele hone e ui ent as a fine
confiscation o e ui ent and or i rison ent can result ro
illegal use or ownership. The laws vary from country to country;
readers should check local laws.
This month we check out various names of gadgetry encountered in everyday electronics. Some of them
are informative, others silly or even a bit dated (like me!) — but still vaguely amusing in their own way.
L
et’s kick off with ‘flower truth in this assertion because an alterna- Wikipedia confirms this and adds that
power’, dating from the swing- tive name for this exercise is a ‘soak test’, the connector was launched in 1937 by
ing sixties, when we all wore in which newly constructed or repaired the RCA company, which explains why
sandals and cheesecloth shirts, with equipment is observed under stressful most Americans calls these plugs ‘RCA
flowers in our hair. Hobby electronics condition over an extended period. Burst connectors’. On the other hand, many
was not a dirt-cheap hobby back then, pipes would be a clear indication of fail- people call them ‘Cinch connectors,’ a
but transistors were just beginning to ure. But we are drifting off-topic, so let’s term widespread in continental Europe.
become affordable (especially if you get back to dodgy capacitors. Historically, the British and US Cinch
bought the cheaper but slightly out- Highly suspect are the capacitors companies made all manner of connec-
of-spec ones). Silicon devices were far nicknamed ‘humbugs’, ‘black beauties’ tors, but whether they also made phono
too expensive for most folk, so we set- and ‘bumblebees’, which were made connectors I cannot say at this moment.
tled for flower power (in other words in the 1950s – all three being of simi- Another classic design of connector
germanium) devices. Because many lar construction. They are notorious with many applications in electronics
people were not very good at spelling, for drifting in value or failing to block is the barrel connector, which is a small
they wrote ‘geranium’ instead, hence DC properly, thus contributing to over- coaxial connector used for hooking up a
the flower power nickname. Yes, hi- heated anodes (by putting a false bias low-voltage power source to both con-
lariously amusing. on the next stage of amplification) and sumer electronic devices and a host
In those far-off days, transistor sets early valve death in general. Their weak of industrial products. The (presum-
were still in the process of ousting the point was a Bakelite resin shell that all ably American) author of the Wikipedia
older valve/tube radios. Manufacturers too often cracked or crumbled, allow- page accords it the alternative names of
used the trendy term ‘solid state’ to ing moisture to enter and degrade the ‘concentric barrel connector’ and ‘tip
promote the new generation of transis- paper dielectric. connector’, but sadly omits the name
torised products, prompting electronics Humbugs looked strikingly similar to ‘ROKA connector’, which is used widely
hobbyists to invent the name ‘hollow the old-fashioned mint humbug sweet, in Europe. Why sadly? Because the de-
state’ for sets that still used round glass while bumblebees took their name from sign of this connector that is now used
things that ran hot. the coloured stripes used to indicate all over the world originated in Germany
their value. Most electronicists replace and derives from the initials of the Robert
Culpable and colourful capacitors these caps without bothering to even Karst electronics company.
Of course, anything electronic that ran test them. Far more desirable, both in While we are on this subject, it’s worth
hot was prone to drifting and general looks and reliability, were and are the noting that conventionally these connec-
unreliability. Many components could Mullard/Philips C280 miniature met- tors are centre-positive, but this applies
not tolerate excessive heat, which is allised metal film capacitors, dating only in consumer electronics. In the US,
probably how electrolytic capacitors from the mid-1960s. Known universally the reverse applies on professional and
acquired their nickname of ‘smooth- by their ‘tropical fish’ nickname, they industrial equipment, the centre pin
ing bombs’ (particularly the ones with remain highly regarded for their immu- being negative. If a gadget using these
ominously bulging top seals). Like most nity to moisture and temperature drift. power connectors appears to be dead
electronic components, capacitors use even though the power supply is known
smoke as their active ingredient! If they Same item, different name to be good, the reversed method of wir-
are overheated or overloaded, they ex- Let’s take the humble phono connec- ing may be the cause. Note that the pin
plode and release the smoke that up till tor – not to be confused with a phone of these connectors can measure either
then had powered them. This is why connector of course. Why does such a 2.1mm or 2.5mm in diameter (2.1mm is
you should always conduct a ‘smoke commonplace item have at least three more commonplace). A 2.5mm power
test’ to check whether a newly built names in the English language? And connector plugged into a device equipped
or repaired gadget will run for several why phono? Answering the second with a 2.1mm pin will not make contact.
hours without liberating any smoke. question first, it’s a throwback from I once discarded a perfectly good ‘wall
Some folk will tell you that smoke when owners of radio receivers (wire- wart’ power supply after failing to spot
testing is not a silly name invented by less sets) could for the first time connect this stupid mistake!
electronicists, but rather an entirely ra- a record deck or electric phonograph. One final case of pluggery with mul-
tional term borrowed from the plumbing On the rear of these upmarket radios tiple names is the mini jack connector,
trade. After new pipework has been in- was a small coaxial connector marked also known as a 3.5mm or 1/8-inch plug
stalled, smoke is created artificially, blown ‘phono’ for plugging in the connecting or socket. The proper name for the socket
into the tubing, thereby enabling an ob- cable. Presumably, this feature origi- is a ‘jack’ and the corresponding ‘plug’
server to check the pipes and make sure nated in the US, where gramophones is the proper name for what some folk
no smoke is leaking. There may be some were called phonographs. confusingly call a ‘jack plug’.
Free-to-enter competition
Closing date
The closing date for this offer is 31 August 2022.
T
his winter – or probably well interest officialdom. If any bona fide an advert now gets a standard form
before then – homes with body, with the clout to investigate, now acknowledgement, but then hears noth-
‘smart’ meters will discover an shows genuine interest and concern, ing further unless the ASA decides to
unhappy truth. When they took up the I will provide access to chapter and follow through on the complaint. The
offer of a free meter, they gave the gas verse documentation. If any reader complainant is, therefore, left dangling
and electric supply companies free- wants to circulate a copy of this ar- with no information on whether or
dom to cut off their power remotely, ticle, for instance to their MP, feel free. not their complaint is being followed
at the flick of a switch (or more likely, I can be contacted via my website: through, and if not, why not. There
the click of a mouse). www.tekkiepix.com is no guidance given on how long a
Unsurprisingly, this doesn’t feature in In November 2021 I complained to silence signals a considered decision
the power companies’ advertising cam- the ASA about adverts (eg, Evening not to act.
paign for smart meters, co-ordinated Standard, 15 November 2021) which The ASA acknowledged, 18 months
by a company called Smart Energy GB. trumpeted that ‘More wind power is a ago, that my, ‘suggestion that we should
All the promotional emphasis is on smart thing. Smart meters are helping indicate a likely time frame within our
reducing bills and saving the planet modernise Britain’s energy system, acknowledgement email is something
with wind turbines and solar power. so it can use more renewables and that struck a chord immediately and
Of course, it’s good that customers solar power’. we will look to implement something
who could pay their bills but persis- I baulked at the ‘so it can use’ claim. like this’.
tently choose not to pay, and try to How does the use of smart meters in ‘It’s a very helpful suggestion, thank
deny entry to cut-off engineers, will homes enable wind turbines and solar you,’ said a senior spokeswoman.
now get their just desserts. But honest farms? Smart meters enable the energy But the last time I looked, the ASA
victims of unhappy circumstance risk companies to save money on human system was still leaving complain-
being stuck on Kafkaesque help lines meter-readers, and remotely discon- ants dangling.
trying to get re-connected. Some may nect supplies. Without evidence or When I pushed the ASA hard on
feel they were misled by the power explanation, ‘so it can use’ seems to the lack of action on my smart meter
companies’ promotions. Questions be a complete non sequitur. complaint, a senior ASA spokesman
will then be asked. explained that it, ‘raised an issue we
Silence isn’t golden have already considered, and therefore
Legal, decent, honest and truthful? The ASA acknowledged receipt of did not need to pursue further.’
So, this month, I will distil the essence my complaint but then fell silent. ‘The ASA has previously investigated
of countless hours of pressuring the This is because the ASA has recently environmental claims by Smart Energy
Advertising Standards Authority over ‘convenienced’ itself – if no one else GB’ the ASA spokesman explained,
the adverts for smart meters it has – by changing its complaint-handling and pointed to a ruling from September
blessed. I have tried – so far in vain – to procedure. Anyone complaining about 2019: https://bit.ly/pe-sep22-asa1
A
ccording to the 16th century can text a ‘FindMe’ link
proverb, ‘Three may keep a to an incoming caller
secret, if two of them are away’. which will generate the
However, the use of three words is caller’s What3Words loca-
central to the idea behind London- tion. Businesses can use
based What3Words, a geolocation What3Words to help with
service that enables users to pinpoint an logistics or the navigation
address by using three easily digestible of company vehicles. It
words. The firm has divided the globe is also finding its way
into a grid of 3-metre squares, which into vehicles, with Subaru
they decided was the resolution needed USA, DPD Parcels UK and
to enable an area the size of an entrance Jaguar Land Rover adding
or a car parking space to be pinpointed What3Words to supple-
accurately. To map the entire planet ment navigation systems.
(seas, oceans, lakes and all) would Across India, street names
need 57 trillion addresses, which they are often duplicated, ad-
calculated could be described using dresses can be confusing,
combinations of three words. The use and roadsides and many What3Words uses easily digestible words to describe
of three words also gave them seven rural areas don’t have ad- any location on the planet. London’s Tower Bridge is
trillion addresses to spare, as two dresses at all. So Indian described here in the desktop version.
words would only have been enough vehicle maker Mahindra announced optimised for voice, making it the ideal
for 1.6 billion squares. The system is last month it is integrating What3Words location system for the voice-enabled
future-proof, because even if buildings with Amazon’s Alexa in its all-new solutions of the future. We can expect
or addresses change over time, the Scorpio-N SUV. to see more voice recognition and Alexa
same three words will always describe integration in due course. It has been
that same geographical location on Multi-language integration made available in 51 languages.
the globe. To make a start with What3Words, an
Many safety benefits come with using app is available for mobile use that will A word or three about logins
What3Words, as the system makes it generate the three-word string, but it can The use of three whole words is
easy to describe one’s precise location also be used offline with GPS, which will also suggested as a way of managing
in an emergency. In the UK, 80% of provide the three-word location with- personal passwords. It’s becoming
emergency services can now recognise out reference to a map (see the guide increasingly pointless to use random
What3Word phrases and it is catching at: https://youtu.be/_JBwRxjCq-k). If character strings like 3hroY7h0#_67,
on overseas, including with the Cana- you have no mobile phone signal, you which is a login that can’t be remem-
dian police. In some cases, services will need another means (radio, lan- bered and will probably end up written
dline) to communicate on a Post-It note somewhere. A non-
those three words in sensical passphrase could be created
order to summon any by stringing three words together, such
services. The website as poachedeggssalt22. At least
https://what3words. they are more human-friendly and
com enables desktop usable, and no more likely to be hacked
users to zoom in to any than any other combination of charac-
address on a map and ters. Britain’s National Cyber Security
the three words will be Centre (NCSC) explains the rationale of
displayed. Both map using three random words this way, at:
and satellite layers are https://bit.ly/pe-sep22-ncsc
available, and a typical However, the use of biometrics and
house might cover ten two-factor authentication (2FA) is
or twelve squares, so increasingly replacing the need for
you can almost pinpoint passwords altogether. In China, facial
your living room using snapshots are increasingly used as a
What3Words. Looking means of payment verification: Fa-
ahead, the company cial-Recognition Payment (FRP) or ‘Scan
Way to go: Indian vehicle maker Mahindra is incorporating also states that it’s the the face to pay’ systems can look up your
What3words with Alexa into its new Scorpio-N SUV. only addressing system picture on their database and complete
T
o date, most of our remote- We achieved 1) through 4) by using two It’s just what you want for a modern
controlled preamplifiers have quad Analog Devices AD8403ARZ10 preamplifier or amplifier, without com-
used motorised potentiometers. digital potentiometer ICs. While these promising the sound quality.
While these have many benefits, such are not especially cheap at around £8 Besides the BackPack, which would
as low noise and distortion, and the each, they are still quite reasonably generally mount on the unit’s front
ability to simply turn the knob if you priced compared to Hi-Fi-quality vol- panel (along with the IR receiver), all
are close to the preamp, they are quite ume control chips. The eight potenti- this circuitry is packed onto a modest-
expensive and can be hard to obtain. ometers they include let us adjust the ly-sized PCB at 206 x 53mm. It has four
They can also fail and wear out. volume, bass, mid and treble levels in pairs of onboard RCA inputs, so that it
Digital volume control ICs are an both channels using just two chips. can be mounted at the back of the unit.
attractive alternative, but there have These devices have impressive spec- It can be powered from a separate AC
only been a few of these with perfor- ifications, borne out by our testing, or split DC supply or an internal trans-
mance that we would call ‘Hi-Fi’, and with a rated THD+N figure of 0.003% former with suitable windings. That
most of those have been discontinued. at 1V RMS/1kHz (they tested consid- includes transformers with high-volt-
They also can be pretty expensive and erably better than that), a −3dB band- age windings to power amplifier mod-
difficult to obtain. width of 600kHz and an impressively ules, and low-voltage secondaries for
Futhermore, since they only adjust low noise level of 9nV per √Hz. So preamps like this one.
the audio level, we need separate they are well suited to audio signal For standalone use, the power input
arrangements for input switching (as processing tasks. can be an onboard socket on the back,
any self-respecting preamp needs at Because each chip has all four poten- near the inputs, along with the optional
least a few pairs of inputs) and tone con- tiometers needed for a channel, the dig- rear panel pre-outs. These are in paral-
trols. Those are a frequently requested ital pot and its associated op amps are lel with a pair of internal RCA sockets,
feature for preamps, and we agree that laid out all in one area, simplifying the which can feed the preamp’s output
they can be handy. For example, they PCB design and minimising crosstalk signals to a couple of internal amplifier
can compensate for loudspeaker short- between channels. modules, making a complete preamp/
comings, such as a lack of bass or tre- The input switching is handled by amplifier combination.
ble, or too much treble. So, any digital three telecom-style relays, which has
preamp we want to desisgn would need worked well for us in the past, as these Performance
to tick the following boxes: mechanical devices have minimal The performance of the preamp is
1. Decently low distortion and noise (at impact on signal quality. summarised in Figs.1-4. Fig.1 shows a
least CD quality, and ideally better) Finally, the control interface is han- plot of total harmonic distortion plus
2. Tone controls (ideally with at least dled by a Micromite LCD BackPack noise (THD+N) against frequency for
three bands for flexibility) with either a 2.8-inch, 320x240 or an input signal level of 1.5V RMS and
3. A wide volume control range oper- 3.5-inch, 480x320 colour touchscreen. an output level of 3V RMS. As the
ating in a logarithmic manner This provides many benefits, such as final stage has a gain of two times, this
4. Adjustable gain to suit a wide range a nice clear volume readout when you means that the volume control section
of signal sources adjust it via the remote, the ability to is set for unity gain.
5. Infrared remote control show the actual frequency response The 20Hz-22kHz bandwidth plot
6. Input switching for any given tone control setting and (in cyan) gives the best indication of
7. Intuitive and attractive colour touch- loading/saving presets – the whole audible performance. This shows a
screen interface for direct control. nine yards. total harmonic distortion level of less
installed). The other pair consists possible to use both at once, given that Control by Micromite
of vertical connectors on the board, the output impedance is relatively low. The digital pots are controlled using
more suited for internal connections This could be the case in an integrated an SPI serial bus, with one CS (chip
to amplifier modules. It should be amplifier that provides pre-out signals. select) line each, plus active-low
the negative rail to better balance out These 11 total control lines are board attached to the BackPack, as the
the current draw. This means that wired back to SIL header CON8, in receiver needs to be mounted behind
all the relay coil positives are con- positions suitable for being directly a hole on the front panel of the unit.
nected to GND, and the negative ends wired to the I/O header on a Micro-
are switched to −12V. Some clamp mite LCD BackPack module. Power supply
diodes connect to GND and some to There are two additional connec- The power supply is pretty basic;
+12V depending on PCB routing con- tions: one to allow the BackPack to AC is applied to either barrel socket
venience; either way, they will still illuminate or flash the onboard LED CON7 or terminal block CON6. If a
absorb back-EMF spikes and prevent (LED1) in response to remote con- centre-tapped transformer is used,
damage to the transistors on switch-off. trol commands and to indicate that this would typically be wired to
PNP transistors Q1-Q4 level shift the power is supplied. This LED could CON6, with the tap to the middle ter-
0-3.3V digital relay control signals to also be duplicated on the front panel, minal. DC split rails can also be fed
allow the NPN transistors with their if desired, along with a series cur- to CON6. If AC is applied, this is rec-
emitters connected to the −12V rails rent-limiting resistor. The other con- tified by bridge rectifier BR1 and fil-
to be switched normally. So the relays nection is for infrared reception, at tered by a pair of 1000µF capacitors.
activate when the associated control pin 8 of the I/O header. The pulsating DC across these
line is pulled down to 0V, and are off While the IR receiver and its sup- capacitors is then regulated to smooth
if that control line is at +3.3V or float- ply RC filter are shown on the circuit ±12V DC rails by REG1 and REG2. We
ing (high-impedance). diagram, they are mounted on a small have chosen 12V rather than the com-
monly-seen 15V because the perfor-
mance is much the same, and we don’t
need the extra signal swing given the
5.5V limitation of the digital pots.
This also provides more headroom
for regulation.
The +12V rail is dropped to +5.5V
using adjustable regulator REG3. This
is adjustable so that it can be set to
precisely +5.5V; to be safe, we don’t
want to exceed the maximum rec-
ommended supply voltage for IC6 or
IC7 (even though the absolute maxi-
mum rating is much higher). A series
fixed resistor is provided to limit the
adjustment range.
Zener diode ZD1 acts as a safety so
that if the output of REG3 is much too
high for some reason, it should con-
duct and prevent damage to IC6 and
IC7. The +2.75V mid-supply rail is
derived from the +5.5V rail using a
resistive divider and trimmed using
BY TOM HARTLEY
This project demonstrates how to use a Micromite as the heart of an IoT
(Internet of Things) device. But there are many other reasons you might wish
to connect a Micromite to your Android smartphone, such as making it easy
to monitor what your device is doing without going to the trouble or expense
of fitting it with an LCD screen. It also makes it really easy to control the
software running on the Micromite. Phone Image Source: Android Open Source project
T
he popular 28-pin Micromite output data stream using an Android 4. A USB-to-TTL converter (eg, one
is a great way to get into pro- app, sending it BASIC commands that is based on the ubiquitous
gramming microcontrollers and so on. CP2102 chip).
because you need so little to get it up 5. A short USB extension cable.
and running, and the BASIC language Basic arrangement 6. A BMP180 atmospheric pressure
it uses is easy to learn. But to make After programming a 28-pin Micro- sensor (for this particular demon-
the most of it, you really need some mite chip via the conventional PC stration application).
sort of screen. USB connection, I was able to dis- 7. A four-AA battery holder modified
That’s why the Micromite LCD connect it from the PC and transmit by tapping the output voltages at
BackPack series (PE, May 2017, May the Micromite’s terminal output data 3V and 4.5V. The fourth cell is not
2018, August 2020) has been so pop- stream over Bluetooth to an Android needed, so that cell position can
ular. It combines the Micromite with App, running on an inexpensive be left empty.
a colour touchscreen, giving you an mobile phone. The design requires 8. A small piece of Veroboard.
easy way to interact with the device very few components: 9. Some hook-up wire.
and display information. But that 1. A smartphone that is running some
arrangement is considerably more version of the Android OS )operat- Bluetooth module setup
expensive and complex, and a sep- ing system). The first job is to configure the Blue-
arate screen isn’t always required. 2. A 28-pin Micromite PIC chip tooth module as required by this proj-
In Part 14 of Make it with Micromite loaded with MMBasic, plus a tan- ect. The HC-05 Bluetooth module has
(PE, March 2020) we showed how talum or ceramic capacitor for the many similarities to a modem, and the
low-cost Bluetooth modules could be VCAP pin – as recommended by procedure to set it up will be familiar
used to allow a Micromite to commu- Geoff Graham. if you have ever set up serial commu-
nicate without wires. But what about 3. An HC-05 Bluetooth module, pref- nications to a modem.
using such a module to interface with erably one with an Enable pushbut- Before you can do this, you will
a smartphone? ton key. need to install a serial terminal
That way, the phone becomes the
user interface to the Micromite, so you
can get away with a much simpler and
cheaper arrangement – assuming you
already have a suitable phone.
And since smartphones generally
have a connection to the internet, the
Micromite can become an IoT (inter-
net of things) device and easily share
data with other devices.
This article explains how to con-
nect a bare Micromite chip to an
Fig.1: the HC-05 Bluetooth
Android mobile phone to communi- transceiver module is wired up to
cate and display data without using a USB-UART bridge and battery
a screen. You can even communi- pack so that the Bluetooth module
cate with the Micromite’s terminal can be set up using a PC.
Screen 1 shows a typical display mit.edu) because that tool has a Blue-
on the mobile phone when connected tooth connectivity module as a stan-
to the Micromite via Bluetooth. This dard built-in item.
particular App can log received text, Python programs run well on
so data coming across from the test mobile phones, so that provides
rig can be saved. another opportunity for enhancing Screen 1: a very basic display of local
Another advantage of using this the usefulness of your data collected barometric pressure (in hectopascals
particular Bluetooth Terminal App is by the Micromite. [hPa]) in the smartphone terminal
that it adds the current date and time Another possibility is to install a app, delivered by the Micromite. By
to every line of data received, making web server on your Android phone, changing the Micromite BASIC code
it unnecessary to build an RTC mod- such as KickWeb (https://bit.ly/ and hardware, you can get it to report
just about anything you want!
ule into your circuit. In fact, now that pe-sep22-kw). That way, you can use
the data is in your phone, you can PHP scripts or continuously loop-
exploit the fact that your phone is, in ing Python programs to forward sen- More Micromite?
reality, a very sophisticated computer sor derived data to services such as Our monthly column Make it with
and display resource. Thingspeak (www.thingspeak.com) Micromite is the best place to
For example, you can now write where your data can be displayed learn all about this powerful, easy-
your own Android Phone Apps using graphically and made available across to-use single-IC microcontroller.
MIT App Inventor (ai2.appinventor. the whole Internet.
STEWART OF READING
17A King Street, Mortimer, near Reading, RG7 3RS
Telephone: 0118 933 1111 Fax: 0118 933 2375
USED ELECTRONIC TEST EQUIPMENT
Check website www.stewart-of-reading.co.uk
Fluke/Philips PM3092 Oscilloscope HP 54600B Oscilloscope
(ALL PRICES PLUS CARRIAGE & VAT)
2+2 Channel 200MHz Delay TB, Analogue/Digital Dual Trace 100MHz
Autoset etc – £250 Please check availability before ordering or calling in
Only £75, with accessories £125
LAMBDA GENESYS PSU GEN100-15 100V 15A Boxed As New £400 Marconi 2305 Modulation Meter £250
LAMBDA GENESYS PSU GEN50-30 50V 30A £400 Marconi 2440 Counter 20GHz £295
IFR 2025 Signal Generator 9kHz – 2.51GHz Opt 04/11 £900 Marconi 2945/A/B Communications Test Set Various Options POA
IFR 2948B Communication Service Monitor Opts 03/25 Avionics POA Marconi 2955 Radio Communications Test Set £595
IFR 6843 Microwave Systems Analyser 10MHz – 20GHz POA Marconi 2955A Radio Communications Test Set £725
R&S APN62 Syn Function Generator 1Hz – 260kHz £295 Marconi 2955B Radio Communications Test Set £800
Agilent 8712ET RF Network Analyser 300kHz – 1300MHz POA Marconi 6200 Microwave Test Set £1,500
HP8903A/B Audio Analyser £750 – £950 Marconi 6200A Microwave Test Set 10MHz – 20GHz £1,950
HP8757D Scaler Network Analyser POA Marconi 6200B Microwave Test Set £2,300
HP3325A Synthesised Function Generator £195 Marconi 6960B Power Meter with 6910 sensor £295
HP3561A Dynamic Signal Analyser £650 Tektronix TDS3052B Oscilloscope 500MHz 2.5GS/s £1,250
HP6032A PSU 0-60V 0-50A 1000W £750 Tektronix TDS3032 Oscilloscope 300MHz 2.5GS/s £995
HP6622A PSU 0-20V 4A Twice or 0-50V 2A Twice £350 Tektronix TDS3012 Oscilloscope 2 Channel 100MHz 1.25GS/s £450
HP6624A PSU 4 Outputs £400 Tektronix 2430A Oscilloscope Dual Trace 150MHz 100MS/s £350
HP6632B PSU 0-20V 0-5A £195 Tektronix 2465B Oscilloscope 4 Channel 400MHz £600
HP6644A PSU 0-60V 3.5A £400 Farnell AP60/50 PSU 0-60V 0-50A 1kW Switch Mode £300
HP6654A PSU 0-60V 0-9A £500 Farnell XA35/2T PSU 0-35V 0-2A Twice Digital £75
HP8341A Synthesised Sweep Generator 10MHz – 20GHz £2,000 Farnell AP100-90 Power Supply 100V 90A £900
HP83630A Synthesised Sweeper 10MHz – 26.5 GHz POA Farnell LF1 Sine/Sq Oscillator 10Hz – 1MHz £45
HP83624A Synthesised Sweeper 2 – 20GHz POA Racal 1991 Counter/Timer 160MHz 9 Digit £150
HP8484A Power Sensor 0.01-18GHz 3nW-10µW £75 Racal 2101 Counter 20GHz LED £295
HP8560E Spectrum Analyser Synthesised 30Hz – 2.9GHz £1,750 Racal 9300 True RMS Millivoltmeter 5Hz – 20MHz etc £45
HP8563A Spectrum Analyser Synthesised 9kHz – 22GHz £2,250 Racal 9300B As 9300 £75
HP8566B Spectrum Analsyer 100Hz – 22GHz £1,200 Solartron 7150/PLUS 6½ Digit DMM True RMS IEEE £65/£75
HP8662A RF Generator 10kHz – 1280MHz £750 Solatron 1253 Gain Phase Analyser 1mHz – 20kHz £600
Marconi 2022E Synthesised AM/FM Signal Generator 10kHz – 1.01GHz £325 Solartron SI 1255 HF Frequency Response Analyser POA
Marconi 2024 Synthesised Signal Generator 9kHz – 2.4GHz £800 Tasakago TM035-2 PSU 0-35V 0-2A 2 Meters £30
Marconi 2030 Synthesised Signal Generator 10kHz – 1.35GHz £750 Thurlby PL320QMD PSU 0-30V 0-2A Twice £160 – £200
Marconi 2023A Signal Generator 9kHz – 1.2GHz £700 Thurlby TG210 Function Generator 0.002-2MHz TTL etc Kenwood Badged £65
20A DC
Motor
Speed Controller
This small but powerful speed controller has a 20A rating and is packed with
features. It suits a wide range of applications and is simple to build and use.
Features include low-battery protection, soft starting and adjustable pulse
frequency. It can handle DC motors that run from near 0V up to 30V.
T
here are a great many controlled using pulse-width modula- vibrating at the PWM frequency. This
applications for DC motors where tion (PWM). That means that the motor can be alleviated to some extent by
speed control is wanted or nec- is driven by a series of on and off voltage adjusting the PWM frequency to pro-
essary. Since DC motors can be run pulses rather than a variable DC supply, duce minimal noise.
directly from batteries, they are used making it more efficient. That noise tends to be reduced as the
in golf carts, electric scooters, bikes, Speed control of the motor is done PWM frequency is increased, and is
skateboards, remote-controlled cars and by varying the pulse width. The ratio of mostly eliminated at PWM frequencies
boats – the list goes on. the pulse width to the interval between above 20kHz (around the upper limit of
In most of those applications, you pulses is the duty cycle. A low duty human hearing).
need a way to control the speed of the cycle will only provide a voltage to the But increasing the frequency can
motor. Going flat out all the time isn’t motor for a small portion of the time, cause problems too. It becomes harder
always a good idea! and the motor runs slowly. to maintain the motor speed against a
A speed controller like this one is the As the on-pulse duration increases, varying motor load using the traditional
ideal solution. It can handle DC motors this greater duty cycle makes the motor back-EMF feedback system. Very high
with a rated voltage of up to 24V (30V run faster until it reaches 100% duty PWM frequencies can also cause a loss
maximum) and continuous currents cycle and is driven continuously. of motor torque.
up to 20A. Oscilloscope traces Scope 1 and These problems and solutions are
This controller is presented as a bare Scope 2 show how this PWM scheme described in more detail in the section
electronic module built on a PCB that works. In Scope 1, the top (yellow) trace titled, PWM motor driving pitfalls at
can be installed in a standard UB3 plas- is the gate drive signal for MOSFETs Q1 higher frequencies.
tic case. It includes heavy-duty termi- and Q2. When it is high, the motor is This controller gives you the ability
nals for the power supply and motor powered. In this case, the duty cycle is to adjust the PWM frequency beyond
connections, plus additional terminals very low at about 9.5%, so the motor audibility while addressing the prob-
for the speed control potentiometer that runs slowly. The lower cyan trace is lems of limited low-speed motor torque
mounts off the PCB. related to the motor current. This is and control at elevated frequencies.
The motor-driving components are used to maintain motor speed with a Other features that are incorporated
mounted on substantial heatsinks for variable load. include soft starting, low-voltage cut-
cooling. The adjustable features like soft- Scope 2 has the same two traces, but out, LED status indication and optional
start rate and feedback gain are set using this time the duty cycle is much higher, motor disconnected detection. These
onboard multi-turn trimpots with volt- and the motor runs faster. The motor is features are easy to set up and adjust
age test points. An onboard LED indi- loaded less than in Scope 1, so the cur- via trimpot adjustments.
cates the speed setting, as well as faults rent reading is lower despite the higher
like low battery or motor disconnection. duty cycle. Soft starting
This is where the motor is slowly
Speed controller design What’s new increased in speed, up to the setting of
While we have published many DC One of the problems with controlling the speed pot. Soft starting reduces the
motor speed controllers in the past, DC motors using PWM is that the motor surge of current and a rapid build-up
this version has more features and bet- can make extra noise due to the motor of motor torque compared to applying
ter performance. The motor speed is windings and other mechanical parts power suddenly. The PWM duty cycle
Scope 1: a pulse-width modulated (PWM) drive signal at a Scope 2: another PWM drive signal, here with a duty cycle of
low duty cycle, about 9.5%. Current has little time to build 35.5%, which is roughly the same as driving the motor at 1/3
during each pulse, so the motor runs slowly. supply voltage, so it will run faster but not nearly at full speed.
The soft-start period adjustment is a duty cycle well above 0% before they the speed control range so that the max-
with VR2, measured at TP2. This volt- start spinning. imum duty cycle is still achieved when
age is monitored at the AN6 input, and As described in the separate panel VR1 is fully clockwise.
sets the maximum rate at which the labelled, PWM motor driving pitfalls Operation at low frequencies can also
motor speed increases. at higher frequencies, in some cases, be optimised using the curve adjust-
The maximum time to reach 100% driving a motor with a high PWM fre- ment, with jumper JP1 inserted to pull
duty cycle from zero is two seconds, quency can mean that the motor will the normally high RA5 digital input low
with 5V at TP2. A 2.5V setting will not start until the duty cycle is at 20%, (pin 2). Without the jumper inserted, the
give a one-second soft-start period, or even higher. RA5 input is pulled high via an internal
and so on. The curve adjustment sets the ini- pull-up current.
VR3 is the speed curve adjustment tial duty cycle when the speed poten- The curve adjustment when JP1 is
trimpot, with corresponding test point tiometer is rotated just clockwise from inserted allows for better feedback
TP3. This is monitored at the AN4 fully-anticlockwise. This adjustment control at very low duty cycles. The
input of IC1, pin 16. This allows the removes the dead zone from the speed adjustment reduces the motor snap-on
speed pot to be used over its entire pot. The curve adjustment range is from effect, where the feedback voltage sud-
range when the PWM frequency is set almost zero to a 33% initial duty cycle. denly rises with an increase of the
relatively high, and can also compen- Whenever the curve setting is non- PWM duty just off from zero. This
sate for the fact that motors can require zero, the software within IC1 expands adjustment sets a feedback offset value
so that feedback is ignored below the range into two halves, 0-2.5V and 2.5- with fully clockwise giving the same
specified speed setting. 5V. From 0V to 2.5V, motor disconnec- effect as fully anti-clockwise.
Trimpot VR3 is also used to enable tion checking is disabled. Above 2.5V, When the motor current feedback is
or disable motor disconnection detec- motor disconnect detection is enabled below a set value for more than about
tion. This is done by splitting VR3’s and the curve adjustment is reversed, 200ms, the motor is determined as being
disconnected. In this case, the PWM 2 and 1, plus a common connection, REG1 is a low-dropout automotive 5V
duty cycle is set to zero and the LED which we have connected to ground. regulator. It is capable of withstanding a
flashes at 2Hz. The other switch terminals connect reverse polarity voltage, so it provides
The motor will only start again after to the RA1, RB6, RB7 and RB5 digi- the circuit with reversed-supply pro-
it is reconnected, and the speed pot is tal inputs of IC1, respectively. All of tection. The maximum recommended
wound fully anti-clockwise. This pre- these pins except for RA1 are config- operating voltage at the input of REG1 is
vents erratic operation due to, for exam- ured in IC1 to provide a pull-up cur- 26V. So for use at up to 30V, ZD1 drops
ple, loose wires. rent. The RA1 input does not have such the voltage at the input by around 4.7V.
Motor disconnect detection is an option, so an external 10kΩ pull-up The dropout voltage for REG1 is typ-
optional, because unless the motor is resistor connects to 5V. ically 0.5V. That means it needs 5.5V at
set up correctly when used at high fre- These pull-ups hold the inputs high the input to ensure that the output is reg-
quencies, false disconnection events (at 5V) whenever the switch does not ulated. The addition of ZD1 means that
can cause nuisance shutdowns. This connect that terminal to ground. The 16 the minimum recommended voltage for
can occur if the curve is not adjusted possible combinations are decoded in the controller is 5.5V + 4.7V = 10.2V.
correctly, with a sufficiently high IC1, and the required PWM frequency We round this up to 10.5V to be safe.
duty cycle at the start of the speed is selected (see Table 1). Note that the controller and motor
pot rotation. positive supply connections are sepa-
Power supply rate, so the motor can be run at a differ-
PWM frequency options Controller power is supplied via CON1’s ent voltage if required.
Switch S1 is used to select the fre- terminals between GND and the con- That means the motor supply could
quency of the PWM drive for the motor. troller supply positive input. The sup- be outside the controller’s range, and
This is a 16-position rotary BCD (bina- ply current passes through zener diode the circuit will still work as long as an
ry-coded decimal) switch. There are ZD1, and the input of regulator REG1 is appropriate controller supply voltage
four switch terminals labelled 8, 4, bypassed with a 470nF capacitor. is applied. The two supply inputs can
Scope 5: switching back to half-bridge driving but bumping Scope 6: the single-ended drive with the higher frequency
up the frequency to 31.4kHz, you can see that the average suffers from the same rapid decay in current as shown in
current value is hardly affected. The current level averages Scope 4, except this time the average current is even lower
higher during the off-time due to the shorter off period. as it has less time to build during the shorter on-pulses.
Testing
Before inserting IC1 into its socket,
check the regulator operation by apply-
ing 10.5-30V between the 0V and the
controller positive supply terminals
on CON1.
Measure the voltage between REG1’s
metal tab and its right-most lead. You
should get a reading close to 5V (4.75
to 5.25V). If not, check that the input
voltage at the left lead of REG1 is at
least 5.5V.
If this reading is correct, switch off
the power and install IC1, making sure
it is oriented correctly, and none of its
leads fold under the body. If you used
a socket for IC2, plug it in now.
At this stage, it is a good idea to wire
potentiometer VR1 to CON2. You will
also need to insert the fuse to continue
testing. The fuse should be rated to Fig.2: the Speed Controller PCB is relatively compact and uses just five SMD parts:
suit the motor; if it is a 1A-rated motor, four resistors and MOSFET driver IC3. MOSFETs Q1 and Q2 and diode D1 attach
install a 1A fuse; for a 20A motor, use a to PCB-mounting heatsinks for cooling. During assembly, watch the polarity of the
20A fuse... and so on. three ICs, diode ZD1, the electrolytic capacitors and BCD switch S1.
Scope 7: with a PWM frequency just under 3kHz, there is Scope 8: with a PWM frequency of nearly 12kHz – the
sufficient time for back-EMF sensing. The motor voltage back-EMF voltage is barely visible just before the start
shoots up immediately after the MOSFETs switch off, then of the next pulse. It would be impractical to sample the
falls back to a lower plateau once the magnetic field has back-EMF voltage at this frequency for this motor, and
decayed and back-EMF starts to become dominant. impossible at higher frequencies.
TEACH-IN 3
£7.99
PRACTICALLY SPEAKING
fol l owi ng courses i n school s and
Surgery, EPE/PE’s regular clinic dealing with readers’ Powered Charger Versatile Theft Alarm pooky
PIC ‘N MIX
Star ti ng out wi th PIC mi crocontrol l ers
nics
Teach-
In FREE Circuits Frost Alarm ini hristmas ights
queries on circuit design problems – from voltage ro
FREE M
TEACH-IN 1 CD-ROM bo
rne
Publishing Ltd 201
0 CD-RO
t
W
1
TWO TEACH-INs FOR TEACH-I N 2
Elec
©
THE PRICE OF ONE!
TWO TEACH-I Ns FOR
The second section – Practically Speaking – Egg Timer ignal njector robe imple adio
THE PRI CE OF ONE!
The free CD-ROM provides cal
Plus:
MikroElektro
nika,
a broad-based introduction
a practi The fr ee CD-ROM pr ovi des a
Provides to PIC Microchip pe
introduction llers L-Tek PoSco
to electronics microcontro
for Windo
ws software pr ac t i c al i nt r oduc t i on t o PIC
components is covered. Finally, our collection of PIC’n’ Mix – starting out with the popular range of PIC
Ingenuity Unlimited circuits provides over circuit designs submitted by readers. microcontrollers and Practically Speaking – tips and techniques for project construction.
The - also contains the complete Electronics Teach-In 1 book, which
provides a broad-based introduction to electronics in PDF form, plus interactive The - also contains
qui es to test your knowledge and T NA circuit simulation software a limited Complete Teach-In 2 book, a practical introduction to PIC microprocessors
version – plus a specially written T NA Tutorial . ikroElektronika, icrochip and -Tek o cope software.
The Teach-In 1 series covers everything from electric current through to
microprocessors and microcontrollers, and each part includes demonstration circuits
to build on breadboards or to simulate on your PC.
£18.95
ELECTRONICS FROM THE PUBLISHERS OF
An el even p ar t t u t or i al
important electronics units that are currently studied in
many schools and colleges. These include, Edexcel
Us es i n exp en s i ve c i r c u i t
s i m u l at i on s of t w ar e free CD-ROM from each issue...
TE level awards and the electronics units of the
... so that’s another TWO Teach-Ins and
FREE M
CD-RO
What a Bargain!!
if not, open double-click
and
Explorer f
index.pd
This CD-ROM
Adobe®
requires
Reader™
from
an d w eb l i n k s
BA SE Mmag.co.uk
www.epe
ne Publishi
ng Ltd.
2011
Audio Out – an
CD
£8.99 R £8.99
ELECTRONICS
DV
ELECTRONICS and Circuit Surgery ELECTRONICS
The Teach-In 6 CD- FROM THE PUBLISHERS OF
by an ell – tate
also contains all TEACH-IN 6 on specialist circuits
TEACH-IN 7 FRE
TEACH-IN 8 CD-ROME SOFTWARE
RASPBERRY Pi ®
DISCRETE LINEAR CIRCUIT DESIGN
the necessary software A COMPREHENSIVE GUIDE TO RASPBERRY Pi
Practically Speaking – • Understand linear circuit design INTRODUCING THE ARDUINO
• Pi PROJECT – SOMETHING TO BUILD • Design simple, but elegant circuits
The - includes
• Hardware – learn about components and circuits
• Pi CLASS – SPECIFIC LEARNING AIMS
for the series, so that • PYTHON QUICKSTART – SPECIFIC PROGRAMMING TOPICS
the techniques of
• Learn with ‘TINA’ – modern CAD software
• Five projects to build: Pre-amp, Headphone Amp,
• Programming – powerful integrated development system
• Microcontrollers – understand control operations
• Pi WORLD – ACCESSORIES, BOOKS ETC
the files for
Tone Control, VU-meter, High Performance Audio Power Amp • Communications – connect to PCs and other Arduinos
• HOME BAKING – FOLLOW-UP ACTIVITIES
readers and circuit project building.
FREE
designers can get DVD-R
OM
ALL THE
SOFTWA
TEACH-I
RE
N6
FREE M
-RO
CD CIRCUIT
Teach-In 8
FOR THE RRY Pi
icrochip A
RE FOR
SERIES
SOFTWA 7
CH-IN
THE TEA
SERIES
martscope software.
building PIC-based projects
USB-PD Triggers,
Decoys and Testers
Left-to-right: the FNC88, WITRN UPD005, ZY12PDN-1 and XY-WPDT
A
PD trigger is an interface The trigger circuitry on the PCB uses attempt to change the supply voltage
circuit that can manage the two main chips: an STM32F030F4P6 to 12V. If the PD host has this voltage
negotiating protocols necessary microcontroller and a PBAFH device, available, it will switch its output to
to request the required voltage and which is likely the USB physical 12V, and the LED will change to green.
current levels from a USB-PD supply, layer interface. Further button presses will change the
as described last month. As soon as it There’s also a small pushbutton voltage to 15V (light blue), then 20V
is connected to a USB-PD compatible switch that can be used to select the (dark blue) – again, assuming the host
host, it engages with the host via the voltage and power level required can supply these voltages.
CC1 or CC2 channels to achieve the from the USB-C PD host, and an RGB If the host doesn’t have one of the
voltage and current levels that are LED to indicate the selected voltage/ voltages that is requested, then the
needed – assuming these are available. power level. LED will glow purple, and the voltage
Some of these modules are also When the ZY12PDN is first con- will stay at the highest voltage which
known as ‘decoy’ or ‘poll detectors’. nected to the PD host, the LED glows is available.
These terms all seem to mean much red to indicate the default 5V supply There’s also a ‘demo’ mode, where
the same thing as PD trigger. voltage. If you then press the button, the LED glows white and the supply
Another variant combines the func- it will attempt to select a 9V supply. voltage cycles through the available
tions of a trigger/decoy module with If the PD host has this voltage avail- levels at approximately 1Hz.
those of a USB-PD digital meter, so it able, it will switch its output to 9V, and If you plug the ZY12PDN into a host
can display the available or selected the LED will change to yellow. If you port that does not support USB-PD
voltage(s) and current(s). press the pushbutton again, this will voltage and power negotiation, after
We’ll start by looking at the small-
est, simplest and cheapest of the trig- The ZY12PDN-3 Reproduced by arrangement with
ger modules. PD trigger, SILICON CHIP magazine 2022.
shown enlarged www.siliconchip.com.au
ZY12PDN-3 ‘naked’ PD trigger for clarity. There
The ZY12PDN-3 module is tiny – see are two other
the photos. Everything is mounted on versions of this
a PCB measuring just 30 x 15mm, with module with
either a USB
the USB-C input socket at one end and
Type-A socket
a small two-way screw terminal block or no connector
at the other end as the power output. fitted instead
The ZY12PDN trigger module is of the screw
available in three versions, which dif- terminal block.
fer only in their output connector or
lack thereof. Instead of the screw ter-
minal block of the ZY12PDN-3, the
ZY12PDN-2 has a USB Type-A socket,
while the ZY12PDN-1 has no output
connector at all.
The front and rear view of the FNC88 module; you can just see the three function buttons at the bottom of the rear view,
along with the switch that connects the built-in PD chip to the CC1 pin.
The XY-WPDT is sold as a kit by Banggood, and only requires fitting the
components together with a screwdriver to assemble it; no soldering is necessary.
Useful links
USB-C https://w.wiki/nto
USB-PD https://w.wiki/34dT
https://bit.ly/pe-sep22-usbc1
Quick Charge https://w.wiki/34dU
www. poscope. com/ epe
- USB - PWM
- Ethernet - Encoders
- Web server - LCD
- Modbus - Analog inputs
- CNC (Mach3/ 4) - Compact PLC
- IO
- up to 256 - up to 32
microsteps microsteps
- 50 V / 6 A - 30 V / 2. 5 A
- USB configuration
- Isolated
Here’s what the assembled XY-WPDT module looks like. The two extra USB-C
sockets on either side allow the unit to operate in pass-through mode.
PoScope Mega1+
PoScope Mega50
From left-to-right we have the USB-C input, PPS mode LEDs (1V, 100mV and - up to 50MS/ s
20mV steps), K1 switch, and current indicator LED. The USB-C input is used - resolution up to 12bit
with the matching output connector on the opposite side to control and measure - Lowest power consumption
voltage or current. Pressing the K1 switch changes between displaying current - Smallest and lightest
- 7 in 1: Oscilloscope, FFT, X/ Y,
or voltage, while holding K1 just turns the screen and indicator LED off. Switch Recorder, Logic Analyzer, Protocol
K2 is used in conjunction with K1 to change the voltage setting, and is a bit more decoder, Signal generator
complicated to set, see: https://bit.ly/pe-sep22-xy
R
ecently, on the EEWeb Fig.1). A potentiometer has
A A
forum, user Kintaro posted a ques- a ‘wiper’ terminal which
tion about controlling resistance connects to a variable location Control input Control input
(R value) (wiper position)
electronically. ‘Right now, I have two on a resistance or chain of R R Wiper
values known, these are the voltage of a resistors. The resistance of
node (X volt) and a resistor (Y ohm). This the potentiometer (between
Electronically controlled resistance – Part 1B B
circuit needs to interpret X volt as X ohm, A and B in Fig.1) is fixed Single resistor (rheostat) Potentiometer
and then tune the adjustable resistor to Z and the control (mechanical
ohm (because the Y ohm resistance and or electronic) sets the value Fig.1. Electronically controlled resistors.
Z ohm resistance in parallel give us the of the resistance fromcontrolled
Electronically A to 1
resistance –1 Part11 1 1
X ohm resistance. The resulting circuit the wiper, and from B to the wiper. This = + + two + ⋯parallel
+
𝑅𝑅! 𝑅𝑅"For𝑅𝑅just # 𝑅𝑅$ 𝑅𝑅% resistors (as in
should work for all the values of known can be anything from zero to the A to Kintaro’s circuit shown in Fig.2) the total
values of the voltage node and the resistor.’ B resistance, with the two summing to resistance is:
The key thing here is the ability to control the A-to-B resistance. FETs naturally 1 1 1 𝑅𝑅"1𝑅𝑅# 1
a resistance with a voltage – the requirement form single voltage-controlled resistors= 𝑅𝑅+! = + + ⋯+
𝑅𝑅! 𝑅𝑅" 𝑅𝑅# 𝑅𝑅" 𝑅𝑅 +$ 𝑅𝑅# 𝑅𝑅%
for a parallel resistor is specific to Kintaro’s (rheostats), whereas digitally controlled
application and can be achieved if the resistors are available in both rheostat and In Kintaro’s application one resistor is
adjustable resistor can be set to the required potentiometer versions. fixed (say R1) and the other (R2) is varied to
𝑅𝑅" 𝑅𝑅!#
value. We will look briefly at this and then All components have limits to the range 𝑅𝑅#! = the desired RT. We can rearrange the
obtain
+ 𝑅𝑅!#
consider electronically controlled resistance of voltages and currents that they can above 𝑅𝑅 "−
equation to give the required R2 value
more generally. handle, but these may be more restricted to achieve a specified total resistance RT:
for electronically controlled resistors
𝑅𝑅" 𝑅𝑅!
Electronic control of resistance than similar value mechanical devices. 𝑅𝑅# =
There are a couple of widely used ways Electronically controlled resistors may have 𝑅𝑅 " − 𝑅𝑅!
of achieving an electronically controlled other restrictions such as the requirement This is not a linear function – see Fig.3 –
resistor (other approaches are possible). for one end to be grounded. which shows the R2 value required to obtain
First, field-effect transistors (FETs) can be Electronically controlled resistors could RT in the range 1 to 9Ω with R1 = 10Ω. If
used as voltage-controlled resistors. Both be considered in any application where a the original control voltage (X in Kintaro’s
JFETs (junction field-effect transistors) and mechanical variable resistor, potentiometer post) is linear, and R2 varies linearly with
MOSFETs (metal-oxide-semiconductor or trimmer might be used but you want to its control voltage, then it cannot be used
field-effect transistors) can be employed facilitate digital (computer/microcontroller) directly to linearly control RT (in Fig.2).
for this purpose, but JFETs are quite control and thus increase a designs To achieve a linear control, it would be
common for this application. Second, functionality. Voltage-controlled resistors necessary to map the input control voltage
there are numerous digital potentiometer are commonly used to provide analogue (Kintaro’s X) to the required control voltage
ICs available. These typically contain a control of amplifiers’ and filters’ (gain and for R2. This could possibly be achieved
network of resistors and switches and are frequency) response in applications such by a microcontroller measuring voltage
designed for use with microcontrollers, as automatic gain control (AGC), adaptive X (via an ADC) and finding the required
often via a serial bus such as SPI or filters and voltage-controlled oscillators. resistor control voltage, either using a
I2C. The digital instruction determines look up table, or via calculation with the
the state of the switches, which in turn Parallel resistors above equation. A DAC could set the R2
control the resistance. Kintaro’s EEWeb post describes a parallel control voltage.
As with mechanical variable resistors, combination of a fixed resistor with an
electronically controlled resistors can be electronically controlled resistor (see
either single resistors (sometimes referred Fig.2). We will look briefly, and in very Control
voltage
to as a ‘rheostats’) or potentiometers (see general terms, at this scenario. One of RT R1 R2
the best-known formulas in electronics is (fixed) (voltage
controlled)
the total resistance RT of a set of parallel
Simulation fi les
Electronically controlled resistance
resistors– Part 12, R3 …RN. The reciprocal
R 1, R
Most, but not every month, LTSpice of RT is the sum of the reciprocals of
is used to support descriptions and parallel resistors:
analysis in Circuit Surgery.
The examples and files are available Fig.2. Fixed resistor R1 in parallel with
1 1 1 1 1 a voltage-controlled resistor R2 giving a
for download from the PE website. = + + + ⋯+
𝑅𝑅! 𝑅𝑅" 𝑅𝑅# 𝑅𝑅$ 𝑅𝑅% total resistance RT.
Fig.4. LTspice circuit for plotting JFET characteristics Fig.5. Typical JFET characteristics showing the ‘ohmic’ (left) and
by varying VGS and VDS. saturation (right) regions.
D NA –
D NA –
IG E
IG E
PE
!
Practical Practical Practical
PE
!
Practical
ES M
N
ES M
N
Practical
N NEW E
N NEW E
–
–
EW
EW
Electronics Electronics Electronics Electronics Electronics
The UK’s premier electronics and computing maker magazine The UK’s premier electronics and computing maker magazine The UK’s premier electronics and computing maker magazine The UK’s premier electronics and computing maker magazine The UK’s premier electronics and computing maker magazine
Circuit Surgery Make it with Micromite Audio Out Circuit Surgery Make it with Micromite Audio Out Circuit Surgery Make it with Micromite Audio Out Flowerpot speakers! PIC n’ Mix Circuit Surgery Make it with Micromite Audio Out Circuit Surgery
Timing and metastability Build an RGB display project Construct a Timing and metastability Fun display project How to make a Transformers Accessing Internet data Superb microphone A low-cost route to Software tools for Understanding Analogue inputs and Constructing the PE Micro-Cap 12
in synchronous circuits using a Micromite Plus transistor radio in synchronous circuits using a Micromite Plus transistor radio and LTspice with your MKC preamplifier high-quality Hi-Fi the PIC18F Differential amplifiers using servomotors Theremin amplifier simulator review
Frequency Reference Mastering Nutube Guitar WIN! Touchscreen WIN! Ultrabrite LED WIN! Don’t miss Random WIN!
WIN!
Signal Distributor RFID tags for Microchip Overdrive and Superb PE PIC Microchip Wide-range Microchip bike light Microchip
Explorer 16/32 our Super Number Microchip
MPLAB Starter Kit
PIC24F LCD and
your projects
Curiosity HPC
Development Distortion Pedal Development USB Curiosity
RCL Box
MCP19114 Flyback
Standalone
Development
Kit Summer Sale! Generator for Serial Memory
Products
Development
Board
WIN!
Board Board
Evaluation
Board WIN! WIN!
Clever Controller
Meet the for dumb chargers
Meet the Cricket: Mastering stepper Micromite
making IoT designs motor drivers Explore-28 Hi-Fi amp on
super easy! the cheap!
Programmable Robot Buggy
Thermal Programmable Ultrasound Completing the
Thermal Roadies’ Test sensing! High-power 45V/8A
Regulator Signal Generator
Regulator Variable Linear Supply
Make your own PCBs Tunable HF Making a Fun LED
with our precision Preamplifier Building the splash with Christmas
Solder Reflow Oven Fabulous low-cost Low-noise
Concrete speakers! NeoPixels! Tree offer!
theremin PSU
PLUS! PLUS! PLUS! PLUS! PLUS!
Techno Talk – Tin whiskers scourge Apr 2021 £4.99 Techno Talk – No blame, no shame? Mar 2021 £4.99 Techno Talk – Bad science and good Jun 2021 £4.99 Sep 2020 £4.99 Techno Talk – Triumph or travesty? Dec 2020 £4.99
Cool Beans – Even cooler ping-pong ball lights!
www.electronpublishing.com @practicalelec practicalelectronics www.electronpublishing.com @practicalelec practicalelectronics www.electronpublishing.com @practicalelec practicalelectronics www.electronpublishing.com @practicalelec practicalelectronics www.electronpublishing.com @practicalelec practicalelectronics
R1
Input
+ U1
Output
–
R2
J1
R3 R4
Control
R5
L
ast month, we showed how easy it is to set
up a PicoMite BackPack. We focussed on the 2.8-inch
320x240 touch TFT module, as this has the same-sized
screen which was used in the original Micromite BackPack
(and thus in many PE projects). In addition, we showed how
to use the bigger 3.5-inch touch TFT with a higher resolution
of 480x320. However, we also mentioned that there are many
smaller (and cheaper) screens that can be used, which are
handy if you only want to show a small amount of data, for
example, the time. Since last month, we have received numerous
emails about using these smaller screens; in particular, asking
for help with the OPTION settings. Therefore, we will begin
this month with a useful guide covering some of the more
popular smaller screens. Fig.1. The Waveshare Pico-LCD-0.96 display module makes for a
While setting up the hardware for this task, I simply connected compact PicoMite BackPack. It has a really nice IPS screen with a
a PicoMite to a display, wrote a short program to show the time, resolution of 160x80.
and left the unit on test while setting up the next PicoMite. for delivery from the Far East). The only other parts you will
Fortunately, I had recently received a delivery of new RPi Pico need are probably already in your spare parts draw: an NPN
modules and display modules; so I was able to set up multiple transistor, a couple of resistors, a single IR transmitter LED,
‘clocks’ and position them side by side. Note that no RTC and as many IR receivers as you have PicoMite BackPacks.
(real-time clock) was used in any of these clocks. Instead, each Let’s begin by showing the OPTION settings to create some
clock was configured using just MMBASIC’s built-in TIME$ PicoMite BackPacks with smaller screens.
variable. All I did was set TIME$ at the command prompt to
a value as close to the exact time as possible. Everything was 0.96-inch (160x80) IPS screen
going well, but then my 10-year-old son made a comment; he This is one of my favourite small screens. It produces a very
noticed that the clocks were all showing a slightly different clear image with vivid colours, and a great viewing angle. It is
time and asked, ‘which clock is actually correct?’. available from many suppliers as a standalone screen (and is
I gave the ‘time is relative’ answer, and then went on to tell the same screen we used back in MIWM, Part 9, PE, Oct 2019).
him that probably none of the clocks were showing exactly It is also available as a Pico plug-in module (see Fig.1 from last
the correct time. However, it gave me an idea for a topic that I month – top-left image). If you search online for ‘Waveshare
had planned for a future article – infrared (IR) communication. Pico-LCD-0.96’ you will see that this plug-in display module
So, the second part of this month’s article will demonstrate costs around £7.
how to synchronise several clocks to show the same time by With the display module and PicoMite connected to each
using MMBASIC’s built-in IR SEND command. Essentially, other, you will need to enter these two configuration settings
we will show you how to add an IR transmitter to one clock at the command prompt:
(the ‘master clock’), and then add an IR receiver to each of the
other clocks so that they can all be set to show the same time. OPTION SYSTEM SPI GP10,GP11,GP28
For this article you will need at least two PicoMite BackPacks OPTION LCDPANEL ST7735S,L,GP8,GP12,GP9,GP13
(ideally three or more), but do remember that a PicoMite costs
less than £4, and displays start from only around £5 (and Once these are set, you will find all the usual MMBASIC
much less from the likes of eBay if you’re prepared to wait graphical commands will work with this screen. To test this,
try it with something like: CLS RGB(CYAN). If you do not
see the screen change to the appropriate colour, type OPTION
Micromite code LIST and check the parameter values are entered as shown
The code in this article is available for download from above. Any errors will need to be fixed – you do this by first
the September 2022 page of the PE website. typing OPTION LCDPANEL DISABLE and then either OPTION
SYSTEM SPI DISABLE (if you made an error with one of those
RUN the above program to see the time displayed in the centre 0.91-inch (128x32) OLED
of the screen; the result is shown in Fig.1. It is also worth OLED (organic light-emitting diode) displays are made up of
making the program automatically start up on power-up, so individually controlled LEDs, so they don’t need a backlight.
stop the program (Ctrl-C), type OPTION AUTORUN ON at the Hence images on an OLED are generally superior to those on
command prompt, and then RUN the program again. Note that an LCD. They have high contrast, making them easy to read,
if power is removed, then the TIME$ variable will be reset to even compared to the older-style LCD character modules, such
’00:00:00’ at power-up. This is useful because it will better as the 16x2, 20x2 and 40x4 displays.
demonstrate the IR time-synchronising that we will cover Several Pico plug-in OLED display modules are available, but the
shortly. Fig.2 is a screen grab of the OPTION settings, and also current ones are not directly supported by the PicoMite because
shows the program listing (with a commented line at the start the relevant display drivers are not built into MMBASIC. However,
showing which screen it is). there is nothing to stop us from using a standalone OLED module
that is supported by MMBASIC. For example, if you search for
1.3-inch (240x240) square TFT ‘Waveshare 0.91-inch OLED’ you will see a compatible OLED
Another useful Pico plug-in display module is the Waveshare module that costs around £5. Note that this OLED module is not
PICO-LCD-1.3 (top-right, Fig.1 in last month’s article). In a colour OLED; instead, it is mono (single colour), typically white
addition to the 240x240 screen, there are four pushbuttons, or blue. This display is easy to interface to a PicoMite since there
and a digital joystick (up, down, left, right and select). The are just four wires to connect (refer to Fig.4):
cost of this display module is around £8. To configure this
display, enter the following configuration settings at the OLED PicoMite
command prompt: VCC 3V3
GND GND
OPTION SYSTEM SPI GP10,GP11,GP28 SDA GP0
OPTION LCDPANEL ST7789,L,GP8,GP12,GP9,GP13 SCL GP1
You will notice that the settings are almost identical to To configure this OLED module, enter the following configuration
the 0.96-inch screen above – the only difference being the settings at the command prompt:
display driver parameter: ST7789 instead of ST7735S. This
is something I like about the Waveshare display modules; OPTION SYSTEM I2C GP0,GP1
they try to use consistent GP pin numbers for identical pin OPTION LCDPANEL SSD1306I2C32,L
functions across their range.
With the 1.3-inch display configured properly, quickly test As before, set the TIME$, set OPTION AUTORUN ON and enter
it: set TIME$ and enter the following five-line program: the following program code:
Adding IR
We are now going to discuss how to add IR functionality to
the clocks so that we can demonstrate how to synchronise Fig.7. The Waveshare 1.28-inch round LCD PicoMite clock.
1
GP22
Slave clocks
Each slave clock just needs a
standard TSOP IR receiver connected
GND
to any spare GP input pin – in this
case we will use GP22. Fig.10 shows
Fig.8. This simple IR the connections but note that we
transmitter circuit uses must connect the TSOP IR Rx to a
an NPN transistor, a 3.3V supply rather than the more
couple of resistors, and usual 5V supply. The reason for this
an IR Tx LED. is that the maximum input voltage
on any input pin (here GP22) is
Fig.9. A Pico-LCD-0.96 master clock built on an expander
3.6V. So, by supplying 3.3V to the TSOP, we will keep the input
module allows easy connection via three DuPont leads to the IR
voltage on GP22 below the 3.6V limit and not damage the Pico.
Tx circuit (which here has been assembled on a breadboard).
Connect a TSOP IR receiver to GP22, GND and 3V3, as
Button B is used to send the time data via IR.
shown in Fig.10. We used three female-female DuPont leads
with the TSOP inserted at one end, and the other end used to that it is actually the Epoch time that is transmitted via IR, and
connect to a 1.3-inch PicoMite clock (that was moved onto an the SlaveClockIR code converts it back into a recognised date/
Expander module – see Fig.11). The program code can then time. We do this because it means we only need to transmit
use the standard IR interrupt (set up with the two commands: five 7-bit key code values to transfer both date and time (refer
SETPIN GP22, IR and IR DevCode, KeyCode, myIrInt). to code comments for more details).
This will result in the program code jumping to a subroutine I hope this has shown you how easy it is to transmit a few
(here called myIrInt) whenever an IR signal is detected. We bytes of data between PicoMites. Why not have a think about
then put the IR receiving code in this subroutine to process, how you can use IR in your project other than to decode
check, and if necessary, update the TIME$ variable. button presses from an IR remote control. If you come up with
anything interesting, then do drop us an email and maybe we
Software can mention it in a future article.
The two required program listings are a bit too long to print
line-for-line here, so we have made two downloads available Next time
at the September 2022 page of the PE website. Download the Next month, we will continue our exploration of the PicoMite
MasterClockIR.txt and SlaveClockIR.txt files and load them and show you how to use a GPS receiver (another low-cost Pico
into the relevant PicoMite clocks. RUN both programs, and if plug-in module) to
using a PICO-LCD-0.96 as the master clock, press the ‘B’ button create a simple and
to sync and update any slave clock that is within range of useful tracker. Questions? Please email Phil at:
the master clock. If you are not using a PICO-LCD-0.96 as the Until then, stay contactus@micromite.org
master, you will need to modify the start of the MasterClockIR safe, and have FUN!
program to allow for a suitable trigger (see comments within
the code for how to do this).
Epoch time
If you take a closer look at the program code, you may spot
two new commands: EPOCH(now) and DATETIME$(n). The
first command converts the current date/time into ‘Epoch
time’ (a number which represents how many seconds have
elapsed since midnight GMT on 1 January 1970). The second
command converts an Epoch time value into the usual date/
time format. Why use these? Epoch time makes it much easier
to do date/time calculations. For example, to add an hour onto
the current time, convert the current
IC1 time into Epoch time, add 3600
TSOP 4xx
IR receiver and convert back to normal date/
time. This way, we don’t have to
GP22 3V3 worry about roll-over for something
awkward like 31 December 1999
GND at 23:34:56 (which would mean
rolling over date, month and year,
Fig.10. The IR receiver as well as the hour to ‘00’) all very
comprises just a single tricky when you start looking into Fig.11. A Pico-LCD-1.3 slave clock built
component – a TSOP it – but very easy with conversion on an expander module allows easy
IR Rx. Ensure it is to an Epoch-time value. connection to the TSOP IR Rx via three
connected to the 3.3V Further examination of the DuPont leads.
supply – not 5V. MasterClockIR code will reveal
A
s is usually the case, I’m from nearby nations, including Sweden and potential hazards like spills and report-
currently bouncing off the walls Finland. I’m also hoping to see represen- ing them, and... the list goes on.
with excitement. Sometime last tatives from a company called Testonica Similarly, when it comes to security ap-
year, I may have mentioned that I’ve (testonica.com), which is headquartered in plications, EVEs can autonomously roam
been invited to give the keynote pre- the Baltic country of Estonia. These guys around buildings looking for unauthorised
sentation at the FPGA Forum 2022 in and gals have a tasty technology called intruders with unrecognised faces, check-
Norway (www.fpga-forum.no). This Quick Instruments. If you are designing a ing doors are locked and lights are turned
auspicious affair is attended by all of circuit board featuring an FPGA, all you off… and so on and so forth. In fact, ear-
the movers and shakers in Norwegian have to do is provide a high-level view of lier this year, the American security com-
programmable space (where no one can the system – including the types of other pany ADT signed the world’s largest order
hear you scream), including designers, devices on the board and their pin maps to date for humanoid robots by ordering
project managers, technical managers, and register maps – and Quick Instru- 140 EVEs from Halodi.
researchers, final-year students and ments automatically generates and com-
FPGA vendors. piles a corresponding firmware test suite, It all starts with a single servo
thereby allowing the FPGA to perform a As amazing as EVE is, such creations all
Norway Ho! sophisticated board-level self-test. start with a single actuator like a servo,
This year’s Forum was originally intended which is the point you and I currently
to take place in February but... COVID... On the eve of a new era find ourselves in our discussions. As dis-
so it was rescheduled for September. The The FPGA Forum has traditionally been cussed last month, we started with a 9g
reason this is particularly poignant for held in the city of Trondheim, which is hobby micro servo, where the ‘9g’ refers
me because I previously gave the key- the third-most populous municipality in to the approximate weight of the servo,
note presentation at this exceptional Norway. Among many other things, Trond- not the amount of torque it can provide.
event deep in the mists of time we used heim is home to the Norwegian University Originally, I was planning on taking
to call 2012. On the one hand, that’s only of Science and Technology (NTNU). There one of these bodacious beauties apart to
10 short years ago, which would be but are two reasons I mention this here. First, show you what’s inside, so I ordered a set
a trifling hop in my time machine if I the day before my keynote, I’ll be giving
could ever get the little scamp working a guest lecture to a gaggle of MSc electri-
(you simply can’t get the parts where I cal and electronic engineering students
live in Huntsville, Alabama). On the other at NTNU (www.ntnu.edu). Second, the
hand, technology has been racing along, company Halodi Robotics (www.halodi.
as is its wont, and much has changed. com), which I introduced in my previous
For example, some FPGA companies that column (PE, August 2022), is headquar-
were with us in 2012 (eg, TierLogic and tered in Norway and their EVE humanoid
Tabula) have given up the ghost, bitten robots (Fig.1) can be found in most Nor-
the dust, and shuffled off this mortal coil wegian universities. I’m hoping an EVE
(I never metaphor I didn’t like). Contrari- will deign to attend my lecture, in which
wise, some feisty newcomers (eg, Efinix case you can bet your cotton socks I’ll be
and Renesas) have decided to scamper taking photographs and reporting further
over to the bar and join the party. in a future column.
Oh yes, and there’s also the fact that we EVE is human-sized and has 23 degrees
are now up to our metaphorical armpits of freedom. Boasting two-arm manipula-
in artificial intelligence (AI), machine tion, EVE can handle an 8kg payload with
learning (ML) and deep learning (DL). each arm. EVE can also squat down to pick
Plus, we are being inundated with new things up off the floor or out of cupboards
flavours of reality (I’m a sucker for straw- and reach up to place objects on shelves.
berry myself), including augmented real- The amazing thing for me is that EVEs
ity (AR), diminished reality (DR), virtu- are already deployed and working around
al reality (VR) and augmented virtuality the world in applications ranging from
(AV) to name but a few. Phew! Suffice it retail to security. In the case of retail, for
to say that I have little doubt I’ll manage example, EVEs can perform tasks like
to scrape together something to talk about roaming a supermarket’s aisles, spot-
(much like my dear old mother, the real ting out-of-place items, and returning
trick is to get us to stop talking). them to their rightful locations, restock-
Oftentimes, in addition to the Norwegian ing shelves, gathering items for remote Fig.1. EVE the humanoid robot. (Image:
contingent, attendees to the Forum come shoppers to pick up later, identifying Halodi Robotics)
When I placed this card keep on saying to myself, ‘But this other
Fig.4. Example Knob Circuit program. under the rotating arm on top stuff is soooo interesting!’
of the servo and ran the pro- For example... the term ‘simple machine’
When we come to the main loop, we gram above, turning the pot from one ex- refers to a mechanical device that can be
start on Line 15 by reading the value treme to the other caused the servo arm to used to change the direction or magni-
from the pot into our PotVal variable. move only 90°. I changed the attach() tude of a force. The six classical simple,
Since the Arduino Uno has a 10-bit ADC method’s min and max arguments to be 700 as defined by Renaissance thinkers, are
(analogue-to-digital converter), this will and 2300, respectively. This resulted in an the lever, wheel and axle, pully, inclined
result in values between 0 and 1023. The approximately 135° swing of the servo arm. plane, wedge and screw.
write() method provided by the Ar- Finally, I tried the servo library’s default I could waffle on about these little beau-
duino’s servo library requires values in values of 544 and 2400, which resulted in ties for ages, but we have other fish to fry.
the range 0 to 180, corresponding to 0° something close to a 180° swing, although Of particular interest to us here is the fact
to 180°, respectively. Thus, on Line 16, I did detect little ‘graunching’ sounds at that gears may be considered simple ma-
we use the Arduino’s map() function to the extremities of the movement. chines that consist of two or more wheels
convert the 0 to 1023 values read from This left me perplexed and puzzled. equipped with interlocking teeth such that
the pot into their 0 to 180 equivalents. On I can accept a little variance, but why when one gear is rotated any other inter-
Line 17, we write this new value to the would the data sheet specify min and locked gears rotate in the opposite direction.
servo, and on Line 18 we insert a 15ms max values of 1000 and 2000 when the It’s probably worth noting that some
delay to give the servo time to respond. servo actually requires values of 544 and people – especially in the UK – informally
2500? (If you have any thoughts on this, refer to gears (aka gearwheels or cogwheels)
A puzzling poser I’d love to hear them.) as cogs, but the term ‘cog’ officially denotes
In Fig.3 you’ll see a small circle of card an individual tooth on the gear.
marked out in 45° angles in the lower Not so simple Although they may appear simple, there’s
left of the image. This is just something I fear this is the point in this article where much more to gears than meets the eye.
I threw together for the purposes of these we may expect some gnashing of teeth We could spend weeks delving into their
discussions. If I had been doing this in and rending of garb because our illustri- intricacies, but we won’t because I can feel
earnest, I would have created a more ous publisher, Matt Pulzer, keeps on tell- Matt’s all-seeing eye starting to swing in
accurate tool divided into 5° segments. ing me to ‘stick to the electronics’ and I my direction.
L R
L
ast time (July 2022) we response. However, no component is with the windings. Next, we have iron loss-
looked at the uses and advantages perfect, although power transformers es (core losses) due to eddy currents and
of one of the oldest components come close in terms of efficiency. Audio hysteresis. Energy is lost by the emission
in electronics – the transformer. This transformers have very real frequen- of stray magnetic fields, which is worse
month, we will examine the limitations cy response limitations at each end of for standard transformers compared to
of real, as opposed to ideal transformers, the audio spectrum and because of the toroidal transformers. These losses are
as well as exploring some common audio way induction operates – depending real. The old crude doorbell transformer
transformer applications. on a rate of change of magnetic flux – in my house continuously dissipated a
transformers cannot pass DC, which is significant 2W of heat. Replacing it with
Transformer equivalent circuit generally a good thing in audio. The lim- a toroid eliminated this energy loss. Over
and ‘parasitics’ itations of a real-world transformer lead 22 years I paid £85 for a lot of electrici-
The theoretically ideal transformer has no us to the transformer equivalent circuit, ty units (385kWh) to run a doorbell that
losses and an infinitely wide frequency which takes account of the non-ideal only rang for around three seconds a day!
Fig.10. No-waste E and I shaped laminations. These are Fig.11. Toroidal transformer cores are wound from a long strip
normally inserted alternately (interleaved) into the wound bobbin. of steel into a ring.
+30V
+
47µF
2.2kΩ 12kΩ 1.0kΩ 4.7kΩ 10V 1.2kΩ
0V
820pF
DCR
2N1711 5Ω
82µF
+
I1 10Ω
TR2 2N3055
BC184 22kΩ VA1040
50Ω 150Ω
CT
TR1 NTC 27Ω 1.0Ω
BC184 2.5W
10µF 10kΩ
+
22kΩ 2N1711
Input
100kΩ
+
1.2kΩ
82µF I2
1500µF
+ 150µF 50V
DC trim 10kΩ I1 + I2
on driver
stage TR2
100kΩ 2N3055
10Ω
10Ω 8-15Ω
+
1.0kΩ 4.7kΩ 330Ω VA1040 100nF
220pF 47Ω 47µF 150Ω 1.0Ω
1W 50Ω
50kΩ NTC 27Ω 2.5W
0V
820Ω
1W
Fig.14a. The circuit of the Rogers Ravensbourne amplifier used two emitter followers with their currents flowing in opposite directions
to cancel DC magnetisation currents. The sound of this simple amplifier circuit was highly regarded in 1979. See inset photo Fig.14b.
+
There is a kink in the BH curve of all magnetic mate- gain control A-log R11
rials due to hysteresis. This is where a reverse force 1.5kΩ
DC current
Transformers do not like DC current in the windings as it
eats up the device’s saturation headroom. Magnetic induc-
No Zobel network Zobel network, C too high
tion voltage is proportional to rate of change of magnetic
flux, so the lower the frequency the less efficient it gets. DC
is zero frequency. If DC current has to be accommodated,
One cycle
of slight such as in the output transformer of a single-ended class A
overshoot amplifier, a ‘resistance’ needs to be inserted in the magnet-
ic circuit to limit the flux which is analogous to electrical
Optimum Zobel values Zobel network, R too high (not enough current. This is achieved by introducing a gap in the circuit.
damping – ringing moves to lower frequency)
In the case of EI laminations, this can be achieved by a butt
joint between the lumped ‘E’ and ‘I’ laminations, as shown
Resonance
dB
(no load) in Fig.13. A plastic spacer can be inserted to increase the
Optimum Zobel size of the gap if necessary. A side effect of this is to reduce
network the inductance. Clever circuits have been devised to cancel
Too much
compensation out the magnetisation of DC currents by running equal cur-
(C too high) rents in opposite directions in the windings. This is one of
the great benefits of push-pull operation. It was added to the
f (Hz)
driver transformers of the Bowes transistor amplifier and the
Typically 30kHz – 90kHz
Rogers Ravensbourne, as shown in Fig.14.
Fig.16. Adding a Zobel network damps the high frequency Capacitance and leakage inductance
resonance. The values have to be determined empirically by Capacitive parasitics are responsible for causing high-fre-
feeding a 1kHz square wave into the transformer primary and quency roll-off. At the upper end of the response curve these
tuning out the ringing on a ‘scope. parameters often form a resonance (see Fig.15) similar to an
C4 R9
100µF+ 1.0kΩ TR3
R10 OC42
0V 820Ω
TR5
OC22
TR2
OC42
1.65+1.65:1
TR1 R14 R15 R18 3W
OC42 3.9kΩ 1.2kΩ 560Ω
C1 R16 R19
100µF 1.2kΩ 560Ω
+
R11
820Ω
Input TR6
C3 R4 OC22
100µF+ 3.3kΩ TR4
OC42
R20
R2 R5 R6 R12 1.65Ω
12kΩ 22Ω 8.2kΩ 1.0kΩ 10%
5W
0V
R21 All resistors 0.25W, ±10% unless otherwise stated
560Ω Electrolytic capacitors 12V DC working
Fig.18. a) (above) Mullard 5W class-A transistor amplifier circuit from 1961; b) (below) I have the output transformers and transistors
for this design and will build one for its historical and teaching value. Apparently, they sounded quite good.
transforms the load imposed on its secondary to a suitable one
for the driving device – we looked at this last time. A typi-
cal transformer ‘matching circuit’ is shown below in Fig.17,
a good valve amplifier using the trusted (and still available)
EL84 output valve, which needs a 5kΩ load. This calls for a
turns ratio of 40:1 to match a 3Ω loudspeaker. The result is
an impedance ratio of 1600:1. Note that with a 3Ω loudspeak-
er this is reflected back to the primary, that is transformed
to 1600 × 3 = 4800Ω. OEP do a suitable audio transformer.
If an 8Ω speaker were to be used then an impedance ra-
tio of 625:1 would be needed, giving a load of 5kΩ. Working
backwards, the square root of the impedance ratio is taken to
get the turns ratio, giving 25:1. I once found a box of cheap
PL84 valves used for old TVs. These have a relatively low-
er impedance, so when designing an output circuit around
them I dropped the HT voltage and transformer ratio to 17:1
to produce a 2.4kΩ impedance.
As an interesting aside, early transistor amplifiers brief-
ly used output transformers (Fig.18) but as their output
current capability increased it became possible to drive
loudspeakers directly.
Output transformers do tend to be big because they have to
under-damped low-pass filter. This effect is usually suppressed transmit significant power. A 20W transformer may weigh a
with a series RC circuit called a Zobel network, named after couple of pounds (1kg). Cores are normally grain-orientated
the telecoms engineer who invented it – see Fig.16. silicon iron for high power handling. Negative feedback is
often applied around output transformers to reduce the dis-
Output transformers tortion and widen the frequency response. However, there
In pre-semiconductor days, valves were the only audio am- is a limit to the amount of feedback that can be applied due
plifying devices available. They are high-voltage (90 to 800V) to phase shifts associated with the transformers high- and
low-current (10 to 100mA) devices, which means a high out- low-frequency roll-offs.
put impedance (Zout) of around 1500 to 10,000Ω. Moving-coil For class-A stages, output transformers enable the greatest
loudspeakers are the opposite, having a low-impedance, typ- theoretical efficiency to be achieved of 50%. (Fig.19a) With-
ically 3 to 16Ω input impedance (Zin). It is not possible to out a transformer, using a push-pull constant-current load
wind a reliable 5000Ω speaker voice-coil, so the only solu- the maximum possible efficiency drops to 25%. With a fixed
tion to this dilemma is an output matching transformer which current source or a simple loudspeaker load it’s 12.5% and
+
–630mV
Input 1000µF
lower volumes it’s even worse.
–2.5V 3V
with RC coupling (Fig.19e), it’s a paltry
100µF 100µF .
. 8.3% with half the audio power going
15V + +6V et 0.5W
into the RC network resistor. The high
0V efficiency in the transformer circuit oc-
Negative feedback curs because the transformer has a high
AC load resistance and a small DC re-
a ye anguard onitoring unit theoretical e iciency o ractical sistance. This means the output device
e lace trans or er ith odulated
sees the full power-rail voltage and the
constant current source VC VC resulting AC swing is twice that.
25% – 30% 12.5%
efficiency efficiency
–1 Input transformer
V = VC V = VC
Moving to the ‘other end’ of an audio
+
om
ow
Sowter 3195 +15V
1:7 o l
XLR input wo C4
1 o 3 + 8
3 220µF
+
IC1a 1
C6
1 R1* R2* 2 –5532 22pF
C3
2 22pF
R8
C1*
150pF R5 C5 R6
*Alternative transformers R4
CW 220µF R9
6 +
+
0V
Fig.20. Transformer-coupled microphone pre-amp. Note how a centre-tap can provide a lossless phantom power connection. Whole
circuit gain: +14dB to +70dB. (Based on a Steve Dove design).
R1 FM424 R4 Output
Nї 1.34:1 Nї
1 1 FM424
DCR DCR NKT218 1.34:1
C1
33µF
OC71
+
Input
R2 R3 C2 R5 R6 C3
Nї Nї +100µF Nї ї + 100µF
0V
Positive earth
Interstage transformers
When amplifying devices were very expensive it was essential
to maximise the gain from each stage, so an impedance-match-
ing ‘interstage transformer’ was employed between stages.
These disappeared from valve amplifiers around 1940, only
to reappear again in the early days of expensive transistors.
These transformers were also called driver transformers, where
dual secondaries were used to provide the phase splitting for Your best bet since MAPLIN
push-pull output stages. A medium level of power is needed,
around 20-200mW, so Radiometal is normally employed for
Chock-a-Block with Stock
Visit: www.cricklewoodelectronics.com
Or phone our friendly kn owledgeable staff on 020 8452 0161
Components • Audio • Video • Connectors • Cables
Arduino • Test Equipment etc, etc
PCBs for most recent PE/EPE constructional projects are available. From the July 2013 issue onwards, PCBs with eight-digit codes
have silk screen overlays and, where applicable, are double-sided, have plated-through holes, and solder mask. They are similar to
photos in the project articles. Earlier PCBs are likely to be more basic and may not include silk screen overlay, be single-sided, lack
plated-through holes and solder mask.
Always check price and availability in the latest issue or online. A large number of older boards are listed for ordering on our website.
In most cases we do not supply kits or components for our projects. For older projects it is important to check the availability
of all components before purchasing PCBs.
Back issues of articles are available – see Back Issues page for details.
All prices include VAT and UK p&p. Add £4 per project for post to Europe; £5 per project outside Europe.
rders and ay ent should e sent to
Practical Electronics, Electron Publishing Ltd
113 Lynwood Drive, Merley, Wimborne, Dorset BH21 1UU
Tel 01202 880299 Email: shop@electronpublishing.com
On-line Shop: www.epemag.com
he ues should e ade aya le to ractical lectronics (Payment in £ sterling only).
NOTE: ost oards are in stoc and sent ithin seven days o recei t o order lease allo u to days delivery i e need to restoc .
PRICE £8.99
• Digital measurements plus a logic probe
• Frequency measurements and a signal generator
• Component measurements plus a semiconductor
junction tester
PLUS...
YOUR GUIDE TO THE BBC MICROBIT
A LOW-COST ARM-BASED SINGLE-BOARD
COMPUTER
Teach-In 9
Get Testing
This series of articles provides a broad-based introduction to choosing and using a wide range © 2018 Wimborne Publishing Ltd.
www.epemag.com
of test gear, how to get the best out of each item and the pitfalls to avoid. It provides hints
and tips on using, and – just as importantly – interpreting the results that you get. The series
deals with familiar test gear as well as equipment designed for more specialised applications.
The articles have been designed to have the broadest possible appeal and are applicable to all branches of electronics.
The series crosses the boundaries of analogue and digital electronics with applications that span the full range of
electronics – from a single-stage transistor amplifier to the most sophisticated microcontroller system. There really is
something for everyone!
Each part includes a simple but useful practical test gear project that will build into a handy gadget that will either
extend the features, ranges and usability of an existing item of test equipment or that will serve as a stand-alone
instrument. We’ve kept the cost of these projects as low as possible, and most of them can be built for less than £10
(including components, enclosure and circuit board).
Practical
Electronics BACK ISSUES
Practical Practical Practical Practical Practical Practical Practical
Electronics Electronics Electronics Electronics Electronics Electronics Electronics
The UK’s premier electronics and computing maker magazine
The UK’s premier electronics and computing maker magazine
The UK’s premier electronics and computing maker magazine
The UK’s premier electronics and computing maker magazine
The UK’s premier electronics and computing maker magazine
The UK’s premier electronics and computing maker magazine
The UK’s premier electronics and computing maker magazine
Circuit Surgery Audio Out Circuit Surgery
Make it with Micromite Audio Out KickStart Make it with Micromite
Circuit Surgery Audio Out Cool Beans Circuit Surgery
Make it with Micromite Audio Out Wind turbine Circuit Surgery
Electronic Building Blocks Audio Out Circuit Surgery
Make it with Micromite Audio Out Circuit Surgery
Make it with Micromite KickStart Make it with Micromite
Exploring op amp PE Analogue Vocoder: Exploring op amp
Using and interfacing the Vocoder: Driver Using the Exploring
Using and interfacing the the Vocoder: Mastering switch Exploring the
Build an iButton-based Vocoder final Small-scale Building a budget Distortion and Designing a practical Code for an iButton-based
Simulating distortion Using transformers in Installing MMBASIC on
Using
a distortion and Exploring DACs and MMBASIC + RPi Pico + display
exponential amplifiers Driver Amplifier design versatile iButton input offsets Amplifier build I2C bus versatile iButton LM35 temp sensor Audio PSU debounce Royer oscillator
Electronic Door Lock assembly garden set-up distortion circuits
electronic stethoscope de-thump circuit Electronic Door Lockand distortion circuits audio electronics Raspberry Pi Pico distortion circuits microcontrollers = PicoMite Backpack!
power supply
Assembly
Board
clear_bit(intcon, 2);
Microchip
Learn Wind Chimes Evaluation Kit from Microchip
FCM_INTERRUPT_TMR
Simple
EF300BA110A122928352
WIN
Flowcode
Programming
86C
:2000200D928FE28073 Flowcode C
void interrupt(void)
{ if (intcon & 4) C
Learn
void interrupt(void) o(); {
bsf STATUS, RP0 Assembly
{ if (intcon & 4) clear_bit(intcon, 2);
bcf STATUS, RP1
Flowcode
:08000800F000F00S030 Hex
192kHz, 24-bit
o(); bsf STATUS, RP0
EF10000 movwf _adcon1
bcf STATUS, RP1 movlw D′192′
Hex :10001000040EF2000A0 :040000008A01122837
Learn
:040000008A01122837 86C EF10000
movwf _option_reg
Vintage Battery
:08000800F000F00S030 :2000200D928FE28073 :10001000040EF2000A0
Programming:
EF10000 EF300BA110A122928352
:10001000040EF2000A0
SuperCodec:
86C
If we do not have a a paper version of a particular SEND TO: Practical Electronics, Electron Publishing Limited
issue, then a PDF can be supplied for the same price. 113 Lynwood Drive, Merley, Wimborne, Dorset BH21 1UU
Your email address must be included on your order. Tel: 01202 880299 Email: stewart.kearn@wimborne.co.uk On-line Shop: www.electronpublishing.com
Please make sure all components are still available before ay ents ust e in sterling che ue ust e dra n on a an and ade aya le to ractical lectronics .
commencing any project from a back-dated issue. All items normally posted within seven days of receipt of order. Copy this form if you do not wish to cut your issue.
DIRECT BOOK SERVICE
The books listed here
have been selected by
No previous coding experience is assumed, making this book ideal for complete beginners
PIC IN PRACTICE – 2nd Ed
as well as those with some previous knowledge. Self-test questions are provided at the
David W. Smith
end of each chapter, together with answers at the end of the
book. So whatever your starting point, this book will take 308 pages Order code NE39 £24.99
THEORY AND you further along the road to developing and coding your
own real-world applications.
MICROCONTROLLER COOKBOOK
REFERENCE 108 Pages Order code BBC MBIT £7.99
Mike James
240 pages Order code NE26 £36.99
UNDERSTANDING ELECTRONIC CONTROL SYSTEMS Order from our online shop at: www.electronpublishing.com
Owen Bishop
228 pages Order code NE35 £36.99
ARDUINO FOR DUMMIES NEWNES INTERFACING COMPANION COMPUTING FOR THE OLDER GENERATION
Tony Fischer-Cripps Jim Gatenby
John Nussey
Arduino is no ordinary circuit board. Whether you’re an artist, 295 pages Order code NE38 £41.00 308 pages Order code BP601 £8.99
a designer, a programmer, or a hobbyist, Arduino lets you
learn about and play with electronics. You’ll discover how to HOW TO BUILD A COMPUTER MADE EASY ANDROIDS, ROBOTS AND ANIMATRONS
build a variety of circuits that can sense or control real-world Robert Penfold Second Edition – John Iovine
objects, prototype your own product, and even create inter-
120 pages Order code BP707 £8.49 224 pages Order code MGH1 £16.99
active artwork. This handy guide is exactly what you need to
build your own Arduino project – what you make is up to you!
EASY PC CASE MODDING ROBOT BUILDERS COOKBOOK
Learn by doing – start building circuits and programming Robert Penfold Owen Bishop
your Arduino with a few easy examples – right away!
192 pages + CD-ROM Order code BP542 £8.99 366 pages Order code NE46 £26.00
Easy does it – work through Arduino sketches line by
line, and learn how they work and how to write your own. FREE DOWNLOADS TO PEP-UP AND PROTECT INTRODUCING ROBOTICS WITH LEGO
Solder on! – don’t know a soldering iron from a curling YOUR PC MINDSTORMS
iron? No problem! You’ll learn the basics and be prototyp- Robert Penfold Robert Penfold
ing in no time. 128 pages Order code BP722 £7.99 288 pages + Order code BP901 £14.99
Kitted out – discover new and interesting hardware to
WINDOWS XP EXPLAINED MORE ADVANCED ROBOTICS WITH LEGO MINDSTORMS
turn your Arduino into anything from a mobile phone to a
N. Kantaris and P.R.M. Oliver Robert Penfold
Geiger counter.
Become an Arduino savant – find out about functions, 264 pages Order code BP514 £7.99 298 pages Order code BP902 £14.99
arrays, libraries, shields and other tools that let you take
your Arduino project to the next level THE INTERNET – TWEAKS, TIPS AND TRICKS HOW TO FIX YOUR PC PROBLEMS
Get social – teach your Arduino to communicate with Robert Penfold Robert Penfold
software running on a computer to link the physical world 128 pages Order code BP721 £7.99 128 pages Order code BP705 £8.49
with the virtual world
WINDOWS 7 – TWEAKS, TIPS AND TRICKS
438 Pages Order code ARDDUM01 £19.99 eBAY – TWEAKS, TIPS AND TRICKS
Andrew Edney
Robert Penfold
128 pages Order code BP716 £7.50 120 pages Order code BP708 £8.49
EXPLORING ARDUINO GETTING STARTED IN COMPUTING FOR
AN INTRODUCTION TO eBAY FOR THE OLDER
Jeremy Blum GENERATION THE OLDER GENERATION
Arduino can take you anywhere. This book is the roadmap. Cherry Nixon Jim Gatenby
Exploring Arduino shows how to use the world’s most 120 pages Order code BP709 £8.49 120 pages Order code BP704 £8.49
popular microcontroller to create cool, practical, artistic
and educational projects. Through lessons in electrical HOW TO FIX YOUR PC PROBLEMS WINDOWS 8.1 EXPLAINED
engineering, programming and human-computer interaction, Robert Penfold Noel Kantaris
this book walks you through specific, increasingly complex 180 Pages Order code BP747 £10.99
128 pages Order code BP705 £8.49
projects, all the while providing best practices that you can
apply to your own projects once you’ve mastered these. COMPUTING WITH A LAPTOP FOR THE OLDER
AN INTRODUCTION TO WINDOWS VISTA
You’ll acquire valuable skills – and have a whole lot of fun. GENERATION
P.R.M. Oliver and N. Kantarris
Explore the features of commonly used Arduino boards Robert Penfold
120 pages Order code BP703 £8.49
Use Arduino to control simple tasks or complex electronics 120 pages Order code BP702 £8.49
Learn principles of system design, programming and
electrical engineering WINDOWS 8.1 EXPLAINED AN INTRODUCTION TO EXCEL SPREADSHEETS
Jim Gatenby
Discover code snippets, best practices and system 180 Pages Order code BP747 £10.99
schematics you can apply to your original projects 18 pages Order code BP701 £8.49
Master skills you can use for engineering endeavours AN INTRODUCTION TO THE NEXUS 7
in other fields and with different platforms KINDLE FIRE HDX EXPLAINED
118 Pages Order code BP744 £8.99
357 Pages Order code EXPARD01 £26.99
118 Pages Order code BP743 £8.99
Please send book order codes: ....................................................................................................... Also ideal for those approaching electronics
from other industries, the Basic Soldering Guide
Handbook is the best resource of its type, and
......................................................................................................................................................... thanks to its excellent colour photography and
crystal clear text, the art of soldering can now be
.......................................................................................................................................................... learned by everyone!
VISIT OUR WEBSITE FOR MORE BOOKS AND FAST, EASY ONLINE
ORDERING: www.electronpublishing.com
Practical Electronics | September | 2022 69
Teach-In 8 CD-ROM CD
EE M
FR RO
-
ELECTRONICS
£8.99
SERIES
FOR
THE TEACH-IN
8
This CD-ROM version of the exciting and popular Teach-In 8 series INTRODUCING THE ARDUINO
• Hardware – learn about components and circuits
• Programming – powerful integrated development system
has been designed for electronics enthusiasts who want to get to • Microcontrollers – understand control operations
• Communications – connect to PCs and other Arduinos
SOFTWARE
The CD-ROM contains the software for both the Teach-In 8 and PICkit 3 series.
3D Printing • Cable • CCTV • Connectors • Components • JTAG Connector Plugs Directly into PCB!!
Enclosures • Fans • Fuses • Hardware • Lamps • LED’s •
No Header! No Brainer!
Leads • Loudspeakers • Panel Meters • PCB Production •
Power Supplies • Relays • Resistors • Semiconductors •
Soldering Irons • Switches • Test Equipment • Transformers
and so much more…
Monday to Friday 08:30 - 17.00, Saturday 08:30 - 15:30
Practical
Electronics
If you want your advertisements to be seen by the largest readership
at the most economical price then our classified page offers excellent Practical Electronics
value. The rate for semi-display space is £10 (+VAT) per centimetre reaches more UK
high, with a minimum height of 2·5cm. All semi-display adverts have a readers than any other
width of 5.5cm. The prepaid rate for classified adverts is 40p (+VAT) per UK monthly hobby
word (minimum 12 words).
electronics magazine.
Cheques are made payable to ‘Practical Electronics’. VAT must be
Our sales figures prove it.
added. Advertisements with remittance should be sent to: Practical
Electronics, 113 Lynwood Drive, Wimborne, Dorset, BH21 1UU. We have been the leading
Tel 07973518682 Email: pe@electronpublishing.com monthly magazine in
For rates and further information on display and classified advertising this market for the last
please contact our Advertisement Manager, Matt Pulzer – see below. twenty-seven years.
Unit 10, Boythorpe Business Park, Dock Walk, Chesterfield,
ADVERTISING INDEX
AO SHOP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 Advertisement offices
CRICKLEWOOD ELECTRONICS . . . . . . . . . . . . . . . . . . . . . . . . . 63 Matt Pulzer
ESR ELECTRONIC COMPONENTS . . . . . . . . . . . . . . . . . . . . . . . 70
FLOWCODE. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
Electron Publishing Ltd
HAMMOND ELECTRONICS Ltd . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1 Buckingham Road
JPG ELECTRONICS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Brighton
MICROCHIP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Cover (ii) East Sussex BN1 3RA
PEAK ELECTRONIC DESIGN. . . . . . . . . . . . . . . . . . . . . . Cover (iv) Tel 07973 518682
POLABS D.O.O.. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 Email pe@electronpublishing.com
QUASAR ELECTRONICS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
SILICON CHIP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 Web www.electronpublishing.com
STEWART OF READING. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
TAG-CONNECT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 For editorial contact details see page 7.
PLUS!
All your favourite regular columns from Audio Out, Cool Beans and Circuit
Surgery, to Make it with Micromite, Techno Talk and Net Work. On sale 1 September 2022
Content may be subject to change
JPG Electronics
Britannia Maison Mes Amis
Bournemouth BH1 9EH, United Kingdom
Inn
Old Road Remember, we print the date of the last issue
ad
d
Roa
Old H
Cha
tswor
th
Morrisons
address sheet that comes with your copy.
Sparks
Digital subscribers, please call 01202 880299
Retail & Trade Welcome • Free Parking • Google St View Tour: S40 2RB or visit: www.electronpublishing.com
Published on approximately the first Thursday of each month by Electron Publishing Limited, 1 Buckingham Road, Brighton, East Sussex BN1 3RA. Printed in England by Acorn Web Offset Ltd., Normanton WF6
1TW. Distributed by Seymour, 86 Newman St., London W1T 3EX. Subscriptions UK: £29.99 (6 months); £54.99 (12 months); £104.99 (2 years). EUROPE: airmail service, £33.99 (6 months); £63.99 (12 months);
£119.99 (2 years). REST OF THE WORLD: airmail service, £41.99 (6 months); £77.99 (12 months); £149.99 (2 years). Payments payable to ‘Practical Electronics’, Practical Electronics Subscriptions, PO Box
6337, Bournemouth BH1 9EH, United Kingdom. Email: pesubs@selectps.com. PRACTICAL ELECTRONICS is sold subject to the following conditions, namely that it shall not, without the written consent of the
Publishers first having been given, be lent, resold, hired out or otherwise disposed of by way of Trade at more than the recommended selling price shown on the cover, and that it shall not be lent, resold,
hired out or otherwise disposed of in a mutilated condition or in any unauthorised cover by way of Trade or affixed to or as part of any publication or advertising, literary or pictorial matter whatsoever.
M usi c n
Preamplifier {
void inte
C
rrupt(vo
K
if (intcon id)
PLUS! 86C
:20002
A110A1
229283
A0
52
P
00D928
You read that right! We now sell the current issue of your favourite electronics
magazine for exactly the same price as in the High Street, but we deliver it
straight to your door – and for UK addresses we pay the postage. No need to
journey into town to queue outside the newsagent. Just go to our website, set
up an account in 30 seconds, order your magazine and we’ll do the rest.
www.electronpublishing.com