Mark,
Yes, that works and, when a value is assigned to the VAL field via the
"field" directive in the database definition file, the UDF field is set to
zero just as it is when the INP field is used for initialization. Is there
any reason to use the INP (or OUT) field for initialization rather than
initializing the VAL field directly?
Fritz
> -----Original Message-----
> From: Mark Rivers [mailto:[email protected]]
> Sent: Friday, June 11, 2004 12:09 PM
> To: [email protected]
> Subject: RE: Initializing a record VAL field with a constant
>
>
> Hi Fritz,
>
> Why not put the initial string (and ai) values directly into the
> VAL field, rather than using INP? I know that works for
> stringout, and I assume it should work for stringin as well.
>
> Mark Rivers
>
> -----Original Message-----
> From: J. Frederick Bartlett [mailto:[email protected]]
> Sent: Fri 6/11/2004 11:57 AM
> To: tech-talk
> Cc: Bartlett, Fritz
> Subject: Initializing a record VAL field with a constant
>
> Recently I was adding some new records to our name/value server
> IOC and I
> noticed an unexpected behavior. My new records, which are of type
> longin and
> ai, are used to supply system-wide values, i.e. firmware version
> numbers for
> comparison with hardware, computational constants, etc., for the
> rest of the
> control system. The records are initialized by placing a constant value in
> the INP field of the record definition text.
>
> As one would expect, after initialization the UDF field for
> these records
> is zero, indicating that the VAL field has had a value assigned at some
> point in the record's existence. What I did not expect was that the SEVR
> field is set to INVALID and the STAT field to UDF. I would have expected
> that, if you are going to bother to set the UDF field to zero, consistency
> would dictate that the SEVR and STAT fields would be given the value
> NO_ALARM, just as it would be when the VAL field is set by a CA put
> operation. Is this behavior intentional and, if so, why?
>
> I also discovered that, for the stringin record, this technique
> of setting
> an initial value by placing a constant -- in this case a string
> constant --
> in the INP field does not work at all. Is there a corresponding method for
> initializing the VAL field of a stringin record?
>
> By the way, we are still using version 3.13.4.
>
> Fritz
>
>
>
>
>
- Navigate by Date:
- Prev:
Initializing a record VAL field with a constant J. Frederick Bartlett
- Next:
Re: Initializing a record VAL field with a constant Brian McAllister
- 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: Initializing a record VAL field with a constant Andrew Johnson
- Next:
RE: Initializing a record VAL field with a constant Allison, Stephanie
- 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
|