Hi everyone, I’m working on a conveyor system using an Omron CP2E PLC. I have several conveyor lines with products. Normally, each line only carries one type of product, but in some cases, mixed products can appear on the same conveyor line.
Because of this, I want to build a system that can track the composition of products on each line. My idea is: if one conveyor line can hold up to 10 pieces, I will use registers D100–D109 to map the products. Each register will represent the sequence and type of product.
My questions are:
- How can I create a program that scans for the first empty register within a specific range, so I can insert the product type into that position?
- If I use a FIFO sequence, when a product leaves the conveyor (for example, from D100), how can I reset that register and automatically shift the remaining registers to the left?
That’s all my questions. Thanks a lot, I really appreciate any information or advice you can share.