diff --git a/displayword.lua b/displayword.lua index 397a91a..f96c845 100644 --- a/displayword.lua +++ b/displayword.lua @@ -36,14 +36,8 @@ function generateLEDs(words, color) buf= buf .. space:rep(4) end -- line3---------------------------------------------- - --TODO ggf. auch ueber viertel vor abbildbar if (words.threequater == 1) then - if (threequater ~= nil) then - buf= buf .. color:rep(11) -- Dreiviertel - else - buf= buf .. space:rep(4) - buf= buf .. color:rep(7) -- VIERTEL - end + buf= buf .. color:rep(11) -- Dreiviertel elseif (words.quater == 1) then buf= buf .. space:rep(4) buf= buf .. color:rep(7) -- VIERTEL @@ -51,7 +45,7 @@ function generateLEDs(words, color) buf= buf .. space:rep(11) end --line 4-------- even row (so inverted) ------------- - if ((words.before == 1) or (words.threequater == 1 and threequater == nil)) then + if ((words.before == 1) or (words.threequater == 1)) then buf=buf .. space:rep(2) buf= buf .. color:rep(3) -- VOR else diff --git a/wordclock.lua b/wordclock.lua index 6a35939..c58b5a1 100755 --- a/wordclock.lua +++ b/wordclock.lua @@ -62,7 +62,13 @@ function display_timestat(hours, minutes, longmode) ret.twenty=1 ret.before=1 elseif (minutes==9) then - ret.threequater=1 + -- Hande if three quater or quater before is displayed + if (threequater ~= nil) then + ret.threequater=1 + else + ret.quater = 1 + ret.before = 1 + end elseif (minutes==10) then ret.tenMin=1 ret.before=1 @@ -125,3 +131,4 @@ function display_timestat(hours, minutes, longmode) collectgarbage() return ret end +