Greetings,
I need to write a program that find the maximim and minimum, with CR1000X datalogger at CRBASIC.
I need it to be from (ex.) 10:01 to 10:10, 10:11 to 10:20 etc.
When I try to do it with Data Tables if finds the maximum and minmum of the 10 mintutes 2 seconds average from 10:00 to 10:10 and from 10:10 to 10:20, so if the maximim is at 10:00 it will still apear in the 10:20 data.
I tried different codes but it's always the same result.
The only different is that sometimes the TimeStamp is wrong - 1 minute ahead of the actuall data, when I use If IfTime(0,1,min) after tha scan, like in this code:
Public Td
Public Td_1mn
DataTables:
DataTable(Table013,true,-1)
DataInterval(0,1,Min,-1)
Average(1, Td, FP2, 0)
EndTable
DataTable(Table110,true,-1)
DataInterval(0,10,Min,-1)
Maximum(1, Td_1mn, FP2, 0,True)
Minimum(1, Td_1mn, FP2, 0,True)
EndTable
Scan(2,Sec, 3, 0)
VoltSe(Td, 1, mV5000, 2, False, 0, _50Hz, 0.1, -40.35)
If IfTime(0,1,min)Then
Td_1mn=Table013.Td_AVG(1,1)
CallTable113
CallTable Table110
EndIf
NextScan
Please help me.