Our full technical support staff does not monitor this forum. If you need assistance from a member of our staff, please submit your question from the Ask a Question page.


Log in or register to post/reply in the forum.

System skipped scan


smile Nov 13, 2016 06:18 PM

Hi to All,

to avoid the occurrence of system scans skipped, I entered once a day (with IF IFTIME......), the instruction "calibrated."

But despite this procedure still occur several system scans skipped.

Hundreds in a few hours, perhaps it does not function properly because I put the intructions IF IFTIME and CALIBRATE in slow scan?

How can I fix this? Since I would not increase the scan time.

thank you all.

Smile


GaryTRoberts Nov 22, 2016 04:43 AM

Can you post your code here?  Also, in the Status table what are the readings of MeasureTime, MaxProcTime, MaxSlowProcTime, SkippedSlowScan, and SkippedScan?  These will give us clues as to what is going on. 


smile Aug 19, 2018 03:30 PM

sorry for the delay, but only a few days ago I came back to the station after it got stuck again.

It seems that for the various errors I can not connect GSM and it does not transmit FTP.

I re-programmed the logger again, but after a few hours it was blocked again.

The modem responds but the logger does not. This is the traffic:

T: 10:14:45.776 ATz. 41 54 7A 0D
R: 10:14:45.776 ATz...OK.. 41 54 7A 0D 0D 0A 4F 4B 0D 0A
T: 10:14:47.823 ATV1&C1&D2. 41 54 56 31 26 43 31 26 44 32 0D
R: 10:14:47.823 ATV1&C1&D2...OK. 41 54 56 31 26 43 31 26 44 32 0D 0D 0A 4F 4B 0D
R: 10:14:47.870 . 0A
T: 10:14:47.886 ATDT338nnnnnnn. 41 54 44 54 33 33 38 3n 3n 3n 3n 3n 37 3n 0D
R: 10:14:47.886 ATDT338nnnnnnn. 41 54 44 54 33 33 38 3n 3n 3n 3n 3n 37 3n 0D
R: 10:15:08.229 ..CONNECT 9600.. 0D 0A 43 4F 4E 4E 45 43 54 20 39 36 30 30 0D 0A
T: 10:15:08.260 ..... BD BD BD BD BD
T: 10:15:08.572 .....q.. BD 90 01 0F FE 71 D2 BD
R: 10:15:09.666 ~.}#.!}%u} }7Pee 7E FF 7D 23 C0 21 7D 25 75 7D 20 7D 37 50 65 65
R: 10:15:09.682 r not responding 72 20 6E 6F 74 20 72 65 73 70 6F 6E 64 69 6E 67
R: 10:15:09.713 .\~ CA 5C 7E
T: 10:15:15.369 .....q.. BD 90 01 0F FE 71 D2 BD
R: 10:15:15.666 ~.}#.!}%v} }7Pee 7E FF 7D 23 C0 21 7D 25 76 7D 20 7D 37 50 65 65
R: 10:15:15.682 r not responding 72 20 6E 6F 74 20 72 65 73 70 6F 6E 64 69 6E 67
R: 10:15:15.713 <.~ 3C AF 7E
T: 10:15:22.478 .....q.. BD 90 01 0F FE 71 D2 BD
R: 10:15:23.884 .....Z.. BD AF FE 00 01 5A 89 BD
T: 10:15:23.916 ................ BD A0 01 7F FE 00 01 0F FE 09 FE 01 03 FF FE 90
T: 10:15:23.916 \. 5C BD
R: 10:15:24.166 a 61
R: 10:15:25.369 ...0...........\ BD AF FE 30 01 0F FE 00 01 89 FE 01 02 FF FE 5C
R: 10:15:25.384 .....p..... A4 BD BD AF FE 70 01 0F FE 00 01
T: 10:15:25.416 ...............Z BD A0 01 7F FE 00 01 0F FE 0A FF 00 01 B0 01 5A
T: 10:15:25.416 .. A9 BD
R: 10:15:25.416 ........... 0A 1F 00 1F 10 03 BF FE B3 C8 BD
T: 10:15:25.431 ............y. BD A0 01 7F FE 00 01 0F FE 8A 1F C3 79 BD
R: 10:15:26.878 ...p.......*5... BD AF FE 70 01 0F FE 00 01 8A FF 2A 35 BD BD AF
R: 10:15:26.895 . FE
T: 10:15:26.897 ...?........ BD A0 01 3F FE 00 01 0F FE C7 86 BD
R: 10:15:26.897 .......3.a 00 01 0F FE 00 01 EF 33 BD 61
T: 10:15:27.935 ......S. BD B0 01 0F FE D3 53 BD
R: 10:15:28.326 ........ BD BF FE 00 01 8C CA BD
T: 10:15:28.342 .....K.. BD 80 01 0F FE 4B 96 BD
R: 10:15:29.342 ........ BD 8F FE 00 01 F6 08 BD
R: 10:15:30.170 a 61
R: 10:15:33.170 a 61
R: 10:15:36.169 a 61
R: 10:15:39.169 a 61
T: 10:15:42.357 +++ 2B 2B 2B
R: 10:15:42.357 ..OK 0D 0A 4F 4B
T: 10:15:42.372 ATH. 41 54 48 0D
R: 10:15:42.372 ..ATH. 0D 0A 41 54 48 0D
R: 10:15:43.482 ..OK.. 0D 0A 4F 4B 0D 0A

The absurd thing is that it worked well throughout the winter and spring, after solving other problems for the old operating systems. Now it's 32.02.

This is a CR800 master for other 2 CR800 in the pakbus network.

There are wifi radiomodem for connect pk1(est) to pk2 (centro) and pk3(ovest)

This is the program :

Public ancora_wifi As Boolean' (extend the wifi master ON time x connect to PC)
Public ppp As Boolean
Public new_est60,new_ovest60,new_centro60 ' x write files in the USB Key
Public new_est24,new_ovest24,new_centro24
Public batt_pk2 As String * 100
Public batt_pk3 As String * 100
Public rTime(9)' x write the file name
Public BattV, result_pk2, result_pk3 'response for remote data (pk2 and pk3)
Public result_pk224, result_pk324
Public PTemp_C
Public TRHData(2)
Public CS65X(6)
Public CS65X_2(6)
Public CS65X_3(6)
Public CS65X_4(6)
Public time_pk2 As String * 100
Public time_pk3 As String * 100
Public APN As String *100
Alias rTime(1) = Year
Alias rTime(2) = Month
Alias rTime(3) = DOM
Alias rTime(4) = Hour
Alias rTime(5) = Minute
Alias rTime(6) = Second
Alias rTime(7) = uSecond
Alias rTime(8) = WeekDay
Alias rTime(9) = Day_of_Year
Public tent_c60, tent_e60, tent_o60 ' attempts to send FTP
Public tent_c24, tent_e24, tent_o24
Public sendftp_c60 As Boolean 'OK to send ftp
Public sendftp_e60 As Boolean
Public sendftp_o60 As Boolean
Public sendftp_c24 As Boolean
Public sendftp_e24 As Boolean
Public sendftp_o24 As Boolean
Public IPAddress As String *100' server credentials
Public UserName As String *100
Dim Password As String *100
Public Path_centro60 As String *100
Public Path_est60 As String *100
Public Path_ovest60 As String *100
Public Path_centro24 As String *100
Public Path_est24 As String *100
Public Path_ovest24 As String *100
Public invio_ftp_c60 As Boolean ' reply FTPClient
Public invio_ftp_e60 As Boolean
Public invio_ftp_o60 As Boolean
Public invio_ftp_c24 As Boolean
Public invio_ftp_e24 As Boolean
Public invio_ftp_o24 As Boolean
'Public sito As String *100
Public month_MMh As String
Public dom_ggh As String
Public winddir, ws_ms,rain_mm, r_c_mm, fine
Public month_MM As String
Public dom_gg As String
Public dir_centro As String *100
Public dir_est As String *100
Public dir_ovest As String *100
Alias TRHData(1)=AirTC
Alias TRHData(2)=RH
Alias CS65X(1)=VWC
Alias CS65X(2)=EC
Alias CS65X(3)=T
Alias CS65X(4)=P
Alias CS65X(5)=PA
Alias CS65X(6)=VR
Alias CS65X_2(1)=VWC_2
Alias CS65X_2(2)=EC_2
Alias CS65X_2(3)=T_2
Alias CS65X_2(4)=P_2
Alias CS65X_2(5)=PA_2
Alias CS65X_2(6)=VR_2
Alias CS65X_3(1)=VWC_3
Alias CS65X_3(2)=EC_3
Alias CS65X_3(3)=T_3
Alias CS65X_3(4)=P_3
Alias CS65X_3(5)=PA_3
Alias CS65X_3(6)=VR_3
Alias CS65X_4(1)=VWC_4
Alias CS65X_4(2)=EC_4
Alias CS65X_4(3)=T_4
Alias CS65X_4(4)=P_4
Alias CS65X_4(5)=PA_4
Alias CS65X_4(6)=VR_4
Units BattV=Volts
Units PTemp_C=Deg C
Units AirTC=Deg C
Units RH=%
Units VWC=m^3/m^3
Units EC=dS/m
Units T=Deg C
Units P=unitless
Units PA=nSec
Units VR=unitless
Units VWC_2=m^3/m^3
Units EC_2=dS/m
Units T_2=Deg C
Units P_2=unitless
Units PA_2=nSec
Units VR_2=unitless
Units VWC_3=m^3/m^3
Units EC_3=dS/m
Units T_3=Deg C
Units P_3=unitless
Units PA_3=nSec
Units VR_3=unitless
Units VWC_4=m^3/m^3
Units EC_4=dS/m
Units T_4=Deg C
Units P_4=unitless
Units PA_4=nSec
Units VR_4=unitless

'historical data
DataTable(est60,True,-1)
DataInterval(0,60,Min,10)
TableFile("USB:est60",8,-1,24,60,min,new_est60,0)
Minimum(1,BattV,FP2,False,False)
Maximum(1,PTemp_C,FP2,False,False)
Minimum(1,PTemp_C,FP2,False,False)
Average(1,PTemp_C,FP2,False)
Maximum(1,AirTC,FP2,False,False)
Minimum(1,AirTC,FP2,False,False)
Average(1,AirTC,FP2,False)
StdDev(1,AirTC,FP2,False)
Maximum(1,RH,FP2,False,False)
Minimum(1,RH,FP2,False,False)
Average(1,RH,FP2,False)
StdDev(1,RH,FP2,False)
Sample(1,VWC,FP2)
Sample(1,EC,FP2)
Sample(1,T,FP2)
Sample(1,P,FP2)
Sample(1,PA,FP2)
Sample(1,VR,FP2)
Sample(1,VWC_2,FP2)
Sample(1,EC_2,FP2)
Sample(1,T_2,FP2)
Sample(1,P_2,FP2)
Sample(1,PA_2,FP2)
Sample(1,VR_2,FP2)
Sample(1,VWC_3,FP2)
Sample(1,EC_3,FP2)
Sample(1,T_3,FP2)
Sample(1,P_3,FP2)
Sample(1,PA_3,FP2)
Sample(1,VR_3,FP2)
Sample(1,VWC_4,FP2)
Sample(1,EC_4,FP2)
Sample(1,T_4,FP2)
Sample(1,P_4,FP2)
Sample(1,PA_4,FP2)
Sample(1,VR_4,FP2)
Average(1,VWC,FP2,0)
Average(1,EC,FP2,0)
Average(1,T,FP2,0)
Average(1,P,FP2,0)
Average(1,PA,FP2,0)
Average(1,VR,FP2,0)
Average(1,VWC_2,FP2,0)
Average(1,EC_2,FP2,0)
Average(1,T_2,FP2,0)
Average(1,P_2,FP2,0)
Average(1,PA_2,FP2,0)
Average(1,VR_2,FP2,0)
Average(1,VWC_3,FP2,0)
Average(1,EC_3,fp2,0)
Average(1,T_3,fp2,0)
Average(1,P_3,fp2,0)
Average(1,PA_3,fp2,0)
Average(1,VR_3,fp2,0)
Average(1,VWC_4,fp2,0)
Average(1,EC_4,fp2,0)
Average(1,T_4,fp2,0)
Average(1,P_4,fp2,0)
Average(1,PA_4,fp2,0)
Average(1,VR_4,fp2,0)
Maximum(1,VWC,FP2,0,0)
Maximum(1,EC,fp2,0,0)
Maximum(1,T,fp2,0,0)
Maximum(1,P,fp2,0,0)
Maximum(1,PA,fp2,0,0)
Maximum(1,VR,fp2,0,0)
Maximum(1,VWC_2,fp2,0,0)
Maximum(1,EC_2,fp2,0,0)
Maximum(1,T_2,fp2,0,0)
Maximum(1,P_2,fp2,0,0)
Maximum(1,PA_2,fp2,0,0)
Maximum(1,VR_2,fp2,0,0)
Maximum(1,VWC_3,fp2,0,0)
Maximum(1,EC_3,fp2,0,0)
Maximum(1,T_3,fp2,0,0)
Maximum(1,P_3,fp2,0,0)
Maximum(1,PA_3,fp2,0,0)
Maximum(1,VR_3,fp2,0,0)
Maximum(1,VWC_4,fp2,0,0)
Maximum(1,EC_4,fp2,0,0)
Maximum(1,T_4,fp2,0,0)
Maximum(1,P_4,fp2,0,0)
Maximum(1,PA_4,fp2,0,0)
Maximum(1,VR_4,fp2,0,0)
Minimum(1,VWC,FP2,0,0)
Minimum(1,EC,fp2,0,0)
Minimum(1,T,fp2,0,0)
Minimum(1,P,fp2,0,0)
Minimum(1,PA,fp2,0,0)
Minimum(1,VR,fp2,0,0)
Minimum(1,VWC_2,fp2,0,0)
Minimum(1,EC_2,fp2,0,0)
Minimum(1,T_2,fp2,0,0)
Minimum(1,P_2,fp2,0,0)
Minimum(1,PA_2,fp2,0,0)
Minimum(1,VR_2,fp2,0,0)
Minimum(1,VWC_3,fp2,0,0)
Minimum(1,EC_3,fp2,0,0)
Minimum(1,T_3,fp2,0,0)
Minimum(1,P_3,fp2,0,0)
Minimum(1,PA_3,fp2,0,0)
Minimum(1,VR_3,fp2,0,0)
Minimum(1,VWC_4,fp2,0,0)
Minimum(1,EC_4,fp2,0,0)
Minimum(1,T_4,fp2,0,0)
Minimum(1,P_4,fp2,0,0)
Minimum(1,PA_4,fp2,0,0)
Minimum(1,VR_4,fp2,0,0)
StdDev(1,VWC,FP2,0)
StdDev(1,EC,FP2,0)
StdDev(1,T,FP2,0)
StdDev(1,P,FP2,0)
StdDev(1,PA,FP2,0)
StdDev(1,VR,FP2,0)
StdDev(1,VWC_2,FP2,0)
StdDev(1,EC_2,FP2,0)
StdDev(1,T_2,FP2,0)
StdDev(1,P_2,FP2,0)
StdDev(1,PA_2,FP2,0)
StdDev(1,VR_2,FP2,0)
StdDev(1,VWC_3,FP2,0)
StdDev(1,EC_3,fp2,0)
StdDev(1,T_3,fp2,0)
StdDev(1,P_3,fp2,0)
StdDev(1,PA_3,fp2,0)
StdDev(1,VR_3,fp2,0)
StdDev(1,VWC_4,fp2,0)
StdDev(1,EC_4,fp2,0)
StdDev(1,T_4,fp2,0)
StdDev(1,P_4,fp2,0)
StdDev(1,PA_4,fp2,0)
StdDev(1,VR_4,fp2,0)
Sample (1,batt_pk2,FP2)
Sample (1,batt_pk3,FP2)
Sample (1,time_pk2,String)
Sample (1,time_pk3,String)
EndTable

DataTable(est24,True,-1)
DataInterval(0,1440,Min,10)
TableFile("USB:est24",8,-1,24,1440,min,new_est24,0)
Minimum(1,BattV,FP2,False,False)
Maximum(1,PTemp_C,FP2,False,False)
Minimum(1,PTemp_C,FP2,False,False)
Average(1,PTemp_C,FP2,False)
Maximum(1,AirTC,FP2,False,False)
Minimum(1,AirTC,FP2,False,False)
Average(1,AirTC,FP2,False)
StdDev(1,AirTC,FP2,False)
Maximum(1,RH,FP2,False,False)
Minimum(1,RH,FP2,False,False)
Average(1,RH,FP2,False)
StdDev(1,RH,FP2,False)
Sample(1,VWC,FP2)
Sample(1,EC,FP2)
Sample(1,T,FP2)
Sample(1,P,FP2)
Sample(1,PA,FP2)
Sample(1,VR,FP2)
Sample(1,VWC_2,FP2)
Sample(1,EC_2,FP2)
Sample(1,T_2,FP2)
Sample(1,P_2,FP2)
Sample(1,PA_2,FP2)
Sample(1,VR_2,FP2)
Sample(1,VWC_3,FP2)
Sample(1,EC_3,FP2)
Sample(1,T_3,FP2)
Sample(1,P_3,FP2)
Sample(1,PA_3,FP2)
Sample(1,VR_3,FP2)
Sample(1,VWC_4,FP2)
Sample(1,EC_4,FP2)
Sample(1,T_4,FP2)
Sample(1,P_4,FP2)
Sample(1,PA_4,FP2)
Sample(1,VR_4,FP2)
Average(1,VWC,FP2,0)
Average(1,EC,FP2,0)
Average(1,T,FP2,0)
Average(1,P,FP2,0)
Average(1,PA,FP2,0)
Average(1,VR,FP2,0)
Average(1,VWC_2,FP2,0)
Average(1,EC_2,FP2,0)
Average(1,T_2,FP2,0)
Average(1,P_2,FP2,0)
Average(1,PA_2,FP2,0)
Average(1,VR_2,FP2,0)
Average(1,VWC_3,FP2,0)
Average(1,EC_3,fp2,0)
Average(1,T_3,fp2,0)
Average(1,P_3,fp2,0)
Average(1,PA_3,fp2,0)
Average(1,VR_3,fp2,0)
Average(1,VWC_4,fp2,0)
Average(1,EC_4,fp2,0)
Average(1,T_4,fp2,0)
Average(1,P_4,fp2,0)
Average(1,PA_4,fp2,0)
Average(1,VR_4,fp2,0)
Maximum(1,VWC,FP2,0,0)
Maximum(1,EC,fp2,0,0)
Maximum(1,T,fp2,0,0)
Maximum(1,P,fp2,0,0)
Maximum(1,PA,fp2,0,0)
Maximum(1,VR,fp2,0,0)
Maximum(1,VWC_2,fp2,0,0)
Maximum(1,EC_2,fp2,0,0)
Maximum(1,T_2,fp2,0,0)
Maximum(1,P_2,fp2,0,0)
Maximum(1,PA_2,fp2,0,0)
Maximum(1,VR_2,fp2,0,0)
Maximum(1,VWC_3,fp2,0,0)
Maximum(1,EC_3,fp2,0,0)
Maximum(1,T_3,fp2,0,0)
Maximum(1,P_3,fp2,0,0)
Maximum(1,PA_3,fp2,0,0)
Maximum(1,VR_3,fp2,0,0)
Maximum(1,VWC_4,fp2,0,0)
Maximum(1,EC_4,fp2,0,0)
Maximum(1,T_4,fp2,0,0)
Maximum(1,P_4,fp2,0,0)
Maximum(1,PA_4,fp2,0,0)
Maximum(1,VR_4,fp2,0,0)
Minimum(1,VWC,FP2,0,0)
Minimum(1,EC,fp2,0,0)
Minimum(1,T,fp2,0,0)
Minimum(1,P,fp2,0,0)
Minimum(1,PA,fp2,0,0)
Minimum(1,VR,fp2,0,0)
Minimum(1,VWC_2,fp2,0,0)
Minimum(1,EC_2,fp2,0,0)
Minimum(1,T_2,fp2,0,0)
Minimum(1,P_2,fp2,0,0)
Minimum(1,PA_2,fp2,0,0)
Minimum(1,VR_2,fp2,0,0)
Minimum(1,VWC_3,fp2,0,0)
Minimum(1,EC_3,fp2,0,0)
Minimum(1,T_3,fp2,0,0)
Minimum(1,P_3,fp2,0,0)
Minimum(1,PA_3,fp2,0,0)
Minimum(1,VR_3,fp2,0,0)
Minimum(1,VWC_4,fp2,0,0)
Minimum(1,EC_4,fp2,0,0)
Minimum(1,T_4,fp2,0,0)
Minimum(1,P_4,fp2,0,0)
Minimum(1,PA_4,fp2,0,0)
Minimum(1,VR_4,fp2,0,0)
StdDev(1,VWC,FP2,0)
StdDev(1,EC,FP2,0)
StdDev(1,T,FP2,0)
StdDev(1,P,FP2,0)
StdDev(1,PA,FP2,0)
StdDev(1,VR,FP2,0)
StdDev(1,VWC_2,FP2,0)
StdDev(1,EC_2,FP2,0)
StdDev(1,T_2,FP2,0)
StdDev(1,P_2,FP2,0)
StdDev(1,PA_2,FP2,0)
StdDev(1,VR_2,FP2,0)
StdDev(1,VWC_3,FP2,0)
StdDev(1,EC_3,fp2,0)
StdDev(1,T_3,fp2,0)
StdDev(1,P_3,fp2,0)
StdDev(1,PA_3,fp2,0)
StdDev(1,VR_3,fp2,0)
StdDev(1,VWC_4,fp2,0)
StdDev(1,EC_4,fp2,0)
StdDev(1,T_4,fp2,0)
StdDev(1,P_4,fp2,0)
StdDev(1,PA_4,fp2,0)
StdDev(1,VR_4,fp2,0)
EndTable

DataTable(centro60,True,-1)
DataInterval(3,60,Min,10)
Minimum(1,BattV,FP2,False,False)
Maximum(1,PTemp_C,FP2,False,False)
Minimum(1,PTemp_C,FP2,False,False)
Average(1,PTemp_C,FP2,False)
Maximum(1,AirTC,FP2,False,False)
Minimum(1,AirTC,FP2,False,False)
Average(1,AirTC,FP2,False)
StdDev(1,AirTC,FP2,False)
Maximum(1,RH,FP2,False,False)
Minimum(1,RH,FP2,False,False)
Average(1,RH,FP2,False)
StdDev(1,RH,FP2,False)
Maximum(1,ws_ms,FP2,False,False)
Minimum(1,ws_ms,FP2,False,False)
WindVector(1,ws_ms,winddir,FP2,False,0,0,0)
FieldNames("WS_ms_S_WVT,WindDir_D1_WVT,WindDir_SD1_WVT")
Totalize(1,rain_mm,FP2,False)
Totalize(1,r_c_mm,FP2,False)
Sample(1,VWC,FP2)
Sample(1,EC,FP2)
Sample(1,T,FP2)
Sample(1,P,FP2)
Sample(1,PA,FP2)
Sample(1,VR,FP2)
Sample(1,VWC_2,FP2)
Sample(1,EC_2,FP2)
Sample(1,T_2,FP2)
Sample(1,P_2,FP2)
Sample(1,PA_2,FP2)
Sample(1,VR_2,FP2)
Sample(1,VWC_3,FP2)
Sample(1,EC_3,FP2)
Sample(1,T_3,FP2)
Sample(1,P_3,FP2)
Sample(1,PA_3,FP2)
Sample(1,VR_3,FP2)
Sample(1,VWC_4,FP2)
Sample(1,EC_4,FP2)
Sample(1,T_4,FP2)
Sample(1,P_4,FP2)
Sample(1,PA_4,FP2)
Sample(1,VR_4,FP2)
Average(1,VWC,FP2,0)
Average(1,EC,FP2,0)
Average(1,T,FP2,0)
Average(1,P,FP2,0)
Average(1,PA,FP2,0)
Average(1,VR,FP2,0)
Average(1,VWC_2,FP2,0)
Average(1,EC_2,FP2,0)
Average(1,T_2,FP2,0)
Average(1,P_2,FP2,0)
Average(1,PA_2,FP2,0)
Average(1,VR_2,FP2,0)
Average(1,VWC_3,FP2,0)
Average(1,EC_3,fp2,0)
Average(1,T_3,fp2,0)
Average(1,P_3,fp2,0)
Average(1,PA_3,fp2,0)
Average(1,VR_3,fp2,0)
Average(1,VWC_4,fp2,0)
Average(1,EC_4,fp2,0)
Average(1,T_4,fp2,0)
Average(1,P_4,fp2,0)
Average(1,PA_4,fp2,0)
Average(1,VR_4,fp2,0)
Maximum(1,VWC,FP2,0,0)
Maximum(1,EC,fp2,0,0)
Maximum(1,T,fp2,0,0)
Maximum(1,P,fp2,0,0)
Maximum(1,PA,fp2,0,0)
Maximum(1,VR,fp2,0,0)
Maximum(1,VWC_2,fp2,0,0)
Maximum(1,EC_2,fp2,0,0)
Maximum(1,T_2,fp2,0,0)
Maximum(1,P_2,fp2,0,0)
Maximum(1,PA_2,fp2,0,0)
Maximum(1,VR_2,fp2,0,0)
Maximum(1,VWC_3,fp2,0,0)
Maximum(1,EC_3,fp2,0,0)
Maximum(1,T_3,fp2,0,0)
Maximum(1,P_3,fp2,0,0)
Maximum(1,PA_3,fp2,0,0)
Maximum(1,VR_3,fp2,0,0)
Maximum(1,VWC_4,fp2,0,0)
Maximum(1,EC_4,fp2,0,0)
Maximum(1,T_4,fp2,0,0)
Maximum(1,P_4,fp2,0,0)
Maximum(1,PA_4,fp2,0,0)
Maximum(1,VR_4,fp2,0,0)
Minimum(1,VWC,FP2,0,0)
Minimum(1,EC,fp2,0,0)
Minimum(1,T,fp2,0,0)
Minimum(1,P,fp2,0,0)
Minimum(1,PA,fp2,0,0)
Minimum(1,VR,fp2,0,0)
Minimum(1,VWC_2,fp2,0,0)
Minimum(1,EC_2,fp2,0,0)
Minimum(1,T_2,fp2,0,0)
Minimum(1,P_2,fp2,0,0)
Minimum(1,PA_2,fp2,0,0)
Minimum(1,VR_2,fp2,0,0)
Minimum(1,VWC_3,fp2,0,0)
Minimum(1,EC_3,fp2,0,0)
Minimum(1,T_3,fp2,0,0)
Minimum(1,P_3,fp2,0,0)
Minimum(1,PA_3,fp2,0,0)
Minimum(1,VR_3,fp2,0,0)
Minimum(1,VWC_4,fp2,0,0)
Minimum(1,EC_4,fp2,0,0)
Minimum(1,T_4,fp2,0,0)
Minimum(1,P_4,fp2,0,0)
Minimum(1,PA_4,fp2,0,0)
Minimum(1,VR_4,fp2,0,0)
StdDev(1,VWC,FP2,0)
StdDev(1,EC,FP2,0)
StdDev(1,T,FP2,0)
StdDev(1,P,FP2,0)
StdDev(1,PA,FP2,0)
StdDev(1,VR,FP2,0)
StdDev(1,VWC_2,FP2,0)
StdDev(1,EC_2,FP2,0)
StdDev(1,T_2,FP2,0)
StdDev(1,P_2,FP2,0)
StdDev(1,PA_2,FP2,0)
StdDev(1,VR_2,FP2,0)
StdDev(1,VWC_3,FP2,0)
StdDev(1,EC_3,fp2,0)
StdDev(1,T_3,fp2,0)
StdDev(1,P_3,fp2,0)
StdDev(1,PA_3,fp2,0)
StdDev(1,VR_3,fp2,0)
StdDev(1,VWC_4,fp2,0)
StdDev(1,EC_4,fp2,0)
StdDev(1,T_4,fp2,0)
StdDev(1,P_4,fp2,0)
StdDev(1,PA_4,fp2,0)
StdDev(1,VR_4,fp2,0)
Sample(1,fine,String)
TableFile("USB:centro60",8,-1,24,60,min,new_centro60,0)
EndTable

DataTable(centro24,True,-1)
DataInterval(9,1440,Min,10)
Minimum(1,BattV,FP2,False,False)
Maximum(1,PTemp_C,FP2,False,False)
Minimum(1,PTemp_C,FP2,False,False)
Average(1,PTemp_C,FP2,False)
Maximum(1,AirTC,FP2,False,False)
Minimum(1,AirTC,FP2,False,False)
Average(1,AirTC,FP2,False)
StdDev(1,AirTC,FP2,False)
Maximum(1,RH,FP2,False,False)
Minimum(1,RH,FP2,False,False)
Average(1,RH,FP2,False)
StdDev(1,RH,FP2,False)
Maximum(1,ws_ms,FP2,False,False)
Minimum(1,ws_ms,FP2,False,False)
WindVector(1,ws_ms,winddir,FP2,False,0,0,0)
FieldNames("WS_ms_S_WVT,WindDir_D1_WVT,WindDir_SD1_WVT")
Totalize(1,rain_mm,FP2,False)
Totalize(1,r_c_mm,FP2,False)
Sample(1,VWC,FP2)
Sample(1,EC,FP2)
Sample(1,T,FP2)
Sample(1,P,FP2)
Sample(1,PA,FP2)
Sample(1,VR,FP2)
Sample(1,VWC_2,FP2)
Sample(1,EC_2,FP2)
Sample(1,T_2,FP2)
Sample(1,P_2,FP2)
Sample(1,PA_2,FP2)
Sample(1,VR_2,FP2)
Sample(1,VWC_3,FP2)
Sample(1,EC_3,FP2)
Sample(1,T_3,FP2)
Sample(1,P_3,FP2)
Sample(1,PA_3,FP2)
Sample(1,VR_3,FP2)
Sample(1,VWC_4,FP2)
Sample(1,EC_4,FP2)
Sample(1,T_4,FP2)
Sample(1,P_4,FP2)
Sample(1,PA_4,FP2)
Sample(1,VR_4,FP2)
Average(1,VWC,FP2,0)
Average(1,EC,FP2,0)
Average(1,T,FP2,0)
Average(1,P,FP2,0)
Average(1,PA,FP2,0)
Average(1,VR,FP2,0)
Average(1,VWC_2,FP2,0)
Average(1,EC_2,FP2,0)
Average(1,T_2,FP2,0)
Average(1,P_2,FP2,0)
Average(1,PA_2,FP2,0)
Average(1,VR_2,FP2,0)
Average(1,VWC_3,FP2,0)
Average(1,EC_3,fp2,0)
Average(1,T_3,fp2,0)
Average(1,P_3,fp2,0)
Average(1,PA_3,fp2,0)
Average(1,VR_3,fp2,0)
Average(1,VWC_4,fp2,0)
Average(1,EC_4,fp2,0)
Average(1,T_4,fp2,0)
Average(1,P_4,fp2,0)
Average(1,PA_4,fp2,0)
Average(1,VR_4,fp2,0)
Maximum(1,VWC,FP2,0,0)
Maximum(1,EC,fp2,0,0)
Maximum(1,T,fp2,0,0)
Maximum(1,P,fp2,0,0)
Maximum(1,PA,fp2,0,0)
Maximum(1,VR,fp2,0,0)
Maximum(1,VWC_2,fp2,0,0)
Maximum(1,EC_2,fp2,0,0)
Maximum(1,T_2,fp2,0,0)
Maximum(1,P_2,fp2,0,0)
Maximum(1,PA_2,fp2,0,0)
Maximum(1,VR_2,fp2,0,0)
Maximum(1,VWC_3,fp2,0,0)
Maximum(1,EC_3,fp2,0,0)
Maximum(1,T_3,fp2,0,0)
Maximum(1,P_3,fp2,0,0)
Maximum(1,PA_3,fp2,0,0)
Maximum(1,VR_3,fp2,0,0)
Maximum(1,VWC_4,fp2,0,0)
Maximum(1,EC_4,fp2,0,0)
Maximum(1,T_4,fp2,0,0)
Maximum(1,P_4,fp2,0,0)
Maximum(1,PA_4,fp2,0,0)
Maximum(1,VR_4,fp2,0,0)
Minimum(1,VWC,FP2,0,0)
Minimum(1,EC,fp2,0,0)
Minimum(1,T,fp2,0,0)
Minimum(1,P,fp2,0,0)
Minimum(1,PA,fp2,0,0)
Minimum(1,VR,fp2,0,0)
Minimum(1,VWC_2,fp2,0,0)
Minimum(1,EC_2,fp2,0,0)
Minimum(1,T_2,fp2,0,0)
Minimum(1,P_2,fp2,0,0)
Minimum(1,PA_2,fp2,0,0)
Minimum(1,VR_2,fp2,0,0)
Minimum(1,VWC_3,fp2,0,0)
Minimum(1,EC_3,fp2,0,0)
Minimum(1,T_3,fp2,0,0)
Minimum(1,P_3,fp2,0,0)
Minimum(1,PA_3,fp2,0,0)
Minimum(1,VR_3,fp2,0,0)
Minimum(1,VWC_4,fp2,0,0)
Minimum(1,EC_4,fp2,0,0)
Minimum(1,T_4,fp2,0,0)
Minimum(1,P_4,fp2,0,0)
Minimum(1,PA_4,fp2,0,0)
Minimum(1,VR_4,fp2,0,0)
StdDev(1,VWC,FP2,0)
StdDev(1,EC,FP2,0)
StdDev(1,T,FP2,0)
StdDev(1,P,FP2,0)
StdDev(1,PA,FP2,0)
StdDev(1,VR,FP2,0)
StdDev(1,VWC_2,FP2,0)
StdDev(1,EC_2,FP2,0)
StdDev(1,T_2,FP2,0)
StdDev(1,P_2,FP2,0)
StdDev(1,PA_2,FP2,0)
StdDev(1,VR_2,FP2,0)
StdDev(1,VWC_3,FP2,0)
StdDev(1,EC_3,fp2,0)
StdDev(1,T_3,fp2,0)
StdDev(1,P_3,fp2,0)
StdDev(1,PA_3,fp2,0)
StdDev(1,VR_3,fp2,0)
StdDev(1,VWC_4,fp2,0)
StdDev(1,EC_4,fp2,0)
StdDev(1,T_4,fp2,0)
StdDev(1,P_4,fp2,0)
StdDev(1,PA_4,fp2,0)
StdDev(1,VR_4,fp2,0)
Sample(1,fine,String)
TableFile("USB:centro24",8,-1,24,1440,min,new_centro24,0)
EndTable

DataTable(ovest60,True,-1)
DataInterval(12,60,Min,10)
Minimum(1,BattV,FP2,False,False)
Maximum(1,PTemp_C,FP2,False,False)
Minimum(1,PTemp_C,FP2,False,False)
Average(1,PTemp_C,FP2,False)
Maximum(1,AirTC,FP2,False,False)
Minimum(1,AirTC,FP2,False,False)
Average(1,AirTC,FP2,False)
StdDev(1,AirTC,FP2,False)
Maximum(1,RH,FP2,False,False)
Minimum(1,RH,FP2,False,False)
Average(1,RH,FP2,False)
StdDev(1,RH,FP2,False)
Sample(1,VWC,FP2)
Sample(1,EC,FP2)
Sample(1,T,FP2)
Sample(1,P,FP2)
Sample(1,PA,FP2)
Sample(1,VR,FP2)
Sample(1,VWC_2,FP2)
Sample(1,EC_2,FP2)
Sample(1,T_2,FP2)
Sample(1,P_2,FP2)
Sample(1,PA_2,FP2)
Sample(1,VR_2,FP2)
Sample(1,VWC_3,FP2)
Sample(1,EC_3,FP2)
Sample(1,T_3,FP2)
Sample(1,P_3,FP2)
Sample(1,PA_3,FP2)
Sample(1,VR_3,FP2)
Sample(1,VWC_4,FP2)
Sample(1,EC_4,FP2)
Sample(1,T_4,FP2)
Sample(1,P_4,FP2)
Sample(1,PA_4,FP2)
Sample(1,VR_4,FP2)
Average(1,VWC,FP2,0)
Average(1,EC,FP2,0)
Average(1,T,FP2,0)
Average(1,P,FP2,0)
Average(1,PA,FP2,0)
Average(1,VR,FP2,0)
Average(1,VWC_2,FP2,0)
Average(1,EC_2,FP2,0)
Average(1,T_2,FP2,0)
Average(1,P_2,FP2,0)
Average(1,PA_2,FP2,0)
Average(1,VR_2,FP2,0)
Average(1,VWC_3,FP2,0)
Average(1,EC_3,fp2,0)
Average(1,T_3,fp2,0)
Average(1,P_3,fp2,0)
Average(1,PA_3,fp2,0)
Average(1,VR_3,fp2,0)
Average(1,VWC_4,fp2,0)
Average(1,EC_4,fp2,0)
Average(1,T_4,fp2,0)
Average(1,P_4,fp2,0)
Average(1,PA_4,fp2,0)
Average(1,VR_4,fp2,0)
Maximum(1,VWC,FP2,0,0)
Maximum(1,EC,fp2,0,0)
Maximum(1,T,fp2,0,0)
Maximum(1,P,fp2,0,0)
Maximum(1,PA,fp2,0,0)
Maximum(1,VR,fp2,0,0)
Maximum(1,VWC_2,fp2,0,0)
Maximum(1,EC_2,fp2,0,0)
Maximum(1,T_2,fp2,0,0)
Maximum(1,P_2,fp2,0,0)
Maximum(1,PA_2,fp2,0,0)
Maximum(1,VR_2,fp2,0,0)
Maximum(1,VWC_3,fp2,0,0)
Maximum(1,EC_3,fp2,0,0)
Maximum(1,T_3,fp2,0,0)
Maximum(1,P_3,fp2,0,0)
Maximum(1,PA_3,fp2,0,0)
Maximum(1,VR_3,fp2,0,0)
Maximum(1,VWC_4,fp2,0,0)
Maximum(1,EC_4,fp2,0,0)
Maximum(1,T_4,fp2,0,0)
Maximum(1,P_4,fp2,0,0)
Maximum(1,PA_4,fp2,0,0)
Maximum(1,VR_4,fp2,0,0)
Minimum(1,VWC,FP2,0,0)
Minimum(1,EC,fp2,0,0)
Minimum(1,T,fp2,0,0)
Minimum(1,P,fp2,0,0)
Minimum(1,PA,fp2,0,0)
Minimum(1,VR,fp2,0,0)
Minimum(1,VWC_2,fp2,0,0)
Minimum(1,EC_2,fp2,0,0)
Minimum(1,T_2,fp2,0,0)
Minimum(1,P_2,fp2,0,0)
Minimum(1,PA_2,fp2,0,0)
Minimum(1,VR_2,fp2,0,0)
Minimum(1,VWC_3,fp2,0,0)
Minimum(1,EC_3,fp2,0,0)
Minimum(1,T_3,fp2,0,0)
Minimum(1,P_3,fp2,0,0)
Minimum(1,PA_3,fp2,0,0)
Minimum(1,VR_3,fp2,0,0)
Minimum(1,VWC_4,fp2,0,0)
Minimum(1,EC_4,fp2,0,0)
Minimum(1,T_4,fp2,0,0)
Minimum(1,P_4,fp2,0,0)
Minimum(1,PA_4,fp2,0,0)
Minimum(1,VR_4,fp2,0,0)
StdDev(1,VWC,FP2,0)
StdDev(1,EC,FP2,0)
StdDev(1,T,FP2,0)
StdDev(1,P,FP2,0)
StdDev(1,PA,FP2,0)
StdDev(1,VR,FP2,0)
StdDev(1,VWC_2,FP2,0)
StdDev(1,EC_2,FP2,0)
StdDev(1,T_2,FP2,0)
StdDev(1,P_2,FP2,0)
StdDev(1,PA_2,FP2,0)
StdDev(1,VR_2,FP2,0)
StdDev(1,VWC_3,FP2,0)
StdDev(1,EC_3,fp2,0)
StdDev(1,T_3,fp2,0)
StdDev(1,P_3,fp2,0)
StdDev(1,PA_3,fp2,0)
StdDev(1,VR_3,fp2,0)
StdDev(1,VWC_4,fp2,0)
StdDev(1,EC_4,fp2,0)
StdDev(1,T_4,fp2,0)
StdDev(1,P_4,fp2,0)
StdDev(1,PA_4,fp2,0)
StdDev(1,VR_4,fp2,0)
Sample(1,fine,String)
TableFile("USB:ovest60",8,-1,24,60,min,new_ovest60,0)
EndTable

DataTable(ovest24,True,-1)
DataInterval(15,1440,Min,10)
Minimum(1,BattV,FP2,False,False)
Maximum(1,PTemp_C,FP2,False,False)
Minimum(1,PTemp_C,FP2,False,False)
Average(1,PTemp_C,FP2,False)
Maximum(1,AirTC,FP2,False,False)
Minimum(1,AirTC,FP2,False,False)
Average(1,AirTC,FP2,False)
StdDev(1,AirTC,FP2,False)
Maximum(1,RH,FP2,False,False)
Minimum(1,RH,FP2,False,False)
Average(1,RH,FP2,False)
StdDev(1,RH,FP2,False)
Sample(1,VWC,FP2)
Sample(1,EC,FP2)
Sample(1,T,FP2)
Sample(1,P,FP2)
Sample(1,PA,FP2)
Sample(1,VR,FP2)
Sample(1,VWC_2,FP2)
Sample(1,EC_2,FP2)
Sample(1,T_2,FP2)
Sample(1,P_2,FP2)
Sample(1,PA_2,FP2)
Sample(1,VR_2,FP2)
Sample(1,VWC_3,FP2)
Sample(1,EC_3,FP2)
Sample(1,T_3,FP2)
Sample(1,P_3,FP2)
Sample(1,PA_3,FP2)
Sample(1,VR_3,FP2)
Sample(1,VWC_4,FP2)
Sample(1,EC_4,FP2)
Sample(1,T_4,FP2)
Sample(1,P_4,FP2)
Sample(1,PA_4,FP2)
Sample(1,VR_4,FP2)
Average(1,VWC,FP2,0)
Average(1,EC,FP2,0)
Average(1,T,FP2,0)
Average(1,P,FP2,0)
Average(1,PA,FP2,0)
Average(1,VR,FP2,0)
Average(1,VWC_2,FP2,0)
Average(1,EC_2,FP2,0)
Average(1,T_2,FP2,0)
Average(1,P_2,FP2,0)
Average(1,PA_2,FP2,0)
Average(1,VR_2,FP2,0)
Average(1,VWC_3,FP2,0)
Average(1,EC_3,fp2,0)
Average(1,T_3,fp2,0)
Average(1,P_3,fp2,0)
Average(1,PA_3,fp2,0)
Average(1,VR_3,fp2,0)
Average(1,VWC_4,fp2,0)
Average(1,EC_4,fp2,0)
Average(1,T_4,fp2,0)
Average(1,P_4,fp2,0)
Average(1,PA_4,fp2,0)
Average(1,VR_4,fp2,0)
Maximum(1,VWC,FP2,0,0)
Maximum(1,EC,fp2,0,0)
Maximum(1,T,fp2,0,0)
Maximum(1,P,fp2,0,0)
Maximum(1,PA,fp2,0,0)
Maximum(1,VR,fp2,0,0)
Maximum(1,VWC_2,fp2,0,0)
Maximum(1,EC_2,fp2,0,0)
Maximum(1,T_2,fp2,0,0)
Maximum(1,P_2,fp2,0,0)
Maximum(1,PA_2,fp2,0,0)
Maximum(1,VR_2,fp2,0,0)
Maximum(1,VWC_3,fp2,0,0)
Maximum(1,EC_3,fp2,0,0)
Maximum(1,T_3,fp2,0,0)
Maximum(1,P_3,fp2,0,0)
Maximum(1,PA_3,fp2,0,0)
Maximum(1,VR_3,fp2,0,0)
Maximum(1,VWC_4,fp2,0,0)
Maximum(1,EC_4,fp2,0,0)
Maximum(1,T_4,fp2,0,0)
Maximum(1,P_4,fp2,0,0)
Maximum(1,PA_4,fp2,0,0)
Maximum(1,VR_4,fp2,0,0)
Minimum(1,VWC,FP2,0,0)
Minimum(1,EC,fp2,0,0)
Minimum(1,T,fp2,0,0)
Minimum(1,P,fp2,0,0)
Minimum(1,PA,fp2,0,0)
Minimum(1,VR,fp2,0,0)
Minimum(1,VWC_2,fp2,0,0)
Minimum(1,EC_2,fp2,0,0)
Minimum(1,T_2,fp2,0,0)
Minimum(1,P_2,fp2,0,0)
Minimum(1,PA_2,fp2,0,0)
Minimum(1,VR_2,fp2,0,0)
Minimum(1,VWC_3,fp2,0,0)
Minimum(1,EC_3,fp2,0,0)
Minimum(1,T_3,fp2,0,0)
Minimum(1,P_3,fp2,0,0)
Minimum(1,PA_3,fp2,0,0)
Minimum(1,VR_3,fp2,0,0)
Minimum(1,VWC_4,fp2,0,0)
Minimum(1,EC_4,fp2,0,0)
Minimum(1,T_4,fp2,0,0)
Minimum(1,P_4,fp2,0,0)
Minimum(1,PA_4,fp2,0,0)
Minimum(1,VR_4,fp2,0,0)
StdDev(1,VWC,FP2,0)
StdDev(1,EC,FP2,0)
StdDev(1,T,FP2,0)
StdDev(1,P,FP2,0)
StdDev(1,PA,FP2,0)
StdDev(1,VR,FP2,0)
StdDev(1,VWC_2,FP2,0)
StdDev(1,EC_2,FP2,0)
StdDev(1,T_2,FP2,0)
StdDev(1,P_2,FP2,0)
StdDev(1,PA_2,FP2,0)
StdDev(1,VR_2,FP2,0)
StdDev(1,VWC_3,FP2,0)
StdDev(1,EC_3,fp2,0)
StdDev(1,T_3,fp2,0)
StdDev(1,P_3,fp2,0)
StdDev(1,PA_3,fp2,0)
StdDev(1,VR_3,fp2,0)
StdDev(1,VWC_4,fp2,0)
StdDev(1,EC_4,fp2,0)
StdDev(1,T_4,fp2,0)
StdDev(1,P_4,fp2,0)
StdDev(1,PA_4,fp2,0)
StdDev(1,VR_4,fp2,0)
Sample(1,fine,String)
TableFile("USB:ovest24",8,-1,24,1440,min,new_ovest24,0)
EndTable

BeginProg
SetSetting ("pppinterface",comrs232)
SetSetting ("pppDialResponse","CONNECT")
SetSetting ("pppdial","atd*99#")
APN="ibox.tim.it"
IPAddress="xxxxxxxxxxxxxxxxxxxx"
UserName="xxxxxxxxxxxxxxxxxxx"
Password="xxxxxxxxxxxxxxxxxxxx"
dir_est="/Torricchio/Master-PK1/"
dir_centro="/Torricchio/Remoto-PK2/"
dir_ovest="/Torricchio/Remoto-PK3/"
' sito="centro"
' sito="EST"
' sito="OVEST"
Path_centro60="vuoto" ' x new file every reset
Path_est60="vuoto"
Path_ovest60="vuoto"
Path_centro24="vuoto"
Path_est24="vuoto"
Path_ovest24="vuoto"
ancora_wifi=false
PortSet (4,0)'wifi ON
SerialOpen (com1,57600,0,0,10000)'wifi radiomodem
SerialOpen (ComRS232,9600,0,0,10000)' gsm/gprs modem
PPPOpen '
SW12(1)' modem gsm/gprs and CS655 ON

'*********************** start
Scan(60,Sec,1,0)
SW12(1)' modem gsm/gprs and CS655 ON
If IfTime (0,60,min) Then PortSet (4,0 )' wifi radiomodem ON
If IfTime (27,60,min) Then
PPPOpen
ppp=TRUE
EndIf
If IfTime (1,60,min) Then
batt_pk2=999' to understand if the remote writes
batt_pk3=999
EndIf
RealTime (rTime)
If IfTime (5,60,min) Then ClockReport (com1,0,4095)'x pk2 clock
If IfTime (15,60,min) Then ClockReport (com1,0,4095)'x pk3 clock

' x build the file name
If DOM <10 Then
dom_gg="0"+DOM
Else
dom_gg=DOM
EndIf
If Month <10 Then
month_MM="0"+Month
Else
month_MM=Month
EndIf
If DOM <10 Then
dom_ggh="0"+DOM
Else
dom_ggh=DOM
EndIf
If Month <10 Then
month_MMh="0"+Month
Else
month_MMh=Month
EndIf
Battery(BattV)
PanelTemp(PTemp_C,_50Hz)
SDI12Recorder(TRHData(),3,"1","M!",1,0)
CallTable est60
CallTable est24

'time windows wifi pk2 1..10 min
'time windows pk3 11..20 min
'get data from remote pk2 e pk3
' min 5 di 10 sync time
' min 2 di 10 1a request dati60 1st attempt
' min 3 di 10 2a request dati60 2nd attempt
' min 4 di 10 3a request dati60 3rd attempt
' min 1 di 10 1a request dati1440 1st attempt
' min 6 di 10 2a request dati1440 2nd attempt
' min 7 di 10 3a request dati1440 3rd attempt
' min 8 di 10 request clock
' min 9 di 10 request batt volt

'get data from PK2
If IfTime (2,60,min) Then
GetDataRecord (result_pk2,COM1,0,2,0000,75,3,32769,centro60,6)
EndIf
If result_pk2 <> 0 Then
If IfTime (3,60,min) Then
GetDataRecord (result_pk2,COM1,0,2,0000,200,1,32769,centro60,6)
EndIf
EndIf
' If result_pk2 <> 0 Then ' third attempt, eliminated to seve time
' If IfTime (4,60,min) Then
' GetDataRecord (result_pk2,COM1,0,2,0000,250,1,32769,centro60,6)
' EndIf
' EndIf
If IfTime (1,1440,min) Then
GetDataRecord (result_pk224,COM1,0,2,0000,75,3,32770,centro24,3)
EndIf

If IfTime (6,1440,min) Then
If result_pk224 <> 0 Then
GetDataRecord (result_pk224,COM1,0,2,0000,200,1,32770,centro24,3)
EndIf
EndIf
' If IfTime (7,1440,min) Then ' third attempt, eliminated to seve time
' If result_pk224 <> 0 Then
' GetDataRecord (result_pk224,COM1,0,2,0000,250,1,32770,centro24,3)
' EndIf
' EndIf

'get data from PK3
If IfTime (12,60,min) Then
GetDataRecord (result_pk3,COM1,0,3,0000,75,3,32769,ovest60,6)
EndIf
If result_pk3 <> 0 Then
If IfTime (13,60,min) Then
GetDataRecord (result_pk3,COM1,0,3,0000,200,1,32769,ovest60,6)
EndIf
EndIf
' If result_pk3 <> 0 Then ' third attempt, eliminated to seve time
' If IfTime (14,60,min) Then
' GetDataRecord (result_pk3,COM1,0,3,0000,250,1,32769,ovest60,6)
' EndIf
' EndIf

If IfTime (15,1440,min) Then
GetDataRecord (result_pk324,COM1,0,3,0000,75,3,32770,ovest24,3)
EndIf

If IfTime (16,1440,min) Then
If result_pk324 <> 0 Then
GetDataRecord (result_pk324,COM1,0,3,0000,200,1,32770,ovest24,3)
EndIf
EndIf
' If IfTime (17,1440,min) Then ' third attempt, eliminated to seve time
' If result_pk324 <> 0 Then
' GetDataRecord (result_pk324,COM1,0,3,0000,250,1,32770,ovest24,3)
' EndIf
' EndIf

' If IfTime (54,60,min) Then
' PPPClose
' ppp=false
' EndIf

If IfTime (0,60,min) Then ancora_wifi=false ' time window extension WIFI x connection with local PC, if necessary
If ancora_wifi = false Then
If IfTime (24,60,min) Then PortSet (4,1)'wifi off
EndIf

' new files name after reset
If Path_centro60="vuoto" Then
Path_centro60=dir_centro+"centro_"+Year+month_MM+dom_gg+".dat"
EndIf
If Path_est60="vuoto" Then
Path_est60=dir_est+"est_"+Year+month_MM+dom_gg+".dat"
EndIf
If Path_ovest60="vuoto" Then
Path_ovest60=dir_ovest+"ovest_"+Year+month_MM+dom_gg+".dat"
EndIf
If Path_centro24="vuoto" Then
Path_centro24=dir_centro+"centro_gg_"+Year+month_MM+dom_gg+".dat"
EndIf
If Path_est24="vuoto" Then
Path_est24=dir_est+"est_gg_"+Year+month_MM+dom_gg+".dat"
EndIf
If Path_ovest24="vuoto" Then
Path_ovest24=dir_ovest+"ovest_gg_"+Year+month_MM+dom_gg+".dat"
EndIf

'enabling ftp sending
If IfTime(30,60,min) Then sendftp_e60=true
If IfTime(33,60,min) Then sendftp_c60=true
If IfTime(36,60,min) Then sendftp_o60=true
If IfTime(39,1440,min) Then sendftp_e24=true
If IfTime(42,1440,min) Then sendftp_c24=true
If IfTime(45,1440,min) Then sendftp_o24=true

' ftp send
If sendftp_e60=true Then
invio_ftp_e60=FTPClient (IPAddress,UserName,Password,"est60",Path_est60,9,1,0,min,-1008)
tent_e60=tent_e60+1
If invio_ftp_e60=true Then
sendftp_e60=false
tent_e60=0
EndIf
EndIf
If sendftp_c60=true Then
invio_ftp_c60=FTPClient (IPAddress,UserName,Password,"centro60",Path_centro60,9,1,0,min,-1008)
tent_c60=tent_c60+1
If invio_ftp_c60=true Then
sendftp_c60=false
tent_c60=0
EndIf
EndIf

If sendftp_o60=true Then
invio_ftp_o60=FTPClient (IPAddress,UserName,Password,"ovest60",Path_ovest60,9,1,0,min,-1008)
tent_o60=tent_o60+1
If invio_ftp_o60=true Then
sendftp_o60=false
tent_o60=0
EndIf
EndIf
If sendftp_e24=true Then
invio_ftp_e24=FTPClient (IPAddress,UserName,Password,"est24",Path_est24,9,1,0,min,-1008)
tent_e24=tent_e24+1
If invio_ftp_e24=true Then
sendftp_e24=false
tent_e24=0
EndIf
EndIf
If sendftp_c24=true Then
invio_ftp_c24=FTPClient (IPAddress,UserName,Password,"centro24",Path_centro24,9,1,0,min,-1008)
tent_c24=tent_c24+1
If invio_ftp_c24=true Then
sendftp_c24=false
tent_c24=0
EndIf
EndIf
If sendftp_o24=true Then
invio_ftp_o24=FTPClient (IPAddress,UserName,Password,"ovest24",Path_ovest24,9,1,0,min,-1008)
tent_o24=tent_o24+1
If invio_ftp_o24=true Then
sendftp_o24=false
tent_o24=0
EndIf
EndIf

If IfTime(57,60,min) Then ' stop if PPP is off
sendftp_e60=false
sendftp_c60=false
sendftp_o60=false
EndIf
If IfTime(57,1440,min) Then
sendftp_e24=false
sendftp_c24=false
sendftp_o24=false
EndIf
If IfTime (57,60,min) Then
SW12(0)  ' modem gsm/gprs and CS655 OFF
PPPClose
ppp=false
SerialFlush(com1)  'clear serial buffer for WIFI radiomodem
EndIf

NextScan
SlowSequence
Scan (300,Sec,0,0)' slow measurements in the soil
SDI12Recorder(CS65X(),3,"0","M3!",1,0)
SDI12Recorder(CS65X_2(),3,"2","M3!",1,0)
SDI12Recorder(CS65X_3(),3,"3","M3!",1,0)
SDI12Recorder(CS65X_4(),3,"8","M3!",1,0)
If IfTime (0,1440,min) Then Calibrate ' run once a day to eliminate errors and gain time

NextScan
EndProg

Sorry  if all is not clear

at the moment I have no other status data, I will return in a few days to the station and download the other information requested.

status:

10/08/2018 13:16:37\par\par
Datalogger Information\par
\b0\fs16 Reported Station Name: 38915\par
OS Version: CR800.Std.32.02\par
OS Date: 12/12/2017\par
OS Signature: 40776\par
Panel Temperature: 26,68 \f1\'b0C\par
\f0 Memory: 4194304 bytes\par
Watchdog Errors: 0\par\par\b \par
\fs20 Program Information\par
\b0\fs16 Current Program: CPU:est-pk1_V20apr18.CR8\par
Start Time: 20/04/2018 08:21:21\par
Run Signature: 11396\par
Program Signature: 50703\par
Results for Last Program Compiled: CPU:est-pk1_V20apr18.CR8 -- Compiled in SequentialMode.\par
Memory Free: 35264 bytes\par\par
\b Program Errors\par
\b0 Program Errors: 0\par
\cf1 Skipped Scans: 2637 - The main scan interval or number of scan buffers may need to be increased.\cf0 \par
Skipped Slow Scans: 0\par
\cf1 Skipped System Scans: 43142\cf0 \par
Skipped Records in est60: 0\par
Skipped Records in est24: 0\par
Skipped Records in centro60: 0\par
Skipped Records in centro24: 0\par
Skipped Records in ovest60: 0\par
Skipped Records in ovest24: 0\par
Variable Out of Bounds: 0\par\par
\b\fs20 Battery Information\par
\b0\fs16 Battery Voltage: 13,78\par
Lithium Battery: 3,44\par
Number of times the datalogger's 12V supply has dropped below operating threshold: 0\par
Number of times voltage has dropped below 5V: 0\par

another programming error, less important now, is that in SC115 I find only data of PK1.

Pk2 and PK3 are not written.

I must also understand why there are only a few days of data in the memory of the logger. There are many months in the PK2 and PK3 loggers!

Regards

Smile


smile Aug 23, 2018 10:18 AM

Hi

I understood and solved the other issues.

It is useful to understand why if I ask to run Calibrate once a day, with:

If IfTime (0,1440,min) Then Calibrate

in the slowscan, I still have a lot of system errors in the day.

Thank you

smile

Log in or register to post/reply in the forum.