From 96cf8df98e502bd9c8eb3976b062a73e1b382c3a Mon Sep 17 00:00:00 2001 From: bsongis Date: Wed, 11 Apr 2012 13:33:46 +0000 Subject: [PATCH] Corrections by Max --- src/general_menus.cpp | 2 +- src/open9x.cpp | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/general_menus.cpp b/src/general_menus.cpp index c8ae1aa9c..3d0638c5b 100644 --- a/src/general_menus.cpp +++ b/src/general_menus.cpp @@ -648,7 +648,7 @@ void menuProcDiagAna(uint8_t event) uint8_t x = i&1 ? 64+5 : 0; putsStrIdx(x, y, PSTR("A"), i+1, TWO_DOTS); lcd_outhex4(x+3*FW-1, y, anaIn(i)); - lcd_outdez8(x+10*FW-1, y, (int16_t)calibratedStick[i]*25/256); + lcd_outdez8(x+10*FW-1, y, (int16_t)calibratedStick[CONVERT_MODE(i+1)-1]*25/256); } #if !defined(PCBARM) diff --git a/src/open9x.cpp b/src/open9x.cpp index 7aadfac3d..ba8c27d77 100644 --- a/src/open9x.cpp +++ b/src/open9x.cpp @@ -2507,8 +2507,9 @@ int main(void) if(cModel!=g_eeGeneral.currModel) eeDirty(EE_GENERAL); // if model was quick-selected, make sure it sticks #if defined (PCBV4) -// Initialise global unix timestamp with current time from RTC chip on SD card interface - RTC rtc; + // TODO move this code inside board_gruvin9x.cpp + // Initialise global unix timestamp with current time from RTC chip on SD card interface + RTC rtc = {0,0,0,0,0,0,0}; struct gtm utm; rtc_gettime(&rtc); utm.tm_year = rtc.year - 1900;