mirror of
https://github.com/opentx/opentx.git
synced 2025-07-24 16:55:20 +03:00
X-Lite external antenna on internal module
This commit is contained in:
parent
0c09c07cd2
commit
c7e882e97d
2 changed files with 4 additions and 3 deletions
|
@ -264,7 +264,6 @@ bool menuModelSetup(event_t event)
|
|||
bool CURSOR_ON_CELL = (menuHorizontalPosition >= 0);
|
||||
|
||||
// Switch to external antenna confirmation
|
||||
bool newAntennaSel;
|
||||
if (warningResult) {
|
||||
warningResult = 0;
|
||||
g_model.moduleData[INTERNAL_MODULE].pxx.external_antenna = XJT_EXTERNAL_ANTENNA;
|
||||
|
@ -661,8 +660,9 @@ bool menuModelSetup(event_t event)
|
|||
break;
|
||||
|
||||
case ITEM_MODEL_INTERNAL_MODULE_ANTENNA:
|
||||
{
|
||||
lcdDrawText(MENUS_MARGIN_LEFT, y, STR_ANTENNASELECTION);
|
||||
newAntennaSel = editChoice(MODEL_SETUP_2ND_COLUMN, y, STR_VANTENNATYPES, g_model.moduleData[INTERNAL_MODULE].pxx.external_antenna, 0, 1, attr, event);
|
||||
uint8_t newAntennaSel = editChoice(MODEL_SETUP_2ND_COLUMN, y, STR_VANTENNATYPES, g_model.moduleData[INTERNAL_MODULE].pxx.external_antenna, 0, 1, attr, event);
|
||||
if (newAntennaSel != g_model.moduleData[INTERNAL_MODULE].pxx.external_antenna && newAntennaSel == XJT_EXTERNAL_ANTENNA) {
|
||||
POPUP_CONFIRMATION(STR_ANTENNACONFIRM1);
|
||||
const char * w = STR_ANTENNACONFIRM2;
|
||||
|
@ -672,6 +672,7 @@ bool menuModelSetup(event_t event)
|
|||
g_model.moduleData[INTERNAL_MODULE].pxx.external_antenna = newAntennaSel;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case ITEM_MODEL_TRAINER_MODE:
|
||||
lcdDrawText(MENUS_MARGIN_LEFT, y, STR_MODE);
|
||||
|
|
|
@ -376,7 +376,7 @@ void setupPulsesPXX(uint8_t port)
|
|||
uint8_t extra_flags = 0;
|
||||
|
||||
/* Ext. flag (holds antenna selection on Horus internal module, 0x00 otherwise) */
|
||||
#if defined(PCBHORUS)
|
||||
#if defined(PCBHORUS) || defined(PCBXLITE)
|
||||
if (port == INTERNAL_MODULE) {
|
||||
extra_flags |= (g_model.moduleData[port].pxx.external_antenna << 0);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue