We have conditions that lock machines then require a supervisor to scan their ID to unlock the machine.
The problem is when the same supervisor needs to scan a second time the Tag Change event never fires seemingly because it knows the same value received is the same if that makes sense.
Does anyone know a way around this?
What “writes” to the tag and what kind of tag is it? Does the timestamp end up changing or no?
It’s an OPC tag. A Tag Change gateway script. I’ve been trying different (Change Triggers) Enabling only
Value etc but it still doesn’t fire when the value is the same.
How would I check the timestamp you mentioned?
So the barcode scan updates a tag in a PLC? Is this our server/drivers you are using?
I inherited this system a while back. It is new to me.
The barcode scan goes through a PLC yes?
I think the server/drivers answer is yes. How would I check?
In the properties of the Tag, the OPC Server = Ignition OPC UA Server
Meh, it doesn’t matter. I don’t think you can make this work the way you want.
I was thinking to use the
Include Timestamp-Only Changes OPC UA tag group property introduced in 8.1.10, but if that works it’s going to end up triggering every time the driver polls.
The tag event will need to send a message to the PLC to have it wipe the content. Your tag event would ignore it when it has been wiped.
Yeah, you’re going to have to reset it. The driver is just going to see barcode “foo” each time it polls. It couldn’t possibly know that’s really a 2nd scan because it didn’t change.
I’ll have to play around with this a bit. See if I can (wipe content) or (reset it) or something similar. Talking to people here, theoretically, there will be scans of other barcodes between supervisor scans.
Do you know if I should be able to write to this tag via scripting using similar to below?
system.tag.writeBlocking(["[default]M99/M99/Scanner/Scan String"], ["hello"])
I keep seeing the error. . .
Error writing to Scan String.value: Bad
Maybe it’s not writable in the PLC then? Assuming the tag in Ignition is already configured RW and not RO.
I’ll have to check Monday. Thank you so much for your help. Mr. pturmel too, thank you!
You really should not wipe it from Ignition. Echo it or use some other signal so the PLC wipes. Otherwise you will eventually lose more scans to the race condition.
Talking with people here today and . . .
They are telling me (the problem I describe in this post) won’t exist here because the logic-flow of this scanning process dictates that another barcode will always be scanned in between the supervisor scans.
I’ll stop trying to get a resolution for this issue for now.