Merge pull request #8232 from opentx/3djc/autoswitch-multipos

Support multipos in autosource/autoswitch
This commit is contained in:
Bertrand Songis
2021-01-19 15:28:38 +01:00
committed by GitHub
8 changed files with 35 additions and 13 deletions
+1 -1
View File
@@ -136,7 +136,7 @@ int checkIncDec(event_t event, int val, int i_min, int i_max, unsigned int i_fla
#if defined(AUTOSWITCH)
else {
uint8_t swtch = abs(getMovedSwitch());
if (swtch) {
if (swtch && !IS_SWITCH_MULTIPOS(swtch)) {
newval = switchToMix(swtch);
}
}
@@ -137,7 +137,7 @@ int checkIncDec(event_t event, int val, int i_min, int i_max, unsigned int i_fla
#if defined(AUTOSWITCH)
else {
unsigned int swtch = abs(getMovedSwitch());
if (swtch) {
if (swtch && !IS_SWITCH_MULTIPOS(swtch)) {
newval = switchToMix(swtch);
}
}
+1 -1
View File
@@ -106,7 +106,7 @@ int checkIncDec(event_t event, int val, int i_min, int i_max, unsigned int i_fla
#if defined(AUTOSWITCH)
else {
unsigned int swtch = abs(getMovedSwitch());
if (swtch) {
if (swtch && !IS_SWITCH_MULTIPOS(swtch)) {
newval = switchToMix(swtch);
}
}
+1 -1
View File
@@ -173,7 +173,7 @@ int checkIncDec(event_t event, int val, int i_min, int i_max, unsigned int i_fla
#if defined(AUTOSWITCH)
else {
unsigned int swtch = abs(getMovedSwitch());
if (swtch) {
if (swtch && !IS_SWITCH_MULTIPOS(swtch)) {
newval = switchToMix(swtch);
}
}
@@ -166,7 +166,7 @@ int checkIncDec(event_t event, int val, int i_min, int i_max, unsigned int i_fla
#if defined(AUTOSWITCH)
else {
uint8_t swtch = abs(getMovedSwitch());
if (swtch) {
if (swtch && !IS_SWITCH_MULTIPOS(swtch)) {
newval = switchToMix(swtch);
}
}