diff --git a/radio/src/mixer.cpp b/radio/src/mixer.cpp index 8643aff15..4db7d0723 100755 --- a/radio/src/mixer.cpp +++ b/radio/src/mixer.cpp @@ -1067,12 +1067,3 @@ void evalMixes(uint8_t tick10ms) PORTH &= ~0x40; // PORTH:6 HIGH->LOW signals end of mixer interrupt #endif } - -#if !defined(CPUM64) && !defined(ACCURAT_THROTTLE_TIMER) - // code cost is about 16 bytes for higher throttle accuracy for timer - // would not be noticable anyway, because all version up to this change had only 16 steps; - // now it has already 32 steps; this define would increase to 128 steps - #define ACCURAT_THROTTLE_TIMER -#endif - - diff --git a/radio/src/opentx.cpp b/radio/src/opentx.cpp index 588cf2773..6afe3827d 100644 --- a/radio/src/opentx.cpp +++ b/radio/src/opentx.cpp @@ -2180,6 +2180,14 @@ void doMixerCalculations() #endif if (tick10ms) { + +#if !defined(CPUM64) && !defined(ACCURAT_THROTTLE_TIMER) + // code cost is about 16 bytes for higher throttle accuracy for timer + // would not be noticable anyway, because all version up to this change had only 16 steps; + // now it has already 32 steps; this define would increase to 128 steps + #define ACCURAT_THROTTLE_TIMER +#endif + /* Throttle trace */ int16_t val; @@ -2233,6 +2241,14 @@ void doMixerCalculations() val >>= (RESX_SHIFT-4); // calibrate it #endif + { + static int cnt = 0; + if (++cnt > 100) { + cnt = 0; + TRACE("Ttrace: %d", (int)val); + } + } + // Timers start for (uint8_t i=0; i