Crbasic example 34. using sdi12sensor() command – Campbell Scientific CR3000 Micrologger User Manual
Page 187

Section 7. Installation
187
Else
'C!/C command sequence complete
Move
(Temp_Meas(X),1,Temp_Tmp(X),1)
'Copy measurements to SDI_Val(10)
cmd(X) = "C!"
'Start next measurement with "C!"
IndDone(X) = -1
EndIf
Next
X
'Summarize Measurement Event Success
For
X = 1
To
4
GroupDone = GroupDone + IndDone(X)
Next
X
'Stop current measurement event, reset controls
If
GroupDone = -4
Then
RunSDI12 = False
GroupDone = 0
For
X = 1
To
4
IndDone(X) = 0
Retry(X) = 0
Next
X
Else
GroupDone = 0
EndIf
EndIf
'End of measurement sequence
NextScan
EndProg
CRBasic Example 34. Using SDI12Sensor() Command
'Program to simulate 4 SDI-12 sensors. Can be used to produce measurements to test
'CRBasic example Using Alternate Concurrent Command (aC)
(p. 186).
Public
Temp(4)
DataTable
(Temp,True,0)
DataInterval
(0,5,Min,10)
Sample
(4,Temp(),FP2)
EndTable
BeginProg
Scan
(5,Sec,0,0)
PanelTemp
(Temp(1),250)
Temp(2) = Temp(1) + 5
Temp(3) = Temp(1) + 10
Temp(4) = Temp(1) + 15
CallTable
Temp
NextScan