23.03.2016, 20:11
(This post was last modified: 24.03.2016, 09:32 by admin.
Edit Reason: Code highlight
)
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.
See http://forum.logicmachine.net/showthread...=groupread for source
BR,
Erwin van der Zwart
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:
-- 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