Appendix B. Example Programs
B-4
Public
BattV :
Units
BattV = Volts
'CR6 battery voltage
Public
PnlTmp_C :
Units
PnlTmp_C = °C
'CR6 panel temperature
Public
AirTempC :
Units
AirTempC = °C
'Air temperature
'Array to hold 11 SR50A measurements composed of a distance and
'quality number.
Public
SR50A(11,2)
Public
SR50A_Raw(2)
Alias
SR50A_Raw(1) = DT :
Units
DT = meters
'Distance from the SR50A.
Alias
SR50A_Raw(2) = RawQ :
Units
RawQ = unitless
'Quality number.
'Sorted array of 11 SR50A measurements composed of a distance and
'quality number. Measurements are sorted by the distance value from
'smallest to largest.
Public
Result_SR50A(11,2)
Public
TCDT :
Units
TCDT = meters
'Temperature corrected distance
Public
Q :
Units
Q = unitless
'Quality number
Public
Inital_Dist :
Units
Inital_Dist = meters
'Distance to ground.
Public
Snow_Depth :
Units
Snow_Depth = meters
'Snow depth.
'Controls SR50A measurement. This flag can be manually controlled to
'run tests in the field or is automatically set 2 minutes before the
'hourly data storage interval. This is done so 11 measurements can
'be made and sorted before the values are stored.
Public
SR50ACtrl
As Boolean
'Set this flag to measure and store the initial distance from the
'SR50A to the ground.
Public
SR50A_MID As Boolean
Dim
n
'used as a counter
'Define Data Tables
DataTable
(Daily,True,-1)
DataInterval(0,1440,Min,10)
Minimum
(1,BattV,FP2,False,False)
Maximum
(1,BattV,FP2,False,False)
Minimum
(1,PnlTmp_C,FP2,False,False)
Maximum
(1,PnlTmp_C,FP2,False,False)
EndTable
DataTable
(Hour,True,-1 )
DataInterval
(0,60,Min,10)
Sample
(1,AirTempC,FP2)
Sample
(1,TCDT,IEEE4)
Sample
(1,Q,FP2)
EndTable
PreserveVariables
'Main Program
BeginProg
'Main Scan
n = 1
Scan
(10,Sec,1,0)
'Battery Voltage measurement 'BattV'
Battery
(BattV)
'Wiring Panel Temperature measurement 'PnlTmp_C'
PanelTemp
(PnlTmp_C,60)
'107 Temperature Probe measurement 'AirTempC'
Therm107
(AirTempC,1,U1,U2,0,60,1,0)
'Automated snow depth measurement. Must occur two minutes before
Содержание SR50A
Страница 2: ......
Страница 6: ......
Страница 30: ...SR50A Series Sonic Ranging Sensors 20...
Страница 32: ......
Страница 53: ...Appendix B Example Programs B 21 CallTable Daily CallTable Hour NextScan EndProg...
Страница 54: ...Appendix B Example Programs B 22...
Страница 56: ......
Страница 78: ...Appendix E Tera Term QuickStart E 10...
Страница 83: ......