From 5b438fb20d8b96860d307253fb0f3a728bcbf223 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Tue, 25 Feb 2020 22:30:16 -0600 Subject: [PATCH] HAS_SDCARD_CONNECTION is more obsolete --- Marlin/Configuration_adv.h | 22 +++++++++---------- Marlin/src/inc/Conditionals_LCD.h | 2 -- Marlin/src/pins/stm32/pins_BTT_SKR_PRO_V1_1.h | 4 ++++ Marlin/src/pins/stm32/pins_STEVAL_3DP001V1.h | 6 ++++- 4 files changed, 19 insertions(+), 15 deletions(-) diff --git a/Marlin/Configuration_adv.h b/Marlin/Configuration_adv.h index b93ab3651..c9e226cef 100644 --- a/Marlin/Configuration_adv.h +++ b/Marlin/Configuration_adv.h @@ -1172,18 +1172,16 @@ // Add an optimized binary file transfer mode, initiated with 'M28 B1' //#define BINARY_FILE_TRANSFER - #if HAS_SDCARD_CONNECTION - /** - * Set this option to one of the following (or the board's defaults apply): - * - * LCD - Use the SD drive in the external LCD controller. - * ONBOARD - Use the SD drive on the control board. (No SD_DETECT_PIN. M21 to init.) - * CUSTOM_CABLE - Use a custom cable to access the SD (as defined in a pins file). - * - * :[ 'LCD', 'ONBOARD', 'CUSTOM_CABLE' ] - */ - //#define SDCARD_CONNECTION LCD - #endif + /** + * Set this option to one of the following (or the board's defaults apply): + * + * LCD - Use the SD drive in the external LCD controller. + * ONBOARD - Use the SD drive on the control board. (No SD_DETECT_PIN. M21 to init.) + * CUSTOM_CABLE - Use a custom cable to access the SD (as defined in a pins file). + * + * :[ 'LCD', 'ONBOARD', 'CUSTOM_CABLE' ] + */ + //#define SDCARD_CONNECTION LCD #endif // SDSUPPORT diff --git a/Marlin/src/inc/Conditionals_LCD.h b/Marlin/src/inc/Conditionals_LCD.h index 5cbdafd6e..7373e65d6 100644 --- a/Marlin/src/inc/Conditionals_LCD.h +++ b/Marlin/src/inc/Conditionals_LCD.h @@ -571,8 +571,6 @@ #define IS_RE_ARM_BOARD MB(RAMPS_14_RE_ARM_EFB, RAMPS_14_RE_ARM_EEB, RAMPS_14_RE_ARM_EFF, RAMPS_14_RE_ARM_EEF, RAMPS_14_RE_ARM_SF) -#define HAS_SDCARD_CONNECTION EITHER(TARGET_LPC1768, ADAFRUIT_GRAND_CENTRAL_M4) - #define HAS_LINEAR_E_JERK (DISABLED(CLASSIC_JERK) && ENABLED(LIN_ADVANCE)) #ifndef SPI_SPEED diff --git a/Marlin/src/pins/stm32/pins_BTT_SKR_PRO_V1_1.h b/Marlin/src/pins/stm32/pins_BTT_SKR_PRO_V1_1.h index b523874cb..8222bbe14 100644 --- a/Marlin/src/pins/stm32/pins_BTT_SKR_PRO_V1_1.h +++ b/Marlin/src/pins/stm32/pins_BTT_SKR_PRO_V1_1.h @@ -182,6 +182,10 @@ // Misc. Functions // +#ifndef SDCARD_CONNECTION + #define SDCARD_CONNECTION LCD +#endif + // // Onboard SD card // NOT compatible with LCD diff --git a/Marlin/src/pins/stm32/pins_STEVAL_3DP001V1.h b/Marlin/src/pins/stm32/pins_STEVAL_3DP001V1.h index e65367971..2b6e6f6c3 100644 --- a/Marlin/src/pins/stm32/pins_STEVAL_3DP001V1.h +++ b/Marlin/src/pins/stm32/pins_STEVAL_3DP001V1.h @@ -236,7 +236,11 @@ #define SDIO_CK_PIN 28 // PC12 SDIO_CK #define SDIO_CMD_PIN 29 // PD2 SDIO_CMD -#if !defined(SDCARD_CONNECTION) || SDCARD_CONNECTION == ONBOARD +#ifndef SDCARD_CONNECTION + #define SDCARD_CONNECTION ONBOARD +#endif + +#if SDCARD_CONNECTION == ONBOARD #define SDIO_SUPPORT // Use SDIO for onboard SD #ifndef SDIO_SUPPORT