Low velocity wind sensing, and recording of the direction, how to do? - Page 1
Forum section: electronics / projects

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 01:16:39 am
content: I already have sensors working for air temperature, pressure and humidity and now I want to figure out a way to tell what direction the wind is blowing and how strong it is.I was thinking that this could be done with an optical encoder disk and a wind vane..Although it would be nice to have an exact angle its not that important to have super high resolution...and an cup style anemometer for velocity.. just counting the number of RPMs.

author: Ian.M
author_rank: Super Contributor
timestamp: September 28, 2017, 01:43:40 am
content: Optical encoders can be an absolute PITA for wind vanes or wind cups due to dust buildup. You cant have effective shaft seals due to the friction they will cause.For most of their wind vanes Autohelm/Raymarine used perpendicular hall sensors and a magnet on the shaft to get sine and cosine outputs that were sampled and put through afour quadrant arctangent functionto get the direction. Resolution was 1 degree. If you go down this road it does mean the mount and nearby housing must be non-magnetic. Its possible to add damping with a fixed copper tube concentric with the shaft, that just clears the ends of the magnet. The hall sensors need to be far enough away from the magnet to get a smoothly varying field as the shaft turns.Consider using an off-the-shelf wind vane + cups assembly from either a home weather station or marine wind instrument. Its not a *cheap* option, but they've dealt with all the tricky design, construction and weatherproofinf issues for you.

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 02:30:43 am
content: I was wondering about this... Your advice to use a commercial weather station head is likely good advice...It may be trickly getting the wind direction at night when the air is relatively still..which is when I want to find out which way the wind is blowing in my location because the very low velocity wind is actually the wind direction I want to capture..Sometimes there are some really nasty smells that come up at odd hours where I live that i want to document..I know who it is..It tends to be at its worst when the wind is almost stagnant..Ive also heard about sensors with no moving parts that use ultrasonic sound- that seems like the kind of sensor a MCU would make possible now assuming that sound velocity increases in the direction wind is blowing?--- wow it appears there are several peoples projects to build this online..for examplehttps://github.com/soldernerd/UltrasonicAnemometer.githttps://github.com/soldernerd/UltrasonicAnemometerHardware.gitQuote from: Ian.M on September 28, 2017, 01:43:40 am

author: CatalinaWOW
author_rank: Super Contributor
timestamp: September 28, 2017, 03:05:39 am
content: I am about to convert the sensor head for a low cost weather station in this manner. Accurite and the conversion comes because the RF link and connection to internet both are terrible, but the sensor head seems to work well. The system is usually available for under well under $100. Wind speed is a cup anemometer with a magnetic reed switch sensing the magnet passing. Minimum speed to turn the cups is a fraction of a mile per hour. Direction is a vane with their own crude optical sensor. It works because a.) the weather seals actually work pretty well. b) The scale of the slots for optical coding are broad - between 1 and 2 mm. Takes a lot of dust to kill. c.) They don't attempt insane resolution. It's been a while since I took it apart to evaluate but by memory it was either four or five bit resolution.I don't know if those kind of specs will meet your needs. The high cost ones probably don't go much lower in speed, but will do better in directional resolution.I suspect the ultrasound wind sensors will have trouble getting very low speed. You can run through the Doppler numbers but it means measuring fraction degree phase changes for most reasonable configurations. Commercial units will have solved those problems, but won't be cheap.Another option that would be robust would be to set up perpendicular fan anemometers. Their response to off axis winds won't follow a perfect cosine dropoff so some calibration would be necessary, but that is what the microprocessor is for.

author: f5r5e5d
author_rank: Frequent Contributor
timestamp: September 28, 2017, 03:16:45 am
content: https://hackaday.com/2013/08/21/ultrasonic-anemometer-for-an-absurdly-accurate-weather-station/

author: MasterT
author_rank: Frequent Contributor
timestamp: September 28, 2017, 03:18:19 am
content: Wiki has an article.https://en.wikipedia.org/wiki/AnemometerMy vote for hot wire, no moving parts. 4 or 5 thermistors will cost less than 1$, uCPU with simple math algorithm could , probably, get accuracy down to degree or so. You will need uCPU in your design anyway, to count rotation, encoder or whatever.

author: DTJ
author_rank: Super Contributor
timestamp: September 28, 2017, 03:27:52 am
content: Commercial units like those made by RM Young use a 360° potentiometer for wind direction.Weatherproofing is nothing fancier than having the top moving vane part form a shroud down over the mount where the pot is located.They last for years without issues.

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 11:57:58 am
content: It's very windy this morning (gusty) so I opened my web browser to see why.. This is happening a lot this year..Oh my, as they say..

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 12:10:38 pm
content: Quote from: MasterT on September 28, 2017, 03:18:19 amThat Wikipedia piece is a very good article..I should mention that if I am going to mount something on my house, its important to me to have it not make any additional noise. Ball bearings are probably enough to make something quiet but my preference would be to install an electronic device that didn't spin, if possible (If I can build one or find an affordable one)Away from the house it doesn't matter but the problem is trees would likely make the readings semi meaningless there. Too many trees, not enough clear space..

author: texaspyro
author_rank: Super Contributor
timestamp: September 28, 2017, 02:49:38 pm
content: I built a weather station for my rocket launch control system. I used 4 SR-04 ultrasonic range finders to implement a sonic anemometer. It measures the time of flight of the sound pulses N-S S-N E-W and W-E directions. The differences between the N-S and S-N (and E-W / W-E) measurements are due to the wind speed in those directions (once sensor offsets are subtracted out). A little math and trig and you have the wind speed and direction. You also get the true air temperature (which is not affected by solar heating of the instrument) from the speed of sound.The station has a 10 DoF IMU in it that gives orientation and also barometric pressure. Also has a humidity sensor and GPS.The station is not weather-proof since bad weather means no launch. You can get weather sealed ultrasonic transducers.Here's a sonic anemometer on Hackaday:https://hackaday.com/2013/08/21/ultrasonic-anemometer-for-an-absurdly-accurate-weather-station/

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 03:13:45 pm
content: This sensor seems to be what is returned when I look for waterproof ultrasonic sensor.I guess my main concern is durability. They seem quite reasonably priced.. (around $7 each)JSN-SR04T ? "Ultrasonic Module Distance Measuring Transducer Sensor Waterproof"Electrical parameters: JSN-SR04TOperating voltage: DC 5VQuiescent current: 5mATotal current work: 30mAAcoustic emission frequency: 40khzFarthest distance: 4.5mBlind: 25cmWiring: + 5V (positive power supply)Trig (control side) RXEcho (the receiver) TXGND (negative)Module size: 41mm * 28.5mmResolution: about 0.5cmAngle: less than 50 degreesWorking temperature: -10 ~ 70 ?Storage temperature: -20 ~ 80 ?Product Features:1, small size, easy to use;2, low voltage, low power consumption;3, high accuracy;4, strong anti-jamming;5, integrated with wire enclosed waterproof probe, suitable for wet, harsh measurement occasions.Application:1, Horizontal distance;2, obstacle avoidance, automatic control;3, the object approaches, there is a perceived4, traffic control;5, security, industrial control;6, artificial intelligence, and researchThe basic working principle:(1) using IO port TRIG trigger location, to the high level signal of at least 10us;(2) module automatically sends 8 40KHz Fang Bo, automatic detecting whether a signal return;(3) a signal return, a high level is output through the IO port ECHO, the time duration of the high level isultrasonic from launch to return. The test distance = (high level time * speed of sound (340M/S)) /2;This module uses the simple method, a control port with a 10US above high level, can wait for high leveloutput at the receiving port. An output can drive the timer, when this port is low can read the timer value,this time for the location of the time, can be calculated distance. So constantly cycle test, that can achievethe measurement of the value of your mobile.Package Included:1 x Ultrasonic Module Distance Measuring Transducer Sensor WaterproofQuote from: texaspyro on September 28, 2017, 02:49:38 pm

author: tszaboo
author_rank: Super Contributor
timestamp: September 28, 2017, 03:14:55 pm
content: Building one is not really difficult. You just place the transducers, and write some simple commands on a micro. What is difficult is to make the system reliable, and to calibrate it. Because when you are trying to measure time of flight, suddenly things start to matter. Like humidity, and temperature effects speed of sound, the structure will carry the sound and provide false readings, tolerances will matter. 1mm difference in distance is 3uS time difference. Its not easy to say the least. And I was measuring lateral air movement only.

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 03:18:59 pm
content: And all elastomeric components like rubbers, age. So if the rubbers you are using to deaden sound interference harden then suddenly the sound from the other transducers gets conducted, I would guess.The math is likely to change substantially over time!Quote from: NANDBlog on September 28, 2017, 03:14:55 pm

author: Mechatrommer
author_rank: Super Contributor
timestamp: September 28, 2017, 03:42:23 pm
content: Quote from: Ian.M on September 28, 2017, 01:43:40 amthisAS5047DMagnetic Rotary Position Sensor IC is made for motor control but can also be used to get absolute angle of the magnet (thats going to be placed on the vane's shaft) through SPI or PWM signal, no need deep math, but its not cheap... ymmv...

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 05:50:45 pm
content: I wonder if there is a sweet spot in the commercial offerings that is both cheap and can accurately measure low wind velocities?I have temperature, humidity and air pressure.. what I want to add is wind direction and velocity..Although I may in the future (for completeness) I currently don't care about rainfall. I would like to be able to record a "yes or no" indication of precipitation, though but that seems likely to be fairly easy.Another way i thought that might work is suspending a very light ball from a string and maybe tracking its deflection optically?

author: Kalvin
author_rank: Super Contributor
timestamp: September 28, 2017, 06:23:54 pm
content: Would a accelerometer work sufficiently well as a wind direction and speed indicator by measuring the tilt of the accelerometer sensor when the device is placed at the tip of a flexing pole/stick?

author: Kleinstein
author_rank: Super Contributor
timestamp: September 28, 2017, 07:21:52 pm
content: In principle the tilt of a thin stick / pole might be possible. However there likely would be quite some oscillation superimposed. The oscillation is more like changing tilt, but also quite some additional acceleration. Also rain and thermal effects from sun light might cause errors. So I doubt this would be a really practical solution with the sensor flapping in the breeze.The ball on a string idea might fail at higher wind speeds due to instability and oscillations. So I would consider this more like an addition to the classical vane and cup anemometer.

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 07:33:59 pm
content: Thats a good question..Tilt isnt the same as acceleration.Deflection of a joystick like device might be a good way of measuring wind.

author: mikeselectricstuff
author_rank: Super Contributor
timestamp: September 28, 2017, 08:00:57 pm
content: You can do it with ultrasonics - two pairs of transducers at right angles. measure the time-of-flight in each direction on each pair, do some maths. No moving parts.http://gillinstruments.com/products/anemometer/windsonic.htm

author: CatalinaWOW
author_rank: Super Contributor
timestamp: September 28, 2017, 08:28:47 pm
content: Quote from: cdev on September 28, 2017, 03:13:45 pmThis is definitely not what you want. It measures time of flight of a reflected pulse of sound. In a wind field the outbound pulse time of travel is reduced, but the return time of travel is increased by exactly the same amount so no information about wind is provided.The ultrasonic wind sensors have a sender at one location and the receiver at a second location.

author: texaspyro
author_rank: Super Contributor
timestamp: September 28, 2017, 09:46:21 pm
content: Quote from: CatalinaWOW on September 28, 2017, 08:28:47 pmThey are definitely what you want. For this application you don't use them to measure the device's reflected signal. You use them to measure the transmitted signal from the opposite device. One devices's sender is the opposite device's receiver. It works quite well doing that.

author: cdev
author_rank: Super Contributor
timestamp: September 28, 2017, 10:11:29 pm
content: Quote from: texaspyro on September 28, 2017, 09:46:21 pmI think I am going to try to build this. What is the lightest amount of wind you can measure? I am curious because I would also like to (just to see what the air is doing) like to see if I can measure wind velocity indoors.. can you measure fairly minute winds? I used to use .5 mil plastic sheeting to measure indoor air currents for weatherproofing, and that works well, the .5 mil painters dropcloth is like a dry cleaning bag, its exceedingly light. It almost floats on air. It would be extremely cool to be able to measure smoke-like currents indoors and record it.I am thinking a lot of interesting data could be collected with a wind velocity sensor

author: texaspyro
author_rank: Super Contributor
timestamp: September 28, 2017, 10:39:06 pm
content: Quote from: cdev on September 28, 2017, 10:11:29 pmThe SR04 devices are rather crude and noisy and a bit drifty. Probably around 2-3 mph.Attached is some code... don't expect it to compile. There are a bunch of include files that may or may not be used. Search github for "megadonkey" and you might find them.

author: David Hess
author_rank: Super Contributor
timestamp: September 29, 2017, 02:43:51 am
content: Heathkit had a design where the transducers for wind speed and direction were reed relays with one relay and a spinning magnet for speed and a circular array of relays, 8 I think, and a magnet for direction. Mine lasted for decades until the polarizer for the LCD screen was eaten by a fungus.

author: Janne
author_rank: Contributor
timestamp: September 29, 2017, 07:40:02 am
content: Quote from: NANDBlog on September 28, 2017, 03:14:55 pmMaybe one could use a transducer measuring a known distance to get the current speed of sound? If you use a transducer, it won't matter if there is wind blowing through the gap.. Should work at least in principle

author: tszaboo
author_rank: Super Contributor
timestamp: September 29, 2017, 09:50:11 am
content: Quote from: Janne on September 29, 2017, 07:40:02 amThere are a lot of ways to compensate for the variables. You can use a pair of transducers in opposite directions, measure the variables and use LUTs, make assumptions, use clever orientation of transducers and do some math. I'm just saying, it is not trivial. And I'm saying that, after working on an ultrasonic spirometer (lung capacity meter) for a year.There is a lot more engineering involved, than first sight. You want to be able to detect 1m/s wind, on a 340m/s carrier. If there is a sensor, with the transducers 10 cm from each other, the change is only 0.8 uS. Now, the linked anemometers will detect 0.01m/s winds. You would need a 120MHz clock signal to capture this small change. Suddenly things, like interrupt latency are important, or propagation delays and variations in the analog parts. Also, 1K temperature change effects the sensors like about 1m/s wind change.

author: mikeselectricstuff
author_rank: Super Contributor
timestamp: September 29, 2017, 11:01:03 am
content: Quote from: NANDBlog on September 29, 2017, 09:50:11 amAssuming you did it digitally. For this sort of appication, analogue methods can offer better precision without needing higgh clock rates, e.g. gating the charge to a capacitor and measuring the voltage difference.

author: max_torque
author_rank: Super Contributor
timestamp: September 29, 2017, 01:38:29 pm
content: A "fun" solution would be a vehicle MAF (Mass Air Flow) meter in a tube, that a stepper motor revolves. As you don't care (i assume) about a high update rate, the system would just scan the tube around, find the the bearing at which it has the highest output (when the tube is parallel to the wind direction). From that, you get speed and direction, and it would look pretty cool!(you could also use some profiling of the tube CSA to get the necessary low velocity resolution (or have two tubes, one for low range, one for high range)A few $$ of parts from a vehicle breakers would see that system built!

author: texaspyro
author_rank: Super Contributor
timestamp: September 29, 2017, 03:57:30 pm
content: Quote from: Janne on September 29, 2017, 07:40:02 amMy code has a calibration routine in it. You don't need to know the distance between the transducers (mine is around 24 inches... large distance gives better accuracy and reduces L/D shading effects).The calibration measures the difference in the N-S S-N times and E-W W-E times to remove SR04 and mechanical offsets and uses the temperature/humidity from a DHT temp/humidity sensor and the air pressure from the barometer in the 10 DoF IMU and calculates the expected speed of sound. By comparing the expected / measured speed of sound it calculates the effective distance between the sensors. When in operation, it calculates air temperature from the measured speed of sound.It is calibrated indoors with 0 wind speed.Here's a nice writeup on a sonic anemometer:http://www.dl1glh.de/ultrasonic-anemometer.html