User manual
Computer Gateway User Manual A-3 5/96
A.2.3
A.2.3 Custom Data Segment Example
CUSTOM
PARAMETER swdbd1: NUMBER "switch deadband value"
TYPE number
ACCESS engineer
EU "psi"
VALUE 0.5
BLD_VISIBLE
PARAMETER swdbd2
EU "psi"
VALUE 0.5
END CUSTOM
Notice that the two parameters generated by this example will be identical in all but their
names. There is no name associated with the CDS because it is identified by the name of
the file into which it is compiled (only one CDS for each file).
A.2.4 Custom Data Segment Compilation Recommendation
The CL compiler maintains a library file that includes the names of all nonstandard
parameter names used in every CDS ever compiled in your system. This file allows for
1000 names, which is normally more than adequate because any of these parameters can be
arrays of values and a particular name is entered only once, no matter how many times it is
used by multiple Custom Data Segments.
Once a name is entered into the library file, however, there is no way to delete the name.
Because it is not desirable to clutter the file with parameter names that were accidentally
mistyped, the compiler does not update the library file unless the compiler directive -UL
(Update Library) is invoked. You should obey the following sequence when compiling a
CDS:
1. First, compile without the -UL directive to ensure that the CDS parameters are free of
errors. Every new parameter is followed by an error indicating that the -UL option
should be used. If any other errors appear, they should be corrected.
2. Recompile with the -UL directive to update the system library file with the CDS
parameter names. There should not be any errors.
It is a good idea on subsequent recompilations to compile without the -UL directive unless
a new parameter name is purposely being added to the CDS. This guards against
erroneous additions that might occur if a parameter name is accidentally mistyped while
editing the file.
You can see all the parameters that have been defined by using File Manager Utilities to
print the system library file
&ASY>PARAMETR.SP. The file &ASY>SEGMENTS.SP can be
printed to see all CDS file names that have been used. The -UL directive also controls
whether CDS file names are entered into the library.