5 COLLECTING DATA GS1
5 Collecting Data
5.1 Sample Program
The following programs are examples that can be used with data
Campbell Scientific data loggers. The first program is for CR3000
data logger, but can easily be adapted for other “CRBasic” type
loggers. The second program is for a CR10X data logger, but can
be easily adapted to other “Edlog” type loggers. The GS1 needs
3.6 to 15 V DC excitation and therefore cannot be excited with the
2.5 V excitation port of many Campbell Scientific data loggers. We
recommend using the switched 12 V or CAO port to excite the GS1.
CR Basic Type Data Logger
’CR3000 Series Datalogger
’date: 7/7/2014
’program author: Kahlin Wacker
’program to read one Decagon GS1 sensor
’ right click on commands for more info.
’wiring
’white - SW - 12 1
’red - SE CH1
’bare gnd
Public GSonemV, VWC ’ variables
DataTable (Table1,1,-1) ’ the data table logs every 60 minutes an average of the output
DataInterval (0,60,Min,10)
Average (1,VWC,FP2,False)
EndTable
BeginProg
Scan(10,Sec,0,0) ’ interval between program runs
SW12(1,1)’ turn on the 12 volt power to the sensor
VoltSe (GSonemV,1,mV5000,21,1,10000,_60Hz,1.0,0)
’read the voltage from the sensor
SW12 (1,0) ’ turn off the 12 volt power to the sensor
VWC = 0.000494 * GSonemV - 0.554 ’mineral soil calibration
CallTable Table1 ’ write data to data table
10