Do lcdWaitDmaEnd() in perMain()

This commit is contained in:
Damjan Adamic
2014-12-07 10:24:27 +01:00
parent f8203b72f7
commit 6f46ef23da
4 changed files with 7 additions and 12 deletions
+7
View File
@@ -131,6 +131,13 @@ void perMain()
// run Lua scripts that don't use LCD (to use CPU time while LCD DMA is running)
luaRunNonGuiScripts();
// wait for LCD DMA to finish before continuing, because code from this point
// is allowed to change the contents of LCD buffer
//
// WARNING: make sure no code above this line does any change to the LCD display buffer!
//
lcdWaitDmaEnd();
// draw LCD from menus or from Lua script
if (luaRunGuiScripts(evt)) { // either stand-alone or telemetry scripts
// let Lua manage LCD fully