CheckAddresses
This subroutine is not a part of the VTScada API. You must write it as part of your communications driver.
| AddOnError |
| Required Boolean. TRUE to force a new AddRead even if VTSGetAddr returns an error when rebuilding reads |
Comments
If a driver detects a PLC configuration change or other event(*) that could change the result of a VTSGetAddr check, the driver should call CheckAddresses so that all addresses of tags using that driver are re-checked.
(*) As an example, an address that previously failed a VTSGetAddr check might now pass.
Example:
Code for this module will be specific for each driver. The following is an example only of how it might be called.
If Ready && PLCModeChanged; [ Driver.CheckAddresses(TRUE); PLCModeChanged = FALSE; ]
Where, Ready is a Boolean flag in the driver indicating that the driver has started. PLCModeChanged is a Boolean flag set in the driver's Refresh module when driver's parameter, PLCMode, changes.
