From 74dfd64e29828b62fbe2117913891f2c0650175a Mon Sep 17 00:00:00 2001 From: bsongis Date: Tue, 1 Jul 2014 12:19:30 +0200 Subject: [PATCH] The background function is not anymore mandatory in Telemetry scripts --- radio/src/lua.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/radio/src/lua.cpp b/radio/src/lua.cpp index 97772780a..ff6a297bc 100644 --- a/radio/src/lua.cpp +++ b/radio/src/lua.cpp @@ -1137,6 +1137,7 @@ void luaInit() // Push OpenTX constants lua_registerint(L, "FULLSCALE", RESX); + lua_registerint(L, "XXLSIZE", XXLSIZE); lua_registerint(L, "DBLSIZE", DBLSIZE); lua_registerint(L, "MIDSIZE", MIDSIZE); lua_registerint(L, "SMLSIZE", SMLSIZE); @@ -1554,6 +1555,9 @@ void luaTask(uint8_t evt) else if (sid.background) { lua_rawgeti(L, LUA_REGISTRYINDEX, sid.background); } + else { + continue; + } } if (lua_pcall(L, inputsCount, sio ? sio->outputsCount : 0, 0) == 0) { if (sio) {