TRN, RND and MOD: the Rounding That Loses a Count, and the Four Lines That Fix It
A flow totaliser on a CompactLogix 5380 reads 8,928 litres at the end of an eight-hour shift. The meter says 8,976. The difference is 48 litres, the flow was steady at 18.7 L/min all day, and the arithmetic in the controller is one ADD and one MOV in a 100 ms periodic task. Nothing is … Read more