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
Tel: (250) 363-6917 | Fax: (250) 363-0045
< mailto:[email protected]
<mailto:[email protected]> >
National Research Council Canada | Conseil national de
recherches Canada
5071 West Saanich Road | 5071 West Saanich Road
Victoria, B. C. V9E 2E7 | Victoria, C.-B. V9E
2E7
Government of Canada | Gouvernement du Canada
-----Original Message-----
From: Vladimir Sirotenko [mailto:[email protected]]
Sent: Wednesday, 2003 September 10 12:24 PM
To: [email protected]
Subject: stale data monitor
Hi,
Is there easy and natural way to monitor stale data from,
say, ai record
just using EPICS records? For example, I have to send
alarm when several
consecutive reading return the same value. The time
interval for those
consecutive reading may be rather large, of the order of
minutes. If it
would be shorter, I could use seq record with delays, but
for several
minutes interval how can I trigger its processing?
Thanks,
Vladimir