瀏覽代碼

begin pattern immediately if Q was empty

etisab 10 年之前
父節點
當前提交
0cdad01f08
共有 1 個文件被更改,包括 4 次插入4 次删除
  1. 4 4
      rebuild/led.lua

+ 4 - 4
rebuild/led.lua

@@ -49,10 +49,10 @@ end
 function enqueue(pattern)
   debug_message('enqueue')
   table.insert(Q, pattern)
-  -- debug_message('tmr.state ' .. tostring(tmr.state(TIMER)))
-  -- if not tmr.state(TIMER) then
-  --   next_pattern()
-  -- end
+  debug_message('tmr.state ' .. tostring(tmr.state(TIMER)))
+  if not tmr.state(TIMER) then
+    next_pattern()
+  end
 end
 
 function next_pattern()