refactoring displayword to a module
This commit is contained in:
parent
c3e48fb17a
commit
ba6734d5ad
@ -46,6 +46,10 @@ local data={}
|
|||||||
local generateLEDs = function(words, colorForground, colorMin1, colorMin2, colorMin3, colorMin4)
|
local generateLEDs = function(words, colorForground, colorMin1, colorMin2, colorMin3, colorMin4)
|
||||||
-- Set the local variables needed for the colored progress bar
|
-- Set the local variables needed for the colored progress bar
|
||||||
data={}
|
data={}
|
||||||
|
|
||||||
|
if (words == nil) then
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
local minutes=1
|
local minutes=1
|
||||||
if (words.min1 == 1) then
|
if (words.min1 == 1) then
|
||||||
@ -249,6 +253,7 @@ M = {
|
|||||||
round = round,
|
round = round,
|
||||||
drawLEDs = drawLEDs,
|
drawLEDs = drawLEDs,
|
||||||
updateColor = updateColor,
|
updateColor = updateColor,
|
||||||
|
data = data,
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
return M
|
return M
|
Loading…
Reference in New Issue
Block a user