Fixed Timing

The timing issues have been fixed in the code.  The PLC starts counting
at 0, not 1.