Sonic Anemometer

by Itrium in Circuits > Sensors

23151 Views, 74 Favorites, 0 Comments

Sonic Anemometer

cover.jpg

Most of the sensors in a weather station now use miniature electronic components to measure the environment. Light, pressure, temperature and humidity can all be quantified with sensors costing a few cents. The one last remaining element is wind speed and direction. Over the last few centuries, the rotating cup anemometer has reigned supreme. Three or four cups spin in the breeze to give an indication of air speed, granted there have been improvements in detecting the spin speed but the basic principal remains the same.

Wind speed may also be measured by detecting the change in the speed of sound caused by the air flow. The earliest attempt I found of applying this method comes from this article in Electronics, 1950. There are now appearing on the market, at a cost of hundreds or thousands of dollars, ultrasonic anemometers that measure wind using similar principles. The challenge of this Instructable was to make a sonic anemometer using hobbyist components costing only a few dollars.

There have been many questions relating to the operation of this anemometer. As such, the expired patent which describes the theory is listed below.

Supplies

The main components needed to make the ultrasonic anemometer are:

4 transducers removed from HC-SR04 ultrasonic range finders

3 CD4046B phase lock loop ICs

1 Piece of strip board

Various resistors and capacitors, see circuit diagram

1 2N2222 transistor or similar

1 Arduino Uno or similar

Arduino IDE for flashing and monitoring wind

Wood to make anemometer body

Sundries like wire, solder, screws, wood etc.<

Wind Speeds

880px-Beaufort_wind_scale.png
Understanding the expected range of wind speeds is a good place to start. The Beaufort scale in the picture tells us that average wind speeds can reach over 30 m/s although short term gusts can be higher. As the velocity of sound is 343 m/s, we can expect changes of about 10% in speed due to high winds.

Proposed Design

wind.png
The design for this anemometer is based on 3 ultrasonic receivers symmetrically arranged around a transmitter transducer. Sound waves from the 40 kHz transmitter radiate outwards to the 3 receivers 25 mm away. Under still air conditions, the sound waves will reach all the receivers at the same time.
The speed of sound increases at higher temperatures which makes the sound waves spread out faster and so there will be fewer waves between the transducers. As this design relies on a fixed number of waves between the transducers, the north receiver is phase locked to the sender. Any change in temperature will alter the sender frequency to keep the wavelength the same.

How Does It Work

north.png
west.png
In calm conditions with no draughts, all three receivers will be experiencing the same part of the sound wave front from the central transmitter. The pictures show what will happen with a north or west wind. A north wind will compress the sound waves on the north side of the sender and spread them out on the south side. However, the phase lock loop will keep the phase constant on the north receiver. Thus only the two southerly sensors will show a phase change related to the wind strength.
A similar situation happens for a westerly wind. The sound waves are compressed on the west side of the transmitter and expand out to the east. With a phase locked north sensor, we can estimate the wind speed from the difference between the east and west sensor phase.
By measuring the change in wavelength or phase at the E and W sensors, we can work out the north and west components of wind velocity. With a little arithmetic, we can then calculate the wind speed and heading.

Construction

blanks.png
The body of the anemometer is made from two pieces of wood held apart with 3 mm bolts. A piece of 18 mm thick fibre board was used for the main body of the anemometer with 16 mm holes drilled for the sensors. The reflector plate was a piece of 4 mm plywood and fixed above the sensors with 3 mm nuts and bolts. Nothing rocket science, other materials could be used instead provided they are rigid and don’t bend in the wind. A hexagonal shape was used for the body because it is easier to cut than a circle! In fact, a circular design with rounded edges would present a much better aerodynamic profile to the wind... beyond my skill set.
A conical lid was added to protect the electronics from the weather and dissuade birds from using it as a perch.

Transducers

assembly.png
As these sensors are run continuously, there is no need for any special dynamic performance. In fact, the sensors used in this project were unsoldered from the cheap and cheerful HC-SR04 range finder widely available. The 4 transducers are push fitted into the holes and connecting leads soldered on to the terminals. As the exact position may need a slight adjustment to tune the system, ream the holes with sand paper to give a firm but not tight fit. There needs to be about 10 mm separation between the two plates.

Circuit Diagram

cct.png

Three phase lock loop 4046 ICs are used to set the sender frequency to 40 kHz and measure the received signal from the sensors. One 4046 is used in the phase lock loop and the other two ICs measure the phase from the remaining two receivers. The phase detectors output a string of pulses where the mark space ratio is proportional to the phase shift. These pulses are averaged by the RC filter and the voltage measured by a microcontroller to find the wind speed and direction. The circuit must be powered from a stable regulated power supply because the phase detector output is power supply sensitive.

Downloads

Circuit Board

cct.png
The electronics are built on a piece of strip board and mounted above the sensors. In this anemometer, the filtered output from the phase detectors was wired to a separate Arduino which measured the output and calculated the wind speed and direction.

Setup

copy waveform.png
The setup requires a basic oscilloscope to tune up the anemometer. Temporarily wire two 10k resistors in series across the voltage supply and connect pin 9 of the phase lock loop IC to this half voltage point. Adjust the variable resistor to make the output on pin 4 run at 40 kHz.
Now we need to measure the signal on the receiver transducers and fine tune the frequency for maximum output corresponding to the resonance frequency of the sensors. The reflector plate spacing can also be adjusted for the highest signal, about 10 mm is a good starting point.
Once there is a good signal from all three sensors, the phase lock loop can be reinstated. Check the output from the phase detectors to see if the mark space ratio is symmetrical, if not, the system can be adjusted by altering the reflector spacing or the sensor depth in the fibre board.
As a final operational test, blow some air into the anemometer with a cold hair dryer and make sure the two phase detectors give a change in output voltage.

Calibration

cal.png
So far, we have made an instrument that gives two voltages according to the wind strength and direction. The next step is to convert these readings into meaningful measurements of wind speed. As most of us do not have access to a calibrated wind tunnel, we can use the local weather forecast to provide a reference for the actual wind speeds. Another alternative is to get a reference wind speed from a traditional rotating cup anemometer. Select a windy day to take the calibration readings in an unsheltered position.
We need 3 sets of readings. The first measurements are the E and W sensor voltages in still air. Next we take the anemometer outside with the N sensor pointing into the wind and take another set of readings. Finally, we turn the anemometer anti-clockwise 90 degrees and take calibration measurements for the east direction.
To a first approximation, we can treat the design as orthogonal where the north wind component is proportional to the difference between the still air and sensor voltages in the wind. The east wind component is proportional to the difference between the two sensor voltages. Scaling factors and voltage offsets can now be calculated from the calibration points.
The final wind speed can be worked out using Pythagorus on the N and E vectors. Wind direction can be estimated using the atan2 function.
These rather tedious voltage measurements and calculations can easily be handled by a small microcontroller such as an Arduino.

Arduino Monitor

nano.png

Measuring the two output voltages and converting them into wind speed and direction is a convenient job for a microcontroller such as the Arduino. The internal ADC in the Arduino can be used to read the anemometer output although a separate module like the ADS1115 would make a more accurate job of the conversion.
The next step is to remove offset voltages and scale the readings using the calibration points to give the N and W components of wind speed. Finally, the readings are combined using Pythagorus for the wind speed and the arctan2 function for direction. The sketch listed below will use the calibration readings and calculate wind speed and direction from the anemometer output voltages.
When running the sketch, the serial monitor will display the raw ADC output as well as the calculated wind speed and bearing. These raw readings are useful when taking the calibration points.
Finally, the anemometer needs siting in the wind with the N sensor pointing north.

Downloads

Conclusions

back.jpg
This ultrasonic anemometer may be constructed for a few dollars using components and materials easily available to the hobbyist. After comparing this design with other DIY ultrasonic anemometers described on the internet, I believe this version represents about the simplest way to sonically measure wind speed and heading. For those interested in this rather specialised subject, there is plenty of scope to optimise and improve the design. For example, weatherproof sensors could be used with extra electronics to make up for their reduced sensitivity. Another idea is to include a heater to prevent freezing in the winter.
I hope you enjoyed looking at this Instructable and may even feel inspired to make your own sonic anemometer 😊