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

This commit is contained in:
Scott Lahteine 2020-03-16 15:59:05 -05:00 committed by GitHub
parent 2fc0df1b39
commit b14c933171
Signed by: GitHub
GPG key ID: 4AEE18F83AFDEB23
31 changed files with 168 additions and 17 deletions

View file

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

View file

@ -20,3 +20,8 @@
*
*/
#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

View file

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

View file

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

View file

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

View file

@ -20,3 +20,8 @@
*
*/
#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

View file

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

View file

@ -20,3 +20,8 @@
*
*/
#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

View file

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

View file

@ -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);
#elif HAS_AUTO_FAN_3
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
/**
* 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
*/

View file

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

View file

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

View file

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

View file

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

View file

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

View file

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

View file

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

View file

@ -30,6 +30,12 @@
// Ignore temp readings during develpment.
//#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
//

View file

@ -38,6 +38,14 @@
#define BOARD_WEBSITE_URL "github.com/makerbase-mks/MKS-SBASE"
#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 LED2_PIN P1_19
#define LED3_PIN P1_20

View file

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

View file

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

View file

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

View file

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

View file

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

View file

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

View file

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

View file

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

View file

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

View file

@ -31,8 +31,14 @@
#define BOARD_INFO_NAME "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"
#undef E1_STEP_PIN

View file

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

View file

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