MODΒΆ
The IEC Operators and additional, norm-extending \ functions Modulo Division of one variable by another of the types: BYTE, WORD, DWORD, SINT, USINT, INT, UINT, DINT, UDINT. The result of this function will be the remainder of the division. This result will be a whole number.
Example in IL:
LD 9
MOD 2
ST Var1 (* Result is 1 *)
Example in ST:
var1 := 9 MOD 2;
Example in FBD: