mirror of
https://github.com/MikaylaFischler/cc-mek-scada.git
synced 2024-08-30 18:22:34 +00:00
#476 fixed PPM not initing fault counter in __index handler when a function is found
This commit is contained in:
parent
0d8d7aeb15
commit
a786404092
@ -141,7 +141,9 @@ local function peri_init(iface)
|
||||
local funcs = peripheral.wrap(iface)
|
||||
if (type(funcs) == "table") and (type(funcs[key]) == "function") then
|
||||
-- add this function then return it
|
||||
self.fault_counts[key] = 0
|
||||
self.device[key] = protect_peri_function(key, funcs[key])
|
||||
|
||||
log.info(util.c("PPM: [@", iface, "] initialized previously undefined field ", key, "()"))
|
||||
|
||||
return self.device[key]
|
||||
|
@ -22,7 +22,7 @@ local t_pack = table.pack
|
||||
local util = {}
|
||||
|
||||
-- scada-common version
|
||||
util.version = "1.2.1"
|
||||
util.version = "1.2.2"
|
||||
|
||||
util.TICK_TIME_S = 0.05
|
||||
util.TICK_TIME_MS = 50
|
||||
|
Loading…
Reference in New Issue
Block a user