From 998cba55218a5a39a79acae51b3a103a93958a50 Mon Sep 17 00:00:00 2001 From: rusefi Date: Sun, 6 Feb 2022 18:46:09 -0500 Subject: [PATCH] EFI_LAUNCH_CONTROL clean-up --- firmware/controllers/algo/engine.h | 3 +-- firmware/controllers/lua/lua_hooks.cpp | 2 ++ 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/firmware/controllers/algo/engine.h b/firmware/controllers/algo/engine.h index 15cf8a76ec..7d4f49368d 100644 --- a/firmware/controllers/algo/engine.h +++ b/firmware/controllers/algo/engine.h @@ -201,9 +201,8 @@ public: GearControllerBase *gearController; #if EFI_LAUNCH_CONTROL LaunchControlBase launchController; -#endif // EFI_LAUNCH_CONTROL - SoftSparkLimiter softSparkLimiter; +#endif // EFI_LAUNCH_CONTROL #if EFI_BOOST_CONTROL BoostController boostController; diff --git a/firmware/controllers/lua/lua_hooks.cpp b/firmware/controllers/lua/lua_hooks.cpp index 6d50b80b79..322009fef6 100644 --- a/firmware/controllers/lua/lua_hooks.cpp +++ b/firmware/controllers/lua/lua_hooks.cpp @@ -497,11 +497,13 @@ void configureRusefiLuaHooks(lua_State* l) { return 1; }); +#if EFI_LAUNCH_CONTROL lua_register(l, "setSparkSkipRatio", [](lua_State* l) { auto targetSkipRatio = luaL_checknumber(l, 1); engine->softSparkLimiter.setTargetSkipRatio(targetSkipRatio); return 1; }); +#endif // EFI_LAUNCH_CONTROL lua_register(l, "enableCanTx", [](lua_State* l) { engine->allowCanTx = lua_toboolean(l, 1);