Browse Source

Wrangle HAL EEPROM types

vanilla_fb_2.0.x
Scott Lahteine 5 years ago
parent
commit
0fec478562
  1. 0
      Marlin/src/HAL/ESP32/eeprom.cpp
  2. 0
      Marlin/src/HAL/LINUX/eeprom.cpp
  3. 2
      Marlin/src/HAL/SAMD51/inc/Conditionals_post.h
  4. 0
      Marlin/src/HAL/STM32/eeprom_wired.cpp
  5. 0
      Marlin/src/HAL/STM32F1/eeprom_wired.cpp
  6. 4
      Marlin/src/HAL/TEENSY31_32/eeprom.cpp
  7. 5
      Marlin/src/HAL/TEENSY31_32/inc/Conditionals_post.h
  8. 4
      Marlin/src/HAL/TEENSY35_36/eeprom.cpp
  9. 4
      Marlin/src/HAL/TEENSY35_36/inc/Conditionals_post.h
  10. 4
      Marlin/src/inc/Conditionals_post.h

0
Marlin/src/HAL/ESP32/eeprom_impl.cpp → Marlin/src/HAL/ESP32/eeprom.cpp

0
Marlin/src/HAL/LINUX/eeprom_impl.cpp → Marlin/src/HAL/LINUX/eeprom.cpp

2
Marlin/src/HAL/SAMD51/inc/Conditionals_post.h

@ -21,6 +21,6 @@
*/ */
#pragma once #pragma once
#if USE_FALLBACK_EEPROM && NONE(SDCARD_EEPROM_EMULATION, SRAM_EEPROM_EMULATION) #if USE_FALLBACK_EEPROM
#define FLASH_EEPROM_EMULATION #define FLASH_EEPROM_EMULATION
#endif #endif

0
Marlin/src/HAL/STM32/eeprom_impl.cpp → Marlin/src/HAL/STM32/eeprom_wired.cpp

0
Marlin/src/HAL/STM32F1/eeprom.cpp → Marlin/src/HAL/STM32F1/eeprom_wired.cpp

4
Marlin/src/HAL/TEENSY31_32/eeprom_impl.cpp → Marlin/src/HAL/TEENSY31_32/eeprom.cpp

@ -20,7 +20,7 @@
#include "../../inc/MarlinConfig.h" #include "../../inc/MarlinConfig.h"
#if ENABLED(EEPROM_SETTINGS) #if USE_WIRED_EEPROM
#include "../shared/eeprom_api.h" #include "../shared/eeprom_api.h"
@ -58,5 +58,5 @@ bool PersistentStore::read_data(int &pos, uint8_t* value, size_t size, uint16_t
return false; return false;
} }
#endif // EEPROM_SETTINGS #endif // USE_WIRED_EEPROM
#endif // __MK20DX256__ #endif // __MK20DX256__

5
Marlin/src/HAL/TEENSY31_32/inc/Conditionals_post.h

@ -21,7 +21,6 @@
*/ */
#pragma once #pragma once
// If no real EEPROM, Flash emulation, or SRAM emulation is available fall back to SD emulation #if USE_FALLBACK_EEPROM
#if ENABLED(EEPROM_SETTINGS) && NONE(USE_WIRED_EEPROM, FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION) #define USE_WIRED_EEPROM 1
#define SDCARD_EEPROM_EMULATION
#endif #endif

4
Marlin/src/HAL/TEENSY35_36/eeprom.cpp

@ -25,7 +25,7 @@
#include "../../inc/MarlinConfig.h" #include "../../inc/MarlinConfig.h"
#if ENABLED(EEPROM_SETTINGS) #if USE_WIRED_EEPROM
#include "../shared/eeprom_api.h" #include "../shared/eeprom_api.h"
#include <avr/eeprom.h> #include <avr/eeprom.h>
@ -66,5 +66,5 @@ bool PersistentStore::read_data(int &pos, uint8_t* value, size_t size, uint16_t
size_t PersistentStore::capacity() { return E2END + 1; } size_t PersistentStore::capacity() { return E2END + 1; }
#endif // EEPROM_SETTINGS #endif // USE_WIRED_EEPROM
#endif // __MK64FX512__ || __MK66FX1M0__ #endif // __MK64FX512__ || __MK66FX1M0__

4
Marlin/src/HAL/TEENSY35_36/inc/Conditionals_post.h

@ -20,3 +20,7 @@
* *
*/ */
#pragma once #pragma once
#if USE_FALLBACK_EEPROM
#define USE_WIRED_EEPROM 1
#endif

4
Marlin/src/inc/Conditionals_post.h

@ -39,7 +39,9 @@
#if ENABLED(EEPROM_SETTINGS) #if ENABLED(EEPROM_SETTINGS)
// EEPROM type may be defined by compile flags, configs, HALs, or pins // EEPROM type may be defined by compile flags, configs, HALs, or pins
// Set additional flags to let HALs choose in their Conditionals_post.h // Set additional flags to let HALs choose in their Conditionals_post.h
#if NONE(FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION, SDCARD_EEPROM_EMULATION) && ANY(I2C_EEPROM, SPI_EEPROM, QSPI_EEPROM) #if ANY(FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION, SDCARD_EEPROM_EMULATION)
#define USE_EMULATED_EEPROM 1
#elif ANY(I2C_EEPROM, SPI_EEPROM, QSPI_EEPROM)
#define USE_WIRED_EEPROM 1 #define USE_WIRED_EEPROM 1
#else #else
#define USE_FALLBACK_EEPROM 1 #define USE_FALLBACK_EEPROM 1

Loading…
Cancel
Save