From 6d3fdfc03a5ce9245eebd2c5677726550038ab8c Mon Sep 17 00:00:00 2001 From: Craig Elder Date: Mon, 9 Jul 2012 15:23:35 -0700 Subject: [PATCH] DataFlash: The current method for checking if chip erase worked is producing false positives. We are forcing the block erase until we have a deterministic test method. --- libraries/DataFlash/DataFlash.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libraries/DataFlash/DataFlash.cpp b/libraries/DataFlash/DataFlash.cpp index 8ad82c2ecc..c09b351f61 100644 --- a/libraries/DataFlash/DataFlash.cpp +++ b/libraries/DataFlash/DataFlash.cpp @@ -201,7 +201,10 @@ void DataFlash_Class::EraseAll(void (*delay_cb)(unsigned long)) StartRead(df_NumPages+1); int32_t format = ReadLong(); - if (format == DF_LOGGING_FORMAT_INVALID) { +// if (format == DF_LOGGING_FORMAT_INVALID) +// the current method for checking if chip erase worked is producing false positives +// we are forcing the block erase until we have a deterministic test method + { // the chip erase didn't work - fall back to a erasing // each page separately. The errata on the APM2 dataflash chip // suggests that chip erase won't always work