A Wind Speed
f you’re like most
people, many of
activities depend on
the weather. For
such as golf,
sailing, and biking,
Interface for the
good weather is essential.
As an avid private pilot, this
situation is especially true for me.
Sure, I can fly when the weather is not
good, but I much prefer to fly when
the sky is blue and the sun is shining.
These conditions have become so
important to me that I sometimes find
myself checking the weekend weather
forecast as early as Tuesday!
As a result of my personal
“dependence” on good weather, I’ve
developed a keen interest in collecting surface of the earth, which in turn heats the JOHN MORLEY
my own weather data, making my air closest to it.
own weather observations, and This heated air begins to rise, forming
forecasting the weather. For many convective air currents (i.e., vertical columns In addition to describing a wind
years, I’ve gathered most of my of rising warm air). As the heated air rises, it
weather data via traditional outlets gradually loses its heat, falls away, and is speed and direction interface for
such as NOAA weather radio and replaced by the continually rising stream of
local TV and radio broadcasts. warm air from the surface. the HCS II home control system,
Over the past few years, easy Global circulation results when the
access to the Internet has enabled me intense sunlight striking the equator causes John presents background
to supplement this data with instant this convective upwelling of heated air
access to both national and regional molecules. These air molecules flow north information on the various
weather data and forecasts. Even more and south toward the poles, cooling and
recently, I’ve added weather-data- sinking en route. Cooler air from the polar techniques for measuring wind
measurement capability to my HCS II regions is in turn drawn into the solar-
system. I can now directly collect and powered furnace at the equator. speed and direction. And, unlike
analyze my own weather data. This natural flow creates a gradient of air
Until now, my weather data- pressure, with low-pressure areas near the the golfer, his finger stays dry and
collection system consisted of sensors equator increasing to high-pressure areas
for measuring outdoor temperature, near the poles. Finally, the effects of the there’s no grass in his hair.
relative humidity, and barometric earth’s rotation about its axis work to ensure
pressure. My most recent additions- that the effects of atmospheric circulation,
transducers and signal conditioners- and varied atmospheric pressure, are
measure the speed and direction of the distributed over a wide geographical area.
wind. These factors contribute in large part to
This article details the design, the continually changing weather patterns
construction, and calibration of the we experience every day. Moving air masses
wind-measurement instruments. (wind) are most often quantified in terms of
their relative direction and velocity. Because
THE BASICS the type of weather we experience is closely
Wind is a phenomenon caused by linked to these moving air masses, a great
large moving masses of air molecules. deal of meteorological information can be
These molecules comprise the gleaned from wind-speed and wind-direction
gaseous atmosphere that surrounds measurements.
our planet. For instance, the passage of a weather
Heat is the driving force behind front (cold or warm) is always
the movement of air molecules in our followed by a change in the wind
atmosphere. Solar radiation heats the direction, temperature, and
HOME AUTOMATION & BUILIRNG CONTROL MARCH 1999 53
barometric pressure. Wind speed can also be There are several common units of which directly displays the air
an excellent indicator of current and future measure for wind speed. Meteorologists in velocity. This measurement system is
weather conditions. the U.S. generally express wind speed in calibrated and the display indicator is
In general, constant wind direction and terms of miles per hour (MPH), based on a marked in the appropriate units using
low to moderate (not gusting) wind velocity statute mile. Certain disciplines, particularly a known wind-speed standard.
indicate a stable air mass and thus fair marine and aviation, express wind speed in Recently, it has become more
weather. High wind velocity, gusting, and terms of knots (or nautical miles per hour). common to measure this pressure
variable wind direction indicate an unstable One kn is equal to 1.15 MPH. using a solid-state pressure sensor.
air mass and unsettled weather. In countries where the metric system is This type of anemometer has the
Your own observations and the weather- used, wind speed is often expressed in terms disadvantage of being very direc-
forecasting experience you acquire will of kilometers per hour. One km/h is equal to tional. Components of air velocity not
likely be the most powerful tools you have to 0.625 MPH. in line with the axis of the pitot
accurately gauge the implications of the A few popular anemometer types are measurement tube are measured
weather data you observe. The relationship reviewed below. inaccurately, if at all.
between this data and the actual weather is For this reason, the pitot anemom-
left to you for further investigation. eter is usually found in applications in
If you thought that adding weather Weighted which the direction of the air velocity
measurement sensors to your HCS II system Pointer Vane is fixed. Applications include air-
was beyond you, think again! I’ll show you velocity measurement in wind tunnels
the steps I took to design and build a and air-speed indicators in airplanes.
complete wind speed and direction measure-
ment interface for my HCS II system. HOT-WIRE ANEMOMETER
So, gather the required parts and warm up For very accurate laboratory-type
your soldering iron, while I show you what’s measurements, the hot-wire anemom-
necessary to add this interface to your own eter (Figure 2b) is often used. This
home control system. anemometer consists of an electrically
heated wire on the end of a sensor
JUST HOW DO I MEASURE? probe and an electronic control
The two instruments commonly used to module.
measure wind speed and wind direction are Air velocity is determined by
the anemometer (wind speed) and the wind measuring the amount of electric
vane (wind direction). The wind vane, Figure 1: The wind VW U&VU itselfwith the IOC~ current it takes to maintain a preset
illustrated in Figure 1, generally consists of a air stream to indicate wind direction. constant temperature in the heated
weighted pointer connected to a small flat wire as air molecules pass over it.
plate. This combination is attached to a As air molecules pass over the
rotating vertical shaft. PITOT ANEMOMETER heated wire, they tend to cool the wire
The force of air molecules striking the Figure 2a illustrates the pitot anemom- (forced-convection cooling). The hot-
flat plate causes the shaft to rotate, aligning eter, one of the simplest instruments that can wire anemometer’s control circuitry
the plate with the direction of the local air be used to measure wind speed. This responds to this cooling (generally
flow. The weighted pointer serves as a anemometer consists of a simple pitot tube measured with solid-state sensors) by
damper to reduce the effects of small and a pressure-measurement system. It is increasing the heating current in the
variations in actual wind direction, as well as based on the principle that moving air wire. As air velocity increases, the
providing a visual indication of the direction molecules flowing into the pitot orifice exert heating current in the wire also
the instrument is pointing for alignment a dynamic pressure proportional to the increases by an amount proportional
purposes. A direct wind-direction readout (or velocity of the air molecules in the tube. to the velocity.
a potentiometer for remote readings) is To determine wind velocity, the pressure Air velocity can then be deter-
usually attached to the rotating shaft of the of the airstream is measured relative to the mined by measuring the difference in
wind vane. pressure of static air. This measurement is the magnitude of the control signal
For meteorological purposes, wind often made using a mechanical diaphragm (over zero airflow conditions) used to
direction is universally expressed in terms of (thin elastic partition) and indicator system. determine the heating current in the
compass heading degrees (O-360”). By the As air velocity increases, air molecules hot-wire. This magnitude is then
way, wind direction is always expressed in strike the diaphragm, exerting an increasing applied to a calibration curve that is
terms of the direction from which the wind is amount of pressure and causing it to expand. temperature compensated to account
coming, not the direction in which the wind The amount of displacement depends on the for the effects of ambient temperature
is going! The term unemometer is derived amount of pitot pressure and the prevailing changes.
from the Greek word arzemo, meaning wind, atmospheric (static) pressure. The hot-wire anemometer is one of
and refers to any instrument used to measure The diaphragm is linked via the most accurate means of measuring
wind velocity. levers and gears to a pointer system air velocity. It is also quite expensive,
54 MARCH 1999 HOME AUTOMATION Ip 9UILDlNG CONTROL
a) Hot Wire
Time Counter Rotating
Reed Switch h Magnet
FigIll? 2: A selection of popular laboratory and meteorological wind-speed
transducers includes: (a) pitot anemometer, (b) hot-wire anemometer, (c)
acoustic anemometer, and (d) rotational anemometer.
HOME AUTOMATION CATALOG !
X-10 COMPATIBLE THERMOSTAT
TM* 1. al* on* *“Nyon*‘~ bwn vm,mg for. ey “mlnp he on and a cullrn~“d~ from on* hum8 cod.
you Illlm 32 wmmsnds wansble glvlnp you cunpl.¶h rem& and automeL conbvl dpn HV~C.
ZCTS INCLUDES TW523 INTERFACE $199
$149.99 Includes 2 Beepers PRIVATE PAGE Extra Beepers $39.99
Local wireless paping system has a range of up to 2 miles
Great for restaurants, small businesses. camping or calling the kids for dinner
We are the first National Distributor of X-10 and Leviton and
WE WILL NOT BE UNDERSOLD ! Home Controls’ color catalog features truly affordable X-IO
Ask for our Dealer Catalog when you call powerline controls, IR products, CCD cameras, wireless home
MODULES $iO.38 MINI CONTROLLER5 $8.80 control devices, security products, drapery controls, audio
COMPUTER INTERFACE $41.88 TIMER $20.34 systems, and everything you can imagine for the remote and
BOOKS, LITERATURE AND SOFTWARE
r PR4CTICAL twos TO nOME AUTOMATIOK $10.99 -nOME AuTOuATlON NElwORK’ $100 automated control of your home!
-rELEPHONE WlRlNO SYSTEMS’ $2.50
How TO TROUBLESHOOT PREMISE WlRlNO SYSTEMS FASTER AND MORE EFFlClENrLr u.85
PECOR* HOME CONn?oL TEC”wxL MAN”*L s8.m 3D UNosCAPINO’(wINoows, 178.95
T(Er WIREO!’ PC BASED BOOK ON HOME WlRlNo s20.O!-30 DEC)C @vINoowS, $70.05
If you’re not buying from us,
you’re paying too much
Kx-T30810 PANASONIC HYBRID TELEPHONE SYSTEMS $586
KX-T9500 PANASONIC 9OOMHz CORDLESS TELEPHONE $199
Photo 1: These small, rugged wind converted to an analog voltage for
transducers are conveniently mounted measurement, or a microcontroller or
on a common o&t bracket for ease of computer can measure wind speed
HCS II INTERFACE
The HCS II wind speed and
direction interface is based on a
commercially manufactured anemom-
eter and wind-vane transducer
assembly like the one in Photo 1.
must be compensated to obtain These instruments were chosen
accurate results. primarily for their robust construction,
Occasionally, acoustic anemom- which promises many years of
eters use a rotating energy source maintenance-free operation. They also
and multiple sound receivers. The came the closest to satisfying my
wind-profile information that this design goals for availability, perfor-
instrument provides makes it well mance, and price.
suited to applications such as the As you can see in the photo, the
detection of violent wind shear near two instruments are paired on a
airports. bracket designed to be offset-mounted
to a vertical mast. The anemometer
ROTATIONAL and wind-vane transducer assembly is
ANEMOMETER supplied complete with mounting
The rotational anemometer hardware and 100’ of cable.
(Figure 2d) should be familiar to The wind-vane shaft is internally
you, as it is the most common type coupled to a 20-k potentiometer for
used for meteorological measurements. This measuring shaft position and wind
which limits its application to the laboratory anemometer consists of a windmill, direction, This potentiometer has a
environment. propeller, or as is most often the case, three complete 360” rotation with no
semiconical cups attached to a rotating rotational stops. The anemometer
ACOUSTIC ANEMOMETER horizontal shaft. shaft is internally coupled to a
The acoustic anemometer works by Moving air molecules striking this magnetic-reed switch. Each revolution
exploiting a very well-known principle: anemometer exert a force on the cups, of the anemometer produces one
moving air molecules affect the speed of an causing the shaft to rotate about its axis. As contact closure of the reed switch.
acoustic sound wave. This type of anemom- air velocity increases, the anemometer The HCS II Supervisory Controller
eter (Figure 2c) usually consists of a sound- shaft’s rotational velocity increases has a number of S-bit analog (ADC)
energy source (transmitter), and a sound- proportionately. The shaft is often directly inputs designed to be connected to
energy collector (receiver), separated by a coupled to an electric generator which analog-type measurement sensors.
precisely measured distance of several measures shaft rotational speed and, thus, Other analog inputs can be added
hundred feet. wind speed. if you use network modules. These
Sound energy is emitted from the In most generator-type rotating anemom- analog inputs are designed to be
transmitter and shortly thereafter is received eters, the magnitude of the generator’s AC interfaced to ground-referenced
at the collector. The time required for the voltage output increases with shaft fre- O-5-VDC analog signals. The HCS II,
sound signal to reach its destination is quency. A precision rectifier and filter can however, is not capable of measuring
proportional (among other things) to the be used to convert the AC voltage generated the frequency of a periodic input
velocity of air molecules moving in the by the rotating shaft into a more useful DC signal (digital) with the accuracy
space between the transmitter and receiver voltage. This DC voltage is then directly required for this interface.
elements. displayed on a voltmeter calibrated to wind Clearly, our design challenge is to
Due to its widely spaced construction, an speed. implement the circuitry required to
acoustic anemometer can capture a more More common today, however, is a interface the anemometer and wind-
general picture of wind activity than other mechanical or electronic switch output. In vane transducer outputs to the HCS II
anemometer types. Unfortunately, the speed these anemometers, there is at least one (and analog measurement inputs. In the
of sound is also affected by changes in air often more) switch closure(s) for each case of wind direction, it’s actually
density due to temperature and barometric- rotation of the anemometer shaft. quite easy.
pressure changes. Again, due to its construc- The freauencv at which switch To be compatible with an HCS II
tion, this type of anemometer is much more closures occur is proportional to the analog input, a signal is needed that
likely to be affected by these changes and wind speed. This frequency can be varies from 0 to 5 VDC and is
56 MARCH 1999 HOME AUTOMATION Ip 9IJI1DRdG CONTROL
proportional to wind direction. mounted the wind transducers to the spare-
Remember, the wind-vane shaft is tire carrier at the rear of my truck. Then, I
directly connected to the wiper of a drove the vehicle on a virtually windless
20-k potentiometer. Therefore, the morning at speeds spanning the input range
position of the pot wiper always of the anemometer while measuring the
indicates wind direction. switch-closure frequency.
It’s a simple matter to connect the Before attempting this experiment, I also
ends of the potentiometer to ground had my vehicle’s speedometer professionally
and to +5 VDC. The wiper voltage calibrated since my new tire diameter
then varies from 0 V (000”) to 5 V differed from the original tires. The
(360“) as the wind vane is rotated. recalibration resulted in a fixed indicated
The relationship between the wiper speed offset of about +3 MPH.
output voltage and wind direction can The results of my data collection are
be determined by: presented in Figure 3. The manufacturer
subsequently verified my findings-one
WindDirection= $ x 360” switch closure per second (or 1 Hz) equaled
2.33 MPH. Thus, over the wind-speed
This relationship assumes that the range of interest (O-l 15 MPH), the switch
potentiometer is completely linear. closure frequency varies from about 1 Hz
According to the manufacturer, the (-2.3 MPH) to 50 Hz (- 115 MPH).
linearity tolerance for the potentiom- There are many ways to convert a
eter is +.5% or less. variable frequency signal into a DC voltage.
The interface circuitry for measur- This type of circuit, often known as a
ing wind speed is somewhat more tachometer circuit (due to its common use
complicated. Remember that the with engine tachometers) is implemented
anemometer shaft is coupled to a most often using a single-chip FN converter
switch. This switch closes once for integrated circuit. The circuit consists of an
every revolution of the anemometer. input comparator, one-shot, and integrator.
The first step in the design of the Each time the input signal crosses the
wind-speed interface is to calibrate comparator threshold, it activates the one-
the anemometer to correlate wind shot, which switches a precise amount of
speed versus switch-closure fre- charge into the integrator input for a
quency. To accomplish this step, I measured time period. As the input signal
0-5-t-m j r-7 r-1777-+-i r i I ’
5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100
Wind Speed (MPH)
@UUV 3: A linear relationship exists between reed-switch closure frequency and wind
speed. All data was measured experimentally (see text for details).
HOME AUTOMATION 8L BUlLlUNG CONTROL MARCH 1996 57
4 To FIncmomcter
adlust so OUT lo SU
~81th 54 i n s t a l l e d
Wind Speed Output
-W,nd Olrcct~on Out~“t
0-su, 000-360 osc4rscr
?10U Regulator +5U Regulator
FigUl?? 4: The wind-speed and direction sensor outputs are converted to analog voltages (O-5 V) to be measured by the HCS II.
increases in frequency, the charge injected (carry-through frequency) goes up dramati- hand (Analog Devices AD650) just to
into the integration capacitor increases cally as frequencies decrease. see how bad the situation would be.
proportionally. The result is an average You can make allowances for reduced As I expected, the output-voltage
output voltage from the integrator propor- input-frequency operation by varying the ripple at the lowest expected input
tional to the input-signal frequency. amount of charge injected by the one-shot frequency was extremely high,
Unfortunately, a number of minimum into the integrator or by enlarging the approaching almost 1 Vp-p! Clearly, I
input-signal characteristics must be observed integration capacitor. However, these needed to measure wind speed
for a circuit of this type to operate correctly. changes can lead to unacceptable circuit- (switch-closure frequency) using an
For this application, the most important response time and circuit instability. entirely different technique, since the
specification is the input frequency range. From Figure 3, it’s clear that the frequencies being measured were
Most FN converters generally operate frequency range of the switch output, across extremely low.
best with frequency inputs greater than 10 the anemometer’s wind-speed range, is Obviously, this job was better
kHz. Although they continue to operate at substantially less than acceptable. Despite suited to a digital counter or micro-
much lower frequencies, the amount of the this problem, I decided to try a few experi- controller! I chose Microchip’s
input frequency that appears at the output ments with a FN converter that I had on PIC16C54 due to the circuit design’s
simplicity, low parts count, and
Module Interface Connectors In the approach I took, the wind-
Wind Instrument Interface Connector HCS II Interface Connector speed transducer is connected directly
(5-Pin DIN Female) (4-Pin Molex Female)
to an input bit of the PIC microcon-
Pin 1: +5 V Pin 1: +12 V troller. An &bit D/A converter
Pin 2: Wind Direction Pin 2: Gnd configured for an output range of O-5
Pin 3: Gnd Pin 3: Wind Direction
VDC is connected to eight of the
Pin 4: Wind Speed Pin 4: Wind Speed
Pin 5: N C PIG’s general-purpose I/O bits, which
are configured as outputs.
Table 1: The wind speed and direction interface module uses standard connectors To measure wind speed, the PIC
to make disconnecting the unit simple. simply counts the number of
58 MARCH 1999 HOME AUTOMATION 1p 9UlLlltNG CONTROL
LiStill 1: XPRESS code can be used to display the wind speed and direction on an LCD-
Link and in the HOST console window.
IF Reset THEN
Timer-(601 = ON
IF Timer(GO)>=l THEN
! Here I read analog input channels 5 and 6
! and convert to standard wind speed and direction units.
Ch5RawData = ADC(5)
Ch5Volts = (Ch5RawData * 50) / 256
WindSpeed = (Ch5Volts * 23) / 10
! Wind speed is 0 MPH at 0 V, 100 MPH at 5 V.
ChbRawData = ADC(6)
ChGVolts = (ChGRawData * 50) / 256
WindDirection = (ChGVolts * 72) / 10
IF WindDirection = 360 THEN
WindDirection = 0
! Wind direction is OOO" at 0 V, 360° at 5 V.
! Here I display wind speed and direction
! on the LCD-Link and in the V3.0 HOST message window.
LCD(O) = "Wind Spd: %PO MPH\n", WindSpeed
Console = "Wind Spd: %PO MPH\n", WindSpeed
LCD(O) = "Wind Dir: %PO deg.\n", WindDirection
Console = "Wind Dir: %PO deg.\n", WindDirection
Timer(60) = ON
anemometer switch closures during a
predetermined time period (fre- WindSpeed= $ x 115 MPH
quency). This count is then scaled to
obtain the &bit digital value which Using a microcontroller, you can measure
drives the DAC. The scale factor switch-closure frequency (and thus, wind
ensures that the digital output is equal speed) with greater resolution than 1 Hz. In
to -255 when the input frequency is my application, however, this level of
equal to 50 Hz (-115 MPH). precision was unwarranted.
The DAC’s output voltage is Besides, the nature of wind-speed mea-
always proportional to the wind speed surements is that they tend to fluctuate at
as measured by the anemometer. The random intervals. To compensate, many
software is programmed to measure wind-speed reporting devices average the
frequencies up to 50 Hz in 1 -Hz speed data recorded over many seconds.
increments. Thus, wind speeds up to Future versions of the software may include
115 MPH can be measured in a user-programmable averaging time period.
increments of 2.3 MPH. Therefore, at
a wind speed of 0 MPH, the output CIRCUIT DESCRIPTION
voltage of the circuit is 0 V, and it is The circuitry required to interface the
-5 V with a wind speed of - 115 wind speed and direction transducers is
MPH. shown in Figure 4a.
The relationship between the DAC As I mentioned earlier, the
output voltage and wind speed can be easiest method I’ve found for
found by: generating a O-5-V signal with the
HOME AUTOMATION Ip BUILDING CONTROL MARCH 1999 58
wind-vane transducer is to connect the ends
of the 20-kQ potentiometer in the sensor
directly to GND and +5 V. The potentio-
meter’s wiper voltage therefore varies
between 0 and 5 V as the wind vane moves
from 000” to 360”.
The wiper voltage is connected to op-
amp U2b, which is configured as a voltage
follower. This amplifier provides impedance
buffering for the potentiometer and a
constant source impedance for the HCS II
Capacitors C3 and C4 filter the potenti-
ometer voltage and reduce rapid voltage
fluctuations. Should the potentiometer
become disconnected, resistor R8 limits the
output current that the amplifier would PhOtO 2: The completed transducer interjke prototype is intended to be mounted indoors, protected
source into the overvoltage-protection diodes from the elements
of the ADC on the HCS II.
WIND SPEED INSTALLATION AND jumper 54 on the circuit board and
The anemometer switch input connects CALIBRATION adjust R7 so that pin 1 of the op-amp
directly to the microcontroller’s (Ul) RAO Installing and calibrating the HCS II U2 is 5.0 V. The wind-speed interface
I/O bit, which is configured in software as an wind speed and direction interface circuit circuit has no other adjustments.
input. The input is pulled up with R2, and (see Photo 2) is relatively straightforward. The manufacturer provides the
C 15 provides a measure of debounce The anemometer and wind vane should be calibration information (1 Hz = 2.3
protection (r = 0.0001 s). permanently mounted to a solid structure of MPH), and you can independently
The other end of the anemometer switch your house, as close to the roof as possible. verify it. This conversion constant is
is connected to ground. The microcontrol- In my installation, the sensors are hard coded into the microcontroller
ler’s RA 1 I/O bit, also configured as an attached to a 5’ steel mast, which is mounted firmware.
input, is connected to a configuration to the waste-vent pipe on the roof using a Being an eternal skeptic, however,
jumper. Connecting this jumper grounds the mounting bracket from a local electronic I borrowed a very expensive wind-
input and puts the microcontroller into parts distributor. It is also possible to find speed indicator during initial
calibration mode. brackets that can be bolted to the side of the installation of my wind-speed
The PIC crystal (Y 1) is a 4.00-MHz unit, house or attached to your chimney. interface to check the output of my
selected to provide a 1 -ps instruction- Remember, it’s generally a good idea to circuit. I was pleasantly surprised to
execution speed in software. This value was locate wind sensors as far above the roof and find that at any given wind velocity,
selected to help make precise time calcula- as far away from other structures (ridge the difference between the calibration
tions more convenient. lines, antennas, etc.) as possible. That way, standard and my circuit didn’t vary by
An 8-bit DAC is connected to eight of the you minimize wind blockage, turbulence, more than a few percent.
microcontroller’s general-purpose I/O bits and other effects of these obstructions.
(RBO_RB7), which are configured as Next, you need an accurate compass to XPRESS CODE
outputs. The DAC’s current output is align the wind vane. I found it helpful to turn The example code in Listing 1
converted to a voltage by op-amp U2a. The the wind vane to a known position such as details the XPRESS programming
converter and op-amp are configured so that south (180”) during the alignment procedure. language statements necessary to
the amplifier’s output is 0 V (0 MPH) when Then, temporarily fix the wind vane in the display the data collected using the
the DAC digital input is OOH, and is 5 V known position with a piece of tape. wind speed and direction interface.
(115 MPH) when the input is FFH. Now, using the compass, determine the Every 60 s, the XPRESS code reads
Potentiometer R7 adjusts the full-scale direction to the preset heading and rotate the the wind speed and direction by
(5-V) output of the DAC circuit. Voltage complete sensor assembly until the wind- measuring the voltages connected to
regulator U5 (LM78L05) provides the circuit vane pointer is facing the proper direction. the HCS II channels 5 and 6 analog
with a regulated source of +5 V while U3 Tighten the mounting hardware to ensure inputs.
(MAX680) is a charge-pump voltage that the wind transducers won’t move after These voltages are then converted
converter used to supply +I 0 V to the DAC alignment. to standard wind speed and direction
and op-amp, as shown in Figure 4b. For the wind-speed interface circuitry, units. The way this process is
The recommended connector pinout the only calibration needed is to accomplished is somewhat unique.
information for the wind speed and direction adjust the DAC full-scale output. Because the XPRESS language
interface module is depicted in Table 1. To make this adjustment, connect doesn’t support floating-point
60 MARCH 1999 HOME AUTOMATION & 9lRlDlNG CONTROL
mathematical operations, all calculations are John Morley is the senior electrical
made using “scaled” integers. engineer on the staff of a small Boston
lundreds of hard-to-find By carefully controlling the placement of area manufacturer of custom
utomatlon, X10, and wireless the displayed decimal point, the proper wind electronic test equipment. His primary
ontrol products. Computer
ontrol of your home, security
speed and direction values are represented responsibility is the design of
ystems, swelllance cameras, and displayed correctly at the LCD-Link or instrumentation used to measure the
ifra-red audio/video control, console message window. By dealing with thermal properties of packaged
IVAC, pet care automatlon,
firing supplies, and much mor el scaled integers, we retain the most-signifi- semiconductor devices, and the
cant portion of our data otherwise lost to reliability of electrical interconnects.
Call 24hrs for FREE round-off after performing integer math John may be contacted at endeavor@
64 page color Catalog
In this example, the raw ADC counts
(O-255) of channels 5 and 6 are first
converted to volts. The apparent range of SOURCES
computed voltages is O-50 V, as a result of
scaling. Computed voltages are then ADC0808 A/D converter, D/A
converted to standard wind speed and converter, operational
direction units. amplifier
For wind speed, we simply multiply the National Semiconductor Corp.
computed input voltage range by 2. This 2900 Semiconductor Dr.
calculation gives a wind-speed range of 0 P.O. Box 58090
(lower limit) at O-V input to 100 (upper Santa Clara, CA 95052
limit) at 5-V input. (817) 468-6300
For wind direction, multiply the com- Fax: (8 17) 468-6935
puted input-range voltage by 72 and divide
by 10. This calculation gives a wind Anemometer and wind-vane
direction range of 0 (lower limit) at O-V sending unit
input to 360 (upper limit) at 5-V input. In Amateur Electronic Supply
meteorological terms, wind direction is most 5710 W. Good Hope Rd.
often represented as ranging from 000” to Milwaukee, WI 53223
Micro Processor Controlled (414) 358-0333
359” (000’ = 360”). So, when the computed
Built-in Speaker and Aux Output Fax: (414) 358-3337
wind direction is 360”, reset the value to
EEPROM Message Storage
Built-in Mic and Auto Gain 000”. Charge-pump voltage
Natural Voice Reproduction converter and MAX680
Record your own announcements TAIL WIND Maxim Integrated Products
to be played with key X-IO events As with almost all data collection, 120 San Gabriel Dr.
interpreting results can be harder than Sunnyvale, CA 94086
collecting them. Weather data in particular is (408) 737-7600
often just like that. In fact, it’s been said Fax: (408) 737-7 194
many times that weather forecasting is the
only profession that allows you to be wrong HCS II
more than 50% of the time and still keep Circuit Cellar, Inc.
your job! 4 Park St.
Weather forecasting seems to be much Vernon, CT 06066
more an art than a science. You’ll find, (860) 875-275 1
however, that the more data you collect and Fax: (860) 872-2204
the more observations you make, the better PIC16C54 microcontroller
your ability to recognize recurrent weather Microchip Technology, Inc.
patterns. 2355 W. Chandler Blvd.
Weather “signatures” begin to emerge as Chandler, AZ 85224-6199
you identify the characteristic conditions for (602) 786-7200
the weather you currently have or will have Fax: (602) 899-9210
in the future. This is not to say that you
won’t occasionally be deluged during the
summer barbecue you promised would be I R S
beautiful. My suggestion-play it safe. Keep
416 Very Useful
an umbrella handy while you’re still wrong
417 Moderately Useful
5 1% of the time!
416 Not Useful
62 MARCH 1999 HOME AUTOMATION Ip 9UlLDlNG CONTROL