Experimental Physics and
| |||||||||||||||||
|
If you use the Alarm Handler (ALH) to display your alarms, there is a configuration option that allows you to have an alarm appear only after it occurred for a certain number of times or persisted for a certain time. Look for chapter 6.3.12 or "Alarm Count Filter" in the Alarm Handler User's Guide. If you want to solve this within the database, use Pete's approach, but rather use a calcout record and use the OCAL field (or a second calc record) to write the RAWTEMP value to the final ai, else you will end up showing the counter instead of the temperature. I would separate the time counting from forwarding the value, which also doesn't link the update period of your final TEMPERATURE ai to the time counter resolution. So I would do something like record (ai, "RAWTEMP") { ... field (SCAN, "I/O Intr") field (FLNK, "CALCFORWARD") } record (calc, "CALCFORWARD") { field (CALC, "A") field (INPA, "RAWTEMP NPP MS") field (INPB, "CALCULATION NPP MS") field (FLNK, "TEMPERATURE") } record (calc, "CALCULATION") { field (SCAN, "1 second") field (CALC, "(B>C||B<D)?(A+1):0") field (INPA, "CALCULATION.VAL") field (INPB, "RAWTEMP") field (INPC, "RAWTEMP.HIHI") field (INPD, "RAWTEMP.LOLO") field (HIHI, "60") field (HHSV, "MAJOR") field (FLNK, "CALCFORWARD") } record (ai, "TEMPERATURE") { field (INP, "CALCFORWARD NPP MS") } (Code is not tested and may contain more bugs ...) Hope this helps, Ralph Bernhard Lopez wrote: Hi,
| ||||||||||||||||
ANJ, 02 Sep 2010 |
·
Home
·
News
·
About
·
Base
·
Modules
·
Extensions
·
Distributions
·
Download
·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing · |