7 parameter types, 1 expressions in parameters – Campbell Scientific CR5000 Measurement and Control Module User Manual
Page 85

Section 4. CRBasic - Native Language Programming
4-9
4.7 Parameter Types
Instructions parameters allow different types of inputs these types are listed
below and specifically identified in the description of the parameter in the
following sections or in PC9000 CRBasic help.
Constant
Variable
Variable or Array
Constant, Variable, or Expression
Constant, Variable, Array, or Expression
Name
Name or list of Names
Variable, or Expression
Variable, Array, or Expression
Table 4.7-1 list the maximum length and allowed characters for the names for
Variables, Arrays, Constants, etc.
TABLE 4.7-1. Rules for Names
Name for
Maximum Length (number of
characters)
Allowed characters
Variable or Array
16
Letters A-Z, upper or lower.
Constant
16
case, underscore “ _” , and
Alias
16
numbers 0-9. The name must
Data Table Name
8
start with a letter. CRBasic is
Field name
16
not case sensitive
4.7.1 Expressions in Parameters
Many parameters allow the entry of expressions. If an expression is a
comparison, it will return -1 if the comparison is true and 0 if it is false
(Section 4.5.3). An example of the use of this is in the DataTable instruction
where the trigger condition can be entered as an expression. Suppose the
variable TC(1) is a thermocouple temperature:
DataTable(Name, TrigVar, Size)
DataTable(Temp, TC(1)>100, 5000)
Entering the trigger as the expression, TC(1)>100, will cause the trigger to be
true and data to be stored whenever the temperature TC(1) is greater than 100.
4.7.2 Arrays of Multipliers Offsets for Sensor Calibration
If variable arrays are used as the multiplier and offset parameters in
measurements that use repetitions, the instruction will automatically step
through the multiplier and offset arrays as it steps through the channels. This
allows a single measurement instruction to measure a series of individually