I am trying to add functionality to a module that will allow data written to a value in ignition to be passed to the module and back to a device.
For reading values from the ignition database would this be the correct call to make?
provider.getTag(p).getValue()
We also need indication of when the value was changed by ignition so that we don’t have to track the last read value in the module. Ideally we would like to register a callback or have an event fired off when a value is changed in ignition.
com.inductiveautomation.ignition.common.expressions.TagListener looks like it implements some of that functionality, is there a better class or function to use?
In both 7.9 and 8.0 though the TagManager you get from the GatewayContext has methods to subscribe to a given TagPath and receives a listener that will get callback when tags change, so start there.
No, no information like that. You might be able to figure out if your module was the source of the change some other way but there’s no info about the source available in the TagChangeEvent you get.