80% found this document useful (5 votes)
415 views100 pages

Nutsvolts20190304 DL PDF

Uploaded by

Alex
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
80% found this document useful (5 votes)
415 views100 pages

Nutsvolts20190304 DL PDF

Uploaded by

Alex
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 100

Custom Actuator Solutions

After nearly four decades of global


success, Hitec continues to deliver
unrivaled reliability, power, speed, and
durability as a world leader in actuator
design. Hitec customers rely on our
engineering and manufacturing teams
to deliver affordable, precision solutions
for a wide range of applications.
Our off-the-shelf and purpose-built
custom products regularly incorporate
innovative features such as magnetic
encoders, brushless motors and
titanium gears, delivering optimal
performance for all your industrial
and commercial applications.

Hitec Commercial Solutions is


proud to offer extensive actuator
lines, custom services, and a
• Sizes Range from 10 - 33mm variety of unmanned platforms, all
• Contactless Position Sensors engineered to effortlessly conquer
• Wide Voltage Operation your most demanding challenges.
• High-Resolution Programmability
• CAN, uCAN & RS-485 Interfaces Available
• Customized Options Available

www.hitecnology.com

Actuator Engineering Reimagined


Hitec Commercial Solutions, LLC Booth No. 4005

9320 Hazard Way, Suite D, San Diego, CA 92123 | (858) 737-9220


Best service. Best Warranty. Best vaLue. no one Beats LDG! contact your Favorite DeaLer toDay!

Where to use LDG


BaLuns & ununs
Not sure which balun or unun is right for your antenna? See our handy chart
below to help you determine which is the best fit for your set-up. All LDG
$
30 ea.
baluns and ununs handle up to 200 Watts PEP and cover frequencies from 200 Watts PEP
1.8 to 30MHz. Visit us at www.ldgelectronics.com or see your favorite dealer
1.8-30MHz
today to learn more and to see our full line of products.

dipolE laddEr linE/TWin lEad


length = 468/freq

1:1 4:1
Balun Balun

Coax Coax

18' Thru 43' Ground End FEd WirE


VErTiCal planE 30' - 135'

9:1
unun
4:1
unun
Coax

Coax >30' Coax Cable

1:1 choke
Coax unun Coax

410-586-2177 [email protected] www.ldgelectronics.com


March-April 2019
08 Q&A NOW IN OUR 40TH YEAR!
Reader Questions Answered Here
Topics discussed this time:
• Firebottle Gain
• Attenuating the Calculations

12 The Ham’s Wireless


Workbench
Practical Technology from the Ham
World
The Smith Chart
The Smith Chart turns the complex
mathematics of transmission lines into circles
and arcs that unlock the mysteries of SWR,
stubs, matching networks, and a whole lot
more! It’s an amazing tool that brings the
arcane math of transmission lines to visual
life, so you can understand them.

91 Open Communication
The Latest in Networking and
Wireless Technologies
Waiting for 5G Wireless
By now, you’ve certainly heard of the
forthcoming fifth generation (5G) wireless
technology. There’s a tremendous amount
of hype about 5G as the various cellular
operators try to pre-sell you on the new
benefits and services. Commercial 5G services
won’t go online until later this year, but we
should see plenty of 5G action in 2020. For
that reason, you’ll need to know more about
5G to understand what impact it will make on
you and the world in general. Here’s a status
report to bring you up to speed.

Projects & Features Page 12

20 Build a Variable Voltage 26 Build the Graphing


Reference Thermometer
A voltage reference is a zener diode-like semiconductor Recently, I began to explore ways to improve and upgrade
that produces an accurate fixed voltage; often, five or 10 my “thermal monitoring technology” and came up with
volts. The downside to a voltage reference is that it only this simple, easy to build trend-plotting thermometer. This
generates a single voltage and has limited current output. I project features a large color graphics display to show the
decided to design a circuit that could generate any voltage current temperature in big bold digits. Better than that, it
between zero volts and 10 volts in 0.1 volt increments. also graphs the temperature trends over the most recent 4,
Here’s how I constructed my variable voltage regulator. 8, 16, or 24 hour period.
■ by Jim Teixeira ■ by Ed Andrews WA9UQN
4 March/April 2019
06 DEVELOPING
Departments 65 BENCH & BUILDER
Subscription Information
Nuts & Volts — PO Box 15277
North Hollywood, CA 91615-9218
PERSPECTIVES 88 NV WEBSTORE Call 877-525-2539 or go to www.nutsvolts.com
How to Learn CW 96 TECH FORUM Subscribe • Gift • Renewal • Change of Info
07 READER FEEDBACK 97 AD INDEX
18 NEW PRODUCTS For more details on subscribing, see our ad on Page 47.

36 CNC Routers: Backlash 58 DIY Biotech: A Spectrophotometer


Backlash can have a detrimental effect on tool life and on
your CNC router’s ability to maintain accurate positioning for Measuring Bacterial Growth
of the X, Y, and Z axes. In this article, we’ll look at the Build an Arduino-based spectrophotometer to explore how
problem of backlash in CNC routers. Once you understand the optical density of bacteria suspended in a liquid can be
what role it plays, you’ll want to diminish its impact on used to measure the rate and stage of bacteria growth.
your machine. Whether you own or intend to build/buy a ■ by Bryan Bergeron
CNC router, make it a habit to routinely check for backlash.
It could save you some money and/or aggravation. 66 Circuit Simulation Made Easy
■ by Roger Secura After reading the May-June 2018 NV article on Ohm’s law,
I thought a follow-up article that goes a little deeper might
42 Getting Started in DIY Modular be in order. Specifically, how Ohm’s Law together with a

Synthesis
computer and a couple of tricks can be used to calculate
the time dependence of much more complex circuits
Like most vintage audio gear, modular synthesizers have involving not just resistors but capacitors, inductors,
been steadily gaining popularity and accessibility since op-amps … you name it! In this article, I’ll describe a
the mid-1990s for both hobbyists and electronic musicians simple numerical method that is intuitive and solves
alike. Providing a hands-on experience into the deep many complex problems with just a few lines of code. No
world of sonic exploration, modular synthesizers are simulator needed!
an unbeatable way to understand the building blocks of ■ by C.A. Hamilton

72 Discovering the NESCAF


synthesis and sound in general.
■ by Steve Harmon

48 The Radio Station that Bridge


Figuring out what the New England Switched Capacitor
Audio Filter does, learning how filters work, and finally

Built building an enclosure from junk box parts was a very


satisfying experience. My NESCAF project proves
It was 1923, and radio was the phenomenon of the something I’ve long thought to be the case: It’s not
day. Over 600 broadcast stations were on the air, and necessary to have an elaborate work bench and expensive
Americans bought 100,000 receivers that year. (Sales test equipment to enjoy the electronics hobby.
would jump to 1,500,000 in 1924.) Many owners hosted ■ by Steve Jackson
“radio parties” and danced to the latest jazz music with
their friends. At the same time, the game of Bridge was 80 Dark Energy and the Expanding
Universe
sweeping the country. Read how one card company used
this “new technology” to promote their products.
■ by Michael A. Banks Time for a little weird science! Concepts such

52 Libraries and Headers in C: A


as energy density and negative pressure as
they relate to our expanding universe are

Tutorial difficult for most of us to understand since


we don’t see them in our daily lives. In this
If you’ve written a program for a microcontroller board article, we’ll explore these ideas and analyze
such as the Arduino, Raspberry Pi, or Propeller QuickStart, an electrical model with similar properties
you have relied on software libraries that provide that is constructed with some copper plates
constants and functions. Often, we use software libraries and an electrometer. Comparing this model
without thinking much about them. When you start to write to the cosmological model of our universe
libraries, it takes time to read documents, follow directions, should help us understand these concepts
and experiment with simple functions. Fortunately, after and emerging theories of the cosmos.
you understand how to create libraries and header files for Hopefully, in the process, we’ll learn more
the software tools you use, you’ll have a useful skill that about how our fantastic universe works.
can simplify programming tasks. Even if you never create ■ by Dr. George R. Steber
a library, you‘ll probably want to know how they work and Nuts & Volts (ISSN 1528-9885/CDN Pub Agree #40702530) is published bi-monthly for $26.95 per
what they contain. This tutorial provides information that year by T & L Publications, Inc., 2279 Eagle Glen Parkway, #112-481, Corona, CA 92883. PERIODICALS
POSTAGE PAID AT CORONA, CA AND AT ADDITIONAL MAILING OFFICES. POST­MASTER: Send
gives you a good start. address changes to Nuts & Volts, P.O. Box 15277, North Hollywood, CA 91615 or Station A, P.O. Box 54,
■ by Jonathan A. Titus Windsor ON N9A 6J5; [email protected].

March/April 2019 5
DEVELOPING
PERSPECTIVES
by
Bryan
Bergeron,
Editor
Published Bi-Monthly By
T & L Publications, Inc.
2279 Eagle Glen Pkwy #112-481
Corona, CA 92883
OFFICE: (951) 371-8497
FAX: (951) 371-3052
WEBSTORE: (800) 783-4624
www.nutsvolts.com

HOW TO LEARN CW
SUBSCRIPTION
Toll Free: (877) 525-2539

I
Outside US: (818) 487-4545
P.O. Box 15277
f you’ve picked up your amateur discussion using a microphone. That North Hollywood, CA 91615
radio license in the past dozen said, my primary reason for using CW [email protected]
years, then there was no CW isn’t practical or logical — I simply
component of the test, and you enjoy it. FOUNDER
may not know CW. However, It’s fun decoding a noisy signal Jack Lemieux
whether or not removing the code from the crud and then using a
component of the FCC (Federal quality straight key or iambic keyer PUBLISHER
Communications Commission) test to connect with the operator on the Larry Lemieux
was a good thing for the amateur other end of the signal chain. [email protected]
radio hobby, there is merit in learning So, let’s say you’re at least
and using CW. Why? intrigued with the possibility of using ASSOCIATE PUBLISHER/
Well, there are the often touted CW as a radio amateur. What are the ADVERTISING SALES
practical and theoretical technical best ways to get up to speed? Robin Lemieux
benefits of CW over SSB (single-side Well, you’ll need to address both [email protected]
band), and some forms of digital sending and receiving CW. To learn to
communications: Minimal bandwidth send CW, you’ll need a straight key, EXECUTIVE DIRECTOR/
and power requirements; simplicity an audible oscillator, and a pair of ear PRODUCTION
Sean Lemieux
of transmitter and receiver circuitry; buds or headphones. For receiving,
[email protected]
relative immunity from noise; and you could rely on a receiver tuned to
security and privacy. W1AW, one of the many YouTube
EDITOR
My chief practical reason for CW communications videos, or, Bryan Bergeron
using CW over voice is the ability to better still, a dedicated CW training [email protected]
operate in the early morning without device or any number of apps for
disturbing anyone. Straight keys and your smartphone or laptop. CONTRIBUTING EDITORS
iambic paddles don’t make much For sending, my recommendation Ward Silver Kristen McIntyre
noise compared with loud verbal is to pick up an affordable straight Lou Frenzel Ed Andrews
Jon Titus George Steber
C.A. Hamilton Michael Banks
Roger Secura Steve Harmon
Steve Jackson Jim Teixeira

SHOW COORDINATOR
Audrey Lemieux

WEBSTORE MARKETING/
COVER GRAPHICS
Brian Kirkpatrick
[email protected]

Copyright © 2019
by T & L Publications, Inc.
All Rights Reserved
All advertising is subject to publisher’s approval.
We are not responsible for mistakes, misprints, or
typographical errors. Nuts & Volts Magazine asumes
no responsibility for the availability or condition of
advertised items or for the honesty of the advertiser.
The publisher makes no claims for the legality
of any item advertised in Nuts & Volts. This is the
sole responsibility of the advertiser. Advertisers
and their agencies agree to indemnify and protect
the publisher from any and all claims, action, or
expense arising from advertising placed in Nuts &
Volts. Please send all editorial correspondence, UPS,
overnight mail, and artwork to: 2279 Eagle Glen Pkwy
#112-481, Corona, CA 92883.

6 March/April 2019
key/practice oscillator combination. For the iambic oscillator, the on and listen to a simulated CW
The best I’ve used is the Japanese most affordable option I’ve used is communication in about a second —
made High-Mound TC-701 Practice an electronic keyer module from less time that it would take me to find
Key, available for $54 from Morse www.elecrorresales.com ($18). The an app icon on my cell phone.
Express (morsex.com). website provides full schematics and For the latest in full-featured
Unlike most key/oscillator printed circuit board layouts for each electronic tutoring for CW, my pick
combinations, the TC-701 is based practice oscillator model. is Morse-it by ICOM. I’m running
on a regular key, but with a code If price is no object, then version 8.1.1 on my iPhone and
oscillator built into the base. When consider the MFJ-407E Deluxe iPads, and it’s by far the most feature
you’re done learning to send CW, Electronic Keyer with Memory packed, easy-to-use Morse Code
you can easily remove the oscillator available from Amazon and ham training app available. At $5 from
circuit and use the key with your radio stores, such as GigaParts ($99). the App Store, it’s still a bargain,
HF transceiver. A slightly cheaper The MFJ-407E is a desktop unit with even compared with the free Morse
option is the MFJ-557 code practice a self-contained speaker and easy-to- tutoring apps.
oscillator/key. It’s about double use front control knobs for volume, I keep the app on my cell phone
the size of the TC-701, but it’s also speed, tone, and weight. for practice on long trips. Because it
significantly cheaper at $37 from For learning to receive CW, can use any text file as an input, the
GigaParts (www.gigaparts.com). my all-time favorite is another MFJ content never grows stale.
Although it’s more challenging product: the MFJ-418 Pocket Morse So, there you have it. Technology
than using a straight key, you could Code Tutor. About the size of a deck aids are readily available. All you
also start learning to send CW by of cards, this unit with LCD screen need is the discipline to spend 10-20
using an iambic keyer and an iambic and internal 9V battery is out of minutes/day practicing and you’ll be
practice oscillator. Check out Morse production but turns up regularly on sending and receiving CW at 10-15
Express for a variety of iambic keyers. eBay. Expect to pay $20-30. WPM before your next issue of Nuts
eBay is, of course, another option. It’s simple to use. I can turn it & Volts arrives. NV

READER FEEDBACK
Mims the Word Thermocycler,” and “Your Amigo Does detector during a flight to 90,000 feet
The January/February 2019 issue of Bluetooth, Live Wi-Fi Webcam.” is worthy of publication in a scientific
Nuts & Volts is absolutely superb! The Finally — and best of all — is Paul paper.
cover story photo collage and article by Verhage’s “Cosmic Rays Redux.” Paul All this in a single issue of Nuts
George R. Steber about “The Discovery has an astonishing record of building & Volts is absolutely amazing. Those
of Radio Waves” is excellent. I was many kinds of payloads that he flies who bemoan the supposed collapse
especially glad the article cited Michael from high-altitude helium-filled balloons. of hobby electronics need to check
Faraday’s connections with James Clerk His Figure 4 showing the supermiposed
Maxwell that led directly to Maxwell’s flux from a muon and cosmic ray Continued on page 95
famous equations.
My next stop was Bryan Bergeron’s
editorial on “The Egonomics of
Learning.” As usual, Dr. Bergeron is THE MOST COMPLETE PROGRAMMING TUTORIAL!
totally on target. Those of us into DIY
electronics should be thankful that a • Everything you need to learn to program PIC® micro-
man with his credentials and immense controllers is included in this package
experience is editor of Nuts & Volts.
Ward Silver’s (NØAX) article about • Learn the fundamental concepts of programming,
antenna rotators took me back to 1958, including program flow, loops, coding techniques, binary
when my father installed a rotator on
our rooftop TV antenna. It seems that manipulation, device-to-device communication, user
the technology worked as well then as interface design, in-circuit debugging, and more!
today.
• Includes all the necessary the software, compiler,
David Goodsell’s article, “Build the
Laser Pencil Engraver” is outstanding. I
$99.99 trainer board, cable, tutorial with exercises and sample
Academic and bulk pricing available
especially liked how he included in this code!
high-tech piece how the pencil being
engraved is mounted on double-sided Check out our other popular products
tape. for PIC® developers including:

PBP3
Then, there’s “Build a Fun U2 Programmer
Stylophone,” “Build an Internet PBP3 Compiler
Digital Clock,” Build an RF Frequency
Counter Buffer for HF,” “More Tricks Prototyping Boards
PICBASIC PRO™ Compiler Experimenter Boards
with Old-School Digital Clocks,” C www.melabs.com
Processor Reduces Debug Headaches,” Contact us at [email protected]
“DIY Biotech: Open Source PCR
March/April 2019 7
Q&A
■ WITH KRISTEN A. McINTYRE

In this column, Kristen answers questions about all aspects of electronics, including
computer hardware, software, circuits, electronic theory, troubleshooting, and anything
else of interest to the hobbyist. Feel free to participate with your questions, comments, or
suggestions. Send all questions and comments to: Q&[email protected].
reduced as the grid goes negative with respect
• Firebottle Gain to the cathode.
In the tube tester you describe, a shortcut
• Attenuating the Calculations they often use is to apply some AC voltage
(often from a transformer secondary possibly
Firebottle Gain connected to the filament supply) to bring the

Q
grid negative relative to the cathode for part of the cycle.
I talked my dad into letting me have his tube The meter measures the plate current. The tube is judged
tester, but it only checks that the tube conducts. to be “good” if the right amount of average plate current
It has selector switches that will connect each reduces the meter current.
pin to either plate voltage, filament voltage, or There’s probably some resistor network being switched
ground. If you set all the switches as instructed, you get in that’s putting the meter’s deflection into the right range
a “good” indication on the meter, but I’d like to get an for the expected plate current change. This is indeed a kind
indication of Gm. of measurement of Gm.
If I look up the tube diagram in my old ARRL The question, though, is how accurate it is and how
handbook and set the cathode to the filament voltage, do you calibrate it. This depends on the design of the tube
it makes the conductance indication on the meter drop tester.
some because — for at least part of the cycle — the grid is I think it might be easiest to bring out a voltage that
negative with respect to the cathode. represents the absolute plate current. This would require
My question is can I quantify the Gm value by doing putting a resistor somewhere in the plate or cathode circuit
this? I could add some banana jacks to add an external to measure that current.
meter if that would help. The cathode works because we assume that the grid
Chuck Bade N0CPF current is very small — essentially zero. A possible issue is

A
that a resistor in the plate circuit will probably be at a high
I love tubes! A wonderful friend of mine, now voltage with respect to the chassis, making it both hard to
deceased, used to call them firebottles. I still measure and a bit of a safety hazard. Of course, a current
refer to them that way. meter could be near the plate voltage if it’s well insulated.
For the uninitiated, let’s discuss Gm. Gm is This argues for measuring from the cathode, which is
defined as the mutual transconductance of an amplifying usually at a low voltage with respect to the chassis. The
element. Transconductance relates input voltage to output Good/Bad meter is likely in a relatively safe spot, so that’s
current as a ratio. So, we put the change in voltage on the a good place to look on the schematic.
top of a fraction and the resulting change in current on Knowing that the grid is seeing part of a sine wave, a
the bottom. We use this on tubes because of the way we peak detector could be used to calculate the tube’s Gm
model their impedance characteristics. more accurately, making sure it’s well into conduction. If
Tubes, like FETs (field-effect transistors), look like the grid voltage is constant for all tubes being tested, then
voltage controlled current sources. The plate current over we can treat the peak negative grid voltage as a constant.
much of the operating range looks like a current source, That makes things easier.
attempting to set its voltage to supply a given amount of The plate current will then be just Gm multiplied by a
current to whatever load is connected to the plate. The constant proportional to the resistor used to measure the
amount of current the plate supplies is set by the grid plate current. This technique avoids the unclear averaging
voltage multiplied by some characteristic constant. That effect of the meter’s internal elements.
characteristic constant is Gm. Of course, like all real world
devices, Gm varies with a number of parameters like Attenuating the Calculations

Q
frequency, operating voltages, etc.
The comparison of tubes to FETs can be extended I was looking at my old (1983) ARRL Antenna
a little further in that they are like a depletion mode Handbook and came across this attenuator
N-channel FET. This means that they conduct (have plate circuit (see Figure 1). I did the calculations to
current) without any grid voltage, and that conduction is verify that the resistor values are all correct by
8 March/April 2019
QUESTIONS and ANSWERS
Post comments on this article and find any associated files and/or downloads at
www.nutsvolts.com/magazine/issue/2019/03.
n FIGURE 1.

putting a 50 ohm resistor across the output. Starting at the slow algorithm, but it’s effective. In the general case for
final stage, I verified that it presented a 50 ohm input to circuits with linear elements, we can use one of two
the previous stage and that it did indeed attenuate by the standard techniques to solve the circuit that will leave us
correct amount. This is really all that is needed to show the with those simultaneous equations to solve.
whole thing works. The two techniques are node analysis and mesh
analysis. The former works with currents and the latter
Question 1: with voltages. They are systematic methods for analyzing
How do you approach this kind of messy problem? a circuit. In the node case, we write current equations for
- Do you generally use numerical methods? each node in the circuit. In the mesh case, we write voltage
- Or, do you derive some sort of simplifying equations for loops that exist in the circuit. See Figure 2 for
assumption to make the system of equations easier to an example of those loops.
solve? The lazy engineer can just plug this circuit into a
simulator and let it do all the work. It will do things like
Question 2: node or mesh analysis and give us an answer. We can do
Is the reason the resistors in the legs of the pi’s have better, though, because this circuit is relatively simple. Only
equal resistance to limit the unknowns to two because two equations are required if we make an assumption.
there are only two conditions? In this case, I can think of a couple of simplifying
Greg Cook KE7DO assumptions — yes, EEs do that all the time! Let’s look at

A
your hand drawing in Figure 3 for reference.
This is a great pair of questions! Numerical Making R3 = R1 reduces the number of variables.
methods — where we try to solve the governing It also helps constrain this under-constrained problem;
equations by plugging numbers in and moving meaning that with less variables, we can calculate an exact
them around a bit until we find a solution — will solution. The other assumption is to collapse the network
certainly work. This type of analysis is often used when the to produce the second constraint equation. This allows a
closed form solution (just doing the algebra) is very difficult simplified two resistor parallel equation — (Ra • Rb)/(Ra +
or cumbersome. We find this to be the case when circuit Rb) — to be used.
topologies get complex and the number of variables is With this, we can generate two simultaneous equations
large. In this case, we get several simultaneous equations that are easy to solve with some algebra. One equation
that must be solved. expresses the attenuation for each stage, assuming a 50
If the equations are linear, we can use a technique ohm load. The second equation enforces the 50 ohm input
called Gaussian elimination. It sounds messy, but it’s not impedance.
really. This is an algorithm that allows us to numerically I’ll leave the algebra as an exercise for the reader. Have
solve such a system in a well understood way. It’s a very fun and send me your solutions! NV

n FIGURE 2.

n FIGURE 3.

March/April 2019 9
SDS1202X-E
$
379!
2-Channel 200MHz Super Phosphor Oscilloscope

• 1GSa/s sampling,14Mpts memory • Large 7” TFT-LCD 256 Level Color Display


• 100k wfm/s refresh, 400k wfm/s refresh (seq) • Auto measurements for 38 parameters
• Low-noise front end: 500uV/div to 10V/div • Math Functions including FFT
• 10 short-cut buttons for easy use • USB Host/USB Device/LAN (VXI-11) interfaces

“Very capable Oscilloscope for $379!” RB “Great scope, great value.” CM “Best scope for the money!” RM “Perfect for this hobbyist.” KL

• Saelig Company, Inc. • www.saelig.com • [email protected] • 1-888-7SAELIG •


(1-888-772-3544)
Robots!

Clockwise from top:


Balboa, Zumo for Arduino,
Romi, Zumo 32U4, 3pi,
Balboa (w/stability conversion kit),
Romi (w/robot arm kit)

Find these robots and more at www.pololu.com


THE HAM‘S WIRELESS WORKBENCH ■ BY WARD SILVER N0AX
[email protected]

The Smith Chart


This strange-looking chart turns the complex
mathematics of transmission lines into circles
and arcs that unlock the mysteries of SWR, stubs,
matching networks, and a whole lot more.
The ways and means of transmission lines can be mysterious as you
may remember from the January 2016 Ham’s Wireless Workbench.
The key to unraveling such mysteries is often having the information
presented in a new way — perhaps an analogy or a picture that
explains what’s happening “inside the line” in a new and different
manner. For many hams, the magic window is a novel and useful
type of graph called a Smith chart.

Smith Chart Background


First described by Phillip Smith in 1939, there are a number of QST articles and a detailed Wikipedia page (en.
wikipedia.org/wiki/Smith_chart) on the Smith Chart. They provide as much background as you care to absorb, and
deeper discussions than this column can provide. You can read these articles first or use them as references throughout this
column. The ARRL has made the QST articles available for downloading at www.arrl.org/smith-chart.

Where Does the Smith Chart Come


From?
Before discussing the chart, let’s back up a step.
All impedances consist of resistance and reactance.
Graphically, these components are represented as
a pair of axes at right angles, as in Figure 1. The
horizontal axis represents resistance (R): positive
to the right of the origin and negative to the left.
The vertical axis represents reactance (X): positive
(inductive) above the origin and negative (capacitive)
below. R and X are the rectangular coordinates of
the impedance. Hold that thought.
In a transmission line, when a wave of RF
voltage and current encounters an impedance

■ Figure 1. This graph shows the rectangular coordinates for any impedance.
The X axis represents resistance (R) and the Y axis represents reactance (X).
Inductive reactance is positive (+Y axis) and capacitive reactance is negative (-Y
axis). Positive resistance which represents loss is on the positive X axis.

12 March/April 2019
PRACTICAL TECHNOLOGY FROM THE HAM WORLD
Post comments on this article and find any associated files and/or downloads at
www.nutsvolts.com/magazine/issue/2019/03.

■ FIGURE 2.
Distorting or Smith Chart Construction
mapping the
rectangular The equation describing how that impedance point
coordinate graph moves around on a graph of rectangular coordinates is
by bending the pretty intimidating:
Y axis toward the
positive X axis Z = ZO [ (ZL + j ZO tan (βl)) / (ZO + j ZL tan (βl)) ]
captures all of its
right-hand side
and the path it describes on a rectangular graph does
impedances inside
the circle formed
not lend itself to easy use. (βl gives the electrical
by the bent position along the line.) What Smith discovered,
reactance axes. however, was that if you distort the rectangular graph
This is the basis of in a certain way (called a mapping), the path of Z along
the Smith Chart. the line becomes a circle on the distorted graph. This is
a lot easier to work with!
different What is this magic mapping? Imagine yourself standing
from the on the origin of the rectangular graph with the positive
characteristic resistance axis in front of you and the negative behind. The
impedance of positive reactance axis starts at your feet and goes straight
the transmission line, Z0, some of the energy in the wave up and the negative straight down. All of the axes extend
is reflected back towards the wave’s source. The phase to infinity.
of the voltage and currents making up the reflected wave Now imagine reaching up over your head and bending
will differ from those in the incoming or incident wave the positive reactance axis down in front of you (make your
depending on the value of the impedance causing the favorite bending noise) in a semicircle whose far end meets
reflection. up with the far end of the positive resistance axis. Do the
The incident and reflected voltage and current waves same for the negative reactance axis, bending it up instead.
combine at every point along the line. At each point, The negative resistance axis still extends behind you, as
the combination results in voltage and current with a straight as ever. This process is sketched in Figure 2.
phase relationship different from either the incident or Viewed from the side, you see a circle created from
reflected waves. It is as if the same energy in the line had the two reactance axes, bisected by the resistance axis.
been applied to an impedance with values of resistance The infinity points of all three join together at the right of
and reactance that create the same phase relationship. the chart. All of the points that were once in the right-hand
If you cut the line at that point and replace the section side of the rectangular graph are now somewhere inside or
beyond the cut with actual components of the equivalent on the boundary of that circle. Points on the left-hand side
impedance, there would be no change to
the waves in the remaining section of the
line! What is Negative Resistance?
The voltages and currents of both
waves also vary with distance along You can’t go to an electronics parts store and buy a negative resistor, but
the line because of the AC nature negative resistance isn’t that unusual. Ordinary positive resistance follows
of the waves. This results in different Ohm’s Law in which voltage and current increase together and consume
combinations of incident and reflected power, dissipating it as heat or doing some kind of physical work.
voltages and currents and their equivalent Instead of consuming power, a negative resistance can generate power
impedance. For example, if the equivalent — even amplify a signal. Negative resistance is usually found in nonlinear
impedance looks like 5Ω of resistance electronic components that have a resistance which varies between positive
and +20Ω of reactance at one point, a and negative regions as current through the component varies. A good
bit farther along the line the equivalent example of such a device is a Gunn diode which is used in oscillators at the
heart of portable radars.
impedance might be 20Ω of resistance and
Gas discharge tubes like neon lamps also show negative resistance,
-5Ω of reactance. That means the point on
acting like a very high positive resistance at low voltages but then switching
the graph of resistance and reactance also to negative resistance when the gas breaks down and conducts. Negative
moves around with position in the line, resistances can’t be created inside transmission lines, so the Smith Chart
returning to its original position every half- only covers the right half of the impedance graph.
wavelength (1/2λ) as it turns out.
March/April 2019 13
PRACTICAL TECHNOLOGY FROM THE HAM WORLD

■ FIGURE 3. Several
impedance values are plotted
on the Smith Chart; 0.2 + j0
is on the center axis at the
point labeled 0.2. The value
3.0 + j1.0 is found by locating
the value 3.0 on the center
axis, then moving upward
along the constant resistance
circle to the arc labeled 1.0
on the outer circle. To find
the value 1.0 — j0.5, start at
the point labeled 1.0 on the
center axis and move down
to the arc labeled 0.5 on the
outer circle; 0 + j0.7 and 0 —
j1.6 are located on the outer
circle where resistance is 0.

Plotting Points on
the Smith Chart
An impedance of R + j X
is plotted at the intersection
of the constant resistance
circle with a value of R and
the constant reactance arc
with a value of X. R values for
the constant resistance circles
are labeled along the center
axis. X values for constant
reactance arcs are labeled
around the outer circle with
positive values along the top
half of the circle. In Figure 3,
several points are plotted as
an example.
of the rectangular graph are now outside the circle. Most RF feed lines and antenna systems are designed
Nothing has been lost, just squashed or stretched. The to work with impedances of 50Ω. If you look for the
Smith Chart ignores everything outside the circle because point of 50Ω of R and 0 X, you will find it squashed way
those points have negative resistance values and cannot be over in the nest of circles at the right-hand side of the
present in a transmission line. chart — not very easy to use. Smith avoided this problem
The straight lines on the rectangular graph after by normalizing all the coordinates to the characteristic
remapping are now circles and arcs on the Smith Chart in impedance of the line, ZO. Normalization replaces the
Figure 3. Lines of constant resistance — originally vertical values of all points by their ratio to ZO; in this case, dividing
and on which all points had the same value of resistance them by 50Ω. An impedance of 50 + j 0 Ω is right in the
— are now nested constant-resistance circles that come middle of the chart at 1.0 + j 0.
together at the far right of the Smith Chart.
That should make sense because all those straight lines
originally went where? To infinity — now the point at the
The Half Wavelength Circle
right side of the Smith Chart. Horizontal constant-resistance The value for Z given in the equation above repeats
lines of points having the same reactance are now bent when βl changes by 1/2λ. On a Smith Chart, this means
into constant-reactance arcs with one end on the outer the value for Z will be in the same spot every 1/2λ along
circle (the original vertical reactance axes) and the other the line. You can see that in the outer circle’s calibration
end at ... yes, that’s right ... infinity (but not beyond)! marks, which are in fractions of a wavelength. Each circuit
14 March/April 2019
around the chart corresponds to moving 1/2λ (electrically) impedance Smith Chart, first flip the chart horizontally
along the line. about a vertical line drawn through the center of the chart.
You can see how this works by plotting the circle That changes all of the constant-resistance circles, touching
for yourself. You’ll need an SWR analyzer (or impedance at the right-hand side of the resistance axis (where R = ∞
meter or network analyzer) that shows both resistance (R) and G = 0), into constant-conductance circles that touch at
and reactance (X) values. It doesn’t need to show the sign the left-hand side of the axis (where G = ∞ and R = 0). All
of the reactance. the constant-susceptance arcs still start on the circle’s outer
Start with a 10 meter long piece of 50Ω RG-58 (any rim, but now meet at the left-hand side of the horizontal
solid-polyethylene 50Ω line will do). This is approximately axis at G = ∞; just as the constant-reactance arcs met at R
one electrical half wavelength long at 10 MHz. Put a coax = ∞.
connector on one end, short the other end, and use your Now flip the chart vertically about a horizontal axis
analyzer to find the lowest frequency at which the meter through the center of the chart. This accomplishes the final
shows zero or a minimum value of X. That is the frequency part of the transformation, adding the effect of the minus
at which the line is electrically 1/2λ long. sign in the equation j B = –j / X.
Note this frequency. Replace the short with a 150Ω Many problems in transmission lines are worked out
resistor. Your meter should now show an SWR of 3:1 and using a combination of Z and Y. Some parts of the problem
the impedance at the analyzer should be 150Ω of R and 0 are easiest working with Z, while others are easiest using Y.
X. On the Smith Chart, this point is at (150 + j 0) / 50 = 3.0 It would be awfully inconvenient to use two separate charts
+ j 0, on the horizontal axis to the right of center. for this, so engineers did the logical thing and printed both
Increase the frequency in 0.5 MHz steps, recording sets of coordinates on a single chart!
R and X at each step and plotting the normalized values The result would be hopelessly cluttered except that
on the Smith Chart. Because you may not know the sign some bright person decided to use two different colors. A
of the reactance, assume the reactance values become sample is downloadable at www.dartmouth.edu/~sullivan/
negative (capacitive) as you increase frequency. colorsmith.pdf. The admittance coordinates are in blue
Stop when you see the reactance go to zero again; and the impedance coordinates in red.
halfway around the chart near 50/3 = 16.6Ω, plotted as Look carefully at the labels on the outer circle axis
0.33 on the horizontal axis. This is the frequency at which near the left-hand side of the chart. You’ll see that the top
the line is 3/4λ long — approximately 13.3 MHz. While label, for example, is “Inductive Reactive Component (+jX/
you’re recording the points, note that the SWR reading ZO), or Capacitive Susceptance (+jB/YO).” Susceptance
doesn’t change. is normalized (just like reactance) by dividing it by the
The points you have plotted should form a semicircle characteristic admittance (YO = 1/ZO) of the transmission
with its lowest point at approximately 0.6Ω of R and –0.8Ω line. If ZO = 50Ω, then YO = 0.02S.
of X. (This is an un-normalized impedance of 30 – j40 Ω.)
Continue increasing the frequency until the points return to
the horizontal axis near the 3.0 mark at which you started. Trivia Night
The line is now 1λ long and the frequency should be twice When you’re out with the other electronic-ers, you can
what it was when you started. impress them by knowing the answer to:
The complete circle of points is called a constant-SWR
circle because all the points on that circle cause the same What single point is the same on both types of Smith Charts?
SWR. (If you dare, plot the points on a rectangular graph — That’s right — 1.0 + j0 at the very center. That is the
which would you rather work with?) only complex number whose reciprocal is the same as the
original number!
Free Admittance!
Impedance, however, is not the only way to work with
voltage and current in a transmission line. Admittance (Y) is
Putting the Smith Chart to Work
the reciprocal of impedance; Y = 1/Z. Similarly, admittance The Smith Chart is a great tool for working out all
is made up of conductance (G) and susceptance (B), which kinds of problems involving impedances, admittances, and
are both in units of siemens (S). G and B are the reciprocals transmission lines. One of the most common is impedance
of their counterparts in the impedance world; G = 1/R and matching. (See the March 2016 Ham’s Wireless
j B = –j / X. (Note that 1 / j = –j.) Impedance is sufficient Workbench for a column on that subject.) The Smith chart
for most problems, but admittance comes in very handy at is a guide to how those transformations can be made using
times. For example, admittances in parallel add together, Ls and Cs by moving along the various circles and arcs to
just as impedances in series add together. the desired impedance, such as the normalized 1.0 + j 0.
To create an admittance version from a “regular” But what does “moving” on the Smith chart mean?
March/April 2019 15
■ FIGURE 4. Beginning with
Point A (3.0 + j0) representing a
resistance of 150 ohms, the effect
of adding series and parallel
components is shown by the red
arrows. See text for discussion.

so we’ll treat the extra 2.0Ω as


an impedance and add it to the
original impedance for a final value
of 5.0 + j0Ω (250 + j0Ω).
On the chart, this move has
to be along a red constant-X arc.
Why? Because adding R in series
does not change X. Point A lies
on the constant-X arc representing
X = 0 (the horizontal axis), so
adding 2.0Ω of R moves to 5.0 +
j0Ω at Point B, also on the X = 0
constant-X arc.
What if instead of series
resistance, we added some series
reactance? Rule 2 would still
apply, but now we’d move along
a constant-R circle because we’re
only changing X. Point C is the
result of adding +j2.0Ω (100Ω) of
inductive reactance in series with
3.0Ω.
The arrow moves along the
constant-R circle labeled “3.0”
at the horizontal axis until it
encounters the constant-X arc
labeled “2.0” at the outer edge of
the chart in the inductive reactance
(upper) half of the circle. The circuit
inset shows the addition of the
There are two simple rules for making the “allowed capacitance (C) to the original impedance (A).
moves.” Let’s add series capacitance instead. Point D is the
Rule 1: Every component is treated as a pure R, L, or C. result of adding –j6.0Ω of capacitive reactance in series
Rule 2: When adding components in series, treat them with 3.0Ω. Once again, the arrow moves along the
as impedances and use the red impedance coordinates. constant-R circle labeled “3.0,” this time in the lower half
When adding components in parallel, treat them as of the chart until it encounters the constant-X arc labeled
admittances and use the blue admittance coordinates. The “6.0.” The inset circuit shows how the impedances are
result is that you’ll be making “moves” on the chart along connected.
the arcs and circles — much like a rook in chess has to What if we add a component in parallel with our
move along the ranks and files. original 150Ω? Again, according to Rule 2, we treat both
Some practice moves are illustrated in Figure 4. On components as admittances, so let’s start by converting
the dual-coordinate chart, find point A: Z = 150 + j0Ω. 3.0 + j0Ω to admittance = 0.33 + j0S which is … the same
Normalized to 50Ω, that is Z = 3.0 + j0Ω. (From here point!
on, we’ll work in normalized coordinates and the pre- That’s a handy thing to remember: A pure resistance
normalized values will be shown in parentheses where and its equivalent conductance are at the same point on
necessary.) the horizontal axis of both the impedance and admittance
Add 2.0Ω (100Ω) in series with the impedance at coordinates.
Point A. Following Rule 2, this is a series combination, Let’s add a capacitor with j1.0S of capacitive
16 March/April 2019
PRACTICAL TECHNOLOGY FROM THE HAM WORLD

■ FIGURE 5. A typical screenshot


from the SimSmith software by
Ward Harriman AE6TY. SimSmith
allows the user to build arbitrarily
complex combinations of components
and transmission lines, showing
the behavior of the system with
frequency.

SimSmith: An Online
Charting Tool
You might be sweating a little
bit and that’s pretty normal for a
first encounter of the Smith Chart
kind! While a lot of eraser crumbs
and compass pencils got worn down
designing circuits and antenna systems
this way, there are online versions that
do a lot of the hard work for you.
The best one I know is the free
SimSmith program by Ward Harriman
AE6TY, available at harriman.ddns.
net/Smith_Charts.html. Figure 5
susceptance in parallel to get a combined admittance shows a typical screen. You can build
(remember, they just add together) of 0.33 + j1.0S. Travel up systems of transmission lines, including stubs, plus
along a constant-G circle (because the conductance was lumped-L and -C and -R components, S-parameter blocks,
not changed) at 0.33S (between the 0.3 and 0.4S circles) and even arbitrary circuits described by data files. There’s
to the constant-B arc labeled “1.0.” This point is shown at E an active user’s group and a number of great tutorials by
in the figure. Larry Benko WØQE. It’s a terrific resource.
Now, add 0.67S of conductance, also in parallel. This I hope you enjoyed this introduction to the Smith
moves the point along a constant-B arc to the constant-G Chart. It’s an amazing tool that brings the arcane math
circle with a value of 0.33 + 0.67 = 1.0S. The result is the of transmission lines to visual life so you can understand
Point F at 1.0 + j1.0S as shown in the inset circuit. them. NV

EASILY ADD MOTION TO


YOUR PROJECT WITH THE
ACTUONIX IOT WIFI BUNDLE

ACTUONIX
R SERIES IOT WIFI WIFI
MICRO LINEAR ENABLED
ACTUATOR BUNDLE DEVICE

VISIT ACTUONIX.COM FOR PRODUCT


INFORMATION AND PROJECT RESOURCES

March/April 2019 17
PRODUCTS
■ HARDWARE
■ SOFTWARE

NEW
■ GADGETS
■ TOOLS

MODERN BUILD Square Beams For more information, contact:


SYSTEM goBUILDA
www.gobilda.com

go BILDA is a modern build


system designed for SERIES OF SPECTRUM
engineers, artists, students, and
makers. It’s metric, lightweight, and
ANALYZERS
has an ever-growing library of parts.
Rapidly prototype like a pro or
enter a educational competition with
B &K Precision has announced
the next evolution of RF test
equipment: its new 2680 series
the ability to make quick in-the-field of spectrum analyzers. This series
modifications using only a hex key. includes a pre-amplifier, 2D spectrum
From small tabletop robots to monitor, and advanced measurements
projects you can ride, goBILDA’s such as channel power, adjacent
interstitial pattern scales like a champ. Square beams may be one of the channel power, and occupied
You don’t need a machine shop most versatile structural elements on bandwidth, which are options on
to make high precision projects. the 8 mm linear pattern. Thru-holes most competing models.
goBILDA is ball bearing based and is from every side allow screws to pass These instruments deliver
manufactured with industry leading through the beams and tie into other performance and functionality in
tolerances. New products include the components. Each end is threaded a compact lightweight design. The
following. so that connecting one square beam series consists of 2.1 and 3.2 GHz
to another only requires a single models, both featuring a large 10.1”
goTUBE screw. Whether they get stacked side TFT wide-screen color display, 1
by side, end to end, or fastened Hz minimum RBW, and tracking
perpendicular to one another, generator. The included PC software
they’ll remain on grid. Pricing supports front panel emulation, 3D
ranges from $1.19-$6.49. spectrum monitor, configuration,
EMI scanning, EMI test reports, and
Low-Side U-Channel remote control capabilities via USB
Low-side U-channel provides or LAN interface. These analyzers
similar structural integrity as the can be further expanded with two
1120 series U-channel while saving optional licenses.
on real estate. The reduced height The reflection measurement
of the sides allows more compact license enables VSWR, reflection
building while still providing three coefficient, and return loss
goTUBE is designed with a 32 sides to build off of. It’s an excellent measurements. The EMI pre-
mm OD in order to run in bearings choice when building a chassis with compliance license activates the
and pillow blocks. The 16 mm motors running perpendicular to instrument’s quasi-peak detection for
pattern is threaded into the ends of the direction of the channel. Pricing EMI measurement functions.
the tube, so you can easily mount ranges from $1.39-$35.69. The 2680 series is well-suited
drive components to the tube for a for applications in two-way radio,
no-slip transmission of power. The site surveying, EMI pre-compliance,
bore of the tube is both 14 mm in characterizing the frequency response
diameter and 12 mm square. The of RF devices, and more. Key features
14 mm diameter allows bearings to of the new 2680 series include:
slide in the ends. The 12 mm square • Frequency range: 9 kHz to 2.1 or
bore caters to creating linear drives 3.2 GHz
with lead screws. Pricing ranges from • Adjacent channel power, total
$2.99-$13.99. power
18 March/April 2019
• Third-order intercept with a compact footprint
• 2D and 3D spectrum and rugged construction.
monitor The PowerBlock PB 5
• High sensitivity -161 was designed for use in
dBm/Hz displayed compact systems and to
average noise level power source components,
(DANL) TVs, and projectors. It’s
• Low phase noise of ideal for situations where
-98 dBc/Hz at 10 kHz you want to isolate digital
offset components from analog
• Low-level uncertainty equipment or segregate
of ±0.7 dB switching power supplies
• 1 Hz minimum from linear power supplies.
resolution bandwidth COMPACT ISOLATION The PowerBlock PB 5 is
(RBW)
• Preamplifier and tracking
TRANSFORMER priced at $799.

T
generator standard on all models he Torus Power PB 5 is a five For more information, contact:
• 10.1” wide-screen 1024x600 amp toroidal isolation transformer Torus Power, Inc.
color display www.toruspower.com
The 2.1 GHz model 2682 and the
3.2 GHz model 2683 have list prices If you have a new product that
at $2,950 and $4,490, respectively, you would like us to run in our
and come with a three year warranty. New Products section, please
email a short description (300-
For more information, contact: 500 words) and a photo of your
B&K Precision product to: newproducts@
www.bkprecision.com nutsvolts.com.

March/April 2019 19
BUILD IT YOURSELF

BUILD A VARIABLE VOLTAGE


REFERENCE

A voltage reference is a zener diode-like semiconductor that


produces an accurate fixed voltage; often, five or 10 volts.
These are laser trimmed, and a 10 volt reference is available
with accuracies up to ±0.0025 volts. My favorite voltage
reference is the 10 volt Texas Instruments (TI) REF102 series
available in accuracies of ±.01 volt (REF102A for $6), ±.005
volt (REF102B for $9), or the ±.0025 volt (REF102C for $12).
This is no place to skimp, so I went with the REF102C for this
project.
20 March/April 2019
By Jim Teixeira

T
he downside to a voltage reference is that it only Notice that the OPA551 output is a negative voltage.
generates a single voltage and has limited current The path from the REF102 to the final output is inverting,
output. I decided to design a circuit that could so plus 10 volts appears as minus 10 volts at the output. I
generate any voltage between zero volts and 10 could have used the REF102 as a negative reference (see
volts in 0.1 volt increments; for example, 4.8 volts with a the REF102 datasheet for how to do this), but I found that
basic accuracy of 10 millivolts and an output current of it performed better (less variance from the 10.000 volts) as
100 milliamps (or one ampere with a power booster; see a positive reference.
the TI OPA551 datasheet). Another source of error is how the circuitry is
To achieve this accuracy requires analysis and assembled. I used a solderless plug-in breadboard for the
mitigation of all possible sources of voltage errors. This will initial testing and the results were bad. The wire leads on
be discussed in the following sections. the resistors are thinner than the wire normally used (22
AWG) and they don’t make reliable contact, so I would see
variations in the output by just touching one of the ladder
Block Diagram resistors or tapping on the breadboard.
Figure 1 is a block diagram of my variable voltage So, I went with an SB404 solderable breadboard and
reference (VVR). Starting at the
left is the 10 volt REF102C which
has an error of ±2.5 millivolts. This
■ FIGURE 1.Variable voltage
is within the 10 millivolt design
reference block diagram.
goal. A 10 resistor ladder network
(a voltage divider) breaks down
the 10 volts into 10 integer volts
as shown. This network is the first
(and largest at about 10 millivolts)
source of voltage error since the
resistors are only 0.1%. I’ll address
this later.
Next in the block diagram are
the two front panel rotary switches:
one for volts and the other for
tenths of volts. It may seem strange
that both switches are wired the
same since the tenths switch works
in tenth volt increments, but I’ll
explain how this works shortly as
well. that completely solved the problem. This breadboard is
It’s very important that the resistor network not be very convenient and it may be possible to thicken the
loaded down by its following circuits, so I have a dual low resistor leads by applying a thin coating of solder.
input offset op-amp (LT1013) wired as a unity gain, very
high impedance buffer. It has about one millivolt input
offset to contribute to the error. Reducing the Resistor
Now comes the fun part. The OPA551 is a very nice Ladder Error
op-amp with a 200 milliamp output and a typical input
offset of one millivolt. It also functions well as a summing I chose 0.1% resistors for everything, but even this
amplifier. precision can give a 10 millivolt error — my entire error
The gain of the amplifier is the ratio of the feedback budget. The ladder resistor value isn’t the critical thing, but
resistor (R13) divided by the input resistor (R11 for the all resistors in the ladder should have the same (or close)
volts path and R12 for the tenths path). Therefore, the value. This also applies to R11 and R13. They should both
gain for the volts path R13/R11 is one and the gain for the have the same value, but not necessarily the same value as
tenths path R13/R12 is 1/10. The summing amplifier simply the ladder resistors.
adds the two inputs in this ratio. I needed a total of 10 1,000 ohm resistors for the
For example, if the volts switch is set to four volts and ladder and two 1,000 ohm resistors for R11 and R13.
the tenths switch is set to eight tenths, the output will be I bought 25 1,000 ohm resistors for 52 cents each
4/1 plus 8/10 or 4.8 volts. from Digi-Key intending to select 10 resistors having
March/April 2019 21
be absolute, only relative accuracy; that is, if
one resistor gives a reading of 0.6 millivolts
and another resistor gives a reading of 1.0
millivolts, we can expect that all resistors
that give a reading of say zero to 1.0
millivolts will be very close in value.
Look at Figure 2. It’s a list of the
measurements on the 22 resistors. The
first column is the resistor ID number, the
second column is the Wheatstone bridge
measurement, and the third column is the
actual resistance measured by an accurate
5-1/2 digit DVM. The list is sorted low to
high on the Wheatstone bridge values.
The highest value in the third column
is 100031 (resistor 20) and the lowest is
99933 (resistor 19); a difference of .98
ohms — almost exactly 0.1% as expected.
■ FIGURE 2. Ladder If we look at the resistors having a
network resistor selection.
Wheatstone voltage between 0 and 0.8,
we get a high of 99957 (resistor 14) and a
low of 99933 (resistor 19) — a difference of
close to the same value for the ladder. You also need two .24 ohms or about 0.02%. Five times better
matched resistors for R11 and R13. than 0.1% and a contribution to the error budget of about
Now comes the challenge: how to measure each of two millivolts!
the 25 resistors to better than .1%. A typical 3-1/2 digit Since the Wheatstone voltages measured are in
handheld meter won’t do it; all resistors would read as the low millivolt range, it’s best if the resistors in the
1,000 ohms! A 4-1/2 digit meter or better yet a 5-1/2 Wheatstone bridge are tack-soldered together at the ends
digit meter is required if we use this direct measurement of the resistor leads. This will reduce undesired voltage
method. drops.
I used an alternate technique for measuring resistance The Xs in the fourth column are the best candidates for
called a Wheatstone Bridge method, with three 1,000 ohm the resistor ladder and the Zs are perfect for R11 and R13.
0.1% resistors from the batch of 25 and a +15 volts power In Figure 2, I also show both the Wheatstone and
source. The voltage measured by the bridge is quite small the 5-1/2 digit DVM results. Clearly, if you have a 5-1/2
(low millivolts) but the two 3-1/2 digit meters I own read digit meter, you won’t have to do the Wheatstone
voltages as low as 0.1 millivolts. measurements. I’m just trying to show how they correlate.
I’m not sure of their accuracy, but we don’t need it to
Detailed
Circuit
Diagrams
Figures 3 and 4 are the
detailed schematics for the VVR
principal circuits. They just add
detail to the block diagram.

Power Supply
The VVR operates from ±15
volts at about 100 milliamps. It can
be supplied in several ways; for
example, AC/DC converters using
■ FIGURE 3.Voltage reference and switches. normal house power for the AC.
22 March/April 2019
These are low priced and available with
dual outputs of ±15 volts.
I get a little nervous about having
120 volts AC floating around in a metal
box that I will come in contact with, so I
looked at alternatives and found a great
one: the Traco Power TEL 3-0523 (Digi-
Key, $16). This is a DC/DC converter
with 4.5V to 9V input and dual outputs
of +15V and -15V at 100 milliamps
each. The input and output are isolated
from each other and it can be powered
with a cell phone charger.
Unfortunately, these chargers
typically use a USB to micro-USB cable.
I couldn’t find a suitable panel mounted ■ FIGURE 4.Voltage reference buffer and output amplifiers.
micro-USB jack, so I just changed the
cable from a USB to a type M barrel
cable. Or, you can just cut off the micro-USB connector
Construction
and run the open end through a grommet and hard-wire it Figure 5 is the assembly diagram for the principal
to the power supply. components of the VVR. As I mentioned earlier, I prefer
I had to cut back the VVR output current to 80 a soldered assembly for best accuracy and stability. I
milliamps because the OPA551 uses 20 milliamps used the SB404 board for this project, but if you prefer a
internally. solderless assembly, then the assembly drawing shown in

■ FIGURE 5.Voltage reference assembly drawing.


March/April 2019 23
Figure 5 can be squeezed by two columns for
the standard 30 column solderless breadboard.
The worst-case power dissipation of the
OPA551 in the VVR is about one watt which
mandates a heatsink. I used thermal glue to bond
a heatsink to the OPA551.

Performance
Figure 6 shows the actual VVR output at
various volts and tenths switch settings. The VVR
performance far exceeds my expectations! I think
the accuracy of the ladder network is the main
contributor at an additional cost of less than $7.
In addition, the output voltage with 0.0
volts/0.0 tenths is only 0.2 millivolts. This means
that the sum of the input offsets of the LT1013
and the OPA551 is close to zero.
The VVR is expected to be used in a
hobbyist workshop environment. However,
it’s still important to evaluate what variations
in performance to expect with changes in the
environmental temperature.
The datasheets for the critical components
are the REF102C; the resistors in the ladder
and R11, R12, R13; the input offset voltage
of the LT1013; and the input offset voltage of
the OPA551. The parameter changes due to
temperature are typically expressed in parts per
million (ppm) per one degree Celsius change in
temperature.
■ FIGURE 6.VVR performance test. The REF102C has an output voltage change
of 2.5 ppm per degree change in temperature.
Parts List We need to determine how many millivolts this
represents. The REF102C has a nominal output
QTY DESCRIPTION SOURCE
of 10 volts. We divide this by one million and
1 REF102C Digi-Key Part#: 296-17005-5-ND get 0.00001 volts or .0.01 millivolts. Since the
REF102C has a ppm of 2.5, we multiply the 0.01
1 LT1013 Digi-Key Part#: 296-7044-5-ND
by 2.5 and get 0.025 millivolts per one degree
1 OPA551 Digi-Key Part#: OPA551PA-ND change in temperature.
25 1,000 ohm 0.1% resistors Digi-Key Part#: 10KADCT-ND The resistors have a resistance change of 25
2 10K ohm 0.1% resistors Digi-Key Part#: BC4503CT-ND ppm per degree change in temperature. Here,
we take 1000 ohms and divide it by 1,000,000
1 Traco Power Supply Digi-Key Part#: 1951-2536-ND
and then multiply by 25 and get 0.025 ohms per
1 Solderable Prototyping Board Jameco Part#: 2191402 degree change for each resistor. Each resistor
1 Heatsink Digi-Key Part#: 345-1089-ND sees only one volt, so the change is 0.025 divided
1 Enclosure Jameco Part#: 208911 by 1000 + 0.025 which is .000025 or .025
millivolts per one degree change in temperature.
2 Rotary Switch Jameco Part#: 576501
Since there are 10 resistors in the ladder,
2 Knobs Jameco Part#: 264955 we get 10 times 0.025 or 0.25 millivolts per
1 Dual Banana Jack Jameco Part#: 2144024 one degree change in temperature. This seems
1 Mini Toggle Switch Jameco Part#: 317287 like a lot but remember that all the resistors are
subjected to the same temperature and will
1 Misc Capacitors mostly experience the same change. The ratio
24 March/April 2019
of the resistors to one another doesn’t change much, and
that’s what is really important. A Wheatstone bridge is a simple circuit for measuring
The LT1013 input offset is a maximum of one millivolt an unknown resistance by connecting it, so as to form a
over the full range of temperatures (-55°C to +125°C). It
quadrilateral with three known resistances and applying
has a typical offset of 0.2 millivolts at room temperature.
The OPA551 has a typical input offset of one millivolt a voltage between a pair of opposite corners.
at room temperature and a maximum of five millivolts over
the full range of temperatures (-55°C to +125°C). your favorite microcontrollers. For example, ever wonder if
What is the maximum error? It’s difficult to determine, the A/D converter on the Raspberry Pi is more accurate or
but I think that based on my test unit results shown in more linear (or both) compared with the A/D converter on
Figure 6 (I didn’t do any component screening except for the Arduino? Well, here’s your chance to find out. NV
the resistors), your error should be less than three millivolts;
probably less than two millivolts over ±20 degrees from
normal room temperature.
Post comments on this article and find any associated
files and/or downloads at www.nutsvolts.com/magazine/
Putting It to Work issue/2019/03.

An obvious first use for the voltage reference is


to calibrate your digital and analog voltmeters. Set the
variable voltage source to a value within the range selected
on the DMM/VOM and adjust the voltage reading
accordingly.
A more advanced application is to map out the
accuracy and linearity of the analog-to-digital converter on

FREE access to over 15 million


schematic parts and PCB footprints
Never create a part by hand again -
try the PROTEUS DESIGN SUITE today!

T: +1 866 499 8184


E: [email protected]

March/April 2019 25
BUILD IT YOURSELF

BUILD THE GRAPHING


THERMOMETER
Use an
Arduino to
Measure
and Show
Climate
Change
Graphs!

I live in the Midwestern region of the US where every winter, it gets cold.
Those of us in the region become focused — dare I say, obsessed — with
the outdoor temperature and the near term predictions and trends.
Recently, I began to explore ways to improve and upgrade my “thermal
monitoring technology” and came up with this simple, easy to build
trend-plotting thermometer. This project features a large color graphics
display to show the current temperature in big bold digits. Better than
that, it also graphs the temperature trends over the most recent 4, 8, 16,
or 24 hour period.
For me and my temperature obsessed brethren, it provides insights into
overnight changes as well as mid-winter encouragement whenever we
see upward trends!
26 March/April 2019
By Ed Andrews WA9UQN Post comments on this article and find any associated files and/or
downloads at www.nutsvolts.com/magazine/issue/2019/03.

T
his project joins an Arduino CPU (central
processing unit), some temperature/humidity
sensors, and a real time clock (RTC) module
to a large (3.5 inch) high resolution color LCD
graphics display to create a fun and useful “graphing
thermometer.” The outcome of this effort is an easy-
to-build device that has the following features and
functions:

• Provides a weather watch device that is tightly


focused on local conditions: Your backyard.
• Fully stand-alone operation: No Wi-Fi or Internet
complexities.
• Simple and easy to build: Uses readily available
modules and parts.
• Easily programmed and customized: Arduino
Integrated Development Environment (IDE) to ■ FIGURE 1. Graphics thermometer display.
the rescue!
• Shows indoor and outdoor temperature and humidity markers label the horizontal axis.
on big bright digits: Large, colorful, easy-to-read
display. The Hardware
✓ Custom large-number font provides great display The availability of large (3.5 inch) low cost 480x320
quality. color LCD shields became the prime driver for this project.
• Vividly shows weather trends: Graphs temperature These high quality LCD display modules are now readily
changes over the previous 4, 8, 16, or 24 hour period. available in the $8-$12 range and make bright, colorful
• Includes a digital clock: Shows day-date-time which digital readouts as well as high resolution graphical plotting
makes for easy-to-read time-stamped trend graphs. very affordable. Additionally, these displays plug directly
• Compact: Fits into a small 3D printed case or mount onto an Arduino Uno or Mega 2560 board (Figure 2) and
into an enclosure of your own design. are fully supported by the Arduino IDE software libraries.
• Flexible core platform and enclosure can be utilized
for other projects and applications.
✓ This project can easily become a full function day-
Which CPU: Uno or Mega?
date-time graphics clock. At first blush, the modest I/O requirements of this
✓ Available SD card slot on LCD shield can be used project can be easily handled by either the Arduino Uno or
to add new features (long term data logging or ??). Mega processors. However, a few quick calculations reveal
that for my implementation, the goal of storing and plotting
24 hours of temperature data will require about 3.2 KB of
The Main Display
The display presented by this instrument
is shown in Figure 1. Day, date, and time
appear across the top banner. Next, current
temperatures are shown on large digital
displays, with humidity readings appearing
right below these readouts.
Now comes the fun part! A graphical
plot of Temperature vs. Time is displayed
showing recent temperature trends.
The vertical Y axis can be configured
to C° or F°, while the horizontal X axis
represents time just like an oscilloscope ■ FIGURE 2.
trace. The user can press a single button to Low cost LCD
select “look-back” time periods of 4, 8, 16, mates directly to
or 24 hours. Arduino Mega.
As you can see, Time-of-Day hour
March/April 2019 27
■ FIGURE 3.
A complete
schematic of
the Arduino
graphing
thermometer.

RAM memory. The Clock and Four-


Also, while the core program is not big, in order to
render high quality characters for the big digital readouts, Button Control Panel
several sizable font data tables must be stored alongside After getting an early prototype working, I decided to
the program itself. add an RTC enhancement. For just a couple of bucks, a
For these reasons, the Uno with only 2 KB of RAM DS3231 RTC add-on module provides accurate, battery-
and 32K of program memory falls short of our needs. The backed clock-calendar information. A few pushbuttons
Mega 2560 with its 8 KB of RAM and 256 KB program make clock setting easy. The same button array allows the
capacity, however, fits the bill nicely! user to easily select the desired trend-plot period.

Sensors The Schematic


I started this development using some “one-wire” The complete schematic for the graphing thermometer
18B20 digital temperature sensors that I had on-hand. is shown in Figure 3. Powered by a simple Arduino wall
While these worked great, I found that the I2C one-wire wart or 5V cell phone charger, the user interacts with the
DHT21 sensors could provide temperature and humidity instrument through a simple pushbutton array.
data for only about $3.50 apiece. If you’ve already got a spare Mega board, power
With a couple of these guys, indoor and outdoor pack, and a few routine junk box items on-hand, you’ll
data is easily captured. Since these sensors require only be spending less than $25 to add the color graphics LCD
one data line, a power wire, and a ground wire, a length display (~$10), RTC module (~$2), sensors (~$3.50 ea), and
of three-conductor ribbon cable is all that is needed for a pushbutton array (~$2).
simple window-sill pass through to the outdoor sensor. If you don’t have access to a 3D printer or are not
inclined to make your own case, a complete set of 3D
28 March/April 2019
printed enclosure parts may be it’s holding the 1530 minutes (25.5
■ FIGURE 4.
purchased through the Nuts & Volts Main loop(). hours) of data.
Junk Box store. When the end of the array is
reached, GBL_TdataNewPtr is reset
back to zero, thus wrapping back
The Software around in a “circular” fashion to the
Tried and true support libraries first array location. A few simple
are used to manage the RTC range-limiting “if tests” are used to
interface, DHT21 sensor interface, keep GBL_TdataNewPtr operating
LCD color graphics display, and properly as it reaches the array
pushbutton debouncing. These must end-point boundaries. With this
be downloaded and added into approach, it’s seen that every new
your IDE library. The Arduino source temperature reading added into
code for the graphing thermometer Trend-Memory automatically deletes
is found in the download material. and replaces the oldest reading in the
Here are a few highlights to give you Tdata[ ] array.
a head start on understanding the As a side note, upon program
program details. startup (i.e., unit plugged into AC
First off, as is usual for Arduino power or CPU reset button pushed),
projects, the device libraries, a few every element of Tdata[ ] is initialized
configuration constants, and some to a value defined as “NoData”
key data variables are initialized in (const int NoData = 9999;). This
the Setup() routine. value is ignored when making trend
Then, the main loop (Figure 4) plots and keeps erroneous, random
begins and repetitively runs through the following task list: power-up values from polluting the trend graph.

1. Update Time-Of-Day display once per minute.


2. Read sensors and update displays once every two Creating a Trend Plot
seconds. In order to make a trend plot, we need to convert our
3. Add new value into trend memory once per minute. stored temperature readings into XY point coordinates
4. Check for operator pushbutton presses. on the LCD display. Figure 5 shows that the X axis of our
• Go to Set-Clock routine when PB1 (+) is pressed. trend graph represents Time and the Y axis represents
• Change trend period if PB3 (Next) is pressed. Temperature.
5. Update and redraw the trend graph once per minute. To make our graph, we need to map the temperature
VALUES into Y coordinates for display. Similarly, we must
transform each array INDEX pointer into an appropriate
Storing Temperature
Values into Trend
Memory
Floating point temperature readings (°C) are
retrieved from each DHT21 sensor every two
seconds. The outdoor reading is converted into a
16-bit signed integer value in units of “tenths-of-
a-degree-C” for inclusion into the trend memory
integer array, Tdata[ ]. Dimensioned to hold 1530
elements, Tdata[ ] is sized to hold 25.5 hours of
outdoor-temperature readings.
Once per minute, the global array index
pointer, GBL_TdataNewPtr is incremented and
the current outdoor temperature reading is stored
into Tdata[GBL_TdataNewPtr]. In this way, pointer
GBL_TdataNewPtr steps through all 1530 locations
of the Tdata[ ] array, filling it up with readings until ■ FIGURE 5.Trend data is stored in a circular data array.
March/April 2019 29
To do this, the MaxTemp/MinTemp limits
are used to drive the map(…) In-HI/In_Low
values. By setting the Out_Low to the bottom Y
coordinate of the graph plot and Out_HI to the
top Y coordinate, the map(…) function is all set
to deliver a fully scaled Y coordinate for each
temperature value we graph.

X Axis Graph
Scaling
■ FIGURE 6.The map function converts data for graphing. It’s also necessary to scale and map the
X axis properly. This process is slightly more
X coordinate. This might be a difficult task were it not for complicated since the user can select trend plot periods
the handy Arduino map(…) function. As shown in Figure of 4, 8, 16, or 24 hours. We are further challenged by the
6, this function will convert an input value (In_Value) to an ‘circular nature’ of the trend memory Tdata[ ] array. To
output value (Out_Value) using a linear straight-line transfer scale X, we need to have an algorithm that will ‘cherry-pick’
function. The passed parameters In_Low, In_Hi, Out_Low, and extract just the 380 points that we need to plot to the
and Out_Hi define the equation of a straight line with an screen from the Tdata[ ] “database” of 1530 readings.
appropriate slope and offset. The function then accepts the This is done by hopping/skipping through the trend
In_Value in “tenths of a degree” and returns the mapped data array in defined steps in order to pick out just
Out_Value in Y axis pixel coordinates. temperature readings that are within the time period we
are showing in our graph. The “Skip_Step_Size” value is
calculated as shown in Figure 7. To trace the graph, we
Y Axis Graph Scaling always begin plotting from the right side of the screen,
To better visualize trends and accentuate even small starting with GLB_TdataNewPtr — the newest and most
temperature changes, we perform automatic “Y axis recent array element stored. In concept, we then march
scaling” every time a new trend graph is drawn. In order from the right screen edge towards the left screen edge,
to do this, the data to be plotted is quickly pre-scanned to pixel by pixel, while repetitively subtracting the Skip_Step_
find the MaxTemp (highest) and MinTemp (lowest) values Size value from GLB_TdataNewPtr.
within the plot data set. In this way, we are ‘stepping back in time’ to retrieve
With these limits in hand, the Y axis graph can be and plot the stored temperature history values as we
“centered” about the mid-point of these two limits. Then, go. We keep doing this until we have plotted all X axis
the overall graph “gain” is adjusted so that MaxTemp values locations of our graph (about 380 points). If you pay close
plot at or near the very top of the graph, while MinTemp attention during graph updates, you’ll see that the graph
values plot at or near the bottom of the graph. does indeed paint to the screen from right to left.

The Lines
Between the
Points
In order to avoid a dotted-line
effect, we actually draw short lines
between adjacent data points to fill in
any spaces that might appear during
large temperature swings. Because
our pixels are so small, we also take
steps to draw “double-wide lines” to
make the trace easier to see.

■ FIGURE 7. X axis scaling formula.


30 March/April 2019
The Challenge of Plotting most straightforward way to print a number to the screen
is to simply read a new temperature value, format it for
Big Characters printing, and then mindlessly ‘draw’ it out in entirety to the
Graphic plotting routines such as fillRect(…), LCD screen. Your smartphone or desktop/laptop computer
drawLine(…), drawPoint(…), print(…), and others are is so fast doing these steps, you can’t even appreciate all
provided by the LCD graphics library and are used that’s happening.
throughout the program to create our finished display. However, with the Mega, our big digits blink even
Unfortunately, the LCD display module itself is pretty basic when their values didn’t change, and we are just erasing
and doesn’t include many on-board line and writing back the same characters to the
drawing, text printing, or other graphics screen. If we insert some logic in front of the
hardware acceleration features. screen writing steps to ensure we only write
This means that the host CPU (our to the screen when we absolutely have to,
Mega) must do most of the work. Getting we can improve performance.
good-looking text onto the screen is a For example, if a temperature value
particularly compute-intensive task. Figure 8 changes from 39.4 to 39.8 degrees, we
shows the high-level steps required to ‘print’ really only need to update and change just
a temperature reading onto the LCD screen. one character; that is, turn the 4 into an 8.
Figure 9 presents the next level of By avoiding the needless rewrites of the
details that show that the CPU must first “3,” “9,” and “.,” we can effectively update
clear out the rectangular background region the display three times faster. In fact, if the
behind the new text to erase whatever was temperature is stable and isn’t changing, we
previously drawn onto the screen. Next, the don’t write anything to the screen!
Mega must retrieve the bit pattern of each By preceding the screen write process
character from a character pattern lookup with a New-character vs. a Previous-
table. character comparison (Figure 10), we can
Finally, the CPU must write each of the avoid rewriting unchanged text.
character pattern ‘foreground pixels’ to the ■ FIGURE 8. Overview of This technique proved to work well and
text “printing” to the LCD.
LCD display memory. Since each of these greatly improves the overall appearance of
actions take many CPU the instrument. It’s pretty
cycles to complete, the slow simple to do and only
(by today’s standards) 16 requires a few bytes of RAM
MHz clock of the Mega is to ‘remember’ what we
noticeably sluggish getting printed to the screen during
the job done. the previous pass through
Although the processes the main loop.
are reasonably fast for small
sized characters (i.e., 10
point fonts), it’s noticeably
Assembly
slow forming the large digits and
of our main temperature
readouts. Since we update
Packaging
these values every couple Challenges
of seconds, the flashing it
causes on these displays is The packaging, wiring,
hard to overlook! and enclosure design for
this project proved to have
its own design challenges.
What Can At first, I thought it was very
be Done handy that the LCD plugged
on top of the Mega CPU.
to Speed After all, this simultaneously
Things Up? ■ FIGURE 10. Improved “Print completes about 20
■ FIGURE 9.Text
String to LCD” scheme. interconnections while
Figure 9 shows that the printing details. creating a solid CPU-display
March/April 2019 31
■ FIGURE 11. Enclosure overview.

always in the back of my mind


for this project. To this end, I
used SolidWorks to model all the
internal parts and come up with the
case design shown in Figure 11.
Connectors on the back side of the
enclosure go to the temp/humidity
sensors. Note: I chose to keep
the indoor temp/humidity sensor
external to the enclosure so that
heat from the electronics wouldn’t
affect the indoor readings.
Figure 12 shows the 3D
printable parts that make up the
project enclosure (five unique
items for a total of seven pieces to
print). An internal CPU-LCD frame
provides the means to secure the
subassembly. However, once joined together, it became LCD/CPU to the front panel.
apparent that there weren’t any convenient mounting holes I printed all the parts with PLA filament and achieved
to anchor the screen to an enclosure opening. very good dimensional accuracy and part fit. As printed,
Additionally, the LCD module obstructs access to the the rear panel has cut-outs for two three-pin sensor
CPU pins that we need to connect to the sensors, RTC connector ports with an additional pair of knock-out
module, and the pushbuttons. Who’d of thought! Here’s features should you wish to add more sensors.
what worked for me.
Tapping Case Parts and
Enclosure Design Putting Things Together
Since I’m always looking for projects to justify the
purchase of my 3D printer, a printed enclosure was Detailed assembly steps that show how the whole
project comes together are found in Figure 13. You
can see that the CPU board mounts to the CPU
frame using 4-40 machine screws (Figure 13_1).
After printing, the CPU-to-frame holes are easily
threaded using a standard 4-40 hand tap. The CPU-
LCD frame subassembly attaches to threaded “boss
features” found on the back side of the front panel.
Rather than use a hand tap, I found that threads
could be easily formed by carefully turning a 4-40 x
.25 in machine screw into each boss. Just go slow
and keep the screw straight and true.
With its self-adhesive backing, Figure 13_3
shows that the 1x4 membrane switch is easily affixed
to the front panel. I color printed custom button
legends onto paper label stock to create appropriate
button labels. A layer of clear tape placed on top of
the new legends will improve their wear resistance.
As an alternative to a membrane switch, you
could use discrete pushbutton switches or even
eliminate mechanical switches altogether by buying

■ FIGURE 12. 3D printed enclosure parts (rear view).


32 March/April 2019
an LCD display module with the
touch screen attached. Uno/Mega
touch-screen LCDs with the same
mechanical layout can be readily
found for just a few dollars more
than the no-touch model I used.
Of course, you’ll have to add
a compatible touch library and
rework the pushbutton control
logic in the software to support this
change.
The two tilt-stand legs are
assembled with 4-40 screws (more
tapping required!) and then are
attached to the rear panel with
4-40 machine screws through
the bottom enclosure vent slots.
Nuts on the backside of the vents
complete the attachment (Figure
13_4). Note in the figure that the
tilt angle can be easily tweaked
after the project is up and running.
The sensor interface PCB
(prototype circuit board), is
mounted to the rear panel with
four No. 4 x 1/4 inch self-tapping
screws (Figure 13_4). Although I
have included Gerber files for a
sensor connector interface PCB this ■ FIGURE 13.
Enclosure and
board is so simple that it could be
final assembly
fabricated using a small piece of
details.
.1 in x .1 in grid prototype board
material. The download materials
for this article have complete details
for the sensor interface board
using either of these construction
methods. your favorite 3D CAD program for tweaks and changes.
Finally, the RTC module slips onto posts projecting
from the rear panel (Figure 13_4). These posts can be
melted over with a soldering iron to retain the RTC module
Wiring Challenges and
or a few layers of two-sided foam tape could be used to Options
simply stick it to the rear panel surface.
Once all the internal wiring has been completed per In order to connect the CPU to the sensors, RTC,
the schematic (see also next section), the front panel is and pushbuttons, one needs to either solder wires to the
joined to the rear panel with four No. 4 x 1/2 inch self- back side of the Mega (yuck!) or figure out a different way
tapping sheet metal screws (Figure 13_5). to make U-turn connections that can redirect the top-
side CPU I/O ports to the back side. I came up with two
different methods to deal with this challenge:
Enclosure Design Files
As mentioned, a full set of 3D printer-ready STL files RTC Wiring: To make the SDA and SCL pin
for all the enclosure parts is included in the download connections between the Mega and the RTC module, I cut
material. You’ll also find the native SolidWorks (2013) individual pins from a strip of long length (~20 mm overall
design files and dimensioned 2D drawings (PDF), as well as length) male SIP pins. I then carefully formed the pins into
STP files that should allow you to transfer the design into a U shape as shown in Figure 14. This enabled the use of
March/April 2019 33
■ FIGURE 14. Making Mega U-turn
connections. Note: LCD panel and
frame are present in view A, but are
not shown in view B.

assignments of your wiring scheme.

Enhancements
and Other
Project Ideas
Falling prices for high quality
female-to-female socket wires to link the RTC to the CPU. color LCD graphics displays make them viable alternatives
Pushbuttons, Sensors, +5V, and Ground Wiring: For to the plain old monochrome text displays or even the
the remaining connections, I used a 36-pin double-row seven-segment LED digital readouts that we’ve come to
male header to make an 18-position U-turn connector. rely on for our microcontroller projects.
By first clamping the header into the vice, I was then able While I’ve described a ready-to-go weather-watch
to bend the short pins close enough to one another, so I device using a graphic display in a fun and useful way,
could make a solder bridge across each of the pin pairs the packaging and design concepts presented here can
(Figure 14B). Build Note: Don’t skip the “vice” as the serve as a launch-point for other projects. In fact, this core
plastic pin frame is easily broken while attempting to bend design has all the elements needed to build a great looking
the individual pins. graphics clock. With the addition of a small speaker, adding
a wake-up alarm is easy.
Once you insert one row of pins into the Mega, Whether it be temperature trends, time and date,
carefully form a slight angle onto each of the outer rows current/voltage readings, battery status, or other variables,
of pins as shown in Figure 14A. This makes it possible to consider giving your next project some extra pizazz by
connect female socket wires from the back side of the including an LCD color graphics display into the design!
CPU board. From this U-turn connector, we can get to +5V, Take care and happy graphing! NV
ground, and all the odd-numbered I/O ports from D23 to
D53. Since the 1x4 membrane switch already terminates
in a .1 in pitch SIP female connector, it can plug right onto
the U-turn connector (pins D37, D39, D41, D43, and D45 REFERENCES
of Figure 14A).
I used discrete female-to-female socket wires to link Arduino IDE, Arduino libraries, useful guides, and references
to the temp/humidity sensor signal lines (Mega pins D23 https://www.arduino.cc
and D25), and the +5V and ground wires to the sensor Graphics thermometer software and hardware details
interface board. Just be sure to count pins carefully so as to https://github.com/Ed-EE-Eng/Graphics_Thermometer
locate and plug everything into the right pins!
As indicated back in the schematic (Figure 3), the gfx Graphics Library
RTC module gets its power and ground from the sensor https://github.com/adafruit/Adafruit-GFX-Library
interface board using a couple more female-to-female Documentation/guideline for using AdaFruit gfx Library
socket wires. https://learn.adafruit.com/adafruit-gfx-graphics-library
RTC Library
Need to Change Port https://github.com/adafruit/RTClib

Assignments? Guideline for Installing and using MCUfriend graphics helper library
https://forum.arduino.cc/index.php?topic=366304.0
While the SDA and SCL wire pair going to the RTC Bounce2 Pushbutton Debouncing Library
are locked pin assignments that you won’t want to https://github.com/thomasfredericks/Bounce2
change, wiring to all the other devices can be moved to
any open pins that might work better for you. This can be DHT Sensor Library
https://github.com/adafruit/DHT-sensor-library
done by simply editing the source code to match the pin
34 March/April 2019
PARTS LIST
ITEM QTY DESCRIPTION SOURCE PN/ORDERING INFO NOTES
1 1 ARDUINO MEGA CPU Arduino.cc ARDUINO MEGA CPU Alt: Search eBay for MEGA compatible
+ Others
https://store.arduino.cc/usa/arduino-mega-2560-rev3
2 1 ARDUINO AC POWER SUPPLY Various, UNO/MEGA POWER SUPPLY, 9 VDC 1A 5V phone charger + cable is an option
eBay
eBay Search: Arduino Uno Power Supply Adapter 9 VDC
3 1 3.5 IN 480x320 LCD DISPLAY eBay 3.5 IN TFT LCD SCREEN MODULE 480x320 Consider adding “Touch Screen” to eBay
FOR ARDUINO UNO & MEGA quiry
Search for: TFT LCD Screen Module 480x320 Arduino UNO MEGA
4 1 DS3231 RTC MODULE Various, DS3231 RTC MODULE
eBay
eBay Search: DS3231 RTC Real Time Clock Module
5 1 CR2032 BATTERY Various, CR2032 BATTERY For use with item 4
eBay
eBay Search: CR2032 BATTERY
6 1 PB1, PB2, PB3, PB4. Various, MEMBRANE 1x4 PUSHBUTTON ARRAY Not req’d if item 3 has touch screen
1x4 PUSHBUTTON ARRAY eBay
eBay Search: 1x4 Matrix Array Keypad
7 1 SENSOR INTFC PCB ASSEMBLY ----- Consists of items a-e below
7a 1 PCB - PROTOTYPE CIRCUIT BOARD Various, DIY Prototype Circuit Breadboard PCB See online build layout details to match 3D
eBay Universal Board 2x8 cm case mtg holes
eBay Search: 2x8 cm Double Side PCB
7b 2 P1, P2. TERM BLOCK HDR 3-POS Digi-Key PCB PART: WM7752-ND @ .78 ea
VERT 3.5 MM PCB MNT. NOTE: MATING PART: WM7733.ND @ $1.14 ea
SCREW TERM MATE REQUIRED
eBay eBay Search: 3-pin 3.5 mm Pitch PCB Plug in Terminal Block
7c 1 P7. 3-PIN RT ANG MALE TERM Digi-Key SAM1051-03-ND @ .25 ea ALTERNATE: Cut from longer strips; eBay
link is for 10 Pcs x 40-pin @ $3.80
eBay eBay Search: 40-pin 2.54 mm Single Row Right Angle Pin Header Strip
7d 1 P5. 6-PIN RT ANG MALE TERM Digi-Key AM1051-06-ND @ .46 ea ALTERNATE: Cut from longer strips
(See notes for item 8)
7e 2 R1, R2. RES 4.7K 1/4W 1% AXIAL Digi-Key 4.75KXBK-ND Value not critical. Can use 4.7K to 10K value,
5-10% precision OK
eBay eBay Search for: 4.7K .25 watt Metal Film Resistor
8 2 S1, S2. DHT21 TEMP/HUMIDITY Various, DHT21 AM2301 DIGITAL TEMPERATURE/
SENSOR MODULE eBay HUMIDITY SENSOR MODULE FOR ARDUINO
eBay Search: DHT21 AM2301 Sensor Module
9 4 NO_4 x .25 IN SELF-TAP SCREW Various STEEL, NUM 4, 1/4 IN SHEET METAL SCREW See McMaster PN for more details
McMaster 90077A106 (Box of 100 Pcs @ $1.45)
10 4 NO_4 x .5 IN SELF-TAP SCREW Various STEEL, NUM 4, 1/5 IN SHEET METAL SCREW See McMaster PN for more details
McMaster 90077A110 (Box of 100 Pcs @ $42.21)
11 4 4-40 x .5 IN SOCK HD MACH Various STEEL, NUM 4, 1/4 IN SHEET METAL SCREW See McMaster PN for more details
SCREW
McMaster 92196A110 (Box of 100 Pcs @ $4.20)
12 4 4-40 x .25 IN SOCK HD MACH Various STAINLESS STL SCKT HD SCRW 4-40 x 1/4 IN See McMaster PN for more details
SCREW
McMaster 92196A106 (Box of 100 Pcs @ $3.92)
13 4 4-40 x .75 IN PHIL HD MACH Various STAINLESS STL PHIL HD SCREW 4-40 x 3/4 IN See McMaster PN for more details
SCREW
McMaster 92196A113 (Box of 100 Pcs @ $4.97)
14 4 4-40 HEX NUT Various STAINLESS STL HEX NUT 4-40 See McMaster PN for more details
McMaster 91841A005 (Box of 100 Pcs @ $3.02)
15 1 INTERNAL WIRING Various MISC PINS, CONNECTORS, WIRES Misc odds and ends
16 1 ENCLOSURE - FRONT PANEL 3D PRINTED FRONT PANEL, 3D PRINTED (PLA) SEE ONLINE DOCS FOR DETAILS
17 1 ENCLOSURE - REAR PANEL 3D PRINTED REAR PANEL, 3D PRINTED (PLA) SEE ONLINE DOCS FOR DETAILS
18 1 CPU/LCD MOUNTING FRAME 3D PRINTED MOUNTING FRAME, 3D PRINTED (PLA) SEE ONLINE DOCS FOR DETAILS
19 2 TILT BASE, CASE MOUNT 3D PRINTED TILT-CASE MNT, 3D PRINTED (PLA) SEE ONLINE DOCS FOR DETAILS
20 2 TILT BASE, FOOT 3D PRINTED TILT-FOOT, 3D PRINTED (PLA) SEE ONLINE DOCS FOR DETAILS
March/April 2019 35
CNC ROUTERS:
BACKLASH
What It is
and How to
Backlash can have a
Measure It
detrimental effect on
tool life and on your CNC
router’s ability to maintain
accurate positioning of
the X, Y, and Z axes. In
this article, we’ll look at
the problem of backlash
in CNC routers. Once you
understand what role
it plays, you’ll want to
diminish its impact on
By Roger Secura
your machine. Whether
you own or intend to build/
buy a CNC router, make it
a habit to routinely check
for backlash. It could save
you some money and/or
aggravation.
36 March/April 2019
I
f you have a metal or wood bench vise in
your workshop, you’ve probably experienced
“backlash” and not even noticed the problem.
FIGURE 1.
For example, if you secure a piece of wood in
a vise and then begin to loosen the jaws, you’ll
notice that the vice handle will rotate somewhere
between 10 to 90 degrees or more before you
see any movement of the jaws.
In other words, the amount of “slop” or “play” in
between the threads of the large lead screw and the
threads within the vise jaws creates a backlash situation.
It’s important to note in our bench vise example
that the delay in the movement (backlash) of the jaws
happens in both directions — tightening or loosening of
the vice.
On a vise, backlash is not too big of a problem, but
on CNC routers, it can put a dent in your tool life and
the accuracy of your X, Y, and Z axes.
Figure 1 shows a cutaway view of the Acme lead
screw and nut setup on my desktop CNC router.
Depending on which direction the stepper motor
rotates, the nut and lead screw attached to the
gantry support board will move the Y axis forward or
backwards.
A close-up view of the Acme lead screw and nut
is shown in Figure 2 below. Notice in the top diagram
how each Acme lead screw thread is engaged on the
right side of each nut thread. Now, when the lead
screw is rotating clockwise (CW), backlash is not a FIGURE 3.
problem because both the lead screw
and nut threads are fully engaged bit (cutting tool) should make wood
with each other (no gap). However, chips no larger than .005” and no
backlash is introduced into the system smaller than .003” in width. In other
when the lead screw changes to a words, you should see wood chips
counterclockwise (CCW) rotation. (not sawdust) flying off your tool bit
Notice in the bottom diagram as it cuts into the workpiece.
how the lead screw threads must Chip load size is important
traverse the gap between the because wood chips remove heat
nut threads before they become from the tool bit. Having too small
fully engaged again. The gap in of a chip load builds up excess heat
between the forward and backward in the tool bit. Heat buildup shortens
engagement of the lead screw and tool life. On the other hand, too
nut threads is called backlash. In big of a chip load can break a small
other words, backlash (hatched diameter tool bit.
area in Figure 2) can be seen in Backlash can change the
either direction as a direct result of recommended chip load size. During
rotational shifts made by the lead a “climb” cut scenario, the cutting
screw. tool edge (flute) tends to grab the
Even though we’re talking about workpiece. Consequently, the cutting
thousandths of an inch here, it can tool will move a distance equal to the
be enough to cause a couple of amount of backlash in the system.
problems. For example, look at the As you can imagine, backlash
“Chip Load” chart in Figure 3. also diminishes the accuracy of a
The chart is recommending that CNC router. Accurate positioning of a
for hardwood, a 1/8” diameter tool FIGURE 2. tool bit is essential when locating the
March/April 2019 37
FIGURE 4. FIGURE 5.
center of a hole, engraving an intricate pattern, or adhering
to drawing tolerances.

BACKLASH: HOW TO MEASURE IT


Measuring backlash is not that hard to do — provided
you have the right equipment. Figure 4 shows the “Dial
Indicator” ($15) and holder ($23) I purchased from
Amazon (see Parts List).
The dial holder has a magnetic base. It’s normally used
on a vertical CNC milling machine because it can attach
itself to the machine’s metal framework.
Since the spoiler boards on CNC routers are normally
made of wood, you have the option of finding a small steel
plate somewhere and using it as a base for the dial holder.
Or, you can construct my simple wood and neodymium
magnet ($9; Amazon) contraption shown in Figures 5
and 6. Either way, just make sure the dial and holder don’t
move while testing for backlash.
(WARNING: The magnets used in this article are
surprisingly strong. I got the tip of my finger caught
between two of these neodymium magnets as they
accidently snapped together. It caused a small blood blister
to appear. Please, don’t let small children get a hold of
FIGURE 6. these magnets.)
38 March/April 2019
TIME TO TEST YOUR RIG
In preparation for the backlash test, you need to
turn off any backlash compensation in your CNC control
software. In Mach 3, for example, just go to the ‘Config’
menu and select ‘Backlash’ from the list. Before you clear
(zero out) any default settings, take your phone and snap
a photo of the current screen — just in case you want to
return to the original settings after the test.
It’s also important to verify that your lead screw
couplings on all three axes are tight. In other words, if
the connectors between the stepper motors and lead
screws are loose, the stepper motor shaft will slip inside
the coupler. This can cause a delay in moving the X axis.
Therefore, any slippage in the couplings must be addressed
or unexpected errors will be introduced into the backlash
test.
Okay, you’ve assembled all the required equipment
you need to measure backlash. Now, let’s start with the
X axis. Set up the dial indicator and holder as shown
in Figure 7. Make sure the dial indicator plunger is
perpendicular to the point of contact.
Now, SLOWLY move (jog) the X axis towards the dial
indicator until the dial indicator plunger is depressed about
a quarter of an inch. This procedure is called preload. The
preload insures that any backlash in the forward motion of
the X axis is eliminated. Next, turn the outer rim of the dial
indicator so the needle reads zero on the dial.
In Mach 3 or your particular CNC control program,
set the ‘Jog Mode’ to ‘Step’ and equal to one thousandth FIGURE 7.
of an inch (.001”). Now, move the X axis towards the dial
indicator by tapping the X axis jog button 10 times. The Now, reverse the movement of the X axis by again
X axis should move the dial indicator needle to the .010” tapping the jog button 10 times in steps of .001”. If the
mark. Note that each line (mark) on the dial is .001”. needle on the dial doesn’t land on the zero mark, you have

Your Single Source of Electronic Equipment, Tools, and Components

01DM820B 01DMMY64 01DMM9803R Sweep Function Generator


Digital Multimeter Digital Multimeter Bench DMM 3MHz, 6 Waveform Functions, Int/Ext Counter,
Super Economy 32 Ranges True RMS lin/log sweep
DMM - Volts, current, Including temperature, Auto and manual Model FG-30 $135
Resistance, Transistor capacitance, frequency range, RS232C (no display)
and Diode Test. and diode/transistor standard interface. Model FG-32
$7.50 $139.95 $195
Includes Leads testing
$29.95 Runs on DC or AC (5 digit display)

01DS1102E 01SDS1052DL DC Power Supplies


100MHz Rigol Oscilloscope Siglent 50MHz DSO Model HY3003
Variable Output, 0-30VDC,
Features: 1 million points of
deep memory, FFT, record
500MSa/s Sampling
32K Memory 0-3Amp. $95
and replay, roll mode, alternate trigger mode, and 6 Digit Frequency Counter Model HY3003-3
USB Interface Two 0-30VDC, 0-3Amp Variable
adjustable trigger sensitivity
$399 7” Color TFT-LCD Screen $279 Outputs plus 5V 3A fixed. $195

Parallax Board of Education Full Kit BOE Full Kit $98.90 0603ZD98
48W Soldering Station
USB version with Stamp and USB Cable. Parallax 7.5V Power Supply $8.95 Temp. Controlled
$15.25
310oF~840oF

1 (800) 972-2225 | http://www.elexp.com | [email protected]


March/April 2019 39
FIGURE 8. FIGURE 9.

some backlash in the amount the dial needle is away from STEP AND REPEAT
the zero mark.
For example, if the dial indicator needle moved from Checking for backlash on the Y axis and Z axis on your
zero to .010” in the forward direction on the X axis, then router is just a matter of repeating the procedure we used
it should move from .010” to zero in the reverse direction. on the X axis. Figure 8 shows how I checked for backlash
If you find when you reverse the movement on the X axis on my Y axis. Figure 9 shows the setup for my Z axis.
that the needle lands on the four thousandths mark on the After you test for backlash on the X, Y, and Z axes,
dial, you have .004” of backlash on your X axis. calculate an average for each axis.
Now, repeat the above procedure a few times at Now, enter the test results into the CNC motion
different locations along the length of the X axis. controller’s backlash screen.
Finally, once the
PARTS LIST backlash problem
is eliminated from
ITEM QTY DESCRIPTION PART# SOURCE APPRX COST your machine, run
1 1 Neodymium Round Base Magnets HLMAG05 Amazon.com $8.99
with Mounting Screws (pack of 4)
the setup procedure
for “Steps per Unit”
2 1 Magnetic Base for Dial Indicator KAMB50F Amazon.com $22.99 in Mach 3 (or in
whatever CNC
3 1 Triton 1” Dial Indicator, ALL-52000 Amazon.com $14.45 control software
.001” Graduation Travel
you’re using). This
40 March/April 2019
will insure the stepper motors are rotating the correct
number of steps for a given unit of measurement.
In other words, when the digital readout (DRO) in your
FIGURE 10.
CNC control software displays 7.00” of X axis movement,
your router will have moved exactly 7.00”.

COMBATING BACKLASH
There are two ways you can reduce the effects of
backlash on a CNC router: software compensation or
hardware compensation.
On the software side, you can manually adjust the
amount of backlash compensation on the X, Y, and Z axes
through your CNC control software. For example, go to the
main screen in Mach 3, and select ‘Config’ from the menu.
Then, select ‘Backlash’ from the list.
On the hardware side, backlash can be corrected by
adding a spring loaded “anti-backlash nut” assembly to the
lead screws on all three axes (see Figures 10, 11, and 12).
Users who own or are building a rack-and-pinion type
of CNC router can employ spring-loaded tensioners, anti-
backlash split pinion gear, or a dual pinion drive to
reduce backlash.

LAST WORD ON BACKLASH


It’s possible to achieve zero backlash on your X,
Y, and Z axes either by installing some anti-backlash
hardware and/or adjusting your CNC control
software. Generally speaking, any backlash that is
above .007” is better minimized with anti-backlash
hardware rather than trying to adjust it within your
CNC control software.
Typically, .001” or .002” of backlash per axis is
an acceptable amount of play for a CNC router that FIGURE 11.
cuts wood, plastic, and foam.
With that being said, you shouldn’t become obsessed
with the goal of completely eliminating it from your CNC
router. A certain amount of clearance (play) between
the lead screw and nut is necessary in order to allow for FIGURE 12.
thermal expansion/contraction, debris extraction, and
lubrication.
Finally, since normal usage of any mechanical system
produces wear and tear, it might be a good idea to
routinely test your machine every 3-4 months just to verify
the anti-backlash system is working as expected. Any minor
backlash problem (few thousandths) you discover can be
fixed within your CNC control software. NV

Post comments on this article and find any associated


files and/or downloads at www.nutsvolts.com/magazine/
issue/2019/03.
March/April 2019 41
Getting Started
in DIY Modular
Synthesis

Case and Power


Like most vintage audio gear, modular synthesizers have By Steve Harmon
been steadily gaining popularity and accessibility since
the mid-1990s for both hobbyists and electronic musicians
alike. Providing a hands-on experience into the deep
world of sonic exploration, modular synthesizers are
an unbeatable way to understand the building blocks of
synthesis and sound in general.

Unlike closed keyboard-based synthesizers, modular


synthesis requires users to physically create “patches”
with cables, knobs, and switches. The elementary
fundamental aspects of sound are exploded into the real
world. The experience is far different than the ‘menu diving’
practice common to many digital keyboards and computers.
Photos/graphics courtesy
Modular synthesis will help you to better understand your of Scott Rise
computer- or keyboard-based gear by breaking down the https://division-6.com
essential elements that are inherent to all synthesis.
42 March/April 2019
What is a Modular Being able to touch and see an exploded view of the
basic elements of electronic sound creation leads to a
Synthesizer? better understanding of how sounds works in general and
Modular synthesizers are composed of many separate a different sense of creativity. Modular wasn’t dead, it was
‘modules,’ typically housed behind a flat control panel just hibernating! When a small German company called
that provides one or more sound-creating functions. The Doepfer started manufacturing modular synthesizers in the
essential functions are: frequency (provided by oscillators 1990s, patch cables, analog oscillators, and knobs were
in various waveforms); volume (provided by amplifiers); an instant nostalgic and performance hit! Fast forward to
shape (provided by envelopes); and tonal contouring 2019 … there now are hundreds of small and large modular
(waveshapers and filters). companies from Roland to Moog to boutique enthusiasts.
Control voltage (CV) is voltage used to manipulate Even better, modular synth DIY has never been cheaper or
these variables with other modules or physical controllers easier to get into.
such as keyboards. These basic functions can be combined In this article, I want to give you an overview on
in thousands of ways to create an infinite palette of sound. how to get started making your own Eurorack DIY
modular synthesizer. (Eurorack was introduced by audio
Brief History manufacturer Doepfer in 1995.) I’ll be taking you through
the initial steps on how to make or source a case and how
Electronics have been used in sound generation and to get it properly powered.
manipulation since the 1950s, but started to take greater Why choose Eurorack when there are other great
shape after the advent of the transistor. Transistors were formats such as 5U (Moog, Synthesizers.com), 4U (Buchla,
quite expensive when innovators such as Bob Moog and Serge), Frac (PAiA, etc.) 3U, and even more?
Don Buchla started inventing their modular formats in the I asked myself that same question when I decided to
1960s. Advances in technology brought down the price of get into making DIY synths and concluded that I really
essential components, and also led to integrated compact wanted to manufacture kits and modules in the format that
keyboard-based synthesizers that took over the market in is used by the most people with the largest community.
the early 1980s. Eurorack took the cake by a large margin.
These machines started to incorporate digital If you want to build your system around a different
technologies such as MIDI (Musical Instrument Digital format, know that there is an increasing amount of
Interface) and were much more compact and easier to use information out there that is easily found.
in a musical performance setting. Unfortunately, modular
seemed to have lost its day in the sun to make way for
“better” tactile performance, presets, digital ICs, etc.
Building a Case
Not so fast! We’re starting here because we need to have

Synthrotek MST System 104 with Alchemical audio touch controller.


March/April 2019 43
Slide nuts.

Synthrotek modular rails with 3U 19’ mounting


brackets.

Nut strips.

Synthrotek modular rails. Eurorack 6U wood cheek ends.

somewhere to house the modules and to attach a power Once you’ve selected your enclosure or ends,
supply (and power bus, etc.). Of course, you can bypass you’ll need a way to mount your rails. Most people use
this section and move straight to power if you want to aluminum slotted rails that contain small square nuts or
purchase a premade unpowered case from the many nut strips that fit into the slotted channel. Companies that
manufacturers out there. You can even buy a kit if you like produce these are TipTop, Vector, and Synthrotek.
for this part. First, you need to determine if you want your If you don’t want to purchase this type of hardware,
case to be portable (such as a suitcase) or something that you can always use some thin strips of wood. One major
is intended for studio and mostly indoor use. If you intend downside to using wood is that your mounting holes will
on performing live music or noise with your modular, you eventually become loose or split if you plan on moving
may want to opt for a portable case that will keep your your modules around (which is quite common and part of
equipment more secure. the fun).
Eurorack modules have exposed PCBs (printed circuit Eurorack modules have a constrained height of 5.06”
boards) and components that are not intended to be (128.5 mm) and the width can vary in HP (Horizontal
exposed to weather and moisture, so choose something Pitch). Each HP is .2” and modules can vary from 2HP to
like a suitcase, make/find a wood box, or even use some 60HP and even more!
cheek ends (or brackets that allow your modular to fit into Module depth varies quite a bit also, but I’d
19” or 23” racks) that can be attached to mounting rails. recommend around 4-5” of depth for your case —
44 March/April 2019
especially if you plan on building
many of your own modules.
In short, you need to have an
opening of at least 5.06” (perhaps a
smidge larger) per row of Eurorack
modules. Eurorack is mostly
considered a 3U sized format
(although 1U modules also exist
and are growing in popularity), so
folks will describe the size of their
system in these terms: “I have a 9U
104HP Eurorack system.”
Vector and Synthrotek rails are
9/32” (7 mm) tall. If you plan on
using wood for mounting rails, it
would be wise to make these no
more than 25/64” (10 mm) tall so
Eurorack flying bus cable and Eurorack power distribution board.
as not to bump into the module
PCBs or components.
In order to mount your rails and support your modules. There will be some templates
precisely, some manufacturers have made various brackets available in the downloads for this article.
that attach to their rails. Pulp
Logic, Synthrotek, and TipTop all
have various solutions for these
The “U” designation
mounting brackets. If you’ll be
refers to the size of a
drilling out the sides of your case
module; specifically, its
or cheeks to mount the rails, just
height. For example, 1U
make sure they are 4.741” hole
is 1.75” H, while 5U is
to hole for 3U and 1.389” for 1U
8.75” H.
when you’re using Vector and
Synthrotek brand rails. Refer to the
manufacturer’s specifications if
using a different brand.

Mounting
Modules to
Rails
If using wood to mount your
modules, choose small and shallow
3/32” or 1/8” (2.5 mm or 3 mm)
shaft diameter wood screws. When
using aluminum extruded rails,
you’ll have to choose between
sliding square nuts or strips of metal
that have pre-drilled and tapped
holes (aptly called nut strips). These
also come in 3/32” or 1/8” holes
and will require matching machine
screws. Most modular companies
ship 1/8” x 9/32” (3 mm x 7
mm) mounting screws with their
modules or kits.
As you can see, there are
many options on how to enclose Synthrotek MST System 104 on workbench
March/April 2019 45
Finding a pre-made power supply that has all three rails
is less common in a wall wart type of supply. Your options
to source or make this supply are quite expansive. You
can buy assembled or kitted power supplies from various
modular manufacturers, but you can also make your own
linear or switching supply. What you want in the end is a
power supply that will be able to handle the amount of
current draw that your modules will require.
How much power will you need? That greatly depends
on how many modules you’ll be using. There is no perfect
rule of thumb, but you can plan on at least 1A for the
+12V rails, .5A for the -12V rail, and 0 to 250 mA for the
+5V rail. You very well may need more!
Some commercially-available power supplies are Row
Power from 4MS company, TipTop μZEUS, and Synthrotek
Super Power. These three options are made into 4HP
modules for very easy case mounting that requires no
additional hardware.
Most manufacturers provide their modules’ current
draw for each rail in their product documentation
since they tend to make multiple versions. If buying
commercially-available units, there’s a great resource at
Eurorack power supply specifications. modulargrid.net that allows you to spec out your system’s
power needs. You can mount your power supply in various
Power ways such as with glue (we like E6000), double-stick 3M
Most Eurorack modules require power in order to foam tape, or screws.
operate. There are a host of unpowered or passive utility Once you have the appropriate amount of power
modules such as mixers, multiples, and some logic, but for your system, you’ll need to get that power to your
these are less common and must be used with modules modules! Eurorack uses 2x5 or 2x8 rows of 2.54 pitch
that are powered. header pins and sockets to connect the power, so you’ll
The Eurorack power standards have three isolated need a bus system that utilizes this standard. Many
power rails which are +12 VDC, -12 VDC, and +5 VDC, manufacturers produce power bus boards and kits as well
and shared ground. Most all modules use +12 volts and as flying bus cables that connect power headers to ribbon
some -12 volts (as most op-amps require dual power cable (this works quite well in open cases such as those
supplies). Some modules — especially digital — use a +5 that are made up of cheek ends and rails).
rail, but it’s less common and not necessary when you are Spend some time figuring out what type of case you’re
getting started. interested in (portable for gigs or a studio solution) before
jumping in. If you’re on a budget (or thrifty!), you
can find an old hard suitcase or shelving unit at a
local thrift store. You can even find the parts you
need to make a power supply quite easily. Just take
2x 12V wall warts and wire them up according to
the diagram included here.

Closing Thoughts
Know that modular synthesis is highly addictive!
You’ll probably outgrow your first case and/or power
in short order.
Make sure you keep an eye out for future
articles that will give you more info on how to start
building your own modules and start making some
noise! NV
Post comments on this article and find any
Eurorack +12V and -12V power supply using two associated files and/or downloads at www.
ungrounded walwarts. nutsvolts.com/magazine/issue/2019/03.
46 March/April 2019
Extreme Robot Spring HamFest Season Specials!!
Motor Control Use 10% off promo code “HAM2019”
www.robotpower.com
Scorpion Ultra for any in stock items on our website!
The BIGGEST 7V - 36V
Featured Items This Month!!
6
2x - 70A Peak H-Bridges
Scorpion EVER Big Power!
6
6 50A continuous w/cooling
Current/Temp protected
Hantek D272 $209.95
6
Big Bots! 6 R/C inputs w/mixing
6
6
4.50" x 2.35" x .7”
Enclosure available
70 MHZ Oscilloscope, Waveform
Generator & Digital Multimeter
www.CircuitSpecialists.com/hantek2d72

Big Motors! TDGC2-2D $104.95


20 Amp Variable AutoTransformer
“Variac”
www.CircuitSpecialists.com/tdgc2-2d

MADE IN
CSI-TC1 $27.95
The Tiniest Electronic Component Tester
THE USA Scorpion EVER Detects many common components!
www.CircuitSpecialists.com/csi-tc1
Scorpion Nano
6 4V - 16V
6 2x - 4A Peak H-Bridges
6 2A continuous
6 Current/Temp protected
R/C inputs w/mixing
6
6 18.5mm x 15mm x 5mm www.CircuitSpecialists.com
6 ~5g 800-528-1417 - 480-464-2485
Phone: 360-515-0691 s [email protected]

March/April 2019 47
JUST FOR FUN HISTORY

The Radio
Station that
Bridge Built

I
t was 1923, and radio was the learn from lecturers holding forth on their
phenomenon of the day. Over 600 areas of expertise. A few tried to make sense of
broadcast stations were on the air, broadcast guitar or swimming lessons.
and Americans bought 100,000 Those without radios gathered in taverns
receivers that year. (Sales would jump to and restaurants to listen to election returns and
1,500,000 in 1924.) descriptions of baseball games.
This new instant mass medium flashed New radio owners everywhere strung wire across
their rooftops to make aerials, and then puzzled out how
news of important events around the country
to connect a loudspeaker to the set, along with the A, B,
in minutes instead of days. In addition to news, and C batteries the setup required. (Soon enough, “house-
tens of thousands tuned in to hear music and current” radios would come along; most of the early ones

Typical components and hookup for a radio receiver in 1923.


48 March/April 2019
By Michael A. Banks

were designed to draw power from fittings screwed into


lamp sockets.)
Once the radios were set up, many owners hosted
“radio parties” and danced to the latest jazz music with
their friends.
At the same time, the game of Bridge was sweeping
the country. It had been brought to New York from
England in 1893. Here, as across the Atlantic, Bridge
replaced the popular game of Whist as a top pastime,
and quickly spread across the nation.
By the early 1920s, there were magazines and books
devoted to Bridge. Regional, national, and international
tournaments received extensive newspaper publicity.
From the print coverage sprang Bridge authorities and
even superstar players. Bridge was big business.
It was natural when, late in 1922, it occurred to
someone in the marketing department of the United
A deck of Bridge cards. These were 1/4” narrower than
States Playing Card Company — then and now the conventional playing cards.
world’s largest producer of playing cards — that radio
might be used to promote Bridge, along with the Bridge Mason, OH (about 40 miles northeast of Cincinnati) and
decks and books published by the company. applied for a broadcasting license. The purpose would be
Such promotion would not be through radio to broadcast programs that promoted the game of Bridge
advertising, however. On-air advertising was all but non- in general and US Playing Card products in particular.
existent in 1923. The Department of Commerce (which at US Playing Card was assigned the call letters WSAI
the time regulated radio) had yet to develop guidelines for and the AM frequency of 970 kilocycles. This frequency
advertising, and it was generally accepted by broadcasters was also occupied by Cincinnati’s largest station, WLW, so
that commercial use of the airwaves was prohibited. the two stations would have to divide up the time used.
A good many radio stations were operated by radio This was not uncommon in the early 1920s, because
manufacturers, as a means of stimulating sales. Radio the Department of Commerce had allocated very few
retailers, churches, newspapers, universities, hotels, and frequencies in the AM band for commercial broadcasting.
even Sears and Henry Ford owned radio stations. None Deciding to go first-class all the way, the company
sold advertising, although station owner’s products or constructed a modern building on its transmitter site,
causes were mentioned frequently, and this justified the along with twin 250 foot towers to support the broadcast
cost of building and maintaining a station. antenna. The very latest thing in radio transmitters was
This being the situation, US Playing Card decided to ordered: a 500 watt Western Electric Model 101A. This put
start its own station, and thus combine the immensely WSAI at the leading edge of radio technology and would
popular game of Bridge with the radio phenomenon. The be sufficient enough to send WSAI’s signal across most of
company purchased a parcel of land on high ground in North America (there being little interference from other
March/April 2019 49
The station went on the air to give buyers a reason
to buy radios, as so many radio makers did back
then. Its initial focus was on classical music and
“educational lectures.”
The two transmitters arrived in Cincinnati in
the same railroad car in March 1923, inspiring a
good-natured race to see which station would get its
transmitter on the air first. WLW won, going on the
air in April. WSAI engineers put its transmitter on the
air in June.
WSAI offered listeners Bridge lessons, talks
about Bridge strategy, reports on tournaments, and
much more — including a daily series of Bridge
games. Noted players such as Sidney S. Lenz, Ella
G. Pimm, Milton Work, and E.V. Shepard would play
sets of games, narrating as they played. Advance
announcement of the hands dealt the players were
given on-air. The quality of the US Playing Card
Bridge decks they used was mentioned frequently.
However, there were few hardcore mavens who
would tune in to nothing but Bridge games and talks,
so WSAI provided other entertainment. Listeners
enjoyed the Toadstool Orchestra and the Bicycle
Male Quartet (“Bicycle” being a company brand),
along with news and “Midnight Entertainers.”
A unique element of WSAI’s programming was
a carillon with 12 bells, built in 1924. According to
the company, this was the first set of chimes built
for radio broadcasting. The bells were designed
The 500 watt (yes, 500 watts!) transmitter that WSAI went and cast by the Meneely Bell Company of Troy, NY.
on the air with in April 1923. The transmitter was built by The instrument was housed in a four-story tower of
Western Electric. neo-Romanesque design, added to the four-story US
Playing Card building at its main entrance.
stations). The station’s studio was located in the US Playing The tower housed bells from 18 inches to 5-1/2 feet in
Card’s headquarters building. diameter. A clock was included, with a face on each of the
By coincidence, WLW had ordered the same tower’s four sides. Music from the carillon was a hallmark
transmitter from Western Electric to install in a new remote- of WSAI programming. All of this was underwritten by the
controlled broadcast station to the west of Cincinnati. increasing sales the company enjoyed as the result of its
WLW’s parent company, Crosley, manufactured radios. Bridge broadcasts.
Late in 1926, the very first radio network
Whist is the direct forerunner of Bridge and is of English origin. Before — the National Broadcasting Company’s NBC
the days of auction Bridge and contract Bridge, it was a very popular network — was established, with WSAI among the
game, but these days, Whist has been superseded by Bridge. founding members. WSAI began sending its Bridge
programming out through NBC’s “Red” network
Whist is a trick-taking card game developed in England. The English to stations in Boston, Philadelphia, Buffalo, Detroit,
national card game has passed through many phases of development, Los Angeles, Milwaukee, and other major US cities.
being first recorded as Trump (1529), then Ruff, Ruff and Honours, Thanks to the network, people listened to radio not
Whisk and Swabbers, Whisk, and finally Whist in the 18th century. only in their homes, but also in shops and other
commercial establishments. It was possible to listen to
In the 19th century, Whist became the premier intellectual card game WSAI on radio-equipped passenger trains as well.
of the Western world, but Bridge superseded it in this position by about WSAI was heard not only in most of the United
1900. Partnership Whist, with four players in two partnerships, remains States, but also as far away as New Zealand at night,
popular in Britain in the form of social and fund-raising events referred thanks to the “skywave” phenomenon and to the
to as Whist drives. station’s excellent transmitter and tower location. It
50 March/April 2019
helped that no other station used the
same frequency as WSAI, except for
WLW which was not on the air when
WSAI was broadcasting.
Obviously, US Playing Card
spent a considerable amount of
money establishing and maintaining
WSAI. In addition to the initial cost —
which ran well into five figures — the
company had to hire technical and
creative staff. The cost of electricity
and special telephone lines required
to send studio programming to the
transmitter ran into several thousand
dollars per month. However, the
impact on US Playing Card’s sales
was enormous.
US Playing Card supported the
Bridge broadcasts with extensive
magazine advertising, providing
radio schedules for all the cities
where the games could be heard.
To build customer enthusiasm
and measure the effectiveness
of the broadcasts, the company
encouraged listeners to write in for
printed reports of each game. Also
available were advance listings of the
hands to be played in future games,
so listeners could play the hands
their way, then compare their play An ad in “American Magazine” WSAI’s reach extended into
with that of the experts. detailing WSAI’s Bridge Canada, so radio Bridge was
Increased sales of card decks programming, with station listing promoted to listeners there as
and other merchandise, outside and schedule. well as in the US. WSAI’s Bridge
stars played on a radio-equipped
advertising, and revenue received for Canadian National Railways
network feeds more than paid for passenger train.
WSAI’s broadcasts for several years.
By 1928, however, US Playing Card was beginning to feel informally suggested to the owner of the largest radio
burdened by the station. It was, after all, in the business station in Cincinnati, WLW, that WSAI might be for sale.
of manufacturing playing cards, books, score sheets, and Negotiations were opened and US Playing Card quickly
other gaming accoutrements. Moreover, the transmitter, reached an agreement to sell WSAI to WLW.
tower, and studio (located in US Playing Card’s main office Today, WSAI can be found at 1360 on the AM dial. Its
building in Cincinnati) wasn’t really needed; Bridge games 5,000 watt transmitter limits its coverage to the “tri-state”
could originate and be transmitted from any NBC network area where Ohio, Indiana, and Kentucky come together at
station’s facilities. Plus, national advertising over NBC was Cincinnati.
less expensive than WSAI’s operating costs. WSAI’s current format is “sports/talk” (it’s a Fox Sports
US Playing Card executives made the decision to affiliate). Few of its listeners are aware that WSAI was once
get out of the radio business. The company’s attorney “the voice of Bridge.” NV

The United States Playing Card Company


www.usplayingcard.com
Post comments on this article and find any associated
WSAI (Fox Sports Radio) files and/or downloads at www.nutsvolts.com/magazine/
https://foxsports1360.iheart.com issue/2019/03.
March/April 2019 51
Libraries and
Headers in C:
A Tutorial
When you start to write libraries, it takes time to read documents,
follow directions, and experiment with simple functions.
Fortunately, after you understand how to create libraries and
header files for the software tools you use, you’ll have a useful skill
that can simplify programming tasks.

I
f you have written a program for a microcontroller libraries without thinking much about them.
board such as the Arduino, Raspberry Pi, or Propeller In this tutorial, I’ll explain how software uses libraries
QuickStart, you have relied on software libraries that and how you can create your own.
provide constants and functions. Often, we use software Each software development tool has its own way
52 March/April 2019
By Jonathan A. Titus Post comments on this article and find any associated files and/or
downloads at www.nutsvolts.com/magazine/issue/2019/03.

to create libraries. For the examples that follow, I’ll use so now we would have the file SimpleTest.o. The suffix
the Parallax SimpleIDE for the Propeller microcontroller indicates object code. However, the compiler doesn’t
(MCU). Several reasons explain why we use libraries: have all the information it requires to give us ready-to-run
machine code. It still needs information from library files
1. They save time. Libraries give us the foundations for such as stdio.c or servo.c.
languages such as C and C++. They comprise functions, The header file gives the compiler spaces for the linker
operations, and constants so we don’t need to create to fill with the library function call, arguments, and returned
them. Think about functions printf() and putc(), as well as value so a precompiled function can be linked.
constants pi (3.14159...) and e (2.71828…). The final step sends all the object files for SimpleTest,
2. They separate us from implementation details. We stdio, servo, and others to a linker that combines all object
don’t need to know how the printf() or I2CStart() functions files seamlessly. Lastly, we get an executable machine
work, for example. We know they work, and we use them language file for our MCU. Our executable file often goes
according to published specifications. through a loader that translates the addresses from the
3. We can create our own libraries and re-use them linker into the addresses required by a specific MCU’s
many times. memory map and register arrangement.
4. They simplify processor upgrades and library In many cases, we use precompiled library files to save
software changes. Suppose you create a motor control time. Then, our software tools don’t need to compile large
project around an X board and use a motor control library libraries each time we make a change to SimpleTest.c.
that includes functions such as set_FWD(), set_REV(), and Precompiled object libraries have a dot-o extension.
Motor_Start(). After a while, you decide to upgrade to the Precompiled functions also offer security because users
company’s XQ board and use the new XQ motor control do not see the source code. That becomes important for
library. The new library provides the same functions, so companies that aim to keep their intellectual property
your software doesn’t need revision. The library’s code confidential.
changes are hidden from us. In general, we create static libraries for MCUs that our
compiler incorporates into our application program. These
To be fair, we can find several reasons to not use a static libraries have a dot-a (archive) extension. Operating
library: systems such as Windows and Linux provide static and
dynamic libraries. The operating system links dynamic
1. Can we trust the code? Who wrote it, and did they libraries to programs at run time, so several applications
document the interface or functions and how they work? that run simultaneously share a single dynamic library. In
Did they add “protection” code? (You’ll learn about that Linux, for example, you would see dynamic library files
later.) with a dot-so (shared object) extension. (File extensions
2. Often it’s easier to copy and paste functions as may vary by compiler type.)
needed. Luckily for us, when we click on an IDE (integrated
3. Creating a library can get complicated and involve development environment) menu item such as
many steps. Is it worth the effort if you only use the library “Build,” “Build Project,” or “Verify/Compile,” the IDE’s
once in a while? preprocessor, compiler, and linker work their magic and
automatically combine the needed object files. The IDE
Even if you never create a library, you probably want to might also let you immediately load the code into your
know how they work and what they contain. This tutorial MCU so you can test it.
provides information that gives you a good start. For various reasons, some programmers take a
command-line approach to compiling and linking code
How Our Tools Work
Before we discuss library details, you should References
understand how programs go from text files to the machine 1. ISO/IEC 9899:2017, “C17 Ballot,” www.open-std.
language (1s and 0s) that tells an MCU what to do. When org/jtc1/sc22/wg14/www/abq/c17_updated_proposed_
we key a program into a text window and save it as, say,
fdis.pdf. Section 6.10.2, “Source file inclusion.”
SimpleTest.c, we have created source code. When we’re
ready, our software development “tools” pass SimpleTest.c 2. “Name Mangling,” Wikipedia, https://en.wikipedia.
through a preprocessor that executes directives such as org/wiki/Name_mangling.
#include.., #define.., and #endif. 3. Drysdale, David, “Beginner’s Guide to Linkers,”
The “preprocessed” information next goes to a https://www.lurklurk.org/linkers/linkers.html.
compiler that converts the software into an object file,
March/April 2019 53
files. For more information, refer to the Resources. SimpleIDE to flash LEDs on a QuickStart board. The first
statement indicates my code needs the standard Propeller
library Simpletools.h:
Use a Library
The IDE you use (say, Microchip MPLAB, Parallax /*
Blink_Lights.c
SimpleIDE, mbed, or Arduino) must include standard Blink all LEDs on QuickStart board five times
libraries specified in the C language standard. Commonly */
used libraries offer math, string, time, input-output, and
#include “simpletools.h” // Include simpletools
other functions.
When you look at a program listing, you’ll see void LED_Test (void)
precompiler directives at the top that indicate the library {
int n;
(or libraries) the program needs. The necessary #include int cycle_count;
statements supply a library file name followed by a dot-h cycle_count = 5;
extension. We call the dot-h files header files. while(cycle_count > 0) // Loop 5 times
{
Here’s a simple program I created with the Parallax for (n = 16; n<24; n++)
{

Resources high(n);
pause(100);
//
//
Set I/O pin n high
Wait 0.20 seconds
low(n); // Set I/O pin n low
To download the improved instructions needed to create a pause(100); // Wait another 0.02
Propeller library with the Parallax SimpleIDE, go to this article’s seconds
downloads. }
cycle_count--; // decrement loop
counter
For more information about the gnu compiler collection and }
the compilation and linking processes, please refer to, “An }
Introduction to GCC for the GNU Compilers gcc and g++,” by
int main() // main code
Brian Gough, Network Theory Limited, Bristol, UK. 2005. ISBN:
{
9780954161798. LED_Test();
}
Parallax SimpleIDE User Guide, https://learn.parallax.com/sites/ // End of Blink_Lights.c
default/files/content/propeller-c-reference/landing/SimpleIDE-
User-Guide-9-26-2.pdf. The functions high, low, and pause do not occur in
the C language. They get declared and defined in the
“Propeller C Library Studies,” a multipart series about libraries simpletools.h file or in its subfiles. Parallax documents
and how to create them at https://learn.parallax.com/tutorials/ clearly explain the functions and constants available, so I
language/propeller-c/propeller-c-library-studies. use them without a second thought. I don’t need to know
how the high, low, and pause functions work, although I
“How to Compile and Run a C Program on Ubuntu Linux,” Keld could investigate them if I chose to. (Caution: Some IDEs
Helsgaun, http://webhotel4.ruc.dk/~keld/teaching/CAN_e14/ use complicated “trees” to arrange library files, so a search
Readings/How to Compile and Run a C Program on Ubuntu through them might seem like a trip down a rabbit hole.)
Linux.pdf.

“Writing an MBED Library,” https://os.mbed.com/cookbook/ Includes Have Two Formats


Writing-a-Library.
The names of header files appear at the start of a
“Writing a Library for Arduino,” https://www.arduino.cc/en/ program in two formats:
Hacking/libraryTutorial.
#include <stdio.h>
#include “servo.h”
“Arduino API Style Guide,” https://www.arduino.cc/en/
Reference/APIStyleGuide. A header file name between carets (#include <stdio.h>)
causes the preprocessor to search for the named file within
“Starting a New GCC Static Library Project,” Atmel Studio 7 directories and folders automatically created when you
User Guide, Section 3.2.6, ww1.microchip.com/downloads/en/ install an IDE. Here, you’ll find the libraries required by the
DeviceDoc/Atmel-Studio-7-User-Guide.pdf. C and C++ standards. (Read the IDE supplier’s documents
that explain how to use its libraries before you write code.)
“Libraries,” http://microchipdeveloper.com/mplabx:libraries. The preprocessor treats the file name enclosed in
Microchip has an excellent description of how programs go from quotes in a different way. According to the C17 draft
C/C++ through a compiler and linker, and how you can create a standard for the C language, the preprocessor replaces the
library.
#include “servo.h” directive with the entire contents of the
54 March/April 2019
named header file. If the preprocessor can’t find the file welcome your error report.
— usually it’s in your working directory or folder — it treats
the directive as if you had written #include <servo.h>. (See
Reference 1.) Build a Library
In addition to the libraries supplied within an IDE, Parallax provides library creation instructions for the
you can find other libraries written by users who either Propeller that explain how to use the SimpleIDE to create
improved on an IDE’s library, added functions to a library, them. I needed an LED_Test library that flashed LEDs on a
or created a library for a specific peripheral device. QuickStart board. Due to confusion about file names in the
three-part instructions, it took several attempts to get the
library properly set up. However, I now know the process
What’s in a Header File? and have suggested revisions to the Parallax lessons. I’ve
When you open the SimpleIDE header file servo.h, provided my instructions and example software in a file
you’ll find many function prototypes such as those shown available with the article downloads.
next. Each defines the data type a function will expect from For information about how to create libraries for
your software and the data type of returned information, various MCUs, please refer to the Resources section of
if any. The servo_stop() function, for example, requires no this article. Based on my experience, I recommend you
data and it returns no data: carefully read the instructions — perhaps several times —
before you start any library-related work.
int servo_set(int pin, int time); Also, the software you want to put in a library should
int servo_get(int pin);
void servo_stop(void); run properly before you put it in a library.
int servo_setramp(int pin, int stepSize); The SimpleIDE library creation process starts after you
create folders to hold project and library files. You then put
The statement #include “servo.h” causes the files in folders and do minor editing. Finally, you build the
preprocessor to replace the servo.h directive with the project; that step creates the proper library files.
entire contents of the servo.h file. Remember, the dot-h The LED_Test library worked and turned each LED on
files contain only function prototypes, not the functions and off in sequence five times. The main program file now
themselves. The prototypes “promise” the compiler that looks like this:
the functions exist elsewhere (in a library file), and specify
how much memory the functions need and the variables #include “simpletools.h”
#include “LED_Test.h”
involved. As a result, all the servo functions and other
information in servo.h become available to your program. int main()
Whoever provided the servo.h and the accompanying {
LED_Test();
servo.c files should have documented what the functions }
do and how you can use them.
You can find the C/C++ standard library application Propeller libraries use one of three memory modes:
programming interface (API) specifications either in the Large (LMM); Compact (CMM); and Cog RAM (COG). I
language standard or on Internet sites such as https:// used the default CMM setting when I created the LED_Test
en.wikipedia.org/wiki/C_standard_library which has library. If you examine Propeller library files, you’ll see
links to specific library pages, and www.cplusplus.com/ folders for appropriate memory models. The servo library,
reference/clibrary which has a helpful index to the for example, includes CMM- and LMM-type libraries.
libraries. The SimpleIDE window includes an icon in the bottom-
For the Propeller servo example, those function left corner of the main project area. I clicked on it to open
definitions — the code that does the work — appear in the a Project Manager area that shows three tabs: Project
servo.c file. The servo_stop function looks like this: Options; Compiler; and Linker. The SimpleIDE user guide
explains the memory modes, speeds of execution, and
void servo_stop(void) memory sizes, so you can choose one appropriate for your
{
if(servoCog - 1); application. Experiment and try more than one model.
{
servoCog = 0;
lockclr(lockID); Guard Your Libraries
lockret(lockID);
} When programmers create libraries, they should always
} add include guard code that prevents library users from
The library creator declared servoCog and other invoking a library more than once. Multiple inclusions of
variables elsewhere. Again, assume the libraries provided a library cause compile-time errors because your program
as part of a company’s IDE went through many tests and has tried to declare variables and functions more than
work properly. If you do find a problem, the company will once. An include guard requires two statements at the start
March/April 2019 55
of a library file and one at the end. The following example you might inadvertently have several #include “servo.h”
file illustrates how to place an include guard in a library file statements in a program (yes, it does happen), the servo
prior to compiling it: library gets included only once. Of course, you may use
the functions in a library as many times as you wish in a
//Start of servo.h file program.
#ifndef servo_H //Library starts here
#define servo_H

all servo.h library code goes here... Don’t Mangle Names


#endif //Library ends here The C++ language allows for function overloading,
which means a function name may have several meanings:
The guard directives work this way: The first time the void test(int); or void test(int, char); or void test(void); for
preprocessor reaches the directive #ifndef servo_H, it finds example. When run through a C++ compiler, the function
nothing has yet defined servo_H. So, the next directive names get “mangled,” so they identify themselves uniquely.
defines servo_H. (Think of a flag bit that could be set The mangled name indicates the data type (or types)
or not set. The servo_H works the same way; either it’s associated with the function name. Mangled names affect
defined or it’s not defined.) After servo_H gets defined the way a linker connects pieces of code to create an
here, the preprocessor continues through the code until executable file. The section that follow shows how the
it reaches the library’s #endif directive. Then, it copies the three test function names appear after being mangled by a
servo.h library into your application program. All code in C++ compiler (gcc 3.x and higher):
a header file belongs between the #define and the #endif
directives. After the preprocessor finishes with the servo.h void test(int); Z1testi
void test(int, char); Z1testic
file, servo_H remains defined. void test(void); Z1testv
If you try to use the servo.h file again elsewhere in
your program, the preprocessor now finds servo_H already Within a C library file, we must ensure the function
defined, so it jumps to the #endif directive and does not declarations don’t get mangled and that we preserve “C
re-use any information in the servo.h file. So, although linkage.” The process that links sections of code to create

56 March/April 2019
an executable program cannot match a mangled C++ compiler. So, in this example, assume it is defined. The
function name with one un-mangled by a C compiler. statement extern “c” { (#2) indicates, “OK, __cplusplus is
To prevent name mangling and linker errors, we direct defined here, so from this point on the left brace -- { -- the
a compiler to treat sections of code as written in C, rather compiler will not mangle names.
than in C++. This protection lets linkers use our library in C We can use them as written in a C or C++ program.
code without problems. A detailed description of function The #endif directive (#3) ends this group of three
overloading and name mangling goes beyond the scope of directives. (You can’t apply extern to code written
this tutorial (see Reference 2 for more details). To ensure specifically for C++.)
names in a C language header file do not get mangled, you The final #ifdef __cplusplus directive (#4) again tests
must add six more preprocessor directives (shown here in __cplusplus which, in this case, remains defined. So, the
bold and numbered for discussion): right brace (#5) ends the no-mangle section of the library’s
C code. The final #endif directive (#6) ends this group of
//Start of servo.h file three directives. The include guard and the prevention
#ifndef servo_H //Library starts here
#define servo_H of name mangling can help you avoid errors that might
challenge your debugging skills.
#ifdef __cplusplus //#1
extern “C” { //#2
#endif //#3 That’s a Wrap
all servo.h library code goes here... You now have had an introduction to how libraries
#ifdef __cplusplus //#4 get created, how to protect library code from a C++
} //#5 compilation, and how to guard against multiple library-
#endif //#6 inclusion attempts. As your next step, learn more about
#endif //Library ends here how your IDE creates libraries and try to create a simple
one. NV
The first new directive (#1) tests for a declaration of Thanks go to my friends, Dr. Michael Batchelder and Mr. Len Bayles
__cplusplus, which gets defined automatically by a C++ whose suggestions improved this article.

www.embeddedARM.com
TS-7180
Single Board Computer

696 MHz i.MX6 UltraLite CPU


4GB eMMc Flash
Up to 1GB RAM
WiFi and Bluetooth Enabled
XBee/NimbeLink sockets
SPI, I2C, CAN, RS-485
Nine-Axis MEMs
Gyroscope, Accelerometer and Compass
Industrial Temp Range (-40 °C to 85 °C)
10+ Year Life Cycle

Board Support Packages,


Source Code and Toolchains
Available

March/April 2019 57
By Bryan Bergeron

DIY Biotech:
A Spectrophotometer for
Measuring Bacterial Growth
In this DIY Biotech
article, we’ll build
an Arduino-based
spectrophotometer
to explore how the
optical density of
bacteria suspended
in a liquid can be
used to measure
Photo 1. DIY spectrophotometer. the rate and stage
of bacteria growth.
INTRODUCTION growth, then you’ll have better success in your DNA
manipulation experiments. Similarly, some experiments
The cultivation of bacteria such as E Coli is a significant require a minimum concentration of bacteria in order to
part of DIY Biotech. Bacterial DNA can be modified, for produce meaningful results.
example, to produce insulin and other lifesaving drugs, and Enter the spectrophotometer, which measures
to display certain characteristics such as glowing in the wavelength-specific optical opacity of a fluid. By shining a
dark. Modifying the bacterial DNA usually requires working light of a particular wavelength — most commonly 600 nm
with organisms that are rapidly dividing because this is or orange — through a suspension of bacteria in a nutrient
when cell wall integrity is compromised. broth and measuring the absorbance of that light at regular
If you know how to identify this stage of rapid bacterial intervals, the concentration (and therefore number) of
58 March/April 2019
Post comments on this article and find any associated files and/or downloads at www.nutsvolts.com/
magazine/issue/2019/03.

bacteria as well as their rate and stage of growth can


be measured. The following section introduces the
science behind the spectrophotometer.

THE SCIENCE
Key STEM Concepts
The change in optical density at 600 nm
(OD600) for a growing bacterial suspension follows
a characteristic curve.
Figure 1. Typical bacterial
• The four phases of bacterial growth, in order, are population growth curve.
the: 1) lag phase; 2) logarithmic or log phase; 3)
stationary phase; and 4) decline phase.
• The Beer-Lambert law essentially states that
absorbance of light by a fluid is a function of: 1)
the concentration of the absorptive substance(s)
in the fluid; and 2) the length of the path the light must bacteria might last from, say, six hours to 12 hours after
make through the fluid. the bacteria are introduced to a nutrient bath. However,
• The relative change in the turbidity or optical density a rough estimate may not be good enough for a specific
at 600 nm of a suspension of bacteria can be used study or genetic manipulation procedure. For example, if
to determine the relative rate and stage of bacterial six hours after introducing bacteria to a nutrient bath the
growth. bacteria population used for a DNA experiment is still in
• Given a known optical path length, the absolute the lag phase, the experiment will likely fail.
optical density at 600 nm of a suspension of bacteria Figure 2 shows another use for determining bacterial
can be used to measure the concentration and number population growth curves: that of identifying optimal
of bacteria in a suspension. environmental conditions including temperature, nutrient
concentration, and oxygen/carbon dioxide concentration
Bacterial Growth for maximum growth rate. Conditions associated with
growth curve Log A are superior to those associated with
Figure 1 shows the typical bacterial population growth curve Log B which, in turn, are superior to those associated
curve. Note that the X axis is time and the Y axis is the with curve Log C. A greater slope corresponds to a greater
logarithm of the concentration of bacteria in the container. rate of growth.
When viable bacteria are suspended in a nutrient
bath, there is a lag time wherein the bacteria grow in size
but not in number. This is followed by a period of rapid
logarithmic growth in the number of bacteria, referred to
as the log phase. Each parent bacterium divides into two
identical daughter bacterium (through a process called
binary fission), each of which grow and divide into two
additional daughter bacterium, and so on.
This log phase of rapid growth in the number of
bacterium eventually comes to a halt when the nutrients
in the bath have been exhausted. This stationary phase is
marked by a constant population of bacteria. Eventually,
bacteria begin dying and the number of bacteria falls.
As shown in Figure 1, the number of bacterium Figure 2. Different
log phase growth
in this decline phase approaches but may not fall to curves resulting from
the level of the initial lag level because of survival different environmental
mechanisms. conditions.
Given a set of conditions in terms of nutrients,
temperature, oxygen, and carbon dioxide in the
atmosphere, the log phase of a particular population of
March/April 2019 59
through a fluid will undergo some degree of
attenuation, as a function of the interaction
of light with the fluid and any particles (e.g.,
bacteria) suspended in the fluid. All else
held equal, the more particulate matter
suspended in the fluid and the more the
particulate matter interacts with the light,
the greater the attenuation.
Similarly, the light traversing a one inch
diameter tube of fluid should be attenuated
less than a beam traversing, say, three feet
of the same fluid. It also stands to reason
that pure water with no particulate matter
should provide the least optical attenuation.
This common-sense view of light
absorption by a fluid is quantified in the
Beer-Lambert Law. The mathematics isn’t
important for our discussion, but the law
Photo 2. The ubiquitous Bausch & Lomb Spectronic 20 spectrophotometer, produced essentially states that absorbance of light by
from the mid ’50s through the mid ’80s.
a fluid is a function of: 1) the concentration
Many of the strains of E Coli available for DIY Biotech of the absorptive particle(s) in the fluid; and 2) the length
are designed for maximum growth at the normal core of the path the light must make through the fluid. In our
body temperature of 37°C. However, I’ve used E Coli to case, the absorptive particles are bacteria and the beam
manufacture the glow-in-the-dark compounds found in must travel the diameter of a test tube — about 1”.
jellyfish, and these bacteria exhibit the maximum rate of An added twist is that bacteria exhibit a peak in light
growth at cooler temperatures. absorption around 600 nm (or orange). That is, if you were
Similarly, E Coli are aerobic bacteria that thrive in an to sweep the spectrum of colors through a sample of E
oxygen-rich environment. Increasing the ambient oxygen Coli or other common bacteria, you would find a peak in
level could be expected to shift the log phase from, for absorbance (or a dip in transmission) at 600 nm. This is in
example, Log B to Log A in Figure 2. contrast with, for example, the chlorophyll found in green
plants, which has a peak absorbance around 400 nm or
Light Absorbance/Transmittance violet.
We can take advantage of this peak in bacteria
It should be obvious that a beam of light traveling absorbance at 600 nm by using a light source of the same
wavelength. This increases the signal/noise
ratio of our measurements compared to
using, say, white light, because absorbance
due to other particles suspended in
the fluid have relatively little effect on
absorbance at 600 nm. By the way, OD600
measurements not only apply to bacteria,
but they are commonly used to quantify the
concentration of yeast in a suspension (think
beer brewing) and to establish a growth
curve of a yeast culture.

PHOTOSPECTROMETER
DESIGN
Commercial Standard
If you search for “photospectrometer”
Photo 3. Internal view of my Spectronic 20 spectrophotometer. on eBay, you’ll likely see dozens of listings
60 March/April 2019
for the Bausch & Lomb Spectronic 20. It’s the most
popular photospectrometer ever sold. Photo 2
shows my eBay purchase ($150), complete with
minor smudges accumulated over 40+ years of use.
The left knob on the front panel is for power and
to zero the 5-1/2” absorbance/percent transmittance
meter. The right control on the front panel is to
set the analog meter to 100%. On the top of the
unit are the sample holder on the left, and the
wavelength selector on the right.
Photo 3 shows the photospectrometer with
the cover removed. The wavelength selector disc
marked from 340 nm-960 nm is in the bottom center
of the photo. The underside of the tube socket for
the photomultiplier tube can be seen on the far left.
Under the wavelength selector disc are the Tungsten
lamp, an objective lens, and a diffraction grating.
Rotating the diffraction grating relative to the
yellow-white Tungsten light source produces a light Photo 4. Note the 600 nm 1W LEDs and heatsinks.
from 340 nm-960 nm with a spectral bandpass of
20 nm. This colored light is directed through the eBay and specialty sites such as Adafruit.com. A bag
test tube containing the bacteria in suspension and to a of 10 Chanzon 1W 600 nm LEDs is available for $5.70.
photomultiplier tube. The circuitry to the right of the meter Similarly, a bag of 25 Chanzon LED heatsinks is available
amplifies the signal to drive the meter. for $7. I used Arctic Silver Arctic Alumina Thermal Cooling
There are, of course, clones of the Spectronic 20 adhesive, available from Amazon for $22/5 gm. There
manufactured in China. The better domestic units are a are less expensive sources for the LED and heatsinks, but
little more compact and feature a digital display. Expect shipping costs add up quickly when you deal with multiple
to pay several hundred dollars for a fully functional vendors.
refurbished unit. Much of the cost and complexity is
related to support for a range of wavelengths, from near IR Power Supply
to near UV. For most of my work — and I suspect for most
DIY Biotech experimenters — OD600 measurements are The Chanzon LEDs used in this project require 300-
sufficient; 600 nm or orange light can be obtained from a 350 mA at 2.0-2.4V. This is easy enough to supply from a
simple LED circuit. constant current bench supply. However, if you want a self-
contained spectrophotometer, there are several options,
LED Light Source such as a Chanzon constant current 300 mA LED driver,
also available from Amazon for $7. The only downside of
Instead of starting out with a white light source such this driver is that it runs on 110V AC, and I like to work
as a halogen or Tungsten bulb and then using a filter or with lower voltage DC supplies.
diffraction grating to select for 600 nm, it’s much simpler
to use a 600 nm LED. High-intensity 600 nm LEDs — which Photodetector
are usually made with aluminum indium gallium phosphide
(AIndGaP) — are affordable, readily available, and easy With a little tweaking, any number of photodetectors
to use. Photo 4 shows several 1W LEDs and a sheet of and photodetector circuits can be used to create a 600
heatsinks, as well as an LED mounted on a heatsink with nm photospectrometer. For example, one of my early
thermal adhesive. prototypes is based on the TEMT6000 phototransistor and
An LED heatsink isn’t strictly required for this voltage divider breakout board (available from Amazon for
application because it’s possible to strobe the LED for a $7). Hookup and the related Arduino code for this analog
second to take a reading. That said, I like a margin of safety light sensor is about as simple as it gets.
and the heatsink pads make wiring simple. Furthermore, I found the TEMP6000 limited in dynamic range,
the solder pads on the heatsinks make the LED units easier however. I sometimes had trouble differentiating the
to handle. control (no bacteria) from the sample containing bacteria.
I sourced the components for this project through My current photospectrometer is based on a powerful
Amazon, at a modest premium over what’s available on and flexible photodetector: the Adafruit TSL2591. This
March/April 2019 61
Uno to control the TSL2591 photodetector. The TSL2591
is an I2C device with a non-alterable address of 0x29. Even
if you’ve never utilized an I2C device before, you’ll find the
TSL2591 a joy to work with. The Adafruit library takes care
of all the low-level details.

THE BUILD
Detector
I chose to use a simple direct wired design to minimize
build time. There are only four 6” jumper wires between
the female sockets on the Arduino Uno and the male
pins on the TSL2591 as shown in Photo 6. It’s possible
to use a traditional breadboard circuit in the form of
a miniature breadboard, so that the TSL2591 can be
mounted vertically. The sensor and light source should be
perpendicular to the long axis of the cuvette or test tube
Photo 5. The Adafruit TSL2591. containing the suspension of bacteria. Table 1 shows the
connections between the TSL2591 and the Uno. Using
high dynamic range digital lux sensor which has separate only four male-female jumper cables, build time for the
sensors for visible and infrared light and user-definable gain detector is on the order
Table 1. Arduino Uno Connections.
from unity to 428X, is available for $10 from Amazon (see of five minutes.
Photo 5). Recall that lux is a measure of light intensity and Arduino TSL2591
5V Vin
that 1 lux equals 1 lumen/m2. Light Source GND GND
Exhaustive documentation and example Arduino code A5 SCL
and associated libraries are available for free download The 600 nm light A4 SDA
from Adafruit. As you’ll see later, the example code is all source is a 1W LED USB Port Mac/PC USB
you need to create a fully functional photospectrometer. connected to my
bench supply in constant current mode. The build involves
Microcontroller soldering 12 inch lengths of 22 gauge copper wire leads
to the LED as shown in Photo 7. Alternatives to a bench
Given the libraries and example code available on the supply include the Chanzon LED driver discussed earlier, or
Adafruit website, it’s only reasonable to use the Arduino any number of LED drivers available online. For example,
Adafruit sells a variety of LED drivers compatible
with high power LEDs starting at about $7.50.

Test Tube/Cuvette Holder


Creating a light-tight holder for a square
cuvette or regular round test tube is the most
labor-intensive component of this build — unless
you have access to a 3D printer. Although I do
own a printer, most readers don’t, so I looked
for a commonly-available alternative.
Another five-minute solution (shown back in
Photo 1 and Photo 8), is to stack ordinary and
inexpensive white board erasers in a way that
blocks extraneous light and supports the LED
and receiver circuits.
Use a hobby knife to cut out a round
or square hole in each of four foam erasers,

Photo 6. The TSL2591 Arduino connections.


62 March/April 2019
depending on whether you’re using cylindrical glass test
tubes or cuvettes. After inserting the light source and
detector in the slots on either side of the hole for the test
tube (refer to Photo 8), the four erasers are stacked onto
each other and either glued together or held in place with
tape. Note that the tube in Photo 8 serves to hold the
stack of erasers in place during construction.
Obvious variations on the build include a stand-alone
instrument that includes an LCD display, battery supply,
aluminum or plastic project box, and 3D printed cuvette or
test tube holder.
There’s nothing special about the use of erasers. A pair
of 4” 2x4 pieces could be used in place of the foam. The
downside of a plastic, aluminum, or wood framework for
this project is the need to work with a drill press or at least
a hand drill to make the necessary modifications.

SOURCE CODE
The source code for this project is a slight modification
of the sample code that’s available from the Adafruit site. Photo 7. A 1W 600 nm LED wired and ready to go.
(The entire source code is only six lines, shown here.) The
most difficult step is installing the Adafruit_TSL2591 library That’s it, thanks to the fantastic example program! The
as well as the Adafruit_Sensor library from the Adafruit program will run continuously and return the real time
repository. Go to https://github.com/adafruit/Adafruit_ values of luminosity every 500 ms or so. Of course, for our
TSL2591_Library. needs, one measure per sample will do.
From the Examples menu, select Adafruit_TSL2591 and Note that the luminosity value obtained from
run the code. When you open the serial monitor window, measuring a test tube of pure broth must be subtracted
you should see the instantaneous lux value scroll down from the value obtained from measuring a test tube of
the window, tagged with the time. All you have to do with the same size and composition that contain the bacteria
the example code is decide on the gain and integration suspensions. In this way, the test tube, broth, and other
time by uncommenting the appropriate timing and gain sources of common error do not contribute to the growth
declarations. For example, the statement: curve or other analysis.

tsl.setGain(TSL2591_GAIN_MED);
sets the gain to medium, or about 25x. Low gain has a
gain of 1x, and high gain has a value of 428x. Similarly, the
statement:

tsl.setTiming(TSL2591_INTEGRATIONTIME_100MS)
sets the integration time to 100 ms. This is appropriate for
bacterial suspensions that are almost clear. Increasing the
integration time to, say 600 ms, is appropriate for highly
turbid suspensions (i.e., low-light conditions). The only
other parameter to consider is what to measure: infrared,
visible light, or a combination of the two. Because 600 nm
is clearly in the visible spectrum, we can ignore the infrared
sensor. The main loop in the program becomes:

void simpleRead(void)
{
uint16_t x = tsl.getLuminosity(TSL2591_VISIBLE);
Serial.print(F(“Luminosity: “));
Serial.println(x, DEC);
} Photo 8. LED, sensor, and test tube (center) embedded in a foam
whiteboard eraser.
March/April 2019 63
photospectrometer, let’s create a growth curve for
E Coli. First, create a liter of standard Luria Bertani
(LB) broth. This involves dissolving 25.0 grams of
LB powder (see Photo 9) into 1,000 ml of distilled
water, and then heating the broth to 121°C for 15
minutes to kill any bacteria.
Next, cool the broth to 37°C and inoculate
the broth with E Coli. Before placing the flask in an
incubator set to 37°C, stir the suspension so that the
E Coli are evenly distributed in the broth and take
a few cc’s and place it in a clean test tube. Insert
the tube into the photospectrometer and watch
the lux values scroll up the screen. Continue taking
samples every hour and recording the lux value.
Make certain you use clean — not necessarily sterile
— test tubes and that you stir the suspension before
taking a sample for measurement. A plot of the
measurements should resemble the classic bacteria
growth chart described earlier.
Photo 9. Luria Bertani (LB) powder, a set of glass test tubes, and a liter Once you’ve obtained a growth chart, make
Erlenmeyer flask filled with LB broth.
another batch of broth and vary the incubation
DEMONSTRATION temperature; say, setting your incubator to 35°C
instead of 37°C, and repeating the measurement sequence.
To demonstrate the capabilities of your OD600 You should see a change in the slope of the log phase —
the magnitude and direction of the change dependent on
the strain of E Coli.
Introducing the DISCUSSION

1(:39-U
0LQL&LUFXLW%RDUG+ROGHU
An inexpensive DIY photospectrometer dedicated
to OD600 measurements is both easy to build and
useful in the DIY Biotech lab. A quick Internet search on
OD600 will reveal tables that you can use to calibrate
your photospectrometer to the absolute concentration of
bacteria per ml.
'(6,*1(' If you’re interested in exploring photospectrometers
in more depth, then consider constructing a unit using an
)25 29(5 RGB LED. You won’t need to modify the receiver hardware
or software, but you may want to leverage the power of
7+(('*( the Uno to accurately control the mix of red, green, and
blue output.
&20321(17 Of course, if you’re new to DIY Biotech and have
%2$5'6 never heard of Luria Bertani broth, then consider an intro
text to Biotech, such as the Illustrated Guide to Home
Model Biology Experiments, by Thompson and Thompson.
220 Another resource is the Carolina Supply website (https://
www.carolina.com), which has an extensive library of
online tutorials.
Innovative H
Holding
olldi
o din
ngg SSolutions
olutio
olutiio
ut ons
n If you’re affiliated with a school, then you should
consider Carolina Supply for E Coli, LB Broth, and
800-759-7535 other supplies. If you’re an independent DIY Biotech
experimenter, then Carolina — among other suppliers — will
not sell you active biologicals. Instead, consider Amino.bio
and The-Odin.com. NV
64 March/April 2019
Bench and Builder
USB Add USB to your next project--

Stuff For The


It's easier than you might think!
USB-FIFO USB-UART USB/Microcontroller Boards
RFID Readers Design/Manufacturing Services Available
Absolutely NO driver software development required!

Electronics
www.dlpdesign.com

DEC and VME Equipment WANTED!


Digital Equipment Corp and
Motorola MVME Systems and Parts
Buy - Sell - Trade
Call Keyways 937-847-2300 or email [email protected]
Hobbyist
setting your ideas into
MOTION
Use Small Mechanical
Components from SDP/SI

START CREATING!

www.sdp-si.com 516-328-3300

Nuts_Volts_Ad_5_24_18 copy.indd 1 5/24/18 11:59 AM

March/April 2019 65
After reading the May-June 2018 NV article on Ohm’s law, I thought a follow-
up article that goes a little deeper might be in order. Specifically, how
Ohm’s Law together with a computer and a couple of tricks can be used to
calculate the time dependence of much more complex circuits involving
not just resistors, but capacitors, inductors, op-amps ... you name it! Let’s
skip the academic approach that you learned in EE101. Real world problems
are usually too difficult for analytics. In this article, I’ll describe a simple
numerical method that is intuitive and solves many complex problems with
just a few lines of code.

B
efore diving into this, we need Suppose that the input to the circuit is a
one more famous law: Kirchoff’s step function; that is, the input voltage
Law, which says that the sum instantaneously goes from Vin = 0 to
of the voltages around a loop 10V at time t = 0. What is the time
is always zero. Take a look at Figure dependence of the output voltage? The
1 which is a circuit with two voltage analytic result using calculus is:
sources and a capacitor. We want to
know the voltage on the capacitor. Vout(t) = Vin(1 – e -t/RC) Equation 1
Applying Kirchoff’s Law, we can
write the loop equation: Figure 1. A simple circuit to illustrate Now suppose that the input is a
Kirchoff’s Law. square wave. For an analytic solution,
V1 – VC – V2 = 0 we have to solve the circuit at every
transition of the square wave until after a few cycles it
It’s important to keep track of the polarities. Since settles down to a periodic waveform — a daunting task.
the polarity of VC and V2 oppose the polarity of V1, those There’s a much easier way. Let’s use a computer and a
terms have a minus sign. Solving for VC, we have: little trick to get the complete solution in just a few lines of
code. Here’s the trick: A capacitor can be described by the
VC = V1 – V2 equation:

For our first problem, let’s find the time dependence ∆Vc = Ic ∆t / C Equation 2
of the voltage VC in the simple RC circuit of Figure 2.
66 March/April 2019
By C. A. Hamilton Post comments on this article and find any associated files and/or
downloads at www.nutsvolts.com/magazine/issue/2019/03.

This says that the change in the


capacitor voltage ∆Vc in a short time
∆t is equal to Ic ∆t / C, where IC is the
current flowing into the capacitor. For
very short times, the change in voltage
is very small so we can approximate
the capacitor as a voltage source with
a voltage VC. This makes the calculation
of IC very simple. Using both Ohm’s
Law and Kirchoff’s Law, we can write:

Vin – ICR – VC = 0

Solving for IC:

IC = (Vin – VC) / R Equation 3

With IC known, we can calculate a


new VC (∆t) from Equation 2 and then a Figure 2. The simulated step response of an RC circuit with time constant RC =
25 ms. The X points are the analytical solution from Equation 1. The red curve
new IC and VC (2∆t) from Equations 2-3, is the numerical solution with dt = 0.25 ms. The blue curve is the numerical
and continue in a loop to obtain the solution with dt = 10 ms.
complete time dependence VC(t) This is
called the numerical method. self-consistent set of units shown
Let’s first do the step function Table 1 in Table 1. The results of the
problem so we can check the result Parameter Unit Symbol simulation are shown in Figure 2
against Equation 1. Code Example 1 Voltage volts V which also shows that when we
is the simple basic code to simulate Current milliamperes mA choose the time increment dt =
the voltage across the capacitor Resistance kohms k 0.25 ms (100 times less than R
of Figure 2 in response to a step Capacitance microfarads μF x C), the numerical solution (red
voltage input. The critical code lines Inductance Henrys H curve) is in perfect agreement with
that simulate the circuit behavior Time milliseconds ms the analytic result (x points). With
are shown in red. Just to be clear, Frequency kiloHertz kHz dt only 2.5 times less than RC
throughout this article I’m using the (blue curve), the error is significant.
March/April 2019 67
Code Example 1: RC circuit step response simulation.
R = 5.0 ‘5 kohm
C = 5.0 ‘5 microfarad, RC = 25 ms
VC = 0 ‘Starting capacitor voltage (volts)
t = -10 ‘Start time (ms)
dt = 0.25 ‘Time increment (ms)
WHILE t< 90 ‘Compute for t = -10 to +90 ms
Input1: IF t>= 0 THEN Vin = 10 ELSE Vin = 0 ‘Create a 10V step at t = 0
IC = (Vin - VC) / R ‘Current into the capacitor (Ohm’s Law)
VC = VC + IC * dt / C ‘Update capacitor voltage
t = t + dT ‘Increment the time
Plot (t, VC) ‘A plotting subroutine defined elsewhere
WEND
END

With dt ≈ RC/100 = 0.25 ms, the


calculation takes 360 time increments
which (on my computer) completes in
less than one second.
Now, let’s change the input to an
offset square wave and make the circuit a
bit faster by setting C = 10 μF and R = 1
kΩ (RC = 10 ms). Implementing a 0.2 kHz
square wave can be done by changing the
line labeled “Input1” as follows:

Input1: If t >= 0 THEN Vin = 5


+ 4 * SGN(SIN(2 * Pi * 0.2 * t)
ELSE Vin = 0

The SGN function returns +1 for a


positive argument and -1 for a negative
argument, and therefore converts the sine
Figure 3. The output (red curve) of the circuit in Figure 1 with a square wave wave to a square wave. Refer to Figure 3.
(blue curve) input. Now, let’s add an inductor as shown
in Figure 4. The equation describing an
inductor is identical to Equation 2 but with
C replaced by L and current and voltage
reversed; that is, the change in the current
through an inductor ∆IL in a short time ∆t is
equal to where VL∆t / L is the voltage across
the inductor:

∆IL= VL∆t / L Equation 4

By the same logic, for short times an inductor


Figure 4. An RLC circuit. can be treated as a constant current source.
In order to update the capacitor voltage and
inductor current at each time increment, we
Code Example 2: Step response of an RLC circuit. need equations for IC and VL.
The code to simulate this circuit is
IC = IL ‘Current into the capacitor
basically the same as Code Example 1
VL = Vin – IL * R - VC ‘Voltage across the inductor but with the red highlighted lines of Code
VC = VC + IC * dt / C ‘Update capacitor voltage Example 1 replaced by Code Example 2. The
result of the RLC simulation is shown in Figure
IL = IL + VL * dt / L ‘Update inductor current
5. Now, it’s time to apply these ideas to a
68 March/April 2019
practical problem.
Let’s look at another article in
the May-June 2018 issue on sine
wave generators. Specifically, the
circuit in Figure 4 on page 86 (Open
Communication column); shown here
as Figure A. This circuit creates a sine
wave by filtering out the fundamental of a
square wave using a three-stage RC filter.
I have drawn the filter part of this circuit
in Figure 6. The component values for
this example are R1 = R2 = R3 = 5 kohms
and C1 = C2 = C3 = 0.1 μF. The square
wave input frequency is f = 0.5 kHz. In
this circuit, C1 and C2 receive current
from both sides so the equations for the
current into these capacitors have two
components as shown in the first two Figure 5. The computed step response Vc of the RLC circuit in Figure 4.
Component values are R = 0.1 kohm, C = 10 μF, and L = 0.1 H.
lines of Code Example 3. The complete
simulation code is obtained by replacing
the highlighted lines of Code Example 1 with Code
Example 3 and (of course) assigning the values of
C1-3 and R1-3. Figure A. Circuit from the
Open Communication
Figure 7 shows the computed time-dependent column.
voltage across each capacitor. The simulation
clarifies the trade-off in this design. Each of the three
stages improves the approximation to a sine wave at
the expense of decreased amplitude.
A larger value of RC will make a better sine
wave, but with a smaller amplitude. For this
simulation, I chose RC = 0.25/ f = 0.25/0.5 = 0.5
ms. (The May-June article chose RC = 0.16 / f which
generates more like a slightly rounded triangle wave.)
In Figure 8, I have breadboarded the circuit
of Figure 6. My oscilloscope happens to include a
function generator, so I can create and view both
the input (top trace, 1V/div) and output (bottom
trace, 0.1V/div) with just my oscilloscope.
There are plenty of circuit simulation
programs that will easily solve the problems I’ve
discussed so far, but when the problem also
includes mechanical components those canned
simulators probably won’t work. Stabilizing the
inverted pendulum is a nice hybrid problem
involving both electronic and mechanical Figure 6. A three-stage RC filter.
components. (See my article on this topic in
the December 2017 issue of SERVO Magazine; www. Code Example 3: Simulation of a three-stage filter.
servomagazine.com.) IC1 = (Vin – VC1) / R1 + (VC2 – VC1) / R2
The simulation of this problem involves both electrical IC2 = (VC1 – VC2) / R2 + (VC3 – VC2) / R3
and mechanical components involving a motor, gravity, IC3 = (VC2 – VC3) / R3
mass, inertia, velocity, positions, and angles. Figure 9 is a
VC1=VC1 + IC1 * dt / C1
diagram of an inverted pendulum stabilization system with
just the basics needed to write a simulation code. VC2=VC2 + IC2 * dt / C2
The inverted pendulum is attached to a motor-driven VC3=VC3 + IC3 * dt / C3
March/April 2019 69
Figure 9, the gain is reduced and given
by the ratio of the feedback impedance
(R3, R4, C4) to the input impedance
(R1, R2, C2). Capacitors C2 and C4
make it possible to shape the frequency
response.
To write the simulation equations,
we just need to know two things: (1)
When the op-amp positive input is
grounded as in Figure 9, the high gain
and feedback cause the negative input
to become a virtual ground; that is, the
voltage at the negative input will be
essentially zero. (2) No current flows
into the op-amp input terminals, which
in the case of Figure 9 means that the
current flowing to the right in R3 equals
the current flowing to the right in R1.
Figure 7. Simulation of a filter to convert a square wave to a sine wave.
Now, we can write the simulation
equations starting with the current Ip.
cart by a free pivot. Sensors measure the cart position and Since V- = 0, the equation is:
the pendulum angle from vertical. These two signals feed
into the control system to produce an output signal that Ip = (Vp – VC2) / R1
drives the motor. The system must keep the pendulum
upright and simultaneously track a command position Vp is the voltage output of the angle sensor when the
input. If you’re wondering about the design details, refer to pendulum is leaning at an angle of P degrees. This is the
my article. Our job here is to simulate the existing design in first line in the simulation code listed in Code Example 4.
Figure 9. Writing the equations for this system is a bit more Code lines 2-3 find the current into capacitors C2 and C4.
complicated. First, let’s address the operational amplifier. Line 4 follows from the fact that V- = 0. Line 6 sums up the
An op-amp simply takes the voltage difference between its signals that drive the motor, including gain factors Gx and
two inputs and multiplies it by a large gain factor, typically Gp that scale the cart acceleration Xdd to Vm — the voltage
on the order of 100,000. When there is feedback as in applied to the motor through R5.

Figure 8. A
breadboard
test showing
the input and
output of the
three-stage filter
circuit in Figure
6. Note that the
top trace is at
2V/div and the
bottom trace is
at 0.2V/div as
in the Figure 7
simulation.

70 March/April 2019
Figure 10. Simulation results for the inverted pendulum.
The top drawing is the animation at time = 0, scaled at
one meter per division. The vertical blue line shows the
command position at time = 0, and the blue square
Figure 9. The control system to stabilize an inverted wave below shows how the command position changes
pendulum and track a command position. with time (oscillating from -5m to +5m every 30s). The
black curve is the cart position and the red curve is the
Code line 8 shows how the acceleration Pdd of pendulum angle (max deviation from vertical is about ±
10 deg), all as a function of time.
the pendulum tilt angle P depends on its length L,
the acceleration of gravity g, the tilt angle P, the cart
acceleration Xdd, the cart velocity Xd, and the rate of and the easy adaptability to problems involving more than
change Pd of the pendulum tilt angle. The derivation of this just electronic components; for example, the dynamic
equation is beyond the scope of this article, but more info behavior of the mechanical parts in the inverted pendulum
can be found on Wikipedia; look up “Inverted Pendulum.” problem.
We now have everything needed to update the state Springs are like inductors, mass is like capacitance,
of the system. Lines 9-10 update the capacitor voltages. Ohm’s Law becomes Newton’s F = MA. You could analyze
Line 11 updates the cart speed Xd based on the known a bridge truss by noting that the beams are like very stiff
acceleration Xdd and then line 12 updates the cart position springs. NASA could never navigate a spacecraft to Pluto
X based on the known speed Xd. Lines 13-14 perform without the numerical method. NV
the same operations to
update cart tilt angle P, Code Example 4: Simulation of an inverted pendulum on a motor-driven cart.
then update the time 1: Ip = (Vp - VC2) / R1 ‘The input current through R1
and the animation, and 2: IC2 = Ip - (VC2 / R2) ‘The current into C2
3: IC4 = Ip - (VC4 / R4) ‘The current into C4
then go back to line 1 4: Vo = -(Ip * R3 + V4) ‘Filter output (inverted)
to compute the next
time increment. Refer to ‘Xdd is the acceleration to be applied to the cart for time dt
Figure 10. 6: Xdd = -Gp * Vo + Gx * (Vcmd -Vx) ‘Close the angle and position loops
Of course, if you
‘Compute the rotational acceleration of the pendulum
have a circuit simulator
8: Pdd = (1 / L) * (g * Sin(P) - Xdd * Cos(P) - Xd * Pd * Sin(P))
on your computer you
can get the results of 9: V2 = V2 + I2 * dt / C2 ‘Update capacitor voltages V2 and V4
Figures 2, 3, 5, and 7 10: V4 = V4 + I4 * dt / C4
without writing any code.
Aside from not 11: Xd= Xd+ Xdd *t ‘Update the cart speed
12: X = X + Xd* dt ‘Update the cart position
needing a simulator, the 13: Pd = Pd + Pdd * dt ‘Update the pendulum rotation rate
beauty of the numerical 14: P = P + Pd* dt ‘Update the pendulum angle
method described in this 15: t = t + dt ‘Update the time
article is the insight it 16: DrawCP ‘Draw the cart and pendulum to the screen
gives to circuit operation 17: Goto 1
March/April 2019 71
Figure 1: Medusa-like PCB found at yard sale.

A
t the worst, I could always salvage some of its to try and identify my new piece of gear. I expected this
parts for use on future projects. Besides, to me to take some time, but after only a couple of searches, I
it was worth the $1 asking price just to satisfy identified the circuit as the popular New England Switched
my curiosity about the function of this strange Capacitor Audio Filter, or NESCAF.
looking device (Figure 1). The NESCAF was designed and built by Bill Siegrist
Once I arrived home, I began perusing the Internet NT1U (a fellow radio operator) and is sold in kit form by
72 March/April 2019
Discovering
the NESCAF By Steve Jackson

How It Started
My latest ham radio adventure began
one afternoon while I was poking
through a box of old electronics at
a neighborhood yard sale. I didn’t
see much of interest and was almost
ready to turn and head for home
when I spotted a mysterious looking
PCB (printed circuit board) with wires
sticking out from all sides. I had no
idea what it was, but since my hobby
is ham radio and I love to tinker with
electronics, I decided to buy it, in hopes
that it would turn out to be something
useful.

the New England QRP (Low Power) Club. NESCAF — as it The Initial Test
turns out — is an audio filter which is designed to connect
between any transceiver and an external speaker or Now that I’d found out what the NESCAF does, it was
headphone. Finding the NESCAF was a stroke of good luck time to connect it and find out if it worked.
for me. Any device which will filter out unwanted signals is I connected the NESCAF’s input to my ICOM 718
a welcome addition to my radio shack. transceiver and the filter’s output to my headphones. I
March/April 2019 73
disconnected the filter and was almost
ready to begin parting it out, when
I decided to take one more listen. I
don’t like to scrap things that are still
functional, and perhaps the hum just
might be something I could fix.
I reconnected the NESCAF, but on
a hunch, I powered it with a battery
instead of the wall wart. As with the
first test, I gradually increased the
volume but surprisingly, the hum had
disappeared. My NESCAF was powered
up and the signal was coming through
Figure 2: Filter schematic. Thanks to Dxing.com for the wall wart information.
as expected.
used a 12 volt wall wart type transformer for the power I adjusted the audio filter’s two potentiometers, turning
supply and I set my transceiver to a frequency on which I them first right and then left, until the signal got a little
knew there would be a signal. My NESCAF was ready for easier to copy. Apparently, when using battery power, the
the test, so after turning on the power, I gradually increased NESCAF works just as it should. The wall wart must have
the volume of the transceiver. been causing the hum by bringing in electrical noise from
NOTE: If you’re new to amateur radio or to audio the house circuit.
devices, be very careful as you test the volume on any unit. Running the filter on battery power works great, but
The gradual loss of hearing I’ve experienced from years of it wasn’t going to be a permanent solution. I’d go broke
loud pops and squeals in my headphones has taught me to replacing the batteries. A wall wart was the obvious choice,
always begin any audio test with the volume control turned but before I could use it, I’d need some type of filter to
down low. keep the outside noise from getting into the NESCAF.
Once you begin the test, you can bring up the volume
very gradually. You’ll be able to enjoy your hobby a lot Building a Transformer Filter
longer if you take good care of your hearing.
It’s a good thing I follow my own rules too, because I I didn’t want to open the wall wart, so I decided to
didn’t have to turn the volume up very high before I could make a small filter. I found a schematic which I thought
hear a steady hum coming through my headphones. No would work. You can see it in Figure 2. I assembled it via
signal at all … just hum. I turned the power off, and once the “dead-bug” method of construction.
again heard the signal. There was no question about it. The If you’re familiar with dead-bug — or ground plane
hum was coming from the filter and not my radio. construction — then you know it’s not pretty, but it does
To be honest, my first reaction on hearing nothing but get the job done. After connecting my homebrew filter,
hum was that the filter must be a dud. After all, I shouldn’t there was no more circuit noise and my NESCAF was
have expected a $1 audio filter found in a used electronics working just as it should. Refer to Figure 3.
bin to actually work. The hum I was hearing was probably While the soldering iron was hot, I decided to change
the reason the previous owner decided to unload the the 4.7K resistor which feeds the power-on indicator LED
NESCAF at a yard sale. to a 1K resistor. With less resistance, the LED shines much
After spending a few minutes feeling like a chump, I brighter than it did with the original circuit.

Figure 3: Wall wart filter built


dead-bug style.

74 March/April 2019
A Closer Look at the
NESCAF
NESCAFs will work with single-side band
signals, but it’s meant primarily for use with
inexpensive QRP rigs which are mostly built from
kits and which have little or no filtering.
At one time or another, almost every radio
operator has experienced problems with noise in
their audio signal. Radio operators even have an
acronym for noise; they call it QRM. There’s little
doubt that an effective audio filter like the NESCAF
would be a welcome addition to almost any radio
shack.
Most of the commercial audio filters are very
pricy, so at $39 plus postage, the NESCAF provides
a very attractive alternative to more expensive Figure 4: Schematic for the New England switched capacitor audio filter uses
filters. building block construction.

The Four Parts of the signal to an LM386 for audio amplification.


4. The LMF100’s passband is output to the ubiquitious
NESCAF LM386 where it’s amplified before being output to the
speaker.
The NESCAF uses a building block construction The operator can control the way the NESCAF works
(Figure 4): through two panel-mounted, dual-ganged 50K ohm
1. The power supply — which is a nominal 12 volts — potentiometers. Detent is set through two onboard trimmer
will work with as little as nine volts. Power is regulated by a pots.
78L09 voltage regulator. The center frequency pot allows the user to raise or
2. The NESCAF uses the LMF100 for the primary IC. lower the frequency in the band pass filter. The pitch can
The LMF100 is the middle chip in a family of switched be set anwhere between 450 Hz and 1,000 Hz.
capacitor audio filter chips, or SCAF for short (Figure
5). The earliest NESCAFs used the MF10 IC, and newer
versions use the LTC1060. Each of these chips are
CMOS ICs programmed with two independent switched
capacitor active audio filters. All three ICs are pin-
compatible.
Both of the switched capacitor audio filters on the
LMF100 use a Butterworth band pass configuration and
are cascaded into multiple stages. When comparing
Butterworth with the Chebychev, Bessel, and other filters,
the Butterworth will often prove to be less sharp at the
cutoff frequency.
This would seem to disqualify Butterworth from
consideration, but whatever value the Butterworth
configuration gives up at the cutoff knee is more than
compensated for by its steady, unchanging volume and
the lack of ripple in its passband.
3. The NESCAF’s time base is provided by the
LM555 oscillator chip. Frequency of the 555 clock pulse
when divided by 100 will equal the center frequency for
the filter. For example, if the 555 is generating 70 kHz,
the center frequency will equal 700 Hz.
The 555 timer oscillates a continuous square wave
pulse to the LMF100 which then outputs the filtered Figure 5: Schematic for the LMF100 IC.
March/April 2019 75
Things to Remember
Before Building
1. Be very careful with your soldering.
Be sure to tin all the leads and keep them as
short as possible. Be careful not to overheat
the components.
2. Inspect your work as you go along.
Don’t wait until the audio filter is completed
to look for soldering problems.
3. Many of the parts are sensitive to
static discharge, so be certain that you’ve
discharged your body before handling the
components — especially the ICs. I use
a wrist band for grounding. Wrist bands
are sometimes cumbersome, but they’re
inexpensive and using one just might
prevent your project from being destroyed
by static discharge.
4. Orientation of the PCB is very
important when building the NESCAF. Make
certain that the “audio in” stencil is always
to your left.
5. Double-check your components
Figure 6: Drilling holes in thin gauge metal, reinforced by 2x4. and make sure you’re working with the
correct part. Don’t substitute components
The bandwidth pot will allow the user to vary the unless you’re absolutely sure you have the correct size and
width of the received pitch to between 90 Hz and 1,500 composition.
Hz. 6. Pay careful attention to the building instructions.
Note: The perfect filter does not exist! Each audio Read them several times before you start building. Take
filter has both strong and weak attributes for the task at breaks as you go along, and don’t push yourself too hard.
hand. Most of the time, the choice of which filter to use It’s much better to go slowly and finish with a working
represents a tradeoff that’s made only after careful analysis device, than it is to go fast and make a mistake that can’t
of each filter’s characteristics. be fixed.

Building the Kit If you’re building a NESCAF from the kit, you
might want to check out this video (the operator’s
The NESCAF kit applies to all levels of builders. While call sign is KD8BBK) at https://www.youtube.
I haven’t built the kit myself, I have closely examined the com/watch?v=gcR25Ho03ug&list=PLedkZGQ_
instructions and the completed circuit. It seems to be in GlprKnp3fDcnBV5eBMnluylnV.
very good order, but I do have some serious reservations The builder walks the viewer step by step, all the way
about whether it really is appropriate for entry-level through to testing. He does a good job, and watching it
builders. could prove helpful to anyone interested in building the
The PCB is closely populated making soldering a NESCAF.
little more difficult, and the building instructions — while
adequate — are sometimes vague and don’t seem
complete enough for a first project.
Building the Enclosure
Also, while I think the only test gear needed is a The NESCAF kit does not include an enclosure, so
multimeter, there are places in the instructions where you’ll have to build your own. Building a project enclosure
reference is made to an oscilloscope and a frequency can often be one of the more satisfying and fun parts of a
counter. project.
Prospective builders would do well to have two or Many of my fellow hams like to use the smallest
three entry level kits under their belts before tackling a possible enclosure for their projects. Not me! Yes, space
project like the NESCAF. can be wasted by using a larger enclosure and sometimes
76 March/April 2019
they can take up precious
bench space, but to me,
the ease of construction Figure 7: My NESCAF ready to be used.
made possible by a larger
enclosure more than
makes up for most of their
drawbacks.
Just remember, it’s no
sin to put your project in a
larger box.
Whenever possible,
I prefer to use materials I
have onhand rather than
make special purchases.
Since my yard sale
NESCAF was already
built when I bought it,
its size and wiring pretty
much dictated the size of
enclosure I needed to use.
Had I gone with a small enclosure, I would have had to
Final Thoughts
rewire my NESCAF, and that is something I most definitely Finding the NESCAF at a yard sale was a great
didn’t want to do. opportunity in many ways; for one thing, I ended up with a
The enclosure I used was an empty Christmas nice audio filter, but even better than that was the chance
tin that was left over from the holiday. These types of it afforded me to learn a little bit about how filters do what
containers make good project enclosures, but they do have they do.
drawbacks. Figuring out what the NESCAF does, learning how
The primary difficulty with them is that they’re often filters work, and finally building an enclosure from junk
made from very thin gauge metal, and thin metal can box parts was a very satisfying experience. My NESCAF
sometimes be difficult to work with. This is especially true project proves something I’ve long thought to be the case:
when it comes to drilling holes. It’s not necessary to have an elaborate work bench and
When I drill holes into thin gauge metal, the first thing expensive test equipment to enjoy the electronics hobby.
I do is reinforce the spot where I’m drilling with a piece of These things are nice, but you can have a lot of fun with
wood; the end of a 2x4 usually works pretty well (Figure just the basic tools. All that’s really needed is a multimeter,
6). a soldering iron, and (most of all) a desire to learn.
I use a metal punch to get the hole started and then Good luck and have fun! NV
use my smallest drill bit to make the pilot hole. Once I’ve
drilled the pilot, I continue drilling with the next size bit
and follow that by stepping up through the sizes until Post comments on this article and find any associated
I reach the right size opening. Make sure your drill bits files and/or downloads at www.nutsvolts.com/magazine/
are sharp. Let the bit do its job. Be careful not to punch issue/2019/03.
through the tin with your bit.
Note: When I made my enclosure, I drilled holes for
the pots on one side and holes for the power and LED on
the opposite side. In hindsight, this wasn’t the best way to
do it. It’s better to locate holes for the power and the LED
on the same side as the potentiometers; perhaps between
the two pots.
Be precise when marking your enclosure and don’t get
in too big a hurry.
Painting the enclosure is pretty straightforward. The
only tip I can offer is to use a primer before applying the
paint — especially if you’re using a brightly colored tin
similar to the one I used.
My completed NESCAF is shown in Figure 7.
March/April 2019 77
Dark Energy
And The
Expanding
Universe By George R. Steber

A stronomers tell us that our universe is not


only expanding, but that it’s accelerating its
expansion. The precise explanation for the
accelerated expansion is a mystery. One
general view is that the universe is permeated
with a material of negative pressure creating
a gravitational repulsion. This material has
become known as dark energy.
Cosmologists conjecture that In this article, we’ll explore these ideas
the negative pressure may and analyze an electrical model with
be caused by the vacuum similar properties that is constructed
of space itself – which might with some copper plates and an
be the case if the vacuum electrometer. Comparing this model to
had a positive energy density. the cosmological model of our universe
Concepts such as energy should help us understand these
density and negative pressure concepts and emerging theories of the
are difficult for most of us to cosmos. Hopefully, in the process, we’ll
understand since we don’t learn more about how our fantastic
see them in our daily lives. universe works.
80 March/April 2019
The universe is a big place
and getting bigger all the time. Figure 1 is a
Hubble Space Telescope (HST) ultra-deep
field photograph of a very tiny patch of sky
— thought to be totally dark, devoid of stars
and galaxies. By adding up the light over 10
Figure 1. Galaxies are everywhere as far as the Hubble
days, however, the HST was able to build up a
Space Telescope can see. This view of nearly 10,000
spectacular picture. The result shows thousands
galaxies is the deepest visible-light image of the cosmos.
of distant galaxies with a myriad of shapes and
(Image courtesy of NASA, ESA, S. Beckwith, and the HUDF Team.)
sizes, providing a direct view of the adolescent
universe when it was still forming billions of
years ago. It is a good impression of what the cosmic Einstein’s Static Universe
sphere looks like all the way out to the most distant
visible galaxies. The cosmic sphere is a very useful way of compiling
Pictures such as this — while captivating — are a astronomical observations of the region of the universe
bit deceiving since they make it seem that galaxies are around us, but it ignores the fact that the universe is
close to each other. In actuality, they are hundreds of expanding. Expansion controls the temperature, density,
thousands to millions of light-years apart. The space and composition of the universe, and the formation of
between galaxies is filled with a tenuous gas having an astronomical structures. Einstein’s theory of gravity was
average density of less than one atom per cubic meter. the first to realize that space and time form an elastic
This is in contrast to the space between stars in a galaxy material called space-time that can be stretched and
— known as the interstellar medium — which is filled with contracted due to the gravitational force that a massive
gas, dust, cosmic rays, and electromagnetic radiation. object has on the space around it.
Cosmologists believe this nearly perfect vacuum of Imagine for a moment that all of space is filled with
space may also contain a dominant mysterious material. a nearly uniform distribution of matter, radiation, or other
They think that this substance has constant energy types of energy. According to Einstein’s theory, the entire
density and fills space with negative pressure. To help us universe can expand or contract, just like the overall
understand these unusual concepts, we’ll study a model stretching or shrinking of an elastic substance. While
of a system with similar properties using an electrometer Einstein believed in his theory, he didn’t like the idea of
and copper plates as mentioned earlier. However, before an expanding or contracting universe but preferred a
we get to that, let’s review how we came to understand model in which the universe is static and eternal.
our accelerating universe. As a consequence, Einstein introduced an extra
form of energy specifically designed to oppose the
gravitational attraction of matter. He didn’t know
what form this energy would take, so he simply
introduced it into his equations as a cosmological
constant which predicts a repulsive gravitational
effect, causing space to expand rather than contract.
In this model, Einstein finely adjusted the
repulsive gravity of the cosmological constant to
precisely counter the attractive gravity of matter. By
setting the opposing influences in perfect balance,
he was able to construct a static model of the
universe. However, this situation is contrived and

Figure 2. Edwin Powell Hubble was an


American astronomer. He played a crucial
role in establishing the fields of extragalactic
astronomy and observational cosmology,
and is regarded as one of the most important
astronomers of all time. (Image courtesy of NASA.)

March/April 2019 81
unstable. Unless the balance between forces is perfect, cosmic expansion caused by the stretching of space-time
the universe either collapses rapidly or blows up! itself.
Cosmologists say the galaxies are not moving
Hubble’s Expanding Universe through space, but rather they are moving in space
because space is also moving. A picture to explain the
Some years after Einstein’s proposal, came expanding universe is to imagine the universe like a loaf
experimental evidence that the universe is not static. In of raisin bread dough, with galaxies being the raisins.
the 1920s while working at the Mt. Wilson Observatory When heated, the bread dough expands, the raisins
with the most advanced technology of the time, Edwin move farther away from each other, but they are still
Hubble showed that some of the numerous distant fixed in the dough. Similarly, all galaxies in the universe
faint clouds of light being observed were actually entire move away from one another because of the expansion
galaxies — much like our own Milky Way. The realization of space in the universe.
that the Milky Way is only one of many galaxies forever
changed the way astronomers viewed our place in the The Universe is Accelerating Its
universe.
Hubble’s greatest discovery came in 1929, when
Expansion
he determined that the farther a galaxy is from Earth, In the early ’90s, cosmologists were fairly certain
the faster it appears to move away. This notion of an about the expansion of the universe. They thought it
expanding universe formed the basis of the Big Bang might have enough energy density to stop its expansion
theory, which states that the universe began with an and collapse or it might have so little that it would
intense burst of energy at a single moment in time — and continue expanding. In either case, gravity was certain
has been expanding ever since. to slow the expansion as time went on. Granted, the
If the universe were static as Einstein wanted, slowing had not been observed, but theoretically it had
Hubble might have found the motion of galaxies to be to slow. After all, the universe is full of matter and the
random with motions in all directions. Instead, he found attractive force of gravity pulls all matter together.
something extraordinary: All the galaxies are moving Then in 1998, Saul Perlmutter and his group
away from us. announced to an astonished crowd at the American
When Hubble plotted the velocity of the galaxies Astronomical Society that they had found evidence that
against their distance, he came across an interesting the separation velocity between galaxies has not been
relationship shown in Figure 3. This is now known as slowing down as expected but, in fact, was speeding up.
Hubble's Law and is interpreted as evidence for an The group used type 1A supernovae as standard candles
expanding universe. The slope of the line, Ho, is the to measure distance and the redshift of their spectra to
Hubble constant. It represents the constant rate of measure their expansion rate. Since looking far out into
space is equivalent to looking back in time, this
procedure allowed the astronomers to probe
the expansion rate at a much earlier time than
Hubble or any other measurement.
So far, there is no precise explanation for
the accelerated expansion. It seems that the
universe is filled with a material of negative
pressure, creating a gravitational repulsion.
The negative pressure material has become
known as dark energy. Assuming the standard
model of cosmology is correct, the best current
measurements indicate that dark energy
contributes 68% of the total energy in the
present-day observable universe.
One possibility for dark energy is the
negative pressure caused by the vacuum itself,
which would be the case if it had a positive
energy density. A vacuum energy density would
be exactly equivalent to what Einstein called a
cosmological constant.

Figure 3. Plot of Hubble’s distance-


velocity relationship for galaxies based on
his original data.

82 March/April 2019
Post comments on this article and find any associated files and/or downloads at
www.nutsvolts.com/magazine/issue/2019/03.

Our intuition rebels at the thought of attributing properties similar qualities to those found in the dark
energy density to a vacuum. However, we should energy of the universe. For this experiment, two large
bear in mind that particle theorists see the vacuum six inch square/single-sided copper boards were utilized
as a complicated state in which “virtual” particles are to act as a parallel plate capacitor and a Keithley model
constantly appearing and disappearing in quantum 616 electrometer for making measurements. The copper
fluctuations. These "virtual pairs" consist of one particle boards were mounted on wooden blocks so that they
with a negative charge and one with a positive charge. could easily slide on a surface and be put close together.
They exist for only a tiny fraction of a second before A photo of these items is shown in Figure 4.
they collide and annihilate each other in a tiny burst of An electrometer is a device for indicating charge or
energy. This energy may be pushing outward on space voltage and is often found in high school and college
itself, causing the universe to accelerate faster. labs. It has certain characteristics which enable reliable
However, much to the consternation of measurement from very high source resistance. When
cosmologists, particle physicists seem to be having used to measure voltage, the input resistance is greater
a problem understanding how the energy density of than 10,000 giga-ohms. As a result, the loading of the
the vacuum could be so amazingly small because it source circuit is relatively insignificant when compared to
contradicts the predictions of quantum field theories. a digital voltmeter having 10 mega-ohms input resistance.
These theories predict vacuum energies that are so large The goal of this demonstration is to show that the
that the universe shouldn't exist at all. This discrepancy is energy inside the capacitor plates has a density that
called the "old" cosmological constant problem. remains constant as the plates are pulled apart and
It’s safe to say that particle physicists are working whose negative pressure has the same magnitude as the
hard to solve this problem. We’ll have more to say about energy density.
this subject in a later section. In any case, it’s now time Refer to Figure 5 for the equipment setup. The
for a demonstration that an expanding space can have a procedure is as follows: First, the plates are brought
constant energy density and negative pressure. close together without touching, with one of the plates
grounded. Next, the other plate is electrified by briefly
Demonstration of Constant touching it to a voltage source; typically 10 volts. This
Energy Density in an Expanding process transfers an amount of charge Q to the plates.
Next, the plates are pulled apart slightly, being
Space careful not to touch them together. The electrometer
now shows an increase in the voltage across the
A large parallel plate capacitor contains within its capacitor — the amount depending on how far the
plates are separated. The increase
in voltage tells us that there is an
increase in the energy stored in the
capacitor. In practice, the voltage
across the capacitor will jump, then
slowly drop due to the loading of the
electrometer. The jump in voltage as
the plates are separated is easily seen.

Energy in the
Capacitor

Now, let’s calculate the energy


stored inside this parallel plate
capacitor. Recall that whenever a
parallel plate capacitor is charged, the
two plates receive equal and opposite

Figure 4. Photo of the


electrometer and parallel
plate capacitor used in the
experiment.

March/April 2019 83
Figure 5. Schematic of
the experimental setup
for the parallel plate
capacitor with Area A
and separation distance
d. An electrometer is
used to measure the
voltage across the
plates.

tend to push the plates apart


— a positive pressure. Since
the electric field is pulling in
the opposite direction, it’s
exerting a negative pressure.
It’s easy to show that the
negative pressure p has the
same magnitude as ρ and
equals:
(4) p = - ½ ε0E2
charges ± Q. We begin by assuming a uniform electric (which is the pressure on the plates)
field E between the plates, ignoring any fringing effects
as shown in Figure 5. The Role of Vacuum Energy in
You can either use Gauss’ law to find Q or use the
relation Q = C V for a parallel plate capacitor, where
Space
C is the capacitance and V is the voltage. A parallel The energy density between the capacitor plates
plate capacitor has the value C = ε0 A/d where ε0 is behaves in some ways like the vacuum energy of space.
the permittivity, A is the area of the plate, and d is the It is thought that the vacuum energy density of space
distance between the plates. The electric field for this ρ is constant throughout all of space and produces
case is E=V/d, so after some simple algebra, we have the a negative pressure p = - ρ, unchanging even if the
following result: space is enlarging. In our simple experiment, when we
(1) Q = ε0EA. enlarge the space between the plates, the extra energy
This shows that Q is proportional to E, since ε0 and comes from doing work by pulling the plates apart.
A are fixed constants. To calculate the energy stored in Cosmologists tell us that in an expanding universe, the
the capacitor, let’s assume that the plates are separated extra energy comes from gravitational potential energy.
by pulling on the positive plate from near zero to d. The It’s not obvious why the negative pressure causes
work W done is the force F times the separation d and the universe to expand. Intuitively, we might think that
must be equal to the energy stored in the capacitor ½ it should cause the universe to pull or contract. What
QV = ½ QEd. Combining this with (1) results in: really matters is the gravitational effect of the negative
(2) W = F d = ½ QEd = ½ ε0E2Ad. pressure. In Einstein’s general relativity (unlike Newtonian
Since E remains constant as the plates are pulled, gravity), both the pressure and the energy contribute to
it should be clear that the energy in the capacitor is the force of gravity.
proportional to the volume (Ad). To get the energy When Einstein's law of gravity is reduced to its
density ρ, divide by the volume (Ad): basics, the sign of the gravitational force is determined
(3) ρ = ½ ε0E2 (energy density between by the algebraic combination of the energy density plus
plates). three times the pressure (three because there are three
Since E and ε0 do not change as the plates are pulled dimensions of space). So, we have:
apart, we see that the energy density in the capacitor (5) g (gravity) = ρ (energy density) + 3p (pressure)
does not change when the volume between the plates is If the pressure is positive — as it is for radiation,
expanded. photons, neutrinos, and matter from the early universe —
the combination is positive, and gravitation is attractive.
Where is the Negative Pressure? If the pressure is negative, it can cancel out the energy
density, reducing gravity in the process.
Notice that when the plates are being pulled apart, If the pressure is negative and big enough, then the
the electric field E is pulling them together. If a balloon sign of the gravity force in Einstein's equation actually
is placed between the plates and filled with air, it would reverses. This happens if (ρ + 3p) is negative. Instead of

84 March/April 2019
Figure 6.
Illustrated here
is the concept
of an alternate
"bubble"
universe in
which our
universe (left)
is not the only
one. Some
scientists think
that bubble
universes
may pop into
existence all
the time, and
occasionally
nudge ours.
Some bubbles
would inflate
wildly, while others would collapse back on
gravity attracting, it repels.
themselves. Our own bubble universe just happens
Astronomical data says that dark energy is positive,
to have the right amount of matter and other
so negative pressure is what is needed for accelerated
variables to endure and foster the creation of stars
expansion. Among the dark energy contenders,
and planets. (Image courtesy of NASA/JPL-Caltech/R. Hurt.)
vacuum energy in the space between galaxies may
meet this condition, provided its density is positive.
Cosmologists say that negative pressure associated which is off by 120 orders of magnitude! Despite this
with dark energy is so large that it overcomes the huge disparity, most cosmologists still consider vacuum
positive (attractive) effect of the energy itself, so the net energy as the most complete scenario to-date. So, it
effect is a push rather than a pull. This results in a net leads the group of dark energy contenders.
repulsive gravitational field in intergalactic space.
The appeal of vacuum energy to cosmology is that Vacuum Energy and the
it could explain why the acceleration has only started
fairly recently on the cosmic timescale. In the early
Multiverse
universe, all the matter was packed much more densely Problems with finding the correct value for the
than today, so there was less space between galaxies. vacuum energy have led to a controversial idea that
Everything was so close together that gravity was the our universe is just a random bubble in an endless,
dominant force, slowing down the acceleration of the bubbling multiverse (see Figure 6) that arises logically
universe that was imparted in the Big Bang. Also, since from nature’s most innocuous feature: empty space. As
there was less space in the universe and the vacuum the hypothesis goes, the seed of the multiverse is the
energy comes from space itself, it played a much smaller inexplicably tiny amount of energy infused in empty
role in the early universe. space — energy known as vacuum energy, dark energy,
The universe has grown much larger in the 13.7 or Einstein’s cosmological constant.
billion years after the Big Bang, so the galaxies are not Nobel laureate Steven Weinberg once said that
packed so close together. Their gravitational pull on each the vacuum ought to be many trillions of times more
other is weakened, allowing the vacuum energy to play a energetic because of all the matter and force fields
more dominant role. coursing through it. So, why is space so empty?
Vacuum energy has its own problems. To match the While we don’t know the answer to this question, the
astronomical data, we require a vacuum energy density extreme vacuity of our vacuum seems necessary for our
of ρ ≈ 10-8 ergs/cm3. Unfortunately, physicists are unable existence.
to reliably calculate the expected vacuum energy in the If the vacuum energy had even slightly more of the
real world or even in some specific field theory such as gravitationally repulsive energy, space would expand too
the Standard Model of particle physics. The best they can quickly for structures like galaxies, planets, or people to
do is to offer order-of-magnitude estimates. form. This fine-tuned situation suggests that there might
Using quantum-mechanical zero-point vacuum be a huge number of universes all with different doses
fluctuations has led to an estimate of ρ ≈ 10112 ergs/cm3 of vacuum energy, and that we happen to inhabit an

March/April 2019 85
Figure 7.
Illustrated
here is the
new theory
of a cyclic
universe.
There is no
big bang,
and cosmic
history
consists of
repeated
cycles. It
eliminates
problems
in current
models but
creates
some of its
own.

extraordinarily low-energy universe because we couldn’t a bounce — not a bang — but the bounce is not the
possibly find ourselves anywhere else. beginning of space or time. Rather, it’s an event with a
This reasoning leads to the anthropic principle: A “before” and an “after” that can be described by the laws
philosophical idea that observations of the universe must of physics.
be compatible with the conscious and sapient life that Steinhardt argues that contraction at the end of a
observes it. It says the universe's ostensible fine-tuning is cycle — rather that eternal expansion — can solve all
the result of selection bias: our observance of only this the problems that the current Big Bang theory poses.
universe, compatible with our life. Only in a universe It smooths out variations and gives rise to large scale
capable of eventually supporting life will there be living uniformity and cosmic structure without any more
beings capable of observing and reflecting on the matter. assumptions.
These arguments depend upon the concept of the The cause of the proposed contraction is not well
multiverse for there to be a statistical population of understood, but neither is the inflation in the Big Bang
universes to select from and from which selection bias model. Steinhardt adds that this bouncing scenario has
could occur. the advantage of not predicting an infinite number of
Many scientists bristle at the tautology of “anthropic universes.
reasoning” and dislike the multiverse for being In this theory, each cycle affects the next. Events that
untestable. Even those open to the multiverse idea would occurred before the last bounce shaped the large-scale
love to have alternative solutions to the cosmological structure of the universe observed today, and the events
constant problem to explore. So far, it has proved nearly that are occurring today will determine the structure of
impossible to solve without a multiverse. the universe in the cycle to come. Perhaps space and
In his last paper, the renowned physicist Stephen time sprang into being many cycles ago, but it is also
Hawking and Thomas Hertog offered an interesting possible that they are literally “endless.”
departure from earlier ideas about the nature of the However, don’t raise your hopes too high, as this
"multiverse." According to the new theory of eternal cyclic universe theory is still in its infancy and there are
inflation, there was a boundary in the past, so time and many problems to solve. Remarkably, however, this new
space had a beginning. The universe that emerged from theory of a cyclic universe is able to match all current
that state is also finite, making it far simpler to deal with astronomical observations with the same accuracy as the
— and test scientifically. If that turns out to be the case, Big Bang picture, and it may explain some aspects of the
it deals a blow to the concept of a multiverse containing universe that the Big Bang picture cannot. Only time will
endless pocket universes. tell if this theory survives.
Another glimmer on the horizon is the emergence
of a new theory of a cyclic universe proposed by Paul We are fortunate to exist in a rare period of time
Steinhardt (Princeton) and collaborators; refer to Figure where competing theories of the universe are being
7. According to this theory, our cosmic history consists thrashed out. This debate may strongly affect the way
of repeating cycles of evolution. Each cycle begins with one views the universe and humanity’s place in it. NV

86 March/April 2019
Printed Circuit Boards Build
Arduino Graphics Interface
e t h i n g
TEENSY Graphics Interface
Mass Measurement
Som
Today
!
Wide Range Pulse Generator
Numitron Clock
Continuity Tester
Pi Scrolling Display Search www.nutsvolts.com for these terms and read the articles.
Search store.nutsvolts.com to find the boards.
Analog Style LED Clock Some are available as complete kits too!

Nuts & Volts and SERVO On CD

Getting Started Kits Popular DIY Kits


ARDUINO: A Beginner’s Guide To Wee Little Talker Skull Kit
Programming Combo Amigo Kit
Learning Labs 1-3
Solar Charge Controller Kit 2.0
Geiger Counter Kit
Poor Man’s Seismograph
LED Cube
88 March/April 2019
To Order Visit
store.nutsvolts.com
or call
1-800-783-4624

Arduino Graphing
Thermometer Kit Popular Clock Kits

March April 2019 89


www.poscope.com

- 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

PoScope Mega1+
PoScope Mega50

-up to 50MS/s
-resolution up to 12bit
-Lowest power consumption
-Smallest and lightest
-7 in 1: Oscilloscope, FFT, X/Y, Recorder,
Logic Analyzer, Protocol decoder, Signal
generator

90 March/April 2019
■ BY LOU FRENZEL W5LEF OPEN COMMUNICATION

Waiting For 5G Wireless


What is it and when can we expect it?

B y now, you’ve certainly heard of the forthcoming fifth generation (5G) wireless
technology. There’s a tremendous amount of hype about 5G as the various cellular
operators try to pre-sell you on the new benefits and services. Commercial 5G
services won’t go online until later this year, but we should see plenty of 5G action
in 2020. For that reason, you’ll need to know more about 5G to understand what impact it
will make on you and the world in general. Here’s a status report on 5G to bring you up to
speed.

Just what is 5G? some factory automation, self-driving cars, and other
mission-critical uses.
5G is the designation for the next generation of
cell phone service. Also referred to as 5G New Radio
(NR), it is a wireless standard being developed by the
What are some of the specifications
Third Generation Partnership Project (3GPP) which is an and highlights of 5G service?
international organization. This standard is expected to be
adopted throughout the world initially to enhance, then  Peak data rates under ideal conditions of up to 10
probably replace the current 4G systems. Gbps. Typical user download experience of 100
The standard is still in the final stages of its Mbps.
development, yet enough is known about the standard  Extended network capacity to one million connections
that semiconductor and equipment companies can begin per square kilometer to accommodate more
designing and making chips and systems, and cellular customers and the IoT node masses.
providers can begin implementing the system and services.  Latency less than 10 milliseconds (s) and to 1 ms or
The final standard is expected to be ratified sometime in less under ideal conditions.
2020.
What are some of the nitty gritty
What is the purpose of 5G? specifications for wireless nerds?
This new standard is targeting three major areas of
application:  Wider bandwidths. The largest channel bandwidth for
 Enhanced mobile broadband (eMBB). The goal is to LTE is 20 MHz. 5G can use up to 100 MHz below
bring higher speed data service to cell phones to 6 GHz. In the mmWave (millimeter wave) bands,
enable new things like improved games and high bandwidths of 80, 100, and 400 MHz up to 1 GHz
definition video. max are possible. Wide bandwidth is the secret
 Massive Machine Type Communications (mMTC). This ingredient to achieving the high data rates.
refers to technologies like the Internet of Things (IoT).  Some form of OFDM modulation. The current
This will extend the usage of the mobile networks to 4G Long Term Evolution (LTE) systems also use
any small sensors for remote monitoring, smart home Orthogonal Frequency Division Modulation. OFDM
uses, industrial automation, smart cities, and similar is made up of multiple subcarriers to handle the data.
applications. LTE uses 15 kHz subcarriers while 5G can use 30,
 Ultra-Reliable and Low Latency Communications 60, 120, 240, or 480 subcarriers. Each subcarrier is
(URLLC). Many applications require quicker response modulated by BPSK, QPSK, 16 QAM, 64QAM, or
times from wireless links. These include military, 256QAM.
March/April 2019 91
THE LATEST IN NETWORKING AND WIRELESS TECHNOLOGIES
Post comments on this article and find any associated files and/or downloads at
www.nutsvolts.com/magazine/issue/2019/03.

yy The use of multiple input multiple output (MIMO) features are not just nice add-ons, but ones essential for 5G
and beamforming antenna technologies with phased operation in the mmWave bands.
arrays. (See a separate question on this.) One real challenge is the smartphone front-end. This
yy Higher spectral efficiency. Spectral efficiency refers is the subsystem made up of many filters and switches that
to how fast the data rate can be achieved in a given select the dozens of cellular frequencies. These filters and
bandwidth. 5G provides up to 30 bits per second the related circuits like low noise amplifiers (LNAs) and
per Hz (30b/s/Hz) thanks to the greater bandwidth, power amplifiers (PAs) are harder to make for mmWave
modulation methods, and MIMO. frequencies.
Semiconductor technologies are also making this
What part of the radio spectrum does possible. New materials like silicon-germanium (SiGe),
BiCMOS, gallium arsenide (GaAs), and others are being
5G use? used to implement especially the new cellular equipment.
New faster processors are available to implement the
5G will use a wide range of spectrum. It will operate complex digital modems.
in the cellular bands below 6 GHz and in many higher
frequency millimeter wave bands above 24 GHz. Spectrum
availability varies widely with different countries and within
What will happen to the current 4G LTE
certain areas of the country, and specifically what spectrum systems?
is owned by the various cellular operators who serve the
local markets. Some of the potential new US assignments The 4G systems use a technology known as LTE.
are: It’s amazingly good, and some have argued that we
yy Standard cellular bands below 6 GHz, plus 2.5, 3.5, don’t really need an upgrade. However, you know how
3.7-4.2, 4.9, 5.9 GHz. electronics people are — always inventing something new
yy 24 GHz and 26 GHz. or trying to improve upon current equipment and services.
yy 27.5 to 28.35 GHz. After all, that is where the new sales and profit come from.
yy 37, 39, 42, and 47 GHz. Will 5G really be as good as LTE? We’ll soon see, but
don’t write off LTE yet. It will be around for many years to
The lower cellular bands (600 to 950 MHz, 1.8 to1.9 come and is continuing to improve with newer faster LTE
GHz, and 2.5 GHz) will be “refarmed” to accommodate Advanced and LTE Advanced Pro versions.
the wider bandwidth 5G signals. The new mmWave bands Furthermore, cellular providers are still rolling out
will provide the larger bandwidths that can deliver the new equipment and services like IoT access. What I really
higher speeds and other capabilities. wonder is whether a user will be able to tell any difference
The Federal Communications Commission (FCC) that between an 4G LTE phone and a 5G phone. What if it’s
regulates cellular radio is planning on some forthcoming worse or just on par?
auctions to sell additional mmWave bands to the major
cellular operators.
What will a 5G smartphone be like?
What technologies are being used to It will definitely be larger. It has to contain all the new
5G radio circuits and phased array antennas, as well as the
produce the performance expected of current 4G LTE circuits. 5G will not be available initially
5G? to many parts of the country and world, so you need that
existing LTE technology.
Antenna technology plays a huge role in the new 5G With all that new circuitry, power consumption will be
system; MIMO will be a major feature. It uses multiple higher. That translates into shorter battery life. However,
antennas and transceivers transmitting on the same the larger size may indicate a larger battery to mitigate that
frequency to minimize bandwidth usage. MIMO makes use problem.
of the different wireless paths from transmitter to receiver. A 5G smartphone will also be more expensive because
This improves the reliability of the transmission, as well as of the new parts. Millimeter wave radio ICs and related
boosts the data rate. All those extra antennas and radios parts have higher price tags. My bet is that initially 5G
take up much more space and eat more power. phones will cost more than $1,000, up to about $2,000.
For millimeter wave bands, phased arrays with a matrix The newest smartphones available today have larger
of 8x8 or 16x16 antenna elements will be used not only to folding screens and cost around $2,000. 5G phones
boost signal power to extend the coverage range, but also probably won’t have folding screens. Some 5G phones are
implement beamforming and agile beam steering. Such now available from Samsung and Chinese makers Huawei,
92 March/April 2019
Xiaomi, and Oppo. Apple probably won’t have a 5G or Wi-Fi 6 as it’s called today. It’s super-fast with download
iPhone until late 2020 or so. speeds up to about 10 Gbps, thanks to OFDM and MIMO
like 5G. However, Wi-Fi 6 is a different animal.
What — if any — big changes will be The primary use is in LANs for Internet access. Home
and office routers will get better with Wi-Fi 6. Yes, 5G will
needed in the cell site base stations let you access the Internet through the cellular network,
and coverage network? but it will most likely be more expensive. 5G phones will
probably have a Wi-Fi 6 chip in them to access the Internet
All new equipment and antennas will be required. as we do now.
Instead of one big macro base station like those used
now to cover a specific area, multiple base stations will
be necessary to handle that same area. These so-called
What cellular operators will be offering
small cells are about the size of a loaf of bread and are not 5G service?
unsightly. While a standard macro cell site now covers an
area of several square miles, it will take a dozen small cells All four of the major service providers will be offering
to cover that same area providing full 5G service. some limited service. These are AT&T, Verizon, T-Mobile,
and Sprint. T-Mobile and Sprint are still trying to merge into
Why are so many cells required? a single entity but that hasn’t happened yet.
The initial offering will most likely be broadband
It has to do with the frequencies of operation. The wireless service to access the Internet. This service is
basic physics of radio waves say that the higher frequencies expected to compete with cable, DSL, and fiber. Some
will travel a shorter distance for a given transmitter power. limited 5G service is expected to be offered later in 2019
Low frequency signals will go much farther. That’s why by AT&T and Verizon.
the lower frequency cellular bands are so coveted and
valuable.
Wireless equipment that operates in the UHF and
Will 5G really be a factor in the IoT
microwave bands have reasonable range. That range movement?
will be even shorter as the small cells begin operating in
the mmWave bands above 24 GHz. There will also be That remains to be seen. The 5G standard is supposed
more indoor cells since mmWave signals don’t penetrate to accommodate many more users, and most of the
buildings, trees, and other obstacles as well as the lower cellular carriers would love to offer service to some IoT
cellular frequencies (if at all). Beamforming boosts devices to boot income and profit. AT&T, T-Mobile, and
transmitted power to overcome these problems, but even Verizon already provide some IoT services with LTE using
that has its limitations. the LTE-M and NB-IoT radio modules. That could continue.
A high percentage of IoT applications use only short
How do all those new small cells data packets at very low speeds, so 5G is overkill. Some
IoT applications may adopt 5G but with so many other
connect to form the network? cheaper options, millions won’t.

These cells will all have to link with central points that
will process and route the calls and connections. That link
What new services or applications will
is called backhaul. Most carriers seem to be using fiber 5G permit?
cable where available, but installing new fiber is a costly
and time-consuming process. Some say that virtual reality/augmented reality (VR/
Backhaul is also implemented with point-to-point AR) with their bulky headsets will use 5G. It’s doubtful that
microwave or mmWave radios. Even some DSL lines are 5G will help sell this niche technology. A good possibility
fast enough and may be cheaper and more available than is that 5G will be the wireless connectivity of choice for
fiber. The cable TV companies with their hybrid fiber and automobiles.
coax cable system could be used. It will first appear in advanced driver assistance systems
(ADAS), then in driverless vehicles. The V2V (vehicle-to-
Will 5G eventually kill Wi-Fi? Or vise- vehicle) radios have been proposed and prophesied for
years as a way for vehicles to communicate with one
versa? another to avoid collisions. Even vehicle-to-infrastructure
Probably not. The latest version of Wi-Fi is 802.11ax (V2I) links between cars and roadside units that transmit
March/April 2019 93
THE LATEST IN NETWORKING AND WIRELESS TECHNOLOGIES

weather, road conditions, construction, and other small cells will have to be mounted somewhere on
information have been proposed. buildings, lamp posts, traffic lights, or other available
An older Wi-Fi-like wireless technology called direct structures, and the cities are trying to make money
short-range communications (DSRC) was originally on it. The FCC is trying to expedite this procedure.
planned, but the final choice by the National Highway yy Carrier investment. It will take billions of dollars to
Traffic Safety Administration (NHTSA) is expected to be fully implement 5G. A whole new network has to be
5G. No telling when that will happen. built and deployed. This is expected. The carriers are
already spending big bucks to get 5G going, but all
When will 5G service begin? have financial limits.
yy Limited and enormously expensive spectrum. The US
Most of the service providers say some limited service is way behind China, South Korea, Japan, Europe,
will be available later in 2019. It takes time to roll out full and other countries in formally allocating spectrum.
services, usually years. Remember how long it took 4G The forthcoming auctions will finally see this happen.
LTE? A decade.
Conclusion
What factors are hindering or delaying 5G is well on its way. Development and
5G service? implementation will continue for years, but you will
eventually get it. Do we really need it? Probably not, but
yy Few 5G smartphones are available. we are going to get it anyway.
yy Local municipalities and jurisdictions are delaying, Look at it this way: 5G NR technology will probably
restricting, and over-pricing the attachment policies make you even more addicted to your smartphone than
for mounting 5G small cells. All those required new you are now. That’s a good thing, right? NV

94 March/April 2019
Reader Feedback Continued from page 7

out Nuts & Volts. They should also become acquanited than a clip? I have thought of wiring “nuts” an electrician
with the magazine’s exceptionally qualified editor at www. would use, but I think that won’t work very well as the two
bryanbergeron.com. legs (LED, resistor) won’t twist around each other as easily as
Forrest M. Mims III multi-strand wire (which I believe is what the nuts are usually
used for). Thanks for Nuts & Volts and SERVO Magazine. I also
Well, sir, you do know how to put a smile on a person’s volunteered to be the “programming mentor” for an area high
face. I’m glad you enjoyed the magazine. As you know, you’ve school FRC team, so I’m learning more about the hardware
been a virtual mentor for me since I was in grade school. I side of robotics (roborio, limelight, etc.)
saved my quarters to buy your little notebooks at RadioShack Tom Harron
and spent my time in the library reading your introductory What a great way to teach electronics! And yikes! Third
classic on electronics. I learned to read (seriously) by studying graders. I’ve extended components with male wire jumpers;
your articles in Scientific American, Popular Science, and the the jumpers sold for use with breadboards. Makes it easy to
rest. I know the other authors as well as the publisher and install a component onto a breadboard or an Arduino.
production staff value your opinion just as highly. Also, you can color-code the leads (e.g., red for anode).
Bryan Bergeron The easiest connectors I’ve used for little hands are based on
magnets on each end of a component that is terminated in a
Teaching Tactics magnet or magnetic wire. But that gets expensive fast. Thanks
I had to smile while reading Bryan Bergeron’s editorial in for the note and good luck!
the Jan-Feb issue. I teach an annual 4H “Fun with Electronics” Bryan Bergeron
class to kids from 5 to 15 years old (in separate groups). Just
the basics with a couple AA batteries, resistors, motors, wires, Charged Up
clips, LED, CdS, etc. I use alligator clips for 3rd grade and Thanks for publishing the interesting story of early
below. They are very tricky for the little kids and frustrating electricity! Very enjoyable! It reinforces my thoughts that one
— it slows down the class when 20% of them don’t have the of the educational tragedies is that most of the way history
dexterity to handle the small components (and I’m scurrying is taught is from a political view when most politicians were
around). With the older kids (using solder), I usually have one simply reacting to the changes in technology of their time. Yet
or two kids with a little burn (I bring a cooler with ice cubes). much of the history of technology is never taught or is buried
Your article was a perfect reminder for me to take a step back or lost.
and reconsider my plans! In 1997, I became aware of the book, Theory And
By the way, I find alligator clips to be a pain — it’s a very Calculation Of Alternating Current Phenomena (1897), by
loose connection — with say the leg of an LED and the leg Charles Proteus Steinmetz and Ernst Julius Berg. Since my
of a resistor. Can you recommend some other solution other class had just finished a course in AC theory and calculations
I had a copy of his 100 year old text shipped to our library.
Students were amazed that they could read and understand
THE OWNERSHIP, MANAGEMENT, AND CIRCULATION STATEMENT OF NUTS & his writing and the AC math.
VOLTS MAGAZINE, Publication Number: 1528-9885 is now published bi-monthly,
effective with the May-June 2018 issue. Subscription price is $26.95. 7. The In the article on radio waves, Heavyside was credited with
complete mailing address of known office of Publication is T&L Publications, Inc., using complex numbers in the analysis of AC circuits.
2279 Eagle Glen Pkwy, #112-481, Corona, Riverside County, CA 92883. Contact Did Heavyside and Steinmetz know each other? Was
Person: Larry Lemieux. Telephone: (951) 371-8497. 8. Complete Mailing address
of Headquarters or General Business Office of Publisher is T&L Publications, Inc., Heavyside extending what Steinmetz had started? My
2279 Eagle Glen Pkwy, #112-481, Corona, CA 92883. 9. The names and addresses impression was that Steinmetz was the first to use complex
of the Publisher, and Associate Publisher are: Publisher, Larry Lemieux, 2279 Eagle numbers for AC analysis but most discoveries did have many
Glen Pkwy, #112-481, Corona, CA 92883; Associate Publisher, Robin Lemieux,
2279 Eagle Glen Pkwy, #112-481, Corona, CA 92883. The names and addresses working on the problems as the current article shows.
of stockholders holding one percent or more of the total amount of stock are: John George Shaiffer
Lemieux, 2279 Eagle Glen Pkwy, #112-481, Corona, CA 928839; Lawrence Lemieux, Instructor Electronics Technology PPCC (ret)
2279 Eagle Glen Pkwy, #112-481, Corona, CA 92883; Audrey Lemieux, 2279 Eagle
Glen Pkwy, #112-481, Corona, CA 92883. 11. Known Bondholders, Mortgagees,
and other security holders: None. 12. Tax Status: Has not changed during preceding
12 months. 13. Publication Title: Nuts and Volts 14. Issue Date for Circulation Typo Fix
Data: October 2017-September 2018. 15. The average number of copies of each
issue during the proceeding twelve months is: A) Total number of copies printed RE: Jan-Feb 2019 issue/pg 38: I read the RF Freq Counter
(net press run); 20,838 B) Paid/Requested Circulation (1) Mailed Outside County Buffer article with great interest and would like to build one
subscriptions: 13,278 (2) Mailed In-County subscriptions: 0 (3) Paid Distribution once I get my electronics workshop set up after a recent
Outside the Mail including Sales through dealers and carriers, street vendor, and
counter sales and other paid distribution outside USPS: 3,817 (4) Paid Distribution move.
by other classes of mail through the USPS: 0; C) Total Paid Distribution: 17,095; D) There is one possible error in the description, however.
Free or Nominal Rate Distribution by mail and outside the mail (1) Free or Nominal Page 3 describes the circuit protection provided by D3/C4.
Rate Outside-County Copies: 0 (2) Free or Nominal Rate In-County Copies: 0 (3)
Free or Nominal Rate Copies Mailed at other classes through the USPS: 0 (4) Free Per the schematic in Figure 2, I think it should read D2/C4.
or Nominal Rate Distribution Outside the mail: 542; E) Total Free or Nominal Rate Am I missing something?
Distribution: 542; F) Total Distribution: 17,637; G) Copies not distributed: 3,189 H. Wintcher
H) Total: 20,825; Percent paid circulation: 96.93%. Actual number of copies of the
single issue published nearest the filing date is September-October 2018; A) Total WA0RGG
number of copies printed (net press run) 27,330; B) Paid/Requested Circulation (1)
Mailed Outside County subscriptions: 17,790 (2) Mailed In-County subscriptions: Yes. The text should read D2/C4.
0 (3) Paid Distribution Outside the Mail including Sales through dealers and carriers,
street vendor, and counter sales and other paid distribution outside USPS: 5,434 Dwayne Kincaid
(4) Paid Distribution by other classes of mail through the USPS: 0; C) Total Paid
Distribution: 23,224; D) Free or Nominal Rate Distribution by mail and outside
the mail (1) Free or Nominal Rate Outside-County Copies: 0 (2) Free or Nominal
Rate In-County Copies: 0 (3) Free or Nominal Rate Copies Mailed at other classes Kudos
through the USPS: 0 (4) Free or Nominal Rate Distribution Outside the mail: 500; As co-founder of Cepheid and a huge nerd, let me extend
E) Total Free or Nominal Rate Distribution: 500; F) Total Distribution: 23,724; G) my most sincere congratulations on Bryan Bergeron’s open-
Copies not distributed: 3,606; H) Total: 27,330; Percent paid circulation: 97.89%. I
certify that these statements are correct and complete. Lawrence Lemieux, Publisher source PCR thermocycler! Bravo!!!!!
- 03/01/2019. Greg Kovacs
March/April 2019 95
TECHFORUM READER - TO - READER

>>> QUESTIONS reputation that English cars have >>> ANSWERS


for electrics. Can you recommend a
Introducing A Time Delay Into RC circuit for this application? (This car is [#9183 - Sep/Oct 2018]
Car Steering aNEGATIVE chassis). Something Strange With The
A local STEAM program is #3192 Patrick Gilmore Range
looking into using an RC car or truck Amherst The effective range of the key
to simulate operating a vehicle on FOB for my Ford F150 seems to have
the moon or other astronomical Devices/Software/Scheme For decreased over recent months. While
object. One big opportunity to excel Wi-Fi Remote Control Using it used to work from distances of
is introducing a time delay (say five Smartphone 75-100 yards easy, now I need to be
seconds) into the steering system to There are a number of articles nearly right in front (10-20 yards) of
model the time required for radio to in the past issues of Nuts & Volts for my vehicle to operate the systems. I
go signals to and from the vehicle. a variety of ways to control devices changed to a fresh battery, but no
The first thought is to buffer the in a home using a variety of control difference. Is it likely there is an
command string at the transmitter or devices and schemes. However, none antenna problem? If so, where is it
receiver. Ideas, hints, suggestions? seem to have the combination of located and is there a test procedure?
#3191 Jon Caples characteristics that I want. I would
Parker, CO like to control a pair of simple I had a similar problem with the
low current AC sockets (ON/OFF) key FOB for my ‘91 BMW. It got
Side Lights As Turn Signals - MG from my cell phone. I would like to so bad that I had to hold the FOB
Auto use a combination of an existing against the driver's window for it to
My brother has an old MG that app, a PIC style device (Ardunio or work. After trying new batteries and
he likes tinkering with. He wants to whatever), and a Wi-Fi module to testing the range of the transmitter
use the side lights to indicate when connect it to my existing Wi-Fi. I do at the local auto supply, I decided
the turn signal is on for drivers that not see why a $100 hub should be that the problem must be with the
are on either side of him. Normally, needed. My present cell phone uses receiver, which I found up inside the
the side lights turn on and off with the Windows operating system, but I dash behind the instrument panel.
the headlights. know that apps for it are scarce and After removing the circuit board
In his case — and to reduce peak I am willing to get an Android device. from its case, I found that there was
power consumption to the blinker I’m stuck on finding the cell phone an antenna matching network with
circuit — he would like the side lights app and the Wi-Fi module. I would an adjustable inductor on the board
to turn on when the signals are off, assume that I would have to write that was not sealed. By speculating
and vice versa (when the turn signal the appropriate code for the PIC how gravity and 27 years of thermal
switch is turned on). Additionally, device. I can interface the PIC with a cycling might affect the adjustment,
if the lights are on, the side lights relay, probably a solid state one. Any I gave it a quarter of a turn in the
should give priority to the turn signal, suggestions? opposite direction and — as luck
turning on and off, opposite to the #3193 Edward Alciatore would have it — my effective range
signals in the front and rear, and Beaumont was restored to over 100 feet. If your
returning to full on when the turn unit was factory installed, you can
signal is not engaged. Troubleshooting Circuit Needed probably find a shop manual at the
I think the simplest way to do this I’m looking for a circuit using a public library to help you locate it,
would be with solid-state relays and piezo buzzer, that I can hear from and perhaps my fix will work for you.
the use of some logic gates (for each the room above the cellar. It will be Good luck with it.
side). I have built hundreds of logic connected to a Taco Heating Zone Jack Noble
circuits, but have not really dabbled Valve on the boiler in the cellar for Shoreline, WA
much in automotive applications. troubleshooting the thermostat when
I know the electronics have their it goes on and off. [#9184 - Sep/Oct 2018]
own temperature and performance #3194 G Forcino Wireless Data To PC
specs and are noisy environments, via email I have a number of wireless
not to mention the notoriously bad temperature/humidity sensors made
96 March/April 2019
>>>YOUR ELECTRONICS QUESTIONS ANSWERED HERE BY N&V READERS

Send all questions and answers by email to [email protected]


or via the online form at www.nutsvolts.com/tech-forum

by Oregon Scientific for use as The Arduino could capture raw and need to vary the pitch slightly to
weather station sensors. I would like transmissions and send the data to match the tuning of my instrument.
to use them for a data acquisition and your PC’s terminal software via a We used to do this easily with vinyl by
monitoring application. Does anyone USB virtual serial port. Then, you varying the speed of the turntable.
know what frequency and mode could look at the raw information and
they operate on and how I might use decide what it means and how to use #1 I would be surprised. CD
them to send data to a PC to record it. players are designed to KEEP their
seasonal trends? Would I need a Oregon Scientific has published speed. I would convert the song to
microcontroller to interpret the output information about its communication one of the usual audio file formats
or could it be read directly by the PC protocol and you can find here: (mp3, wav) and run it on a computer
and then logged and displayed using wmrx00.sourceforge.net/Arduino/ with the free Audacity tool. That
software such as MakerPlot? OregonScientific-RF-Protocols.pdf. lets you change the speed and even
The SourceForge project has other allows you to keep the pitch! (Effect
Oregon Scientific registered information and code that might help -> Change Tempo; Effect -> Change
with the Federal Communications you: wmrx00.sourceforge.net. Speed). I use Audacity constantly.
Commission (FCC) to use 433.93 Jon Titus Werner G
MHz as the frequency for its units Herriman, UT via email
YPGSL109, YPG SL109, YPG-SL109,
YPG-SL1O9, YPG-SLI09, and YPG- [#11188 - Nov/Dec 2018] #2 CD players for the professional/
5L109. For only a few dollars, you can Tuning The Music DJ market have variable pitch built in.
buy small transceiver modules for the Is there a way to vary the speed Erik von Seggern
Arduino family of microcontrollers of a music CD player? I play my Escondido, CA
(MCUs) and others. instruments along with the recordings

ADvertiser INDEX Accutrace .................................. 99


Actuonix Motion Devices .......... 17
Circuit Specialists ..................... 47
■ LOOK FOR ■ SEARCH FOR ■ FIND Find your favorite advertisers here!
CQ Magazine ............................ 94
ACTUATORS EDUCATION ROBOTICS DLP Design .............................. 65
Actuonix Motion Devices ME Labs Actuonix Motion Devices
Hitec Commercial Solutions PoLabs Electronix Express Electronix Express .................... 39
BATTERIES/CHARGERS EMBEDDED SYSTEMS goBUILDA ExpressPCB ............................. 90
Hitec Commercial Solutions Saelig Co. Inc. Hitec Commercial Solutions goBILDA ................................... 98
Technologic Systems Pololu
BUYING ELECTRONIC Robot Power Hammond Manufacturing ......... 56
SURPLUS ENCLOSURES Hitec Commercial Solutions ....... 2
Keyways Hammond Manufacturing SDP/SI
TEST EQUIPMENT Keyways ................................... 65
CIRCUIT BOARDS EVENTS
Accutrace LED Expo Circuit Specialists Labcenter Electronics ............... 25
ExpressPCB Maker Faire Electronix Express LDG Electronics .......................... 3
Saelig Co., Inc. Pico Technology
HAM GEAR LED Expo ................................. 78
CNC Circuit Specialists PoLabs
Saelig Co., Inc. Maker Faire .............................. 79
Routakit CQ Magazine
LDG Electronics Measurement Computing ........ BC
COMPONENTS TOOLS
Circuit Specialists LCDs/DISPLAYS goBUILDA ME Labs ..................................... 7
Electronix Express Saelig Co., Inc. PanaVise PanaVise .................................. 64
Saelig Co., Inc. PoLabs
MICROCONTROLLERS / I/O Pico Technology ....................... 19
DATA LOGGING BOARDS Routakit
PoLabs ..................................... 90
Measurement Computing ME Labs TRANSFORMERS
Pico Technology Robot Power Pololu ........................................ 11
Technologic Systems Hammond Manufacturing
DESIGN/ENGINEERING/ Robot Power ............................. 47
REPAIR SERVICES MOTORS / MOTOR TUNERS Routakit .................................... 87
Accutrace CONTROL LDG Electronics
ExpressPCB goBUILDA Saelig Co., Inc. ......................... 10
Labcenter Electronics Hitec Commercial Solutions USB SDP/SI ...................................... 65
Robot Power DLP Designs
DEVELOPMENT Technologic Systems ................ 57
PLATFORMS/TOOLS RF CONNECTORS WIRELESS PRODUCTS W5SWL Electronics .................. 65
Technologic Systems W5SWL Electronics Technologic Systems
March/April 2019 97
AVAILABLE AT goBILDA.COM
[email protected] • 620.705.5959
ea ea ea

Our Full Service Capabilities:

(408)748-9600
ITAR I SO 9001:2008 UL Approved
Bring Your Pi to Work!

MCC 118
Analog Input
• 8 channels
• 100 kS/s
• 12-bit resolution

MCC 152
Analog Output
• 2 channels
• 8 DIO

Measurement Computing now offers


DAQ HATs for Raspberry Pi ®

MCC Raspberry Pi measurement HATs were designed to bring high-quality


measurements to the ubiquitous low-cost computer. MCC DAQ HATs are the
perfect solution for adding professional quality DAQ capabilities to the Pi platform.

MCC DAQ HATs include:


• Complete SW library for easy programming
1 YEAR • Full set of examples in C® and Python™
• Stackable for high-channel count
• Quality from a trusted source
• Perfect for: embedded system design,
industrial IoT, end-of-line test, and more...

www.mccdaq.com/DAQ-HAT

©2019 Measurement Computing Corporation, 10 Commerce Way, Norton, MA 02766 • [email protected]

You might also like