07.10.2022, 05:33
Most likely you have some group writes coming from addresses that are not present on LM.
Replace get_value/knx_callback functions with this and see if it works:
Replace get_value/knx_callback functions with this and see if it works:
Code:
function get_value(addr, datahex)
local obj = dt_cache[addr]
if obj == nil then
obj = grp.find(addr)
dt_cache[ addr ] = obj or false
end
if obj then
return knxdatatype.decode(datahex, obj.datatype), obj
end
end
function knx_callback(event)
local addr = event.dst
local value, obj = get_value(addr, event.datahex)
if value ~= nil then
send_metric('rawdata', obj.name, addr, value)
end
end