Go Down

Topic: Aduino Mega and SD Card (Read 866 times) previous topic - next topic

tmonteit

I recently upgraded my Arduino UNO to an Arduino Mega 2560.    On the UNO I had a Sparkfun SD card riser that sat on top of the pins and worked just fine.  On the Mega it doesn't work.     I am confused by some documentation because it says the Mega uses pin 53.  But the doesn't sit over pin 53?  How do I make the SD Card work on the Mega?  Is there some real beginner documentation on how to make this work?





johnwasser

The SD card use the SPI interface.  On the UNO that's pins 10-13.  On the Mega that's pins 50-53.

If you have a pin that goes to UNO pin 10 that's the "Slave Select" pin and should either got to Mega pin 10 or Mega pin 53 depending on how the SD library you  are using selects the SS pin.

The other three pins (UNO 11, 12 and 13) go to Mega pins 50, 51, and 52, respectively.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Go Up