164
TimingdiagramB:FunctionwithpositivedifferenceDelta
Descriptionofthefunction
ThefunctionfetchestheanalogsignalatinputAx.
AxismultipliedbythevalueoftheA(gain)parameter,andthevalueatparameterB(offset)isaddedto
product,i.e.
(Ax ∙ gain)+offset=actualvalueofAx.
OutputQissetorreset,dependingontheset(On)thresholdanddifferencevalue(Delta).Thefunction
automaticallycalculatestheOffparameter:Off=On+Delta,wherebyDeltamaybepositiveornegative.
Seethecalculationrulebelow.
Calculationrule
WhenyousetanegativedifferentialvalueDelta,theOnthreshold>=Offthreshold,and:
Q=1,iftheactualvalueAx>On
Q=0,iftheactualvalueAx ≤ Off.
SeethetimingdiagramA.
WhenyousetapositivedifferentialvalueDelta,theOnthreshold<theOffthreshold,andQ=1,if:
On ≤ theactualvalueAx<Off.
SeethetimingdiagramB.
SettingtheParparameter
Thegainandoffsetparametersareusedtoadaptthesensorstotherelevantapplication.
Viewinprogrammingmode(example):