Merge pull request #6867 from conkerkh/fix_sdio_det_pin

Fixes SD Card detect pin on SDIO targets.
This commit is contained in:
Michael Keller 2018-10-03 23:08:34 +13:00 committed by GitHub
commit 172c208979
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 0 deletions

View File

@ -204,6 +204,9 @@ void sdcard_init(const sdcardConfig_t *config)
} else {
sdcard.cardDetectPin = IO_NONE;
}
if (config->cardDetectInverted) {
sdcard.detectionInverted = 1;
}
if (sdioConfig()->useCache) {
sdcard.useCache = 1;
} else {

View File

@ -3818,6 +3818,8 @@ const cliResourceValue_t resourceTable[] = {
#endif
#ifdef USE_SDCARD_SPI
DEFS( OWNER_SDCARD_CS, PG_SDCARD_CONFIG, sdcardConfig_t, chipSelectTag ),
#endif
#ifdef USE_SDCARD
DEFS( OWNER_SDCARD_DETECT, PG_SDCARD_CONFIG, sdcardConfig_t, cardDetectTag ),
#endif
#ifdef USE_PINIO