2021/05/26

debug function for LUCI

 local debug = 0

function dbg_print(...)

if 1 == debug then

local dbg = io.open("/dev/console", "w")

    if dbg then

        dbg:write(os.date("[%H:%M:%S]: "))

        for _, o in ipairs({...}) do

            dbg:write(tostring(o)..'  ')

        end

        dbg:write("\n")

        dbg:close()

    end

end

end