Batch counter

Each part passing the sensor adds 1. At the preset the batch is full. A button resets the count for the next batch.

Step by step

Pick a step. The rungs are drawn by the editor after Core scans the program up to that step.

1. Part 1. The CTU rung turns on, so ACC goes to 1.

StepPartEyeBatch.ACCBatch.DNBatchFull
1. Part 11100
2. Gap0100
3. Part 21200
4. Gap0200
5. Part 31311
6. Press NextBatchPB0001
7. Release NextBatchPB0000

Why it works

  • A CTU adds 1 to ACC each time its rung turns on. A part that stays in front of the sensor counts once.
  • DN turns on when ACC reaches PRE.
  • RES sets ACC back to 0 and clears DN. PRE is kept.

Common mistakes

  • Resetting with a MOV of 0 into ACCRES clears DN as well as ACC. Use RES on the counter tag.
  • Holding the reset buttonWhile RES is true the counter stays at 0, so parts that pass during the reset are lost.

Instructions used

Related