The modulo function is very useful and I didn't find it on the operators supplied with Robo Pro.
The modulo corresponds to the remainder after division (reference). 5 mod 3 = 2 How to calculate it? a mod b = a - ( b * int ( a / b ) ) with int as integer part |
On our example,
5 mod 3 = 5 - ( 3 x int ( 5 / 3 ) ) = 5 - ( 3 x int ( 1,66 ) ) = 5 - ( 3 x 1 ) = 2 The main use is to convert a single number in coordinates, like row and column. On a 3x3 storage warehouse, box #5 corresponds to the 1st row and 2nd column. It is hugely used on the New Magasin project. |
Download
Download the driver with an example for RoboPro.
This file is under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. |
|