RMG USM GT400 Operating Manual page 166

Ultrasonic flowmeter
Hide thumbs Also See for USM GT400:
Table of Contents

Advertisement

10 Operation
• The value is checked to be 0. The first term is found to be u10 == 0. The result
is true if u10 contains a 0.
• For the second part, a 32-bit integer registers is imported. This value has to be
158
read bitwise. It is a 32-bit unsigned integer (unsigned long int). The prefix is a
large U. Register address is 2; the value U2 must be
requested.
• Now it is checked whether any bit is set to 4. As operator the bitwise "and" has
to be used (&). The second part of the expression results to U2 & 4. The result
is 0 when the bit with the value 4 is not set and a value other than 0 is set. Bits
with other values then 4 do not affect the result.
• The two partial expressions are joined via a logical "and" (&&). Following the
bracket rules both subexpressions have to be put in brackets. The complete ex-
pression for AZ-51 is found to be (u10== 0)&&(U2&4).
Arithmetic Operators Comparison Opera-
Addition +
Subtraction -
Multiplication *
Division /
Modulo %
Sign -
Terms may be
• a?b:c means: if a then b else c
• brackets: ()
• constants:
Integers, for example, 42
Floating point, for example, 1.234
Exponential, for example, 1.2345E-3
unsigned, the sign is realized by the operator sign
Information to the status of the PGC
The input field of coordinate AZ-51 accommodates a maximum of 20 characters.
If this is insufficient for the formulation of a more complex expression, there are a
total of four coordinates for the status.
Manual USM GT400 · EN10 · May 2021
Logical Operators
tors
greater >
Logical And &&
smaller <
baud
greater or equal >=
Logical Or ||
less or equal <=
Not!
equal ==
not equal to =!
Bitwise Operators
Bitwise And &
Bitwise Or |
exclusive or ^
Bitwise negation

Advertisement

Table of Contents
loading

Table of Contents