Merge pull request #598 from EdgeTX/maxChannels
Tweak max channel values for MPM generally, MPM DSM2 and DSM2
This commit is contained in:
@@ -567,6 +567,7 @@ class ModuleWindow : public FormGroup {
|
||||
channelStart->setMax(MAX_OUTPUT_CHANNELS - sentModuleChannels(moduleIdx) + 1);
|
||||
});
|
||||
channelEnd->enable(minModuleChannels(moduleIdx) < maxModuleChannels(moduleIdx));
|
||||
if (channelEnd->getValue() > channelEnd->getMax()) channelEnd->setValue(channelEnd->getMax());
|
||||
}
|
||||
|
||||
void update()
|
||||
|
||||
@@ -367,6 +367,16 @@ inline int8_t maxModuleChannels_M8(uint8_t moduleIdx)
|
||||
else if (isModuleAFHDS3(moduleIdx)) {
|
||||
return 10;
|
||||
}
|
||||
else if (isModuleDSM2(moduleIdx)) {
|
||||
return 0; // 8 channels
|
||||
}
|
||||
else if (isModuleMultimoduleDSM2(moduleIdx)) {
|
||||
return 4; // 12 channels
|
||||
}
|
||||
//TODO: This should be based on the selected protocol
|
||||
else if(isModuleMultimodule(moduleIdx)) {
|
||||
return 8; // 16 channels
|
||||
}
|
||||
else {
|
||||
return maxChannelsModules_M8[g_model.moduleData[moduleIdx].type];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user