User Manual UMAX030541. Version V1 30-116
For example, in the case where the user may want to combine two inputs such that a
joystick (Input 1) is the primary control of an output, but the speed can be incremented or
decremented based on a potentiometer (Input 2), it may be desired that 75% of the scale
is controlled by the joystick position, while the potentiometer can increase or decrease
the min/max output by up to 25%. In this case, Input 1 would have a gain of 0.75, while
Input 2 uses 0.25. The resulting addition will give a command from 0 to 100% based on
the combined positions of both inputs.
For each input pair, the appropriate arithmetic or logical operation is performed on the
two inputs, InA and InB, according the associated function in sub-index of InB in object
4y50h
Math Y Operator
. The list of selectable function operations is defined in Table 19.
0 =
True when InA Equals InB
1 !=
True when InA Not Equal InB
2 >
True when InA Greater Than InB
3 >=
True when InA Greater Than or Equal InB
4 <
True when InA Less Than InB
5
<
=
True when InA Less Than or Equal InB
6 OR
True when InA or InB is True
7 NOR
True when InA and InB are False
8 AND
True when InA and InB are True
9 NAND
True when InA and InB are not both True
10 XOR
True when InA/InB is True, but not both
11 XNOR
True when InA and InB are both True or False
12 +
Result = InA plus InB
13 -
Result = InA minus InB
14 x
Result = InA times InB
15 /
Result = InA divided by InB
16 MIN
Result = Smallest of InA and InB
17 MAX
Result = Largest of InA and InB
Table 19
– Object 4y50h Math Function Operators
For Function 1, InA and InB are Math Inputs 1 and 2, respectively.
For Function 2, InA is the result of Function 2 and InB is Math Input 3, respectively.
For Function 3, InA is the result of Function 3 and InB is Math Input 4, respectively.
Exclusively
within
a Math Block, there is a third control parameter: Object 4y02h,
Math
Y Function Number.
This parameter
allows for the result of any Function (1, 2 or 3) to
be the input to any
Math Input Y
within the same Math Block. Therefore,
Math Y Input
Source
must be a Math Block
and
Math Y Input Number
must be the same number as
being configured. When these four parameters match, if
Math Y Function Number
is set
to 1, 2, or 3, the respective input will be the result of the Function selected. By default,
Math Y Function Number
is set to 0
– in which case this parameter is ignored and uses
the Math Block output result. These functions can only be used
within
the Math Block.
They can not be used for other Math Blocks or logic blocks.