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.

aycontrol and status of lights!
#2
Hi,

Objects inside LM are default without 'read' flag.

You can add this as a event-based script on your (status) object(s) to make it respond on a read request.

Use TAG to run it on multiple objects from single script

Don't forgot to enable the checkbox 'Execute on group read' to have the script triggered on a read request.

Code:
12345678
-- only reply to group read requests if event.type == 'groupread' then    obj = grp.find(event.dst)    -- object found and has datatype set    if obj and obj.decoded then       grp.response(event.dst, obj.value, obj.datatype)    end end

See http://forum.logicmachine.net/showthread...=groupread for source

BR,

Erwin van der Zwart
Reply


Messages In This Thread
RE: aycontrol and status of lights! - by Erwin van der Zwart - 23.03.2016, 20:11

Forum Jump: