Experimental Physics and Industrial Control System
> From [email protected] Tue Oct 24 03:45:03 1995
> Return-Path: <[email protected]>
> Date: Tue, 24 Oct 1995 10:48:12 +0100 (BST)
> To: [email protected]
> Subject: more help with ar, please
> Mime-Version: 1.0
> Content-Type> : > TEXT/PLAIN> ; > charset=US-ASCII>
> Content-Length: 1374
> X-Lines: 53
>
> I just started to cool a cryostat with epics reading the temperatures and
> AR logging them. I just happened to notice that the values written to
> disk were repititions of the initial temperatures, not what epics was
> currently reading, ie:
>
> PROGRAM: AR
> SAMPLE: at 10/24/95 10:39:16.020--operator snapshot
> %endHeader%
> ser3:ecalcs_54.VAL DBF_DOUBLE 0 0 1 8203.000
> ser3:emosub_87.VALA DBF_DOUBLE 0 0 1 261.8000000
> ser3:emosub_87.VALC DBF_DOUBLE 0 0 1 280.8000000
> %endData%
> PROGRAM: AR
> SAMPLE: at 10/24/95 10:40:56.020--operator snapshot
> %endHeader%
> ser3:ecalcs_54.VAL DBF_DOUBLE 0 0 1 8303.000
> ser3:emosub_87.VALA DBF_DOUBLE 0 0 1 261.8000000
> ser3:emosub_87.VALC DBF_DOUBLE 0 0 1 280.8000000
> %endData%
>
> the temperatures are actually changing, I can see them on a dm display
> which is connected to exactly the same records/fields.
>
> My archive script is:
>
> NAME: ls1
> DESC: test it
> ACT: always
> INACT: never
> TRIGGER: every 0:1:40
> SNAPSHOT: for 1 samples
> OUTPUT: set:txt /net/idsun1/epics1/mch/epics/ar/arSet/ls2.txt
> %endHeader%
> ser3:ecalcs_54.VAL
> F ser3:emosub_87.VALA
> # F ser3:emosub_87.VALB
> F ser3:emosub_87.VALC
> F ser3:emosub_87.VALD
> F ser3:emosub_87.VALF
> F ser3:emosub_44.VALA
>
>
> Dose anybody have any ideas?
>
> tia
>
> Ian A Smith
> Telephone:
> +44 (0) 131 668 8257 Royal Observatory Fax: +44 (0) 131 668 1130
> Blackford Hill Web: http://www.roe.ac.uk/
> Edinburgh
> UK
>
>
What kind of a record is emosub_87?
If it is a subroutine record it looks from the
subroutine record code that the archiver will not get any values back
but the val field.
I am going to post this reply to the exploder also,
so that someone who is an expert on record code can also reply.
I am appending the relevant segment of code from the record support
for subroutine records to this message.
The code could be changed so that archive values would be
returned for the subroutine input fields by checking the difference
between *pnew and *pprev against psub->adel in the loop that posts monitors
for changes in the input fields and setting the bit for DBE_LOG in the monitor
mask in case the change is larger than psub->adel. The problem with
this approach is that there is only one adel and it will probably not
fit all the input fields.
/* check for archive change */
delta = psub->alst - psub->val;
if(delta<0.0) delta = -delta;
if (delta > psub->adel) {
/* post events on value field for archive change */
monitor_mask |= DBE_LOG;
/* update last archive value monitored */
psub->alst = psub->val;
}
/* send out monitors connected to the value field */
if (monitor_mask){
db_post_events(psub,&psub->val,monitor_mask);
}
/* check all input fields for changes*/
for(i=0, pnew=&psub->a, pprev=&psub->la; i<ARG_MAX; i++, pnew++, pprev++) {
if(*pnew != *pprev) {
db_post_events(psub,pnew,monitor_mask|DBE_VALUE);
*pprev = *pnew;
}
return;
}
Rozelle Wright
---------------------------------------------------------
| |
|Rozelle Wright Phone (505) 667-4804 |
|Los Alamos Natl Labs AOT-8 FAX (505) 665-5107 |
|PO Box 1663 MS-H820 Group Office (505) 667-6087|
|Los Alamos, NM 87545 email : [email protected] |
| |
---------------------------------------------------------
- Replies:
- Re: Subroutine record input fields don't get archived I.Smith
- Navigate by Date:
- Prev:
more help with ar, please Ian Smith
- Next:
Re: Subroutine record input fields don't get archived Marty Kraimer
- 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
2024
- Navigate by Thread:
- Prev:
more help with ar, please Ian Smith
- Next:
Re: Subroutine record input fields don't get archived I.Smith
- 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
2024