Improve USB Media Host conditions (#20176)

Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com>
This commit is contained in:
Victor Oliveira
2020-11-18 02:48:14 -03:00
committed by GitHub
parent c1920f31ca
commit f1cdd02d4c
11 changed files with 40 additions and 32 deletions

View File

@ -360,14 +360,13 @@
*/
#if ENABLED(SDSUPPORT)
#if SD_CONNECTION_IS(ONBOARD) && DISABLED(NO_SD_HOST_DRIVE) && !defined(ARDUINO_GRAND_CENTRAL_M4)
#if HAS_SD_HOST_DRIVE && SD_CONNECTION_IS(ONBOARD)
//
// The external SD card is not used. Hardware SPI is used to access the card.
// When sharing the SD card with a PC we want the menu options to
// mount/unmount the card and refresh it. So we disable card detect.
//
#undef SD_DETECT_PIN
#define HAS_SHARED_MEDIA 1
#endif
#if PIN_EXISTS(SD_DETECT)
@ -381,7 +380,6 @@
#define SD_DETECT_STATE LOW
#endif
#endif
#endif
#if ANY(HAS_GRAPHICAL_TFT, LCD_USE_DMA_FSMC, HAS_FSMC_GRAPHICAL_TFT, HAS_SPI_GRAPHICAL_TFT) || !PIN_EXISTS(SD_DETECT)