diff --git a/radio/src/opentx.cpp b/radio/src/opentx.cpp index f20fc27c6..404c49784 100644 --- a/radio/src/opentx.cpp +++ b/radio/src/opentx.cpp @@ -1020,11 +1020,7 @@ void checkTrims() } #if !defined(SIMU) -#if defined(FLYSKY_HALL_STICKS) uint32_t s_anaFilt[NUM_ANALOGS]; -#else -uint16_t s_anaFilt[NUM_ANALOGS]; -#endif #endif #if defined(JITTER_MEASURE) @@ -1068,8 +1064,8 @@ void getADC() DEBUG_TIMER_STOP(debugTimerAdcRead); for (uint8_t x=0; x> (1 - ANALOG_SCALE); } else { @@ -1088,7 +1084,6 @@ void getADC() #endif } #else - uint16_t v; v = getAnalogValue(x) >> (1 - ANALOG_SCALE); #endif @@ -1126,13 +1121,8 @@ void getADC() // Variables mapping: // * = v // * = s_anaFilt[x] -#if defined(FLYSKY_HALL_STICKS) uint32_t previous = s_anaFilt[x] / JITTER_ALPHA; uint32_t diff = (v > previous) ? (v - previous) : (previous - v); -#else - uint16_t previous = s_anaFilt[x] / JITTER_ALPHA; - uint16_t diff = (v > previous) ? (v - previous) : (previous - v); -#endif if (!g_eeGeneral.jitterFilter && diff < (10*ANALOG_MULTIPLIER)) { // g_eeGeneral.jitterFilter is inverted, 0 - active // apply jitter filter s_anaFilt[x] = (s_anaFilt[x] - previous) + v; diff --git a/radio/src/opentx.h b/radio/src/opentx.h index f20aecfe2..527166329 100644 --- a/radio/src/opentx.h +++ b/radio/src/opentx.h @@ -1280,11 +1280,7 @@ extern Clipboard clipboard; #endif #if !defined(SIMU) -#if defined(FLYSKY_HALL_STICKS) extern uint32_t s_anaFilt[NUM_ANALOGS]; -#else -extern uint16_t s_anaFilt[NUM_ANALOGS]; -#endif #endif #if defined(JITTER_MEASURE)