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.

function from timer
#3
Thanks for this script; 
I modified it slightly because I don't need to send commands to consecutive group addresses.
The script works with the switching commands, but when I send 0%, it doesn't transmit that value—though it does transmit anything above 1%.
Code:
value = event.getvalue() on = value > 0 if on then   grp.checkwrite('1/0/1', value) end addresses = {   '1/1/1',   '1/1/2',   '1/1/4',   '1/1/5',     '1/1/7',   '1/1/8',   '1/1/10',   '1/1/11',   '1/1/13',   '1/1/14',   '1/1/16',   '1/1/17',   '1/1/19',   '1/1/20' } for _, address in ipairs(addresses) do   grp.checkwrite(address, on) end
Reply


Messages In This Thread
function from timer - by Danny - Yesterday, 09:02
RE: function from timer - by admin - Yesterday, 09:11
RE: function from timer - by Danny - Yesterday, 10:15
RE: function from timer - by admin - Yesterday, 10:17

Forum Jump: