g+
g+ Communities
Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  <20002001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  Index 1994  1995  1996  1997  1998  1999  <20002001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014 
<== Date ==> <== Thread ==>

Subject: Delay of Maximize Severity in OUT Links
From: Benjamin Franksen <franksen@mail.bessy.de>
To: EPICS Techtalk <tech-talk@aps.anl.gov>
Date: Tue, 04 Jan 2000 17:18:49 +0100
Hello,

while testing the latest changes to the mbboDirect record, I noticed the
following, which seems to be a general problem.

Imagine two (or more) output records with soft support. They are chained
by their OUT links pointing to some field of the next record. The links
are PP and MS.

Now, if the severity of the first record changes during processing, this
change is NOT forwarded to the next record until it is processed the
next time. Instead the old severity is used. If the first record is a bo
with two state dependend severities, and if this record is always
alternating between one and zero, the second record will ALWAYS have the
wrong severity, namely the one from the last processing, not the
current.

The reason is that the record support code of most record types calls
recGblResetAlarms after calling the device support's write function. The
latter will call dbPutLink if it is a soft support. But when dbPutLink
sees the MS flag on, it sets the severity of the target record to the
source records's SEVR, which have not yet been updated (recGblSetSevr
sets only NSEV and NSTA). Only when the source record calls
recGblResetAlarms will STAT/SEVR be set to NSTA/NSEV, but then
processing of the target record is long over.

As a solution one could change dbPutLinkValue to use NSEV instead of
SEVR of the source record, i.e. change line 827 in dbAccess.c from

	recGblSetSevr(pdest,LINK_ALARM,psource->sevr);

to 

	recGblSetSevr(pdest,LINK_ALARM,psource->nsev);

How about that? Will this break other code?

BTW: The problem does not exist with input links because, if the input
link is PP and MS, the source record will have been processed completely
before dbGetLink evaluates the source record's STAT.

Ben
-- 
The Notorious Neb Nesknarf


Replies:
Re: Delay of Maximize Severity in OUT Links Marty Kraimer

Navigate by Date:
Prev: dbNameToAddr... Mythili Srinivasan
Next: Re: Delay of Maximize Severity in OUT Links Marty Kraimer
Index: 1994  1995  1996  1997  1998  1999  <20002001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014 
Navigate by Thread:
Prev: dbNameToAddr... Mythili Srinivasan
Next: Re: Delay of Maximize Severity in OUT Links Marty Kraimer
Index: 1994  1995  1996  1997  1998  1999  <20002001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014 
ANJ, 10 Aug 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICSv4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·