From bbc2e11cca29db8681955d18d7e95a9b5e497d3b Mon Sep 17 00:00:00 2001 From: Bertrand Songis Date: Sun, 10 Apr 2016 14:26:15 +0200 Subject: [PATCH] [Horus] Pots included in inputsMoved(...) function --- radio/src/gui/horus/widgets.cpp | 3 ++- radio/src/opentx.cpp | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/radio/src/gui/horus/widgets.cpp b/radio/src/gui/horus/widgets.cpp index 06e2e8de7..79debce31 100644 --- a/radio/src/gui/horus/widgets.cpp +++ b/radio/src/gui/horus/widgets.cpp @@ -307,7 +307,8 @@ void drawHorizontalSlider(coord_t x, coord_t y, int len, int val, int min, int m } else if (options & OPTION_SLIDER_NUMBER_BUTTON) { drawTrimSquare(x, y - 1); - lcdDrawChar(x + 2, y, '0' + val, SMLSIZE | TEXT_INVERTED_COLOR); + char text[] = { (char)('0' + val), '\0' }; + lcdDrawText(x + 5, y - 1, text, SMLSIZE | CENTERED | TEXT_INVERTED_COLOR); } else if (options & OPTION_SLIDER_SQUARE_BUTTON) { drawTrimSquare(x, y - 1); diff --git a/radio/src/opentx.cpp b/radio/src/opentx.cpp index a3f734171..92fa608ad 100644 --- a/radio/src/opentx.cpp +++ b/radio/src/opentx.cpp @@ -926,7 +926,7 @@ getvalue_t convert8bitsTelemValue(uint8_t channel, ls_telemetry_value_t value) bool inputsMoved() { uint8_t sum = 0; - for (uint8_t i=0; i> INAC_STICKS_SHIFT; for (uint8_t i=0; i> INAC_SWITCHES_SHIFT;