From d5411a4f87a2d28747e898bfe71091fad879e7e3 Mon Sep 17 00:00:00 2001 From: bsongis Date: Fri, 11 May 2012 21:20:16 +0000 Subject: [PATCH] [Simu] THR warning was not working --- src/open9x.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/open9x.cpp b/src/open9x.cpp index f30dccb94..a537b063f 100644 --- a/src/open9x.cpp +++ b/src/open9x.cpp @@ -844,9 +844,10 @@ void checkTHR() int thrchn=(2-(stickMode&1));//stickMode=0123 -> thr=2121 +#ifdef SIMU + int16_t lowLim = THRCHK_DEADBAND - 1024 ; +#else int16_t lowLim = THRCHK_DEADBAND + g_eeGeneral.calibMid[thrchn] - g_eeGeneral.calibSpanNeg[thrchn]; - -#ifndef SIMU getADC_single(); // if thr is down - do not display warning at all #endif int16_t v = anaIn(thrchn);