Experimental Physics and
| |||||||||||||||
|
what's the calc record supposed to do if it calculates infinity? I have tested the following with R3.13.2/vxWorks5.5/ppc and R3.14.6/Linux/x86 1) field (CALC, "A/B") If B is 0.0, the record becomes invalid (as expected) but the value does not change to 'inf' but stays the previous value. In my opinion this is wrong behaviour. (On the other hand, the value IS invalid, thus it might be any number.) 2) field (C, "inf") field (CALC, "B?A/B:C") This works. VAL is 'inf' and the record is invalid. If one argues in that the record is invalid in 1) because VAL couldn't be calculated, why is it invalid in 2) even though it is accurately inf? If one argues that the value IS inf in 2), why is the record invalid and why is the value wrong in 1)? 3) field (CALC, "B?A/B:inf") Does not work. The string inf is not accepted as a constant in the CALC field. This is inconsistent with the behaviour of DBF_DOUBLE fields. I know that there has been some discussion about infinity and what it means in the 'real world', in EPICS and for a driver. But there are cases, where infinity had a real meaning. E.g. the resistance if a cable is broken. I miss the possibility to have a valid infinity. Dirk -- Dr. Dirk Zimoch Swiss Light Source Paul Scherrer Institut Computing and Controls phone +41 56 310 5182 fax +41 56 310 4413
| ||||||||||||||
ANJ, 02 Sep 2010 |
·
Home
·
News
·
About
·
Base
·
Modules
·
Extensions
·
Distributions
·
Download
·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing · |