03.12.2018, 07:44
You can make the conversion via a script. Create a virtual object via 4 byte floating point data type. Use this object for control/display.
In this example source 2 byte object is 1/1/1 and virtual object is 32/1/1. Change as needed.
Attach an event script to virtual object (32/1/1):
Then attach another event script to source object (1/1/1):
In this example source 2 byte object is 1/1/1 and virtual object is 32/1/1. Change as needed.
Attach an event script to virtual object (32/1/1):
Code:
-- do nothing if triggered by another event script
if event.sender ~= 'se' then
value = event.getvalue()
grp.write('1/1/1', value * 100)
end
Then attach another event script to source object (1/1/1):
Code:
-- do nothing if triggered by another event script
if event.sender ~= 'se' then
value = event.getvalue()
grp.write('32/1/1', value / 100)
end