What is the best way to read OPC tags based on the event and not based on Scan classes.
I have plenty of tags which have uncertain update cycle in the PLC since they are recipe based. Hence, I don’t want to put pressure on the PLC and do the tag update when the recipe is actually changed in PLC.
I know I can do scripting and read through system.opc.readValue(). Looking for any other straight forward way.
Any leads would be appreciated.
You’ll need something in the PLC that changes to let Ignition know to read the rest. That trigger item would be an OPC tag with a scan class/tag group pace that is fast enough so you don’t miss triggers. Then you use a tag change script to read all other relevant data with system.opc.readValues(). If you would like these other values to also be available as tags, create memory tags for them and write to the memory tags from the trigger’s tag change script.
1 Like
Why I didn’t thought of the same ? LOL.
Thanks