mirror of
https://github.com/opentx/opentx.git
synced 2025-07-16 04:45:17 +03:00
Fix Horus haptic mode (#4224)
This commit is contained in:
parent
d9d7920c1c
commit
9bbc595eb1
2 changed files with 7 additions and 2 deletions
|
@ -3595,12 +3595,16 @@ OpenTxGeneralData::OpenTxGeneralData(GeneralSettings & generalData, BoardEnum bo
|
|||
}
|
||||
if (version >= 216 && IS_TARANIS(board))
|
||||
internalField.Append(new SignedField<3>(generalData.splashDuration));
|
||||
else if (version >= 213 || (!IS_ARM(board) && version >= 212))
|
||||
else if ((version >= 213 && !IS_HORUS(board)) || (!IS_ARM(board) && version >= 212))
|
||||
internalField.Append(new UnsignedField<3>(generalData.splashMode)); // TODO
|
||||
else
|
||||
else if (!IS_HORUS(board))
|
||||
internalField.Append(new SpareBitsField<3>());
|
||||
|
||||
internalField.Append(new SignedField<2>((int &)generalData.hapticMode));
|
||||
|
||||
if (IS_HORUS(board))
|
||||
internalField.Append(new SpareBitsField<3>());
|
||||
|
||||
if (IS_ARM(board))
|
||||
internalField.Append(new SignedField<8>(generalData.switchesDelay));
|
||||
else
|
||||
|
|
|
@ -999,6 +999,7 @@ PACK(struct RadioData {
|
|||
NOBACKUP(uint8_t mavbaud:3);
|
||||
SPLASH_MODE; /* 3bits */
|
||||
NOBACKUP(int8_t hapticMode:2); // -2=quiet, -1=only alarms, 0=no keys, 1=all
|
||||
HORUS_FIELD(int8_t splashSpares:3);
|
||||
AVR_FIELD(uint8_t blOffBright:4)
|
||||
AVR_FIELD(uint8_t blOnBright:4)
|
||||
ARM_FIELD(int8_t switchesDelay)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue