feat: Deadzone option for NV14 sticks (#1777)
Imported from open-flysky/Flysky-OpenTX-Test-Branch * companion: Don't nuke `stickDeadZone` setting * Implement data storage properly * Add missing check for NV14 storage struct sizes * Formatting * Use one less byte in the packed data struct Thanks @raphaelcoeffic :) * Move setting of stickDeadZone default * Use a Choice combo rather than NumberEdit * Good riddance magic number * Also set default stick zone if setting is missing * Teach tests about `STICK_DEAD_ZONE` * Tweak choice width * Cpn NV14 add stick dead zone to hardware and section labels * Cpn NV14 align default pot names to radio Co-authored-by: elecpower <neilh713@tpg.com.au>
This commit is contained in:
co-authored by
elecpower
parent
9d27a6923c
commit
d9b51f8ecf
@@ -823,7 +823,7 @@ PACK(struct TrainerData {
|
||||
#if defined(BUZZER)
|
||||
#define BUZZER_FIELD int8_t buzzerMode:2 // -2=quiet, -1=only alarms, 0=no keys, 1=all (only used on AVR radios without audio hardware)
|
||||
#else
|
||||
#define BUZZER_FIELD int8_t spare4:2 SKIP
|
||||
#define BUZZER_FIELD int8_t spare1:2 SKIP
|
||||
#endif
|
||||
|
||||
PACK(struct RadioData {
|
||||
@@ -913,6 +913,12 @@ PACK(struct RadioData {
|
||||
GYRO_FIELDS
|
||||
|
||||
NOBACKUP(int8_t uartSampleMode:2); // See UartSampleModes
|
||||
#if defined(STICK_DEAD_ZONE)
|
||||
NOBACKUP(uint8_t stickDeadZone:3);
|
||||
NOBACKUP(uint8_t spare2:3 SKIP);
|
||||
#else
|
||||
NOBACKUP(uint8_t spare2:6 SKIP);
|
||||
#endif
|
||||
});
|
||||
|
||||
#undef SWITCHES_WARNING_DATA
|
||||
|
||||
Reference in New Issue
Block a user