g+
g+ Communities
Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  <20052006  2007  2008  2009  2010  2011  2012  2013  2014  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  <20052006  2007  2008  2009  2010  2011  2012  2013  2014 
<== Date ==> <== Thread ==>

Subject: CA links and EPICS Records user routines
From: Andy Foster <ajf@observatorysciences.co.uk>
To: Epics Questions <tech-talk@aps.anl.gov>
Date: Thu, 13 Jan 2005 17:12:41 +0000 (GMT)
Dear All,

This is just an observation about a change in the behaviour of
those EPICS records which can have a user routine associated with
them (i.e. through the SNAM field). In particluar, I have in mind
the sub and genSub records.

Prior to 3.13.8, the user routine was always called, regardless of
whether any CA input link was connected or not. This changed
at 3.13.8 because "dbGetLink" started returning -1 if a link
was disconnected. And, hence, in that case, the user routine never
gets called. And consequently, the output links never fire off
or get updated.

We may be alone in this, but for our telescope systems, we have
a few instances where we have an input CA link to a genSub
and the status of the connection (or the ALARM severity of the
record, if propagated with MS), is used within the user routine
itself to determine what values to use in the calculation.
If the connection is good, it pulls in the real values, if it
is bad, it uses some simulated values or something else. This
design breaks now because the user routine never gets called.
I say value(s) because often it is an array we are dealing with.

I'm sure there are ways around this by using an intervening record
to link to the outside world and so convert all the genSub links
into local DB links but one thing I thought of doing was adding an extra
field to the genSub which could take two values:

OLD meaning ignore the return status for disconnected links
    and call the user routine anyway (and to help support this
    it would nice be if "dbGetLink" returned a different error number
    for a disconnected link than it does for other types of error)

or

NEW behave as 3.13.8 onwards

(The default for the field would be NEW)

I'm just interested to know if this change in behaviour, at 3.13.8,
has affected anyone else besides us! Of course, I'm only
talking about changing the genSub record above, since it is outside of
"base". The change, at 3.13.8, still affects the sub record.

I would be very interested to hear any comments.

Best wishes,

Andy

--------------------------------------------------------------------
Observatory Sciences Limited    Email: ajf@observatorysciences.co.uk
William James House             Tel: 44 - (0)1223 - 508259
Cowley Road                     Fax: 44 - (0)1223 - 508258
Cambridge, CB4 0WX, UK          http://www.observatorysciences.co.uk


Replies:
Re: CA links and EPICS Records user routines Ralph Lange

Navigate by Date:
Prev: Re: PV gateway Ralph Lange
Next: RE:counting semaphore for 3.14.x Kate Feng
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  <20052006  2007  2008  2009  2010  2011  2012  2013  2014 
Navigate by Thread:
Prev: Re: PV gateway Ralph Lange
Next: Re: CA links and EPICS Records user routines Ralph Lange
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  <20052006  2007  2008  2009  2010  2011  2012  2013  2014 
ANJ, 02 Sep 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICSv4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·