MOD block
Short summary
Name |
|
→POU type |
|
Category |
|
Conform to →IEC-standard |
currently restricted |
Graphical interface |
|
Available since |
version 1.0.0 (for Neuron Power Engineer) |
Functionality
The mathematical function modulo is called: The block returns the result for IN1 modulo IN2
(the remainder of the division IN1 / IN2
).
Enter the value for the dividend at input IN1
and the value for the divisor at input IN2
.
No check of invalid connections For this block, invalid connections are not checked by Neuron Power Engineer (except for the checks listed under "Internal error diagnostic for block"). Therefore, enter code in your application to detect invalid connections (e.g. See "IEC-blocks for the application" for information what the consequences of an invalid connection might be. |
Inputs, return value
|
Identifier |
Description |
|
---|---|---|---|
Inputs: |
|
|
1st value (dividend) |
|
|
2nd value (divisor) |
|
Return value: |
– |
|
|
Input EN
and output ENO
are available when →calling the block. See "Execution control: EN, ENO" for information on input EN
and output ENO
.
See:
-
"Blocks for safe logic" whether this block is supported for developing safety-relevant applications.
-
"Highlighting safe logic in the FBD-editor" for the effects when using the block as a block for safe logic.
Internal error diagnostic for block
The block checks for a division by 0
before it is executed.
In this error case, the output ENO
of the block is set to value FALSE
(or an equivalent) and according to →IEC-standard the result will be set to 0
.
Example for usage within ST-editor
|
When creating your application within the ST-editor, enter a call of a block by typing the text as requested by the syntax or use Content Assist.