1994 1995 1996 1997 1998 1999 2000 2001 2002 <2003> 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 | Index | 1994 1995 1996 1997 1998 1999 2000 2001 2002 <2003> 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 |
<== Date ==> | <== Thread ==> |
---|
Subject: | RE: stale data monitor |
From: | "Redman, Russell O." <[email protected]> |
To: | "'Vladimir Sirotenko'" <[email protected]>, [email protected] |
Date: | Wed, 10 Sep 2003 13:58:59 -0700 |
One
possible way would be to construct a delay line of ai records, say delay0,
delay1 and delay2, and a calc record. Set their input
links
delay0.INP =
(hardware) delay1.INP = delay0 NPP
delay2.INP = delay1 NPP
calc.INPA = delay0 NPP
calc.INPB = delay1 NPP
calc.INPC = delay2 NPP
and
their forward links
delay0.FLNK = calc delay1.FLNK = delay0
delay2.FLNK = delay1
Processing starts with delay2 which gets its new value from the current
value of delay1, then causes delay1 to process. Delay1 gets its new value
from the current value of delay0, then causes delay0 to process. Delay0
gets its new value from the hardware, then causes the calc record to process and
compare the three values. Initializing the chain might be a bit of a
chore, however.
If you
need to do this in more than one place, this purely EPICS solution is not likely
to be the best solution. It is a bit more of a fuss to configure, but it
would probably be easier in the long run to write a few lines of C code to put
into a subr or gensub record.
Cheers, Dr. Russell O. Redman
|