g+
g+ Communities
Argonne National Laboratory

Experimental Physics and
Industrial Control System

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

Subject: Re: acalcOut
From: Tim Mooney <mooney@aps.anl.gov>
To: Pavel Maslov <pavel.masloff@gmail.com>
Cc: EPICS Tech Talk <tech-talk@aps.anl.gov>
Date: Thu, 10 Jan 2013 11:28:52 -0600 (CST)
Hi Pavel,

What is the value of the NUSE field?  Most of the acalcout record uses NELM for the number of active array elements if NUSE==0,
but the array posting code neglects to do this.  If NUSE==0, AVAL won't be posted.  This will be fixed in 3.2.

For completeness, the acalcout record posts AVAL if any array element (in the range [0..NUSE-1]) has a different value than it had the last time AVAL was posted.  AVAL is always posted with the attributes DBE_VALUE and DBE_LOG.  (MDEL and ADEL do not affect array posting in the acalcout record.  They are used only to decide whether the VAL field should be posted, and if so with what attributes.)


Tim


From: "Pavel Maslov" <pavel.masloff@gmail.com>
To: "Yong Hu" <yhu@bnl.gov>
Cc: "EPICS Tech Talk" <tech-talk@aps.anl.gov>
Sent: Thursday, January 10, 2013 10:02:11 AM
Subject: Re: acalcOut

Hi Yong,

You are right! $(P)$(R)WF1 does get processed. And I do see the waveform on the chart (.AVAL field), it is not updated on the chart . Rather, I have to manually update the OPI hitting F5. The wf1 record is a waveform record and strangely enough it gets updated on the XY plot. I just thought it's the AVAL field of the aCalcOut record that has no monitors.

>> Does it mean: evaluate the _expression_ CC*5/128*A-B, store the result in the input array AA, and set the AVAL field to AA?
Yes.




On Thu, Jan 10, 2013 at 7:02 PM, Hu, Yong <yhu@bnl.gov> wrote:

Hi Pavel,

 

Firstly, we can’t see how the record "$(P)$(R)WF1 gets processed. Is there any forward link to this record? for instance,  

 

record(… ,  "$(P)$(R)wf1") {

field(FLNK, "$(P)$(R)WF1")

}

 

If no, you may add CP or CPP in INPA, INPB, INCC,  such as field(INCC, "$(P)$(R)wf1 CP").

 

Secondly, you may set "$(P)$(R)WF1.MDEL to -1, which means the monitor is triggered whenever the record is scanned. Then, camonitor “"$(P)$(R)WF1”. But I’m not sure if this works for the acalcout record.

 

Lastly, I’m not quite sure if you used the "Store" operator correctly for "AA:=CC*5/128*A-B;AA". Does it mean: evaluate the _expression_ CC*5/128*A-B, store the result in the input array AA, and set the AVAL field to AA?

 

Yong

 

 

From: tech-talk-bounces@aps.anl.gov [mailto:tech-talk-bounces@aps.anl.gov] On Behalf Of Pavel Maslov
Sent: Thursday, January 10, 2013 2:05 AM
To: EPICS Tech Talk
Subject: acalcOut

 

Hello,

 

I am experiencing some difficulties with this record type. 

 

record(acalcout, "$(P)$(R)WF1") {

  field(NELM, "2500")

  field(INPA, "$(P)$(R)setY1:RBV")

  field(INPB, "$(P)$(R)ch1pos:RBV")

  field(INCC, "$(P)$(R)wf1")

  field(CALC, "AA:=CC*5/128*A-B;AA")

}

 

I would like to plot an array in CSS 3.1.4. So I'm using an XY graph widget with the Y PV parameter pointed to $(P)$(R)WF1.AVAL.

However it does not put a monitor on the AVAL field. So the plot is not being updated every time the calculation is made.

 

Any suggestions will be much appreciated.

 

--
Best regards,


Pavel Maslov, MS
Controls Engineer at Pulsed power Lab
Efremov Institute for Electro-Physical Apparatus
St. Petersburg, Russia

Mobile: +7 (951) 672 22 19
Landline: +7 (812) 461 01 01




--
Best regards,


Pavel Maslov, MS
Controls Engineer at Pulsed power Lab
Efremov Institute for Electro-Physical Apparatus
St. Petersburg, Russia

Mobile: +7 (951) 672 22 19
Landline: +7 (812) 461 01 01



--
Tim Mooney (mooney@aps.anl.gov) (630)252-5417
Software Services Group (www.aps.anl.gov)
Advanced Photon Source, Argonne National Lab


References:
Re: acalcOut Pavel Maslov

Navigate by Date:
Prev: Re: duplicating process variables James F Ross
Next: Re: medm build keith . thorne
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  <2013
Navigate by Thread:
Prev: Re: acalcOut Pavel Maslov
Next: routing Pavel Maslov
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  <2013
ANJ, 10 Jan 2013 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· EPICSv4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·