Writing Expressions - YOKOGAWA SMARTDAC+ GX10 User Manual

Paperless recorder
Hide thumbs Also See for SMARTDAC+ GX10:
Table of Contents

Advertisement

1.6 Configuring Math Channels (/MT option)
1.6.3
Writing Expressions
Common Items
1-68
Follow the rules below when writing expressions.
• Use up to 120 characters to write expressions.
• The precedence of computing terms can be specified using parentheses.
• Specify channels in expressions using channel numbers.
Example: 0001, 0012, A001, C001
• The "0" in the top digit of I/O channel numbers (0101), math channel numbers (A001),
communication channel numbers (C010), constants (K), internal switch numbers (S),
flags (F), and recording status (REC) can be omitted.
Examples: 101, A1, C10, K1, S1, F1, REC1
• The data of the previous scan is used in the computation for its own channel number and
channel numbers greater than its own channel number in the expression.
• Write special computations (HOLD, RESET, and CARRY) and conditional expressions at
the beginning of expressions.
Order of Precedence in Computations
The order of precedence of computation in expressions is as follows:
Type
Function
Special computation and
conditional expression
Power
Logical negation
Multiplication and division
Addition and subtraction
Greater than and less than .GT. (or >), .LT. (or <), .GE. (or >=), .LE. (or <=)
Equal and not equal
Logical product
Logical sum and exclusive
logical sum
Limitations
The following limitations exists in expressions.
Type
TLOG Computation
CLOG computation
PRE
HOLD(a):b
RESET(a):b
CARRY(a):b
Conditional equation
[a?b:c]
Computing Element
ABS(), SQR(), LOG(), LN(), EXP(), TLOG.MAX(), TLOG.MIN(), TLOG.
AVE(), TLOG.SUM(), TLOG.P-P(), TLOG.PSUM(), CLOG.MAX(), CLOG.
MIN(), CLOG.AVE(), CLOG.SUM(), CLOG.P-P(), BIT, INT, SIN, COS
PRE, HOLD, RESET, CARRY, [a?b:c]
**
NOT
*, /, MOD
+, –
.EQ. (or =), .NE. (or <>)
AND
OR, XOR
Limitations
A computing element cannot be written inside the parentheses.
Only one TLOG computation can be specified in a single expression.
The number of channels that can be written in the parentheses is up to 30
channels.
A computing element cannot be written inside the parentheses.
Only one CLOG computation can be specified in a single expression.
A computing element cannot be written inside the parentheses.
Can only be written at the beginning of an expression.
Only one HOLD computation can be specified in a single expression.
Can only be written at the beginning of an expression.
Only one RESET computation can be specified in a single expression.
Can only be written at the beginning of an expression.
Only one CARRY computation can be specified in a single expression.
Only TLOG.SUM can be written in b.
RESET, CARRY, or HOLD cannot be written to a, b, or c.
Other computing elements cannot be combined (example: [a?b:c]+0001).
However, conditional equations can be specified for a, b, and c.
IM 04L51B01-01EN

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Smartdac+ gp10Smartdac+ gx20Smartdac+ gp20

Table of Contents