Campbell Scientific CSAT3 CSAT3 3-D Sonic Anemometer - Page 35

Average 1,panel_temp,IEEE4,FALSE

Page 35 highlights

CSAT3 Three Dimensional Sonic Anemometer Totalize (1,n,IEEE4,NOT (del_T_f) OR NOT (disable_flag_on(2))) FieldNames ("del_T_f_Tot") Totalize (1,n,IEEE4,NOT (sig_lck_f) OR NOT (disable_flag_on(2))) FieldNames ("sig_lck_f_Tot") Totalize (1,n,IEEE4,NOT (amp_h_f) OR NOT (disable_flag_on(2))) FieldNames ("amp_h_f_Tot") Totalize (1,n,IEEE4,NOT (amp_l_f) OR NOT (disable_flag_on(2))) FieldNames ("amp_l_f_Tot") Average (1,panel_temp,IEEE4,FALSE) Average (1,batt_volt,IEEE4,FALSE) EndTable '*** Working Data Tables *** 'Compute the wind direction This data is output every OUTPUT_INTERVAL minutes. DataTable (wnd_vec,TRUE,1) DataInterval (0,OUTPUT_INTERVAL,Min,1) 'Compute wind direction from CSAT3 data. WindVector (1,wind_east,wind_north,IEEE4,disable_flag_on(1),0,1,2) WindVector (1,Uy,Ux,IEEE4,disable_flag_on(1),0,1,2) EndTable '*** Program *** BeginProg n = 1 'Set all CSAT3 variables to NaN. Move (Ux,5,NaN,1) 'Set the SDM clock speed. SDMSpeed (SDM_PER) Scan (SCAN_INTERVAL,mSec,3,0) 'CRBasic datalogger panel temperature. PanelTemp (panel_temp,250) 'Get CSAT3 wind and sonic temperature data. CSAT3 (Ux,1,3,91,CSAT_OPT) 'Measure battery voltage. Battery (batt_volt) 'Copy and convert CSAT3 for compass wind vector computation. wind_east = -1*Uy wind_north = Ux 'Define 61502 as NaN. If ( diag_csat = NaN ) Then ( diag_csat = 61502 ) 27

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72

CSAT3 Three Dimensional Sonic Anemometer
Totalize (1,n,IEEE4,NOT (del_T_f) OR NOT (disable_flag_on(2)))
FieldNames ("del_T_f_Tot")
Totalize (1,n,IEEE4,NOT (sig_lck_f) OR NOT (disable_flag_on(2)))
FieldNames ("sig_lck_f_Tot")
Totalize (1,n,IEEE4,NOT (amp_h_f) OR NOT (disable_flag_on(2)))
FieldNames ("amp_h_f_Tot")
Totalize (1,n,IEEE4,NOT (amp_l_f) OR NOT (disable_flag_on(2)))
FieldNames ("amp_l_f_Tot")
Average (1,panel_temp,IEEE4,FALSE)
Average (1,batt_volt,IEEE4,FALSE)
EndTable
'*** Working Data Tables ***
'Compute the wind direction
This data is output every OUTPUT_INTERVAL minutes.
DataTable (wnd_vec,TRUE,1)
DataInterval (0,OUTPUT_INTERVAL,Min,1)
'Compute wind direction from CSAT3 data.
WindVector (1,wind_east,wind_north,IEEE4,disable_flag_on(1),0,1,2)
WindVector (1,Uy,Ux,IEEE4,disable_flag_on(1),0,1,2)
EndTable
'*** Program ***
BeginProg
n = 1
'Set all CSAT3 variables to NaN.
Move (Ux,5,NaN,1)
'Set the SDM clock speed.
SDMSpeed (SDM_PER)
Scan (SCAN_INTERVAL,mSec,3,0)
'CRBasic datalogger panel temperature.
PanelTemp (panel_temp,250)
'Get CSAT3 wind and sonic temperature data.
CSAT3 (Ux,1,3,91,CSAT_OPT)
'Measure battery voltage.
Battery (batt_volt)
'Copy and convert CSAT3 for compass wind vector computation.
wind_east = -1*Uy
wind_north = Ux
'Define 61502 as NaN.
If ( diag_csat = NaN ) Then ( diag_csat = 61502 )
27