Explorar el Código

Fix STM32F1 SD-based EEPROM emulation (#13475)

If `openFile` is given `true`, then it has read-only access. Because all the writing occurs on the next line, this breaks SD card as EEPROM.
pinchies hace 6 años
padre
commit
ef3b93daa1
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1
    1
      Marlin/src/HAL/HAL_STM32F1/persistent_store_sdcard.cpp

+ 1
- 1
Marlin/src/HAL/HAL_STM32F1/persistent_store_sdcard.cpp Ver fichero

@@ -55,7 +55,7 @@ bool PersistentStore::access_start() {
55 55
 
56 56
 bool PersistentStore::access_finish() {
57 57
   if (!card.isDetected()) return false;
58
-  card.openFile(eeprom_filename, true);
58
+  card.openFile(eeprom_filename, false);
59 59
   int16_t bytes_written = card.write(HAL_STM32F1_eeprom_content, HAL_STM32F1_EEPROM_SIZE);
60 60
   card.closefile();
61 61
   return (bytes_written == HAL_STM32F1_EEPROM_SIZE);

Loading…
Cancelar
Guardar