Hello,
I have written a PV server using P4P based on the lazycounter_server_cothread.py example in the P4P repository. It uses NTScalars with the valueAlarm option set to True. I am able to set valueAlarm fields through both the program and pvput commands and then see the results with pvget:
$ pvget -vv DAQ:NEH:tst:3:test_pv
DAQ:NEH:tst:3:test_pv epics:nt/NTScalar:1.0
uint value 2
alarm_t alarm
int severity 0
int status 0
string message
time_t timeStamp 2023-12-08 10:04:59.245
long secondsPastEpoch 1702058699
int nanoseconds 244999885
int userTag 0
structure valueAlarm
boolean active true
uint lowAlarmLimit 2
uint lowWarningLimit 0
uint highWarningLimit 0
uint highAlarmLimit 4
int lowAlarmSeverity 3
int lowWarningSeverity 0
int highWarningSeverity 0
int highAlarmSeverity 3
double hysteresis 0
However, I don’t see the alarm structure’s fields changing (although I’m not sure what to expect). Where should the alarm evaluation occur?
I found this comment in the Normative-Types-Specification page:
Code that checks for alarms should use code similar to the following:
followed by some C code showing how to do the alarm evaluation (without hysteresis) and raising. Is it the intention that similar code should be in the application layer of my PV server, rather than in some common lower layer? If so, how should this be done since I haven’t found the equivalent of some of these routines in P4P?
Thank you for any guidance you can give me!
Ric Claus
SLAC/LCLS
- Replies:
- Re: Fwd: Raising alarms with P4P Michael Davidsaver via Tech-talk
- Navigate by Date:
- Prev:
Re: Simulated limit switches on motorSim motor Torsten Bögershausen via Tech-talk
- Next:
Re: Fwd: Raising alarms with P4P Michael Davidsaver via Tech-talk
- 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
- Navigate by Thread:
- Prev:
Re: EPICS Event Scan Field causes EDM PV readback to not update in Text Entry widget Johnson, Andrew N. via Tech-talk
- Next:
Re: Fwd: Raising alarms with P4P Michael Davidsaver via Tech-talk
- 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
|