Logging bar code data and seeing if it's been scanned twice

We are trying to use ignition to data log from a barcode scanner. We also want the ability to if a barcode is scanned twice to write back to the plc with an error. Is this possible within ignition?

Warning— I am a little new to ignition

Thanks fro the help

Yes, it’s possible.

I admit it, I was feeling a bit snarky there. I was going to leave it there, since there’s not a lot to go on, but here’s my take on it. (My view is from a manufacturing standpoint)

First, though, welcome to the forums! Don’t let my lack of sleep or caffeine trouble you. :slight_smile:

At the beginning of the cycle, it should be assumed the part is bad until told otherwise from the process. It’s the same with duplicate scans.

I would do this with a transaction group.

  • The scan comes in as a read-only item.

  • A query expression item to check if there are any duplicates. If it returns 0, there is no duplicate. More than 0 is a problem.

SELECT count(*)
FROM table
where barcode = '{new_scan_item_in_group}'
  • send status back to PLC

This is just a rough outline, but a transaction group, IMO, is the least painful way to go.