LPC1768 EEPROM fallback to flash, add overrides (#17184)

2.0.x
Scott Lahteine 5 years ago committed by GitHub
parent 2fc0df1b39
commit b14c933171
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -24,5 +24,5 @@
#if USE_EMULATED_EEPROM #if USE_EMULATED_EEPROM
#undef SRAM_EEPROM_EMULATION #undef SRAM_EEPROM_EMULATION
#undef SDCARD_EEPROM_EMULATION #undef SDCARD_EEPROM_EMULATION
#define FLASH_EEPROM_EMULATION 1 #define FLASH_EEPROM_EMULATION
#endif #endif

@ -20,3 +20,8 @@
* *
*/ */
#pragma once #pragma once
// If no real EEPROM, Flash emulation, or SRAM emulation is available fall back to SD emulation
#if ENABLED(EEPROM_SETTINGS) && NONE(USE_REAL_EEPROM, FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION)
#define SDCARD_EEPROM_EMULATION
#endif

@ -21,10 +21,6 @@
*/ */
#pragma once #pragma once
#if ENABLED(EEPROM_SETTINGS) #if USE_EMULATED_EEPROM && NONE(SDCARD_EEPROM_EMULATION, SRAM_EEPROM_EMULATION)
#undef USE_REAL_EEPROM #define FLASH_EEPROM_EMULATION
#define USE_EMULATED_EEPROM 1
#if DISABLED(FLASH_EEPROM_EMULATION)
#define SDCARD_EEPROM_EMULATION 1
#endif
#endif #endif

@ -36,12 +36,11 @@
* 16Kb I/O buffers (intended to hold DMA USB and Ethernet data, but currently * 16Kb I/O buffers (intended to hold DMA USB and Ethernet data, but currently
* unused). * unused).
*/ */
#include "../../inc/MarlinConfigPre.h" #include "../../inc/MarlinConfig.h"
#if ENABLED(FLASH_EEPROM_EMULATION) #if ENABLED(FLASH_EEPROM_EMULATION)
#include "persistent_store_api.h" #include "persistent_store_api.h"
#include "../../inc/MarlinConfig.h"
extern "C" { extern "C" {
#include <lpc17xx_iap.h> #include <lpc17xx_iap.h>

@ -24,5 +24,5 @@
#if USE_EMULATED_EEPROM #if USE_EMULATED_EEPROM
#undef SRAM_EEPROM_EMULATION #undef SRAM_EEPROM_EMULATION
#undef SDCARD_EEPROM_EMULATION #undef SDCARD_EEPROM_EMULATION
#define FLASH_EEPROM_EMULATION 1 #define FLASH_EEPROM_EMULATION
#endif #endif

@ -20,3 +20,8 @@
* *
*/ */
#pragma once #pragma once
// If no real EEPROM, Flash emulation, or SRAM emulation is available fall back to SD emulation
#if ENABLED(EEPROM_SETTINGS) && NONE(USE_REAL_EEPROM, FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION)
#define SDCARD_EEPROM_EMULATION
#endif

@ -23,8 +23,7 @@
#if ENABLED(EEPROM_SETTINGS) && defined(STM32F7) #if ENABLED(EEPROM_SETTINGS) && defined(STM32F7)
#undef USE_REAL_EEPROM #undef USE_REAL_EEPROM
#define USE_EMULATED_EEPROM 1
#undef SRAM_EEPROM_EMULATION #undef SRAM_EEPROM_EMULATION
#undef SDCARD_EEPROM_EMULATION #undef SDCARD_EEPROM_EMULATION
#define FLASH_EEPROM_EMULATION 1 #define FLASH_EEPROM_EMULATION
#endif #endif

@ -20,3 +20,8 @@
* *
*/ */
#pragma once #pragma once
// If no real EEPROM, Flash emulation, or SRAM emulation is available fall back to SD emulation
#if ENABLED(EEPROM_SETTINGS) && NONE(USE_REAL_EEPROM, FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION)
#define SDCARD_EEPROM_EMULATION
#endif

@ -35,15 +35,13 @@
#define HAS_LINEAR_E_JERK 1 #define HAS_LINEAR_E_JERK 1
#endif #endif
// If no real EEPROM, Flash emulation, or SRAM emulation is available fall back to SD emulation
#if ENABLED(EEPROM_SETTINGS) #if ENABLED(EEPROM_SETTINGS)
#if NONE(FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION, SDCARD_EEPROM_EMULATION) && EITHER(I2C_EEPROM, SPI_EEPROM) #if NONE(FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION, SDCARD_EEPROM_EMULATION) && EITHER(I2C_EEPROM, SPI_EEPROM)
#define USE_REAL_EEPROM 1 #define USE_REAL_EEPROM 1
#else #else
#define USE_EMULATED_EEPROM 1 #define USE_EMULATED_EEPROM 1
#endif #endif
#if NONE(USE_REAL_EEPROM, FLASH_EEPROM_EMULATION, SRAM_EEPROM_EMULATION)
#define SDCARD_EEPROM_EMULATION 1
#endif
#else #else
#undef I2C_EEPROM #undef I2C_EEPROM
#undef SPI_EEPROM #undef SPI_EEPROM

@ -1993,9 +1993,24 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
static_assert(PWM_PIN(E2_AUTO_FAN_PIN), "E2" AF_ERR_SUFF); static_assert(PWM_PIN(E2_AUTO_FAN_PIN), "E2" AF_ERR_SUFF);
#elif HAS_AUTO_FAN_3 #elif HAS_AUTO_FAN_3
static_assert(PWM_PIN(E3_AUTO_FAN_PIN), "E3" AF_ERR_SUFF); static_assert(PWM_PIN(E3_AUTO_FAN_PIN), "E3" AF_ERR_SUFF);
#elif HAS_AUTO_FAN_4
static_assert(PWM_PIN(E4_AUTO_FAN_PIN), "E4" AF_ERR_SUFF);
#elif HAS_AUTO_FAN_5
static_assert(PWM_PIN(E5_AUTO_FAN_PIN), "E5" AF_ERR_SUFF);
#elif HAS_AUTO_FAN_6
static_assert(PWM_PIN(E6_AUTO_FAN_PIN), "E6" AF_ERR_SUFF);
#elif HAS_AUTO_FAN_7
static_assert(PWM_PIN(E7_AUTO_FAN_PIN), "E7" AF_ERR_SUFF);
#endif #endif
#endif #endif
/**
* Make sure only one EEPROM type is enabled
*/
#if ENABLED(EEPROM_SETTINGS) && 1 < ENABLED(SDCARD_EEPROM_EMULATION) + ENABLED(FLASH_EEPROM_EMULATION) + ENABLED(SRAM_EEPROM_EMULATION)
#error "Please select only one of SDCARD, FLASH, or SRAM_EEPROM_EMULATION."
#endif
/** /**
* Make sure only one display is enabled * Make sure only one display is enabled
*/ */

@ -31,6 +31,12 @@
#define BOARD_INFO_NAME "AZSMZ MINI" #define BOARD_INFO_NAME "AZSMZ MINI"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //

@ -38,6 +38,12 @@
#define BOARD_INFO_NAME "BIQU Thunder B300 V1.0" #define BOARD_INFO_NAME "BIQU Thunder B300 V1.0"
#endif #endif
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Limit Switches // Limit Switches
// //

@ -36,6 +36,12 @@
#define BOARD_INFO_NAME "BIQU BQ111-A4" #define BOARD_INFO_NAME "BIQU BQ111-A4"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Limit Switches // Limit Switches
// //

@ -23,6 +23,12 @@
#define BOARD_INFO_NAME "BIGTREE SKR 1.1" #define BOARD_INFO_NAME "BIGTREE SKR 1.1"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Limit Switches // Limit Switches
// //

@ -23,6 +23,12 @@
#define BOARD_INFO_NAME "BIGTREE SKR 1.3" #define BOARD_INFO_NAME "BIGTREE SKR 1.3"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
/** /**
* Trinamic Stallguard pins * Trinamic Stallguard pins
*/ */

@ -25,6 +25,14 @@
#define BOARD_INFO_NAME "BIGTREE SKR 1.4" #define BOARD_INFO_NAME "BIGTREE SKR 1.4"
#endif #endif
//
// EEPROM
//
#if NONE(FLASH_EEPROM_EMULATION, SDCARD_EEPROM_EMULATION)
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
#endif
// //
// SD Connection // SD Connection
// //

@ -32,6 +32,10 @@
// Ignore temp readings during development. // Ignore temp readings during development.
//#define BOGUS_TEMPERATURE_GRACE_PERIOD 2000 //#define BOGUS_TEMPERATURE_GRACE_PERIOD 2000
#if DISABLED(SDCARD_EEPROM_EMULATION)
#define FLASH_EEPROM_EMULATION
#endif
// //
// Steppers // Steppers
// //

@ -30,6 +30,12 @@
// Ignore temp readings during develpment. // Ignore temp readings during develpment.
//#define BOGUS_TEMPERATURE_GRACE_PERIOD 2000 //#define BOGUS_TEMPERATURE_GRACE_PERIOD 2000
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Enable 12MHz clock output on P1.27 pin to sync TMC2208 chip clocks // Enable 12MHz clock output on P1.27 pin to sync TMC2208 chip clocks
// //

@ -38,6 +38,14 @@
#define BOARD_WEBSITE_URL "github.com/makerbase-mks/MKS-SBASE" #define BOARD_WEBSITE_URL "github.com/makerbase-mks/MKS-SBASE"
#endif #endif
//
// EEPROM
//
#if NONE(FLASH_EEPROM_EMULATION, SDCARD_EEPROM_EMULATION)
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
#endif
#define LED_PIN P1_18 // Used as a status indicator #define LED_PIN P1_18 // Used as a status indicator
#define LED2_PIN P1_19 #define LED2_PIN P1_19
#define LED3_PIN P1_20 #define LED3_PIN P1_20

@ -32,6 +32,12 @@
#define BOARD_INFO_NAME "MKS SGen-L" #define BOARD_INFO_NAME "MKS SGen-L"
#define BOARD_WEBSITE_URL "github.com/makerbase-mks/MKS-SGEN_L" #define BOARD_WEBSITE_URL "github.com/makerbase-mks/MKS-SGEN_L"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //

@ -42,6 +42,12 @@
#define BOARD_INFO_NAME "Re-ARM RAMPS 1.4" #define BOARD_INFO_NAME "Re-ARM RAMPS 1.4"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //

@ -32,6 +32,12 @@
#define BOARD_INFO_NAME "Selena Compact" #define BOARD_INFO_NAME "Selena Compact"
#define BOARD_WEBSITE_URL "github.com/Ales2-k/Selena" #define BOARD_WEBSITE_URL "github.com/Ales2-k/Selena"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //

@ -32,6 +32,12 @@
#define BOARD_INFO_NAME "Azteeg X5 GT" #define BOARD_INFO_NAME "Azteeg X5 GT"
#define BOARD_WEBSITE_URL "tinyurl.com/yx8tdqa3" #define BOARD_WEBSITE_URL "tinyurl.com/yx8tdqa3"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //
@ -47,7 +53,6 @@
#define Z_MIN_PIN P1_26 #define Z_MIN_PIN P1_26
#define Z_MAX_PIN P1_29 #define Z_MAX_PIN P1_29
// //
// Steppers // Steppers
// //

@ -187,6 +187,14 @@
#endif // HAS_SPI_LCD #endif // HAS_SPI_LCD
//
// EEPROM
//
#if NONE(FLASH_EEPROM_EMULATION, SDCARD_EEPROM_EMULATION)
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
#endif
// //
// SD Support // SD Support
// //

@ -31,6 +31,12 @@
#define BOARD_INFO_NAME "Azteeg X5 MINI WIFI" #define BOARD_INFO_NAME "Azteeg X5 MINI WIFI"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// DIGIPOT slave addresses // DIGIPOT slave addresses
// //

@ -24,6 +24,12 @@
#define BOARD_INFO_NAME "BIGTREE SKR 1.4 TURBO" #define BOARD_INFO_NAME "BIGTREE SKR 1.4 TURBO"
#define SKR_HAS_LPC1769 #define SKR_HAS_LPC1769
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Include SKR 1.4 pins // Include SKR 1.4 pins
// //

@ -31,6 +31,12 @@
#define BOARD_INFO_NAME "Cohesion3D Mini" #define BOARD_INFO_NAME "Cohesion3D Mini"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //

@ -31,6 +31,12 @@
#define BOARD_INFO_NAME "Cohesion3D ReMix" #define BOARD_INFO_NAME "Cohesion3D ReMix"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //

@ -31,8 +31,14 @@
#define BOARD_INFO_NAME "MKS SGen" #define BOARD_INFO_NAME "MKS SGen"
#define BOARD_WEBSITE_URL "github.com/makerbase-mks/MKS-SGEN" #define BOARD_WEBSITE_URL "github.com/makerbase-mks/MKS-SGEN"
#define MKS_HAS_LPC1769
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
#define MKS_HAS_LPC1769
#include "../lpc1768/pins_MKS_SBASE.h" #include "../lpc1768/pins_MKS_SBASE.h"
#undef E1_STEP_PIN #undef E1_STEP_PIN

@ -32,6 +32,12 @@
#define BOARD_INFO_NAME "Smoothieboard" #define BOARD_INFO_NAME "Smoothieboard"
#define BOARD_WEBSITE_URL "smoothieware.org/smoothieboard" #define BOARD_WEBSITE_URL "smoothieware.org/smoothieboard"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //

@ -32,6 +32,12 @@
#define BOARD_INFO_NAME "TH3D EZBoard" #define BOARD_INFO_NAME "TH3D EZBoard"
#define BOARD_WEBSITE_URL "th3dstudio.com" #define BOARD_WEBSITE_URL "th3dstudio.com"
//
// EEPROM
//
#define FLASH_EEPROM_EMULATION
//#define SDCARD_EEPROM_EMULATION
// //
// Servos // Servos
// //

Loading…
Cancel
Save