I can input the maximum number of reading errors or matching errors in the camera screen but how does it really work?
You have to understand that you have to setup the reader, be it a barcode reader or a OCR recognition reader so well that you have seldom an error. Readers nowadays will read very accurately if well positioned, lighted, and setup. If you want the controller to deal with a bad reader, you are taking the wrong resolution path because the controller just gets the result from the reader, a good controller will not makeup for a bad reader.
Above, you define that the machine should SOFT-STOP (set the machine stop signal but remain in production) when 2 reading errors in sequence are reached. 3 For matching.
What does that mean?
We have an error counter that starts at 0. With every error, it is incremented by one. With every good reading it is decremented by one if it is more than 0 of course.
If you think each number between hyphens is a product, and if you think that every underlined product had a reading or matching error, here is what will happen if you say max. 3 errors:
Case A: products 03 and 04 are bad this brings the counter to 2, still below maximum of 3. Since next 2 products are good, counters goes first to 1, then to 0.
Case B: products 07, 08, and 09 are bad, the counter reaches 3, the machine gets a softstop (or feeder stop if you want) and the error counter gets back to zero.
Case C: a lot of products after 15 are bad but the machine keeps bringing bad products. At product 16 a soft stop is released but the machine does not stop or still has a lot of products on the belt, so the counter goes up to 3 and back to 0 when it releases the stop. But more bad products keep coming, at product 19, it releases another stop.