EPICS Controls 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  2014  2015  2016  2017  2018  2019  2020  2021  2022  <20232024  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  <20232024 
<== Date ==> <== Thread ==>

Subject: Re: [EXTERNAL] phoebus Tank widget: Limits from PV?
From: Jure Varlec via Tech-talk <tech-talk at aps.anl.gov>
To: tech-talk at aps.anl.gov
Date: Fri, 7 Jul 2023 08:31:46 +0200

Hi Kay,

Thanks for explaining this, I've been wondering how CSS handles it. Obviously, not enough to go check for myself, but it had been in the back of my mind for quite a while. Given the lengths both sides of the connection go to in order to support dynamic limits over CA, it seems natural that they would be supported when using PVA. Is this assumption correct? Does it also depend on the versions of software involved?

Thanks,
Jure

On 7/5/23 21:47, Kasemir, Kay via Tech-talk wrote:

Caution: This email originated from outside of Cosylab.

Channel Access has a problem with changing runtime limits.

 

For a double-typed channel, a client could historically subscribe to DBR_TIME_DOUBLE to get timestamp, status, value,

or to DBR_CTRL_DOUBLE which sends all the limits, units, precision, …, and the value, but NOT THE TIME STAMP??!

 

So well-formed clients used to read the DBR_CTRL_DOUBLE once, then subscribe to the DBR_TIME_DOUBLE.

That way the client fetched the large and rarely changing CTRL info once, then only got the more efficient time/status/value updates.

That’s great for 99.76% of all use cases, but when you change the limits at runtime, you don’t see that in the client.

 

For a while there’s now a new DBE_PROPERTY modifier for the subscription that allows you do subscribe to the  DBR_CTRL_DOUBLE data but only get updates when limits and units change. That’s the best of all worlds:
Subscribe to property changes on DBR_CTRL_DOUBLE for the 0.24% use case, plus subscribe to the DBR_TIME_DOUBLE for the 99.76% use case.

.. except: Older IOCs and older gateways don’t support DBE_PROPERTY, so you should only enable that if everybody in your system can handle it.

 

See https://control-system-studio.readthedocs.io/en/latest/preference_properties.html#pv-ca for the org.phoebus.pv.ca/dbe_property_supported setting to enable it.

 

See also https://epics.anl.gov/tech-talk/2016/msg01005.php and  https://epics.anl.gov/tech-talk/2021/msg00030.php

 

-Kay

 

 

From: Paul Sichta <psichta at pppl.gov>
Date: Wednesday, July 5, 2023 at 3:35 PM
To: Kasemir, Kay <kasemirk at ornl.gov>
Cc: tech-talk at aps.anl.gov <tech-talk at aps.anl.gov>
Subject: Re: [EXTERNAL] phoebus Tank widget: Limits from PV?

Kay,

Thanks for those tips.  My database file has LOPR/HOPR as -140/160,  but after the IOC is running the LOPR/HOPR are written with new values, e.g. -100/500.

 

When I use the caget command,  the display limits show -100/500.

When I probe the tank widget (PV)  in phoebus it shows, in the metadata section,  display range of -140/160,  and when I look carefully on the tank widget scale it also shows -140/160  range for the case where I checkbox to use the PV Limits - so the PV Limits checkbox is working, but ....

 

How in the heck does phoebus know what the loaded database limits were,  rather than reading the PV's current values?  Is there a cache where it is read by phoebus one time or upon initial connection?  I tried restarting phoebus but it always thinks the display limits are the loaded database's -140/160.

 

Regards,

-ps

 

 

On Wed, Jul 5, 2023 at 2:31 PM Kasemir, Kay <kasemirk at ornl.gov> wrote:

When I try it with this type of record, tank & meter & progress bar all get the 0..10 range from the record:

 

record(calc, "ramp")

{

   field(SCAN, "1 second")

   field(INPA, "ramp")

   field(CALC, "A<10?A+1:0")

   field(HOPR, "10")

   field(LOPR, "0")

}

 

In “probe” you should also see “Display Range: 0.0 .. 10.0”, and from a command line `caget -d CTRL_DOUBLE ramp` should show the same Lo and Hi disp limit.

 

 

 

From: Tech-talk <tech-talk-bounces at aps.anl.gov> on behalf of Paul Sichta via Tech-talk <tech-talk at aps.anl.gov>
Date: Wednesday, July 5, 2023 at 1:51 PM
To: tech-talk at aps.anl.gov <tech-talk at aps.anl.gov>
Subject: [EXTERNAL] phoebus Tank widget: Limits from PV?

Hello, 

I have used  the checkbox to select "Limits from PV'' which I expected would be taken from  LOPR and HOPR of the PV.  That checkbox seems to make no difference;  the tank's range is always the Minimum and Maximum values used for the widget's properties.  I see the same ignoring of PV limits for the meter and progress bar.

 

I'm using channel access for the PV's ,  and version master 2023-06-28 04:51,  but some earlier versions I have do the same thing.

 

Regards,

-ps

 

 

 


Replies:
Re: [EXTERNAL] phoebus Tank widget: Limits from PV? Kasemir, Kay via Tech-talk
References:
phoebus Tank widget: Limits from PV? Paul Sichta via Tech-talk
Re: [EXTERNAL] phoebus Tank widget: Limits from PV? Kasemir, Kay via Tech-talk
Re: [EXTERNAL] phoebus Tank widget: Limits from PV? Paul Sichta via Tech-talk
Re: [EXTERNAL] phoebus Tank widget: Limits from PV? Kasemir, Kay via Tech-talk

Navigate by Date:
Prev: interrupt read data in int32Driver example timesir via Tech-talk
Next: issue of getTimeStamp from EVR Di Wang 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  <20232024 
Navigate by Thread:
Prev: Re: [EXTERNAL] phoebus Tank widget: Limits from PV? Kasemir, Kay via Tech-talk
Next: Re: [EXTERNAL] phoebus Tank widget: Limits from PV? Kasemir, Kay 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  <20232024 
ANJ, 07 Jul 2023 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·