Have you tried field(CALC, "A==1?1:0") instead of field(CALC, "A=1?1:0") on your VME system?
Yong
________________________________________
From: [email protected] [[email protected]] on behalf of J. Lewis Muir [[email protected]]
Sent: Tuesday, May 29, 2012 11:09 PM
To: EPICS Tech Talk
Subject: calc VAL field not updating from bi VAL field
I've got a problem where a calc record's VAL field is not
updating when I expect it to.
I load the following database into my IOC:
calc-bi.db >>>
record(bi, "$(P)Unidig1Bi1") {
field(ZNAM, "Low")
field(ONAM, "High")
}
record(calc, "$(P)ClcBacklightBi") {
field(INPA, "$(P)Unidig1Bi1.VAL CP MS")
field(CALC, "A=1?1:0")
}
<<<
like this:
st.cmd >>>
...
dbLoadRecords("calc-bi.db","P=17lab:")
...
<<<
I then start camonitor:
camonitor console >>>
$ camonitor 17lab:ClcBacklightBi.VAL 17lab:ClcBacklightBi.A
17lab:ClcBacklightBi.VAL 2012-05-29 19:48:44.845452 1 LINK
INVALID
17lab:ClcBacklightBi.A 2012-05-29 19:48:44.845452 0 LINK
INVALID
<<<
And then I perform a series of caput commands in another console:
caput console >>>
$ caput 17lab:Unidig1Bi1.VAL 0
Old : 17lab:Unidig1Bi1.VAL Low
New : 17lab:Unidig1Bi1.VAL Low
$ caput 17lab:Unidig1Bi1.VAL 1
Old : 17lab:Unidig1Bi1.VAL Low
New : 17lab:Unidig1Bi1.VAL High
$ caput 17lab:Unidig1Bi1.VAL 0
Old : 17lab:Unidig1Bi1.VAL High
New : 17lab:Unidig1Bi1.VAL Low
$ caput 17lab:Unidig1Bi1.VAL 1
Old : 17lab:Unidig1Bi1.VAL Low
New : 17lab:Unidig1Bi1.VAL High
<<<
camonitor shows the following:
camonitor console >>>
17lab:ClcBacklightBi.VAL 2012-05-29 21:11:28.307312 1
17lab:ClcBacklightBi.A 2012-05-29 21:11:28.307312 0
17lab:ClcBacklightBi.A 2012-05-29 21:11:33.423978 1
17lab:ClcBacklightBi.A 2012-05-29 21:11:36.990645 0
17lab:ClcBacklightBi.A 2012-05-29 21:12:32.507352 1
<<<
As you can see, the 17lab:ClcBacklightBi record's VAL field
updates once when the record first processes and then never
again. The "A" field is updating correctly as I change
17lab:Unidig1Bi1.VAL, but 17lab:ClcBacklightBi.VAL never updates
again.
If I change the CALC expression to "A", the VAL field updates
correctly. If I change it back, it stops working again.
Environment:
* VME processor module: Motorola MVME-2100 (vxWorks-ppc603)
- CPU: MPC 8240
- Memory: 32 MB
* OS: VxWorks 5.5.2
* Kernel: WIND 2.6
* BSP: mv2100-asd5 (by Andrew Johnson)
* Build toolchain: Tornado 2.2.2
* EPICS 3.14.12.2 (+Known Problems patches)
I tried this on darwin-x86 (x86_64) and it did not fail, so to
date it is only failing for me on my VME systems. (I initially
discovered the problem on an MVME-5100.)
This worked fine with older software (i.e. VxWorks 5.4.2 with
EPICS 3.14.11) on my VME systems.
Thanks,
Lewis
- Replies:
- Re: calc VAL field not updating from bi VAL field J. Lewis Muir
- References:
- calc VAL field not updating from bi VAL field J. Lewis Muir
- Navigate by Date:
- Prev:
calc VAL field not updating from bi VAL field J. Lewis Muir
- Next:
device support for CPCI Qazi Zia-ul-Haque
- 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:
calc VAL field not updating from bi VAL field J. Lewis Muir
- Next:
Re: calc VAL field not updating from bi VAL field J. Lewis Muir
- 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
|