Hi Roger,
The precision is sufficient for our application,which is to trigger a water sampler at a nominal discharge and I've tried the same equation in excel and on a Campbell data logger and get the correct results.
I'm using a calibrated fluke loop calibrator so simulate the output from the level device (4-20mA). The input is scaled into mm and this is recording correctly, the polynomial Y11 is then applied to the scaled input but the result is clearly incorrect.
Here is the full code that I'm using:
' stage 1 - reset actions
H
CLEAR
\W1
RESET
\W4
/e
' stage 2 - switches, parameters
/H
/e /R
/S
P14=600 P17=120 P26=30
99CV(W)=98989
P30=6
P36=0
' stage 3 - Date, Time
D=\d
T=\t
' stage 4 - start of job
' Set up span for conversion of 4 to 20 mA output from Ultrasonic and polynomial for flow calculation
S1=0,750,4,20"mm" ' Working range of flume = 0mm to 750mm
Y11=0,0.36375,0.00096516"L/Sec"
' stage 5 - user entered commands
' stage 6 - immediate schedule initialisation
' Initialise storage variables
1CV("Sampling Threshold ",W)=1
2CV("Catchment Area (m2)",W)=1381000
3DSO=0
$="NVZ111.cmd"
' stage 7 - schedule list
BEGIN
RA15S HA '15 minute schedule
1DSO=1 'Turn on ultrasonic
7SV=15000 5
7SV=10
1DSO=0 'Turn off ultrasonic
6CV(W)=(6CV(6CV<600))
7CV(W)=(6CV(6CV>1)) 'Ignore stage height less than 1.0 mm
7CV("Flow (l/sec)",Y11,=11CV) 'Calculate and log flow
12CV("Discharge (litres)")=12CV+11CV*900 'Calculate and log Discharge
13CV("Discharge ")=12CV/2CV 'Calculate and log Discharge in mm
2+V("Battery",U,0.013) 'Read and log battery voltage
2HSC("Cum Rain")
P15=1
RZ15S HZ 'Alarms
IF1(13CV>1CV)"[2DSO=1 7SV=500 5#I(W) 2DSO=0 7SV=10 12CV(W)=0 14CV=14CV+1]"
END
' stage 8 - logging options
/O
LOGON
' stage 9 - post schedule options
' stage 10 - run commands
G
/q
The results are fully repeatable on several different DT50s
Hi Roger,
The precision is sufficient for our application,which is to trigger a water sampler at a nominal discharge and I've tried the same equation in excel and on a Campbell data logger and get the correct results.
I'm using a calibrated fluke loop calibrator so simulate the output from the level device (4-20mA). The input is scaled into mm and this is recording correctly, the polynomial Y11 is then applied to the scaled input but the result is clearly incorrect.
Here is the full code that I'm using:
' stage 1 - reset actions
H
CLEAR
\W1
RESET
\W4
/e
' stage 2 - switches, parameters
/H
/e /R
/S
P14=600 P17=120 P26=30
99CV(W)=98989
P30=6
P36=0
' stage 3 - Date, Time
D=\d
T=\t
' stage 4 - start of job
' Set up span for conversion of 4 to 20 mA output from Ultrasonic and polynomial for flow calculation
S1=0,750,4,20"mm" ' Working range of flume = 0mm to 750mm
Y11=0,0.36375,0.00096516"L/Sec"
' stage 5 - user entered commands
' stage 6 - immediate schedule initialisation
' Initialise storage variables
1CV("Sampling Threshold (mm)",W)=1
2CV("Catchment Area (m2)",W)=1381000
3DSO=0
$="NVZ111.cmd"
' stage 7 - schedule list
BEGIN
RA15S HA '15 minute schedule
1DSO=1 'Turn on ultrasonic
7SV=15000 5#I(W) 5#I(W) 1#I("Ultrasonic",S1,=6CV(W)) 'Read output from ultrasonic and apply span
7SV=10
1DSO=0 'Turn off ultrasonic
6CV(W)=(6CV*(6CV<600))
7CV(W)=(6CV*(6CV>1)) 'Ignore stage height less than 1.0 mm
7CV("Flow (l/sec)",Y11,=11CV) 'Calculate and log flow
12CV("Discharge (litres)")=12CV+11CV*900 'Calculate and log Discharge
13CV("Discharge (mm)")=12CV/2CV 'Calculate and log Discharge in mm
2+V("Battery",U,0.013) 'Read and log battery voltage
2HSC("Cum Rain")
P15=1
RZ15S HZ 'Alarms
IF1(13CV>1CV)"[2DSO=1 7SV=500 5#I(W) 2DSO=0 7SV=10 12CV(W)=0 14CV=14CV+1]"
END
' stage 8 - logging options
/O
LOGON
' stage 9 - post schedule options
' stage 10 - run commands
G
/q
The results are fully repeatable on several different DT50s