Skip to content

Commit

Permalink
remove my mess I created with EdgeTX#3355
Browse files Browse the repository at this point in the history
  • Loading branch information
mha1 committed Apr 6, 2023
1 parent 72be0d2 commit 8cf0124
Showing 1 changed file with 15 additions and 6 deletions.
21 changes: 15 additions & 6 deletions radio/src/storage/storage_common.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,16 +143,25 @@ void postModelLoad(bool alarms)

// fix colorLCD radios not writing yaml tag receivers
ModuleData *intModule = &g_model.moduleData[INTERNAL_MODULE];
ModuleData *extModule = &g_model.moduleData[EXTERNAL_MODULE];

for(uint8_t receiverIdx = 0; receiverIdx < 3; receiverIdx++) {
if(intModule->pxx2.receiverName[receiverIdx][0])
intModule->pxx2.receivers |= (1 << receiverIdx);
if(intModule->type == MODULE_TYPE_ISRM_PXX2) {
for(uint8_t receiverIdx = 0; receiverIdx < 3; receiverIdx++) {
if(intModule->pxx2.receiverName[receiverIdx][0])
intModule->pxx2.receivers |= (1 << receiverIdx);
}
}

ModuleData *extModule = &g_model.moduleData[EXTERNAL_MODULE];

if(extModule->pxx2.receiverName[receiverIdx][0])
extModule->pxx2.receivers |= (1 << receiverIdx);
if(extModule->type == MODULE_TYPE_ISRM_PXX2) {
for(uint8_t receiverIdx = 0; receiverIdx < 3; receiverIdx++) {
if(extModule->pxx2.receiverName[receiverIdx][0])
extModule->pxx2.receivers |= (1 << receiverIdx);
}
}

storageDirty(EE_MODEL);

#endif

#if defined(MULTIMODULE) && defined(MULTI_PROTOLIST)
Expand Down

0 comments on commit 8cf0124

Please sign in to comment.