Skip to content

Commit ffad4ba

Browse files
author
Henning Hasemann
committed
Hotfix to make sd2card work with wireless modules
On mega2560. Currently breaks ethernet modules though.
1 parent 7e48030 commit ffad4ba

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

libraries/SD/utility/Sd2Card.cpp

+4
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,10 @@ uint8_t Sd2Card::eraseSingleBlockEnable(void) {
211211
* can be determined by calling errorCode() and errorData().
212212
*/
213213
uint8_t Sd2Card::init(uint8_t sckRateID, uint8_t chipSelectPin) {
214+
// <HOTFIX>
215+
chipSelectPin = 4;
216+
// </HOTFIX>
217+
214218
errorCode_ = inBlock_ = partialBlockRead_ = type_ = 0;
215219
chipSelectPin_ = chipSelectPin;
216220
// 16-bit init start time allows over a minute

0 commit comments

Comments
 (0)