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  2023  <20242025  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  <20242025 
<== Date ==> <== Thread ==>

Subject: Re: Adding additional fields to be archived in "policies.py"
From: Timo Korhonen via Tech-talk <tech-talk at aps.anl.gov>
To: Gerrit Kühn <gerrit.kuehn at aei.mpg.de>, "Michael Davidsaver via Tech-talk" <tech-talk at aps.anl.gov>
Date: Fri, 6 Sep 2024 07:47:19 +0000
Hi Gerrit,


When you retrieve data from the archiver, _each_ sample looks something like this:

[ 
{ "meta": { "name": "ISrc-CS:ISS-HVPS-01:Vol-S" , "EGU": "kV" , "PREC": "2" },
"data": [ 
{ "secs": 1698307344, "val": 0.0, "nanos": 7123291, "severity":0, "status":0 }
] }
 ]

(I used the REST API in a browser to get this sample.)


The timestamp seconds (1698307344) tells that this particular sample was taken at Thursday, 26 October 2023 10:02:24 GMT+02:00 DST, converted to our local time zone. Add the nanoseconds and you get the exact time.

You see the "severity" and "status" values, which in this case were both 0. 

You then of course need the additional metadata (HIHI,HIGH,LOW,LOLO) to tell what the alarm actually means. But this metadata is not saved with each sample.

I hope this helps.

Cheers,

Timo


On 2024-09-06, 08:15, "Tech-talk on behalf of Gerrit Kühn via Tech-talk" <tech-talk-bounces at aps.anl.gov <mailto:tech-talk-bounces at aps.anl.gov> on behalf of tech-talk at aps.anl.gov <mailto:tech-talk at aps.anl.gov>> wrote:


Am Thu, 5 Sep 2024 12:03:20 -0700
schrieb Michael Davidsaver via Tech-talk <tech-talk at aps.anl.gov <mailto:tech-talk at aps.anl.gov>>:


Hello Michael,


> > We would now like to archive additional fields ("STAT" and "SEVR") for
> > specific PVs, and are not quite sure as to how or where to add them. 


> Alarm (and time) meta-data is always stored. Adding STAT/SEVER would be
> redundant.


Sorry if this is an absolute newbie question, but how can we access this
stored data then? .STAT and .SEVR are alarm fields, but the archiver lists
only these fields in the details section of the PV as being archived:


---
Archive Fields HIHI,HIGH,LOW,LOLO,LOPR,HOPR
---


We can access these fields just fine by giving their name (e.g.,
PVNAME.HIGH) in the archiver admin ui. They are listed as "Being
Archived", and their data can be retrieved.
However, fields like .STAT and .SEVR are not listed as "Being Archived".
Where would the alarm fields end up in the archiver, and how can we access
them?




Greetings from Hannover,
Gerrit




Replies:
Re: Adding additional fields to be archived in "policies.py" Gerrit Kühn via Tech-talk
References:
Adding additional fields to be archived in "policies.py" Windsor Tanner via Tech-talk
Re: Adding additional fields to be archived in "policies.py" Michael Davidsaver
Re: Adding additional fields to be archived in "policies.py" Gerrit Kühn

Navigate by Date:
Prev: Re: Adding additional fields to be archived in "policies.py" Gerrit Kühn
Next: Re: Adding additional fields to be archived in "policies.py" Gerrit Kühn 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  <20242025 
Navigate by Thread:
Prev: Re: Adding additional fields to be archived in "policies.py" Gerrit Kühn
Next: Re: Adding additional fields to be archived in "policies.py" Gerrit Kühn 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  <20242025 
ANJ, 11 Sep 2024 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions ·
· Download · Search · IRMIS · Talk · Documents · Links · Licensing ·