'CR1000X Series 'Created by Short Cut (4.1) 'Declare Variables and Units Public BattV Public PTemp_C Public AirTC Public RH Public SlrW Public SlrMJ Public PAR_Den Public PAR_Tot Public WS_ms Public WindDir Public Rain_mm Units BattV=Volts Units PTemp_C=Deg C Units AirTC=Deg C Units RH=% Units SlrW=W/m^2 Units SlrMJ=MJ/m^2 Units PAR_Den=umol/s/m^2 Units PAR_Tot=mmol/m^2 Units WS_ms=meters/second Units WindDir=degrees Units Rain_mm=mm 'Define Data Tables DataTable(Table1,True,-1) DataInterval(0,15,Min,10) Sample(1,BattV,FP2) Sample(1,PTemp_C,FP2) Average(1,AirTC,FP2,False) FieldNames("AIRTEMP") Sample(1,RH,FP2) FieldNames("RELHUMID") Average(1,PAR_Den,FP2,False) FieldNames("QUANTUM") Average(1,SlrW,FP2,False) FieldNames("PYRANOM") Totalize(1,Rain_mm,FP2,False) FieldNames("PRECIP") Maximum(1,WS_ms,FP2,False,True) FieldNames("MAX_WINDSPEED,TIME_MAX_WINDSPEED") WindVector(1,WS_ms,WindDir,FP2,False,0,0,2) FieldNames("MEAN_HORIZONTAL_WINDSPEED,MEAN_RESULTANT_WINDSPEED,MEAN_WIND_DIRECTION,STDDEV_WIND_DIRECTION") EndTable DataTable(Table2,True,-1) DataInterval(0,1440,Min,10) Minimum(1,BattV,FP2,False,False) EndTable 'Main Program BeginProg 'Main Scan Scan(15,Sec,1,0) 'Default CR1000X Datalogger Battery Voltage measurement 'BattV' Battery(BattV) 'Default CR1000X Datalogger Wiring Panel Temperature measurement 'PTemp_C' PanelTemp(PTemp_C,60) 'HMP45C (7-wire, cable switched power) Temperature & Relative Humidity Sensor measurements 'AirTC' and 'RH' PortSet(C1,1) Delay(0,150,mSec) VoltSe(AirTC,1,mV1000,1,False,0,60,0.1,-40) VoltSe(RH,1,mV1000,2,False,0,60,0.1,0) PortSet(C1,0) If RH_2>100 AND RH_2<108 Then RH_2=100 'LI200S Pyranometer measurements 'SlrMJ' and 'SlrW' VoltDiff(SlrW,1,mV200,2,True,0,60,1,0) If SlrW<0 Then SlrW=0 'Calculate total flux 'The multiplier to calculate total flux was calculated by Short Cut 'and based on a program execution rate (scan rate) of 15 Seconds. 'If you change the program execution rate outside of Short Cut with the CRBasic Editor 'you will need to recalculate this multiplier. See the sensor manual for more details. 'SlrMJ=SlrW*0.001552795 'Calculate flux density SlrW=SlrW*70.4215 'LI190SB Quantum Sensor measurements 'PAR_Tot' and 'PAR_Den' VoltDiff(PAR_Den,1,mV200,3,True,0,60,1,0) If PAR_Den<0 Then PAR_Den=0 'Calculate total flux 'The multiplier to calculate total flux was calculated by Short Cut 'and based on a program execution rate (scan rate) of 15 Seconds. 'If you change the program execution rate outside of Short Cut with the CRBasic Editor 'you will need to recalculate this multiplier. See the sensor manual for more details. PAR_Tot=PAR_Den*3.751426 'Calculate flux density PAR_Den=PAR_Den*250.095 'RM Young 05305 Wind Speed & Direction Sensor measurements 'WS_ms' and 'WindDir' PulseCount(WS_ms,1,P1,5,1,0.1024,0) BrHalf(WindDir,1,mV5000,7,VX1,1,2500,True,20000,60,355,0) If WindDir>=355 Or WindDir<0 Then WindDir=0 'TE525/TE525WS Rain Gauge measurement 'Rain_mm' PulseCount(Rain_mm,1,P2,1,0,0.254,0) 'Call Data Tables and Store Data CallTable Table1 SendData(ComSDC7,0,4094,Table1,0) CallTable Table2 SendData(ComSDC7,0,4094,Table2,0) NextScan EndProg