09.12.2015, 10:50
Code:
-- Gets values
value1 = grp.getvalue('3/3/0')
value2 = grp.getvalue('3/3/1')
-- Math calculus, is, us, uh
if value1 > value2 then
-- Writes correct value to group address
grp.update('3/3/9', value2)
else
grp.update('3/3/9', value1)
end
I have this script that compares two values and writes the lowest value to a group address. However, I´m not writing it in the correct format. Consequently, the data will not display on screens in the house. ETS does not recognise the data type as a temperature, rather as a 2-byte float.
How do I write a 9.001 Temperature data type to the group?