# HG changeset patch # User ideenmodellierer # Date 1585083578 -3600 # Node ID 1c0b911c367f4b13718d8a68e69a45c2af34a438 # Parent b90ddf57f7f1447fa4c79fe2f7c6c65388cf6fad Added compile variant enabling the reset of profile sample information: In case the sample ring has an overrun prior to the header ring then header will point to no longer available sample locations causing problems when the no longer existing samples are read. To avoid this also in earlier versions a variant has been added which enables the user to reset the invalid sample information by selecting the problematic dive in the infolog menu and pressing the middle button. Added function which confirms consistency of dive log settings: Meaning last dive and dive header are valid at startup. Repair and find lastDiveID are only called in case a inconsistency is detected diff -r b90ddf57f7f1 -r 1c0b911c367f Discovery/Inc/externLogbookFlash.h --- a/Discovery/Inc/externLogbookFlash.h Tue Mar 24 21:59:11 2020 +0100 +++ b/Discovery/Inc/externLogbookFlash.h Tue Mar 24 21:59:38 2020 +0100 @@ -149,7 +149,7 @@ void ext_flash_enable_protection(void); void ext_flash_read_block_start(void); - +uint8_t ext_dive_log_consistent(void); void ext_flash_repair_dive_log(void); uint8_t ext_flash_erase_firmware_if_not_empty(void); @@ -165,5 +165,6 @@ uint32_t ext_flash_AnalyseSampleBuffer(char *pstrResult); void ext_flash_CloseSector(void); +void ext_flash_invalidate_sample_index(uint32_t sectorStart); #endif /* EXTERN_LOGBOOK_FLASH_H */