Do it again for each one
Getting the lesson ready…
A FOR loop does the same rule once for each slot, all inside one scan. Set the total to 0.0 first.
Do it again for each one: the words you will learn
- lines the PLC does again and again: here, once for each slot
- loop
- starts a loop: its line says which tag counts, where it starts and where it stops
- FOR … TO … DO
- says where the lines of a FOR loop stop
- END_FOR