MicroSD on Pro Micro

I'm not sure if "Sensors" is the right topic for this, sorry if it's not.

So i'm using an arduino Pro Micro (5V) and a Sparkfun Shifting MicroSD. I'm trying to find out how to write and read information on there. I keep finding programs but they are all on pins 11, 12 ... stuff like that. My MircoSD is connected to the Pro Micro on pins 10, 16, 14 and 15. Is there any way I can change the pins so that this can work?
Thanks

SD cards are SPI devices, and the '11, 12 ... stuff like that' are the hardware SPI pins. Why don't you just use them, after all, by the code you have posted and the connections you have described, you have nothing else connected.

Well, I do have other stuff connected, a lot actually, a BME680, GPS, Servo Motor and APC220.
Anywho... I don't have pin 11 and 12 on Pro Micro, they only have 2-10 and then 10 14 15 16. That's the problem :confused:

look at the datasheet for the pro-micro - Hardware SPI is on 14,15 & 16, you will need an extra pin for CS/SS (Chip select or Slave select).

Thank you missdrew!

Where can I find this Datasheet? This is the sheet i'm dying to find xD

(edited) Oh wait, you mean datasheet for the Pro Micro :confused: I was looking for a way to connect the Pro Micro. Cause the program I use (the basic ReadWrite example) doesn't have the pins I have.

GOOGLE : Pro Micro Pinout
or 32U4 Datasheet

Yeah... that's not really what I'm looking for. This is just the Pro Micro pinout. Where do I change the pins in the program??

YOU CAN’T! That is what HARDWARE SPI means!

So I’m using a Pro Micro and a microSD card holder. I also have a bunch of other stuff connected: BME680, GPS, APC220, Servo Motor.

But the problem is that I can’t seem to find how to connect it. In the example problem they tell you to use pins 11, 12, 13, 4 but my Pro Micro obviously doesn’t have those pins.

/*
  SD card read/write

  This example shows how to read and write data to and from an SD card file
  The circuit:
   SD card attached to SPI bus as follows:
 ** MOSI - pin 11
 ** MISO - pin 12
 ** CLK - pin 13
 ** CS - pin 4 (for MKRZero SD: SDCARD_SS_PIN)

  created   Nov 2010
  by David A. Mellis
  modified 9 Apr 2012
  by Tom Igoe

  This example code is in the public domain.

*/

#include <SPI.h>
#include <SD.h>

File myFile;

void setup() {
  // Open serial communications and wait for port to open:
  Serial.begin(9600);
  while (!Serial) {
    ; // wait for serial port to connect. Needed for native USB port only
  }


  Serial.print("Initializing SD card...");

  if (!SD.begin(4)) {
    Serial.println("initialization failed!");
    while (1);
  }
  Serial.println("initialization done.");

  // open the file. note that only one file can be open at a time,
  // so you have to close this one before opening another.
  myFile = SD.open("test.txt", FILE_WRITE);

  // if the file opened okay, write to it:
  if (myFile) {
    Serial.print("Writing to test.txt...");
    myFile.println("testing 1, 2, 3.");
    // close the file:
    myFile.close();
    Serial.println("done.");
  } else {
    // if the file didn't open, print an error:
    Serial.println("error opening test.txt");
  }

  // re-open the file for reading:
  myFile = SD.open("test.txt");
  if (myFile) {
    Serial.println("test.txt:");

    // read from the file until there's nothing else in it:
    while (myFile.available()) {
      Serial.write(myFile.read());
    }
    // close the file:
    myFile.close();
  } else {
    // if the file didn't open, print an error:
    Serial.println("error opening test.txt");
  }
}

void loop() {
  // nothing happens after setup
}

This is the example code i’m talking about.
Is there another program that is used for Pro Micro? Or can I change the pins anywhere?

Really? Pro Micro doesn't have a pin 4?

It has pins 2 through 10 and 14, 15 and 16.
So the problem isn't pin 4, but pin 11, 12 and 13.

Ohh okay, so if I can't change the pins, Is there another library I can use? or can I use another wiring? I2C or something?

Cross posting from https://forum.arduino.cc/index.php?topic=732402

   SD card attached to SPI bus as follows:
 ** MOSI - pin 16
 ** MISO - pin 14
 ** CLK - pin 15
 ** CS - pin 4 (for MKRZero SD: SDCARD_SS_PIN)

Just wire to the hardware MISO, MOSI & SCK pins!

Duplicate topics moved to a common location and merged

Cross-posting is against the rules of the forum. The reason is that duplicate posts can waste the time of the people trying to help. Someone might spend 15 minutes (or more) writing a detailed answer on this topic, without knowing that someone else already did the same in the other topic.

Repeated cross-posting will result in a timeout from the forum.

In the future, please take some time to pick the forum board that best suits the topic of your question and then only post once to that forum board. This is basic forum etiquette, as explained in the sticky "How to use this forum - please read." post you will find at the top of every forum board. It contains a lot of other useful information. Please read it.

Thanks in advance for your cooperation.

This is how the micro SD was already wired to the microSD:

SCK - 10
DO - 16
DI - 14
CS - 15

The Pro Micro Datasheet says:
SCLK - pin 15
MISO - pin 14
MOSI - pin 16

So I don't know if it's wired wrong, but the BME680 is wired the EXACT same way and works perfectly.

You have SCK and CS mixed up

As I said, The BME680 is wired the same and works perfectly.
Why is there no problem there then?

OK, if you don't want to accept the help, then I'm out! I tell you the CORRECT WAY to wire it up, but you (who came here for help?) argue that the help given is wrong.

Good luck with your project!