This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

1 byte to 3byte time/date
#1
Hello

Can anyone make a lua script for a wiser for knx.

I have a 1 byte object 1 or 0 (1/1/1)

and want to write 1 hour to 32/1/1 (3 byte time/date) when 1/1/1 is 1 and with 0 reset time to 0

thank you.
Reply
#2
Event script on your bit object, change the 1/1/1 to your Time group
Code:
-- time table
time = {
day = 0,
hour = 1,
minute = 0,
second = 0,
}

value = event.getvalue()
if value then
grp.write('1/1/1', time)
else
grp.write('1/1/1', 0)
end
------------------------------
Ctrl+F5
Reply


Forum Jump: