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.

script for scene change
#5
(26.04.2022, 11:35)admin Wrote: Attach your scenes to 1 byte unsigned object with trigger value from 1 to 10. Create an event script for scene up/down (1 bit). Change scene trigger object (32/1/17) as needed.
Code:
out = '32/1/17'

up = event.getvalue()
nr = grp.getvalue(out)

if up then
  nr = nr + 1
  if nr > 10 then
    nr = 1
  end
else
  nr = nr - 1
  if nr < 1 then
    nr = 10
  end
end

grp.update(out, nr)

Thank you for this. it worked fine.

(26.04.2022, 14:20)Daniel Wrote: Just create event script on the dim object, change group as needed and if the disable value is 0 then change true to false
Code:
-- write value (e.g. boolean 'true') to object with group address 1/1/1, datatype must be set for this object
grp.write('1/1/1', true)


Thanks a lot for this. This worked fine too.
Reply


Messages In This Thread
script for scene change - by Vik - 26.04.2022, 11:25
RE: script for scene change - by admin - 26.04.2022, 11:35
RE: script for scene change - by Vik - 28.04.2022, 15:47
RE: script for scene change - by Vik - 26.04.2022, 13:46
RE: script for scene change - by Daniel - 26.04.2022, 14:20

Forum Jump: