diff --git a/sufst-controller/sd.cpp b/sufst-controller/sd.cpp index 692844938a8c222e92882ba716acb42ee1f76cf6..a3e330d96a38a67de50078c53ace8fbcaf904506 100644 --- a/sufst-controller/sd.cpp +++ b/sufst-controller/sd.cpp @@ -56,7 +56,7 @@ void sdProcess() sdWritesCntBeforeFlush++; - if (sdWritesCntBeforeFlush <= SD_WRITES_BEFORE_FLUSH) { + if (sdWritesCntBeforeFlush >= SD_WRITES_BEFORE_FLUSH) { file.flush(); sdWritesCntBeforeFlush = 0;