# HG changeset patch # User ideenmodellierer # Date 1586886334 -7200 # Node ID 04d94851cd1b102c404ae85a20329aaccc9ec8c7 # Parent aa1d71875e257064e9f811b6209dd000ba50c878 Removed no longer needed reset profile function: The function was used to mark a profile as invalid. It has been replaced by a comparison between sample and header profile length values. diff -r aa1d71875e25 -r 04d94851cd1b Discovery/Src/tInfoLog.c --- a/Discovery/Src/tInfoLog.c Tue Apr 14 19:44:19 2020 +0200 +++ b/Discovery/Src/tInfoLog.c Tue Apr 14 19:45:34 2020 +0200 @@ -66,9 +66,6 @@ void stepBackInfo(void); void stepForwardInfo(void); void showLogExit(void); -#ifdef ENABLE_PROFILE_RESET -void resetDiveProfile(void); -#endif /* Exported functions --------------------------------------------------------*/ void tInfoLog_init(void) @@ -181,9 +178,6 @@ switch(sendAction) { case ACTION_BUTTON_ENTER: -#ifdef ENABLE_PROFILE_RESET - resetDiveProfile(); -#endif break; case ACTION_BUTTON_NEXT: showNextLogPage(); @@ -437,21 +431,3 @@ show_logbook_test(0, stepBack); } -#ifdef ENABLE_PROFILE_RESET -void resetDiveProfile() -{ - uint8_t stepBack; - SLogbookHeader logbookHeader; - convert_Type dataStart; - stepBack = (6 * (infolog.page - 1)) + infolog.line - 1; /* calculate current dive ID */ - logbook_getHeader(stepBack ,&logbookHeader); - - dataStart.u8bit.byteHigh = 0; - dataStart.u8bit.byteLow = logbookHeader.pBeginProfileData[0]; - dataStart.u8bit.byteMidLow = logbookHeader.pBeginProfileData[1]; - dataStart.u8bit.byteMidHigh = logbookHeader.pBeginProfileData[2]; - - dataStart.u32bit &= 0xFFFF0000; /* set to sector start */ - ext_flash_invalidate_sample_index(dataStart.u32bit); -} -#endif