In order to make my head clean from the project management, I am doing
to write an IOC for the Keithley 6514 electrometer currently. ECR Ion
source team has a Faraday cup, they want to use that Keithley model to
record the extracted beam current with the remote or serial connection.
I've found some already developed Keithley IOCs from EPICS sites, and
google-found-sites, and learned how other people uses it within the
EPICS framework. They are excellent to glimpse a functionality before I
start to work on it.
The developed IOC works fine with a simple and basic functionality.
This unit has two ways to setup the integration time of the A/D
converter. The first way is to use a selected value between 0.01 and 10.
The second one is to use the predefined values, such as SLOW, MED, and
FAST. The end user wants to use only the predefined values (SLOW, MED,
and FAST).
--- DB file ---
record(mbbo, "$(SYS)-$(SUBSYS):$(DEV):SetADRate")
{
field(DESC, "Set Predefined Rate")
field(DTYP, "stream")
field( OUT, "@devkeithley6514.proto setADRate $(PORT) $(A)")
field(ZRST, "Slow")
field(ZRVL, "0")
field(ONST, "Med")
field(ONVL, "1")
field(TWST, "Fast")
field(TWVL, "2")
field(FLNK, "$(SYS)-$(SUBSYS):$(DEV):GetADRate")
}
record(mbbi, "$(SYS)-$(SUBSYS):$(DEV):GetADRate")
{
field(DESC, "Get Predefined Rate")
field(DTYP, "stream")
field( INP, "@devkeithley6514.proto getADRate $(PORT) $(A)")
field(ZRST, "Slow")
field(ZRVL, "0")
field(ONST, "Med")
field(ONVL, "1")
field(TWST, "Fast")
field(TWVL, "2")
field(PINI, "YES")
}
--- protocol file ---
setADRate {
out "CURR:NPLC %{6.00|1.00|0.10}";
@init { out "CURR:NPLC?"; in "%{6.00|1.00|0.10}"; }
}
getADRate {
out "CURR:NPLC?"; in "%{6.00|1.00|0.10}";
ExtraInput = Ignore;
}
-----------------
It works fine if I set only predefined bit in mbbo and mbbi, such as
0, 1, and 2.
case 1) caput ECR11-Diag:FC01:SetADRate 3
returns the following messages:
Warning: enum index value '3' may be too large.
Old : ECR11-Diag:FC01:SetADRate Slow
CA.Client.Exception...............................................
Warning: "Channel write request failed"
Context: "op=1, channel=ECR11-Diag:FC01:SetADRate, type=DBR_DOUBLE,
count=1, ctx="ECR11-Diag:FC01:SetADRate""
Source File: ../oldChannelNotify.cpp line 160
New : ECR11-Diag:FC01:SetADRate
Current Time: Wed Mar 04 2015 07:56:12.932662247
At this point, the following 4 values are
ECR11-Diag:FC01:SetADRate.VAL
ECR11-Diag:FC01:SetADRate.RVAL 0
ECR11-Diag:FC01:SetADRate.STAT CALC
ECR11-Diag:FC01:SetADRate.SEVR INVALID
case 2) caput ECR11-Diag:FC01:SetADRate -1
returns the following messages:
Old : ECR11-Diag:FC01:SetADRate Slow
CA.Client.Exception...............................................
Warning: "Channel write request failed"
Context: "op=1, channel=ECR11-Diag:FC01:SetADRate, type=DBR_DOUBLE,
count=1, ctx="ECR11-Diag:FC01:SetADRate""
Source File: ../oldChannelNotify.cpp line 160
New : ECR11-Diag:FC01:SetADRate Illegal Value
Current Time: Wed Mar 04 2015 07:56:05.867136097
At this point, the following 4 values are
ECR11-Diag:FC01:SetADRate.VAL Illegal Value
ECR11-Diag:FC01:SetADRate.RVAL 0
ECR11-Diag:FC01:SetADRate.STAT SOFT
ECR11-Diag:FC01:SetADRate.SEVR INVALID
Two behaviors are quite acceptable and reasonable in terms of a
client, but the many problems are in the IOC itself. IOC prints a ton of
error or warning messages as follows
Case 1)
2015/03/04 14:07:30.017055 cbLow Value 3 not found in enum set
2015/03/04 14:07:30.017583 cbLow ECR11-Diag:FC01:SetADRate: Formatting
value 3 failed
2015/03/04 14:07:30.017610 cbLow ECR11-Diag:FC01:SetADRate: Cannot
format value with '%{6.00|1.00|0.10}'
Case 2)
2015/03/04 14:07:12.854089 cbLow Value 65534 not found in enum set
2015/03/04 14:07:12.854104 cbLow ECR11-Diag:FC01:SetADRate: Formatting
value 65534 failed
2015/03/04 14:07:12.854283 cbLow ECR11-Diag:FC01:SetADRate: Cannot
format value with '%{6.00|1.00|0.10}'
Here is my question:
How to ignore out-of-range index in mbbo or mbbi in both cases?
Where I have to implement it?
Thanks,
Han
--
Jeong Han Lee, Dr.rer.nat.
---------------------------
Accelerator Systems Division
Rare Isotope Science Project
Institute for Basic Science
Daejeon, South Korea
---------------------------
tel : +82-42-878-8733
fax : +82-42-878-8799
- Replies:
- Re: How to handle out-of-index of MBBO/MBBI? Michael Davidsaver
- Navigate by Date:
- Prev:
Re: "No conversion between src & dest" warning with pcaspy Jameson Graef Rollins
- Next:
Re: error on the IOC shell for asyn driver Vishnu Patel
- 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:
RE: error on the IOC shell for asyn driver Mark Rivers
- Next:
Re: How to handle out-of-index of MBBO/MBBI? Michael Davidsaver
- 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
|