Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Flysky PL18 Support #4105

Merged
merged 57 commits into from
Dec 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
6aa74d2
feat: add bootloader support for flash erase
raphaelcoeffic Sep 24, 2023
075ff2f
feat: PL18 support
rotorman Dec 26, 2021
65ce1b5
feat: ADC driver timeout
raphaelcoeffic Sep 24, 2023
bb351fc
feat: use milliseconds for TRACE instead of a float
raphaelcoeffic Sep 25, 2023
573d8b8
WiP: no internal module
raphaelcoeffic Sep 26, 2023
e23fad0
Update cst340 driver to generic EXTI driver.
richardclli Oct 4, 2023
192db00
Fixed rebase problems due to changes in PR #3894.
richardclli Oct 6, 2023
2e2bc98
Fixed rebase problems due to changes in PR #4139.
richardclli Oct 9, 2023
df1b9e9
Workaround for interrupt occurs when touch panel is idle.
richardclli Oct 6, 2023
ced2648
Fixed some LCD bugs in PL18
Oct 11, 2023
e4fc082
Enable the support of UART7 internal module.
richardclli Oct 3, 2023
debdc3d
Fixed rebase problems due to changes in PR #3814.
richardclli Oct 13, 2023
ce5051b
Fixed rebase problems due to changes in PR #4104.
richardclli Oct 14, 2023
9c9bfae
Fixed compile error in B/W radios.
richardclli Oct 14, 2023
627d439
fix: T20 Trims
pfeerick Oct 15, 2023
7165b09
fix: PL18 tests
pfeerick Oct 15, 2023
08ea168
Fixed PL18 int MPM problem after PR #3822 and #4198.
richardclli Oct 16, 2023
1c0bc16
Update datastructs after rebase.
richardclli Oct 17, 2023
4d6c7ef
Added RTC Voltage ADC Settings.
richardclli Oct 17, 2023
bcc4a0b
PL18 has 3 pots.
richardclli Oct 17, 2023
759f881
Fixed LUA mixer problem due to changes in PR #3973.
richardclli Oct 19, 2023
6dd943a
Added default switch config for PL18.
richardclli Oct 19, 2023
816dd28
Amended some PL18 properties in companion.
richardclli Oct 19, 2023
3671f5a
Fixed rebase problem due to PR #4038
richardclli Oct 19, 2023
1097c84
Fixed rebase problems due to changes in PR #3036
richardclli Oct 25, 2023
40851fc
Fixed trims listing in diagnostics screen.
richardclli Oct 27, 2023
6ffbebe
Added PL18EV support.
richardclli Oct 28, 2023
bb7e8f6
Fixed PL18EV build problem.
richardclli Oct 28, 2023
a10b381
Missing PL18EV definition in commit-tests.sh
richardclli Oct 29, 2023
c15570e
fix: Erronous quote
pfeerick Oct 29, 2023
fda50b6
chore: Remove unused graphics
pfeerick Oct 29, 2023
7818eed
fix: Another erronous quote :laughing:
pfeerick Oct 29, 2023
b471014
Fine tuned PL18EV stick ends mapping.
richardclli Oct 30, 2023
41c50e2
Fixed a typo in comment.
richardclli Oct 31, 2023
8a22e7f
Fixed another problem of PL18EV mapping.
richardclli Oct 31, 2023
e8aa970
Cleaned up touch driver.
richardclli Oct 31, 2023
72af39b
Fixed rebase problems due to changes in PR #3870.
richardclli Nov 2, 2023
1177c55
Map PL18EV stick end pots and switched to EXT1-4.
richardclli Nov 2, 2023
fb26b69
Fixed rebase problem due to PR #4027.
richardclli Nov 6, 2023
3fd40af
chore: Update tests post #3279 merge
pfeerick Nov 7, 2023
56c0269
fix: Regenerate yaml post #4267
pfeerick Nov 10, 2023
3812c9c
chore: Update PL18 test image post #4290
pfeerick Nov 10, 2023
328175b
Fixed SPI flash problem in reading the chip ID.
richardclli Nov 13, 2023
56e9460
Fixed PL18EV ADC channels mapping.
richardclli Nov 14, 2023
8f59a38
Added companion build for pl18ev.
richardclli Nov 14, 2023
17f1f4f
Amended default pot configuration.
richardclli Nov 14, 2023
10a80b3
Refined PL18 bootloader.
richardclli Nov 15, 2023
3c2a921
Prevent calling to FrFTL when it is not initialized.
richardclli Nov 17, 2023
bd0b2bd
Added LED Strip.
richardclli Nov 18, 2023
7806585
Use LED strip for status LED.
richardclli Nov 20, 2023
2ba55ff
Fixed rebase problems due to changes in PR #4331.
richardclli Nov 20, 2023
219ade5
Fixed some typo in comments.
richardclli Nov 21, 2023
84544cb
Added LUA functionalities setup for RGB LEDs
richardclli Nov 23, 2023
0c82d08
Fixed problems in LCD detection
richardclli Nov 23, 2023
f46e188
chore: Update PL18 test image post #4337
richardclli Nov 28, 2023
9c4e24a
Fixed build problem post #3846
richardclli Dec 4, 2023
1b6d7b3
fix: Unnecessary changes, typos, formatting
pfeerick Dec 5, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .github/workflows/actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ jobs:
- tx16s
- nv14
- el18
- pl18
- pl18ev
pfeerick marked this conversation as resolved.
Show resolved Hide resolved
- t12
- t16
- t18
Expand Down Expand Up @@ -90,9 +92,9 @@ jobs:
matrix:
target:
- nv14;el18
- pl18;pl18ev
- t12
- t16
- t18
- t16;t18
- t8;zorro;pocket;mt12;commando8
- tlite;tpro;tprov2;lr3pro
- t20
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ jobs:
matrix:
target:
- nv14;el18
- pl18;pl18ev
- t12
- t16
- t18
Expand Down
2 changes: 2 additions & 0 deletions companion/src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -318,6 +318,8 @@ elseif(PCB STREQUAL X10 AND PCBREV STREQUAL T18)
set(FLAVOUR t18)
elseif(PCB STREQUAL NV14 AND PCBREV STREQUAL EL18)
set(FLAVOUR el18)
elseif(PCB STREQUAL PL18)
set(FLAVOUR pl18)
else()
string(TOLOWER ${PCB} FLAVOUR)
endif()
Expand Down
4 changes: 4 additions & 0 deletions companion/src/companion.qrc
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,10 @@
<file>images/simulator/NV14/right.png</file>
<file>images/simulator/NV14/top.png</file>
<file>images/simulator/NV14/bottom.png</file>
<file>images/simulator/PL18/left.png</file>
<file>images/simulator/PL18/right.png</file>
<file>images/simulator/PL18/top.png</file>
<file>images/simulator/PL18/bottom.png</file>
<file>images/wizard/ailerons.png</file>
<file>images/wizard/airbrakes.png</file>
<file>images/wizard/elevons.png</file>
Expand Down
49 changes: 42 additions & 7 deletions companion/src/firmwares/boards.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,9 @@ uint32_t Boards::getFourCC(Type board)
case BOARD_FLYSKY_NV14:
return 0x3A78746F;
case BOARD_FLYSKY_EL18:
return 0x3A78746F; // TODO: check this
return 0x3A78746F;
case BOARD_FLYSKY_PL18:
return 0x4878746F;
default:
return 0;
}
Expand Down Expand Up @@ -159,6 +161,7 @@ int Boards::getEEpromSize(Board::Type board)
case BOARD_RADIOMASTER_TX16S:
case BOARD_FLYSKY_NV14:
case BOARD_FLYSKY_EL18:
case BOARD_FLYSKY_PL18:
return 0;
default:
return 0;
Expand Down Expand Up @@ -206,6 +209,7 @@ int Boards::getFlashSize(Type board)
case BOARD_RADIOMASTER_TX16S:
case BOARD_FLYSKY_NV14:
case BOARD_FLYSKY_EL18:
case BOARD_FLYSKY_PL18:
return FSIZE_HORUS;
case BOARD_UNKNOWN:
return FSIZE_MAX;
Expand Down Expand Up @@ -419,6 +423,20 @@ SwitchInfo Boards::getSwitchInfo(Board::Type board, int index)
if (index < DIM(switches))
return switches[index];
}
else if (IS_FLYSKY_PL18(board)) {
const Board::SwitchInfo switches[] = {
{SWITCH_2POS, "SA"},
{SWITCH_3POS, "SB"},
{SWITCH_2POS, "SC"},
{SWITCH_3POS, "SD"},
{SWITCH_3POS, "SE"},
{SWITCH_2POS, "SF"},
{SWITCH_3POS, "SG"},
{SWITCH_3POS, "SH"}
};
if (index < DIM(switches))
return switches[index];
}
else if (IS_FAMILY_HORUS_OR_T16(board)) {
const Board::SwitchInfo switches[] = {
{SWITCH_3POS, "SA"},
Expand Down Expand Up @@ -497,6 +515,8 @@ int Boards::getCapability(Board::Type board, Board::Capability capability)
return 7;
else if (IS_HORUS_X12S(board))
return 3;
else if (IS_FLYSKY_PL18(board))
return 3;
else
return 3;

Expand All @@ -509,7 +529,7 @@ int Boards::getCapability(Board::Type board, Board::Capability capability)
case Sliders:
if (IS_HORUS_X12S(board) || IS_TARANIS_X9E(board) || IS_JUMPER_T20(board))
return 4;
else if (IS_TARANIS_X9D(board) || IS_HORUS_X10(board) || IS_FAMILY_T16(board))
else if (IS_TARANIS_X9D(board) || IS_HORUS_X10(board) || IS_FAMILY_T16(board) || IS_FLYSKY_PL18(board))
return 2;
else
return 0;
Expand All @@ -531,7 +551,7 @@ int Boards::getCapability(Board::Type board, Board::Capability capability)
getCapability(board, Board::MouseAnalogs) + getCapability(board, Board::GyroAnalogs);

case MultiposPots:
if (IS_HORUS_OR_TARANIS(board) && !(IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board)))
if (IS_HORUS_OR_TARANIS(board) && !(IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board) || IS_FLYSKY_PL18(board)))
return getCapability(board, Board::Pots);
else
return 0;
Expand All @@ -558,6 +578,8 @@ int Boards::getCapability(Board::Type board, Board::Capability capability)
return 6;
else if (board == BOARD_FLYSKY_NV14 || board == BOARD_FLYSKY_EL18)
return 8;
else if (board == BOARD_FLYSKY_PL18)
return 8;
else if (board == BOARD_RADIOMASTER_TX12_MK2 || board == BOARD_RADIOMASTER_BOXER || board == BOARD_JUMPER_TPRO)
return 6;
else if (board == BOARD_RADIOMASTER_POCKET)
Expand Down Expand Up @@ -600,7 +622,7 @@ int Boards::getCapability(Board::Type board, Board::Capability capability)
return getCapability(board, Board::Switches);

case SwitchPositions:
if (IS_HORUS_OR_TARANIS(board) || IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board))
if (IS_HORUS_OR_TARANIS(board) || IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board) || IS_FLYSKY_PL18(board))
return getCapability(board, Board::Switches) * 3;
else
return 9;
Expand All @@ -610,7 +632,9 @@ int Boards::getCapability(Board::Type board, Board::Capability capability)


case NumTrims:
if (IS_FAMILY_HORUS_OR_T16(board) && !(IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board)))
if (IS_FLYSKY_PL18(board))
return 8;
else if (IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board))
return 6;
else if (IS_IFLIGHT_COMMANDO8(board))
return 0;
Expand All @@ -626,7 +650,7 @@ int Boards::getCapability(Board::Type board, Board::Capability capability)
return IS_STM32(board) ? true : false;

case HasColorLcd:
return IS_FAMILY_HORUS_OR_T16(board);
return IS_FAMILY_HORUS_OR_T16(board) || IS_FLYSKY_NV14(board) || IS_FLYSKY_PL18(board);

case HasSDCard:
return IS_STM32(board);
Expand All @@ -647,7 +671,7 @@ int Boards::getCapability(Board::Type board, Board::Capability capability)
return false;

case SportMaxBaudRate:
if (IS_FAMILY_T16(board) || IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board) || IS_TARANIS_X7_ACCESS(board) ||
if (IS_FAMILY_T16(board) || IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board) || IS_FLYSKY_PL18(board) ||IS_TARANIS_X7_ACCESS(board) ||
(IS_TARANIS(board) && !IS_TARANIS_XLITE(board) && !IS_TARANIS_X7(board) && !IS_TARANIS_X9LITE(board)))
return 400000; // 400K and higher
else
Expand Down Expand Up @@ -833,6 +857,14 @@ StringTagMappingTable Boards::getAnalogNamesLookupTable(Board::Type board, const
{tr("TltY").toStdString(), "TILT_Y", 14},
});
}
} else if (IS_FLYSKY_PL18(board)) {
tbl.insert(tbl.end(), {
{tr("VRA").toStdString(), "POT1"},
{tr("VRB").toStdString(), "POT2"},
{tr("VRC").toStdString(), "POT3"},
{tr("LS").toStdString(), "LS"},
{tr("RS").toStdString(), "RS"},
});
} else if (IS_HORUS_X10(board) || IS_FAMILY_T16(board)) {
if (version < adcVersion) {
tbl.insert(tbl.end(), {
Expand Down Expand Up @@ -964,6 +996,8 @@ QString Boards::getBoardName(Board::Type board)
return "FlySky NV14";
case BOARD_FLYSKY_EL18:
return "FlySky EL18";
case BOARD_FLYSKY_PL18:
return "FlySky PL18";
case BOARD_BETAFPV_LR3PRO:
return "BETAFPV LR3PRO";
case BOARD_IFLIGHT_COMMANDO8:
Expand Down Expand Up @@ -1198,6 +1232,7 @@ int Boards::getDefaultInternalModules(Board::Type board)
case BOARD_JUMPER_TLITE_F4:
case BOARD_JUMPER_TPRO:
case BOARD_JUMPER_TPROV2:
case BOARD_FLYSKY_PL18:
return (int)MODULE_TYPE_MULTIMODULE;

case BOARD_BETAFPV_LR3PRO:
Expand Down
13 changes: 11 additions & 2 deletions companion/src/firmwares/boards.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ namespace Board {
BOARD_JUMPER_TLITE,
BOARD_JUMPER_TLITE_F4,
BOARD_FLYSKY_NV14,
BOARD_FLYSKY_PL18,
BOARD_RADIOMASTER_ZORRO,
BOARD_JUMPER_TPRO,
BOARD_BETAFPV_LR3PRO,
Expand Down Expand Up @@ -398,6 +399,11 @@ inline bool IS_FLYSKY_EL18(Board::Type board)
return (board == Board::BOARD_FLYSKY_EL18);
}

inline bool IS_FLYSKY_PL18(Board::Type board)
{
return (board == Board::BOARD_FLYSKY_PL18);
}

inline bool IS_TARANIS_XLITE(Board::Type board)
{
return board == Board::BOARD_TARANIS_XLITE || board == Board::BOARD_TARANIS_XLITES;
Expand Down Expand Up @@ -475,7 +481,9 @@ inline bool IS_FAMILY_HORUS(Board::Type board)

inline bool IS_FAMILY_HORUS_OR_T16(Board::Type board)
{
return IS_FAMILY_HORUS(board) || IS_FAMILY_T16(board) || IS_FLYSKY_NV14(board)/*generally*/ || IS_FLYSKY_EL18(board)/*generally*/;
return IS_FAMILY_HORUS(board) || IS_FAMILY_T16(board) ||
IS_FLYSKY_NV14(board)/*generally*/ || IS_FLYSKY_EL18(board)/*generally*/
|| IS_FLYSKY_PL18(board);
}

inline bool IS_HORUS_OR_TARANIS(Board::Type board)
Expand All @@ -485,7 +493,8 @@ inline bool IS_HORUS_OR_TARANIS(Board::Type board)

inline bool IS_STM32(Board::Type board)
{
return IS_TARANIS(board) || IS_FAMILY_HORUS_OR_T16(board) || IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board);
return IS_TARANIS(board) || IS_FAMILY_HORUS_OR_T16(board) ||
IS_FLYSKY_NV14(board) || IS_FLYSKY_EL18(board) || IS_FLYSKY_PL18(board);
}

inline bool IS_ARM(Board::Type board)
Expand Down
11 changes: 9 additions & 2 deletions companion/src/firmwares/generalsettings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,8 @@ void GeneralSettings::init()
strcpy(bluetoothName, "t16");
else if (IS_FLYSKY_NV14(board))
strcpy(bluetoothName, "nv14");
else if (IS_FLYSKY_PL18(board))
strcpy(bluetoothName, "pl18");
else if (IS_FAMILY_HORUS_OR_T16(board))
strcpy(bluetoothName, "horus");
else if (IS_TARANIS_X9E(board) || IS_TARANIS_SMALL(board))
Expand Down Expand Up @@ -269,7 +271,7 @@ void GeneralSettings::init()

internalModule = g.profile[g.sessionId()].defaultInternalModule();

if (IS_FLYSKY_NV14(board))
if (IS_FLYSKY_NV14(board) || IS_FLYSKY_PL18(board))
stickDeadZone = 2;

}
Expand All @@ -285,7 +287,7 @@ void GeneralSettings::setDefaultControlTypes(Board::Type board)
return;

// TODO: move to Boards, like with switches
if (IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board)) {
if (IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board) && !IS_FLYSKY_PL18(board)) {
potConfig[0] = Board::POT_WITH_DETENT;
potConfig[1] = Board::POT_MULTIPOS_SWITCH;
potConfig[2] = Board::POT_WITH_DETENT;
Expand All @@ -294,6 +296,11 @@ void GeneralSettings::setDefaultControlTypes(Board::Type board)
potConfig[0] = Board::POT_WITHOUT_DETENT;
potConfig[1] = Board::POT_WITHOUT_DETENT;
}
else if (IS_FLYSKY_PL18(board)) {
richardclli marked this conversation as resolved.
Show resolved Hide resolved
potConfig[0] = Board::POT_WITHOUT_DETENT;
potConfig[1] = Board::POT_WITHOUT_DETENT;
potConfig[2] = Board::POT_WITHOUT_DETENT;
}
else if (IS_TARANIS_XLITE(board)) {
potConfig[0] = Board::POT_WITHOUT_DETENT;
potConfig[1] = Board::POT_WITHOUT_DETENT;
Expand Down
20 changes: 10 additions & 10 deletions companion/src/firmwares/opentx/opentxeeprom.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ inline int MAX_POTS_STORAGE(Board::Type board, int version)
{
if (version <= 218 && IS_FAMILY_HORUS_OR_T16(board))
return 3;
if (version <= 220 && IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board))
if (version <= 220 && IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board) && !IS_FLYSKY_PL18(board))
return 5;
if (IS_FAMILY_T12(board))
return 2;
Expand Down Expand Up @@ -147,7 +147,7 @@ inline int MAX_XPOTS(Board::Type board, int version)

inline int MAX_SLIDERS_STORAGE(Board::Type board, int version)
{
if (version >= 219 && (IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board)))
if (version >= 219 && (IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board) && !IS_FLYSKY_PL18(board)))
return 4;
return Boards::getCapability(board, Board::Sliders);
}
Expand Down Expand Up @@ -183,7 +183,7 @@ inline int SWITCHES_CONFIG_SIZE(Board::Type board, int version)

inline int MAX_MOUSE_ANALOG_SOURCES(Board::Type board, int version)
{
if (IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board))
if (IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board) && !IS_FLYSKY_PL18(board))
return 2;
else
return 0;
Expand Down Expand Up @@ -211,10 +211,10 @@ inline int MAX_GYRO_ANALOGS(Board::Type board, int version)
#define MAX_CURVES(board, version) ((version >= 219 || HAS_LARGE_LCD(board)) ? 32 : 16)
#define MAX_GVARS(board, version) 9
#define MAX_SCRIPTS(board) (IS_FAMILY_HORUS_OR_T16(board) ? 9 : 7)
#define MAX_TELEMETRY_SENSORS(board, version) (version <= 218 ? 32 : ((IS_FAMILY_HORUS_OR_T16(board) || IS_TARANIS_X9(board) || IS_FLYSKY_NV14(board)) ? 60 : 40))
#define MAX_TELEMETRY_SENSORS(board, version) (version <= 218 ? 32 : ((IS_FAMILY_HORUS_OR_T16(board) || IS_TARANIS_X9(board) || IS_FLYSKY_NV14(board) || IS_FLYSKY_PL18(board)) ? 60 : 40))
#define NUM_PPM_INPUTS(board, version) 16
#define ROTENC_COUNT(board, version) ((IS_STM32(board) && version >= 218) ? 0 : 1)
#define MAX_AUX_TRIMS(board) ((IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board)) ? 2 : 0)
#define MAX_AUX_TRIMS(board) ((IS_FAMILY_HORUS_OR_T16(board) && !IS_FLYSKY_NV14(board) && !IS_FLYSKY_PL18(board)) ? 2 : 0)
#define MAX_SOURCE_TYPE_SPECIAL(board, version) SOURCE_TYPE_SPECIAL_COUNT

inline int switchIndex(int i, Board::Type board, unsigned int version)
Expand Down Expand Up @@ -2910,7 +2910,7 @@ void OpenTxModelData::beforeExport()

// TODO remove when enum not radio specific requires eeprom change and conversion
// Note: this must mirror reverse afterImport
if (!IS_FLYSKY_NV14(board))
if (!IS_FLYSKY_NV14(board) && !IS_FLYSKY_PL18(board))
modelData.trainerMode -= 1;

if (modelData.trainerMode > TRAINER_MODE_SLAVE_JACK) {
Expand Down Expand Up @@ -2957,7 +2957,7 @@ void OpenTxModelData::afterImport()

// TODO remove when enum not radio specific requires eeprom change and conversion
// Note: this must mirror reverse beforeExport
if (!IS_FLYSKY_NV14(board))
if (!IS_FLYSKY_NV14(board) && !IS_FLYSKY_PL18(board))
modelData.trainerMode += 1;

if (modelData.trainerMode > TRAINER_MODE_SLAVE_JACK) {
Expand Down Expand Up @@ -3003,7 +3003,7 @@ OpenTxGeneralData::OpenTxGeneralData(GeneralSettings & generalData, Board::Type

internalField.Append(new UnsignedField<16>(this, chkSum));

if (!IS_FAMILY_HORUS_OR_T16(board) || (IS_FLYSKY_NV14(board))) {
if (!IS_FAMILY_HORUS_OR_T16(board) || IS_FLYSKY_NV14(board) || IS_FLYSKY_PL18(board)) {
internalField.Append(new UnsignedField<8>(this, generalData.currModelIndex));
internalField.Append(new UnsignedField<8>(this, generalData.contrast));
}
Expand Down Expand Up @@ -3067,11 +3067,11 @@ OpenTxGeneralData::OpenTxGeneralData(GeneralSettings & generalData, Board::Type
internalField.Append(new SignedField<8>(this, generalData.PPM_Multiplier));
internalField.Append(new SignedField<8>(this, generalData.hapticLength));

if (version < 218 || (!IS_TARANIS(board) && !IS_FAMILY_HORUS_OR_T16(board)) || IS_FLYSKY_NV14(board)) {
if (version < 218 || (!IS_TARANIS(board) && !IS_FAMILY_HORUS_OR_T16(board)) || IS_FLYSKY_NV14(board) || IS_FLYSKY_PL18(board)) {
internalField.Append(new UnsignedField<8>(this, generalData.reNavigation));
}

if ((!IS_TARANIS(board) && !IS_FAMILY_HORUS_OR_T16(board)) || IS_FLYSKY_NV14(board)) {
if ((!IS_TARANIS(board) && !IS_FAMILY_HORUS_OR_T16(board)) || IS_FLYSKY_NV14(board) || IS_FLYSKY_PL18(board)) {
internalField.Append(new UnsignedField<8>(this, generalData.stickReverse));
}

Expand Down
Loading