Hello all. I stumbled upon a curious behavior of mbbo record with configured IVOA field, both in EPICS 3.15.6 and 7.0.7
We were originally testing it in an areaDetector IOC, but managed to make a minimal example. Basically, we want to set forbidden values to mbbo record in such a way that the IOC does not accept values above a certain number (in the example, above or equal to
five).
I defined the following record:
record(mbbo, "record_name") {
field(DESC, "description")
field(ZRST, "zero_string") field(ZRVL, "zero_value")
field(ONST, "one_string") field(ONVL, "one_value")
field(TWST, "two_string") field(TWVL, "two_value")
field(THST, "three_string") field(THVL, "three_value")
field(FRST, "four_string") field(FRVL, "four_value")
field(IVOA, "1")
}
By configuring the IVOA field to "Dont drive outputs", i expect that whenever i put 5 into record_name, it does nothing and statys in the old value. This works in ioc shell:
epics> dbpf record_name 3
DBF_STRING: "three_string"
epics> dbgf record_name
DBF_STRING: "three_string"
epics> dbpf record_name 7
recGblRecordError: 7 Illegal choice PV: record_name
DBF_STRING: "three_string"
epics> dbgf record_name
DBF_STRING: "three_string"
However, in a linux terminal with caget and caput this is not true:
marco@s-swc10-l:~$ caget record_name
record_name three_string
marco@s-swc10-l:~$ caput record_name 7
Warning: enum index value '7' may be too large.
Old : record_name three_string
New : record_name
marco@s-swc10-l:~$ caget record_name
record_name
marco@s-swc10-l:~$
And it changes the value to zero. Even worse: when in an asyn IOC, the value passed to writeInt32 asyn function is also zero.
Is there any better way to set an operational limit to mbbo? Am i missing something?
Thanks in advance,
Marco
Aviso Legal: Esta mensagem e seus anexos podem conter informações confidenciais e/ou de uso restrito. Observe atentamente seu conteúdo e considere eventual consulta
ao remetente antes de copiá-la, divulgá-la ou distribuí-la. Se você recebeu esta mensagem por engano, por favor avise o remetente e apague-a imediatamente.
Disclaimer: This email and its attachments may contain confidential and/or privileged information. Observe its content carefully and consider possible querying
to the sender before copying, disclosing or distributing it. If you have received this email by mistake, please notify the sender and delete it immediately.
|