diff --git a/source/disc_io/io_m3sd.c b/source/disc_io/io_m3sd.c index f1253a7..5ea117b 100644 --- a/source/disc_io/io_m3sd.c +++ b/source/disc_io/io_m3sd.c @@ -256,7 +256,7 @@ static bool _M3SD_initCard (void) { return false; } - _M3SD_sendCommand (SD_APP_OP_COND, 3<<16); + _M3SD_sendCommand (SD_APP_OP_COND, SD_OCR_VALUE); if ((_M3SD_getResponse_R3 (responseBuffer)) && ((responseBuffer[1] & 0x80) != 0)) { // Card is ready to receive commands now break; diff --git a/source/disc_io/io_scsd.c b/source/disc_io/io_scsd.c index 13648a8..f4891a5 100644 --- a/source/disc_io/io_scsd.c +++ b/source/disc_io/io_scsd.c @@ -208,7 +208,7 @@ static bool _SCSD_initCard (void) { return false; } - _SCSD_sendCommand (SD_APP_OP_COND, 3<<16); + _SCSD_sendCommand (SD_APP_OP_COND, SD_OCR_VALUE); if ((_SCSD_getResponse_R3 (responseBuffer)) && ((responseBuffer[1] & 0x80) != 0)) { // Card is ready to receive commands now break; diff --git a/source/disc_io/io_sd_common.h b/source/disc_io/io_sd_common.h index 0d17257..3ed5afb 100644 --- a/source/disc_io/io_sd_common.h +++ b/source/disc_io/io_sd_common.h @@ -32,6 +32,9 @@ 2006-07-11 - Chishm * Original release + + 2006-07-28 - Chishm + * Changed voltage range that the SD card can use */ #ifndef IO_SD_COMMON_H @@ -59,6 +62,9 @@ #define SET_BUS_WIDTH 6 #define SD_APP_OP_COND 41 +/* OCR (Operating Conditions Register) send value */ +//#define SD_OCR_VALUE 0x00030000 /* 2.8V to 3.0V */ +#define SD_OCR_VALUE 0x003F8000 /* 2.7V to 3.4V */ /* SD Data repsonses */ #define SD_CARD_BUSY 0xff