19 running average, Crbasic example 61. pt100 in four-wire full-bridge – Campbell Scientific CR1000 Measurement and Control System User Manual
Page 263

Section 7. Installation
263
Figure 81: PT100 in four-wire full-bridge
CRBasic Example 61. PT100 in Four‐Wire Full‐Bridge
'See FIGURE. PT100 in Four-Wire Full-Bridge
(p. 263)
for wiring diagram.
Public
BrFullOut
Public
Rs_Ro
Public
Deg_C
BeginProg
Scan
(1,Sec,0,0)
'BrFull(Dst,Reps,Range,DfChan,Vx1,MPS,Ex,RevEx,RevDf,Settle,Integ,Mult,Offset)
BrFull
(BrFullOut,1,mV25,1,Vx1,1,2500,True,True,0,250,.001,.02344)
'BrTrans = Rf*(X/(1-X))
Rs_Ro = 50 * (BrFullOut/(1 - BrFullOut))
'PRTCalc(Destination,Reps,Source,PRTType,Mult,Offset)
PRTCalc
(Deg_C,1,Rs_Ro,2,1.0,0)
NextScan
EndProg
7.8.19 Running Average
The AvgRun() instruction calculates a running average of a measurement or
calculated value. A running average is the average of the last N values where N is
the number of values, as expressed in figure Running-Average Equation
(p. 263),
Figure 82: Running-average equation