<< Click to Display Table of Contents >>
DeviceLow |
This property defines the lowest value achieved by this I/O Tag in a device. This property is used to perform a scale adjustment of the value received from a device before setting it to the Value property. Likewise, the inverse operation is performed before sending that value to the I/O Driver, when writing. This conversion only occurs when the EnableScaling property is set to True. The default value of this property is 0 (zero). The next script contains an example of using this property.
Sub Tag_OnStartRunning()
' Adjusts the scale of temperature
' ranging from 0 to 255 at PLC, but it actually means
' 0 to 100 Celsius degrees
EU = "Celsius degrees"
EnableScaling = True
DeviceHigh = 255
DeviceLow = 0
EUHigh = 100
EULow = 0
End Sub
NOTE |
Bit values, the properties from Bit00 to Bit31, are not affected by adjustments in the scale, that is, they represent the bits from the value read by a device before conversion. |