I've added logging every 2 minute current CPU if it's above 1. I'm pretty sure that this isn't a problem here but let's log this.
I'm using such function to get current CPU usage stats:
But as I understand even if there will be some problem with writing to SD card LM shouldn't has a problem until restart.
I'm using such function to get current CPU usage stats:
Code:
function getCPUStats()
local f = assert(io.popen("cat /proc/loadavg"))
local loadavg = {}
for line in f:lines() do table.insert(loadavg, line) end
f:close()
-- 0.16 0.19 0.15 1/69 16886
loadavg = loadavg[1]:split(' ')
for i=1, 5, 1 do
if i ~= 4 then loadavg[i] = tonumber(loadavg[i]) end
end
return loadavg
end
But as I understand even if there will be some problem with writing to SD card LM shouldn't has a problem until restart.
Done is better than perfect