diff --git a/companion/src/firmwares/opentx/opentxeeprom.cpp b/companion/src/firmwares/opentx/opentxeeprom.cpp index 466f8dfa5..588bb6562 100644 --- a/companion/src/firmwares/opentx/opentxeeprom.cpp +++ b/companion/src/firmwares/opentx/opentxeeprom.cpp @@ -86,8 +86,10 @@ class SwitchesConversionTable: public ConversionTable { addConversion(RawSwitch(SWITCH_TYPE_VIRTUAL, i), val++); } - addConversion(RawSwitch(SWITCH_TYPE_OFF), -val+offset); - addConversion(RawSwitch(SWITCH_TYPE_ON), val++); + if (!(flags & POPULATE_TIMER_MODES)) { + addConversion(RawSwitch(SWITCH_TYPE_OFF), -val+offset); + addConversion(RawSwitch(SWITCH_TYPE_ON), val++); + } if (version < 216) { // previous "moment" switches diff --git a/radio/src/eeprom_conversions.cpp b/radio/src/eeprom_conversions.cpp index f1fbe8c83..af715fef8 100644 --- a/radio/src/eeprom_conversions.cpp +++ b/radio/src/eeprom_conversions.cpp @@ -387,12 +387,14 @@ int ConvertSwitch_215_to_216(int swtch) return -ConvertSwitch_215_to_216(-swtch); else if (swtch <= SWSRC_LAST_SWITCH) return swtch; + else if (swtch > SWSRC_LAST_SWITCH + 32) { + swtch -= (22+32); + if (swtch > SWSRC_ON) + swtch = 0; + return swtch; + } else { swtch += (2*4) + (3*6); // 4 trims and 2 * 6-pos added as switches - if (swtch > SWSRC_ON) - swtch -= (22+32+1); - if (swtch > SWSRC_ON) - swtch = SWSRC_ON; return swtch; } }