feat(mpm): remove FrSky special treatment madness (#3032)
This commit is contained in:
@@ -173,7 +173,6 @@ static int luaModelGetModule(lua_State *L)
|
||||
if (module.type == MODULE_TYPE_MULTIMODULE) {
|
||||
int protocol = g_model.moduleData[idx].multi.rfProtocol + 1;
|
||||
int subprotocol = g_model.moduleData[idx].subType;
|
||||
convertEtxProtocolToMulti(&protocol, &subprotocol); // Special treatment for the FrSky entry...
|
||||
lua_pushtableinteger(L, "protocol", protocol);
|
||||
lua_pushtableinteger(L, "subProtocol", subprotocol);
|
||||
if (getMultiModuleStatus(idx).isValid()) {
|
||||
@@ -246,8 +245,7 @@ static int luaModelSetModule(lua_State *L)
|
||||
#endif
|
||||
}
|
||||
#if defined(MULTIMODULE)
|
||||
if (protocol > 0 && subprotocol >= 0) { // Both are needed to compute etx protocol
|
||||
convertMultiProtocolToEtx(&protocol, &subprotocol);
|
||||
if (protocol > 0 && subprotocol >= 0) {
|
||||
g_model.moduleData[idx].multi.rfProtocol = protocol - 1;
|
||||
g_model.moduleData[idx].subType = subprotocol;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user