]> oss.titaniummirror.com Git - tinyos-2.x.git/commitdiff
Add AeroVane infrastructure to support physical/reading of the sensor.
authorsmckown <smckown@4bc1554a-c7f2-4f65-a403-e0be01f0239c>
Sat, 7 Nov 2009 23:58:55 +0000 (23:58 +0000)
committerR. Steve McKown <rsmckown@gmail.com>
Tue, 1 Dec 2009 03:01:48 +0000 (20:01 -0700)
AeroVaneReadC implements a timer every 28800 ticks of the 32KHz clock (or 900
binary ms).  At each timer event it reads the wind vane via WindVaneReadC.
On every 4th read it reads the anemometer via AnemometerReadC, calculates the
average vane position over the last 4 reads (it's been summing all along),
and uses Notify.notify() to send out the aerovector structure.  This means
that the user should get an AeroVane vector (reading) every 3.516 seconds, where
both the direction and the speed have been averaged over 4 reads during that
period.


No differences found