MicroSD Cards and SDFS


Closed Thread
Results 1 to 34 of 34

Hybrid View

  1. #1
    Join Date
    Jan 2009
    Location
    Miami, Florida USA
    Posts
    699

    Default MicroSD Cards and SDFS

    Hi all,

    Well, this is probably a very dumb question . I'm trying to get a MicroSD card to work with SDFS. The first question I have is about the pin names. In the schematics provided in the SDFS zip file there are 12 pins for the SD card, and they are named as
    • CS
    • DATA IN
    • Vss
    • Vdd
    • SCLK
    • DATA OUT
    • CD
    • WP
    • GROUND

    Plus some NC pins. Now, all of the SD cards that I can find have 8 pins named as follows
    • DAT2
    • DAT3/CD
    • CMD
    • VDD
    • CLK
    • VSS
    • DAT0
    • DAT1

    So the question would be, how do you relate one to the other? Am I talking about two different things here?

    My second question would be about about the PIC speed when initializing the SD card. Do I need to slow down the PIC to initialize the SD card?

    Thank you all for your help,

    Robert

    Name:  MicroSD.JPG
Views: 2656
Size:  47.1 KB
    Attached Images Attached Images

  2. #2
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    SD cards have 9 pads.
    Looking at the pads and the pads towards you the right hand pad is #9(the pad on the angle). From there they then going from right to left 1 to 8

    The other three connections from the socket are a common, Write Protect, and Card Detect.

    SD pads 8 and 9 are pulled high (3.3 volt) with a 10k.
    Pad #4 is 3.3 volt.
    Pads 3 and 6 are VSS.
    Pad #1 is Chip Select, CS
    Pad #2 is Data Out from PIC, into SD.
    Pad #7 is Data In to PIC, out from SD.
    Dave
    Always wear safety glasses while programming.

  3. #3
    Join Date
    Jan 2009
    Location
    Miami, Florida USA
    Posts
    699


    Did you find this post helpful? Yes | No

    Default

    mackrackit,

    Thank you for your response.

    Quote Originally Posted by mackrackit View Post
    SD cards have 9 pads.
    All the MicroSD cards that I have seen so far have 8 pads. Look at the attached picture.

    Name:  MicroSD.JPG
Views: 2147
Size:  21.5 KB

    Can I use SDFS with MicroSD cards that have 8 pads? From searching in google, I found that these MicroSD cards can operate in two modes, SPI and SD modes. Please take a look at the attached pics.

    Name:  SPI-Mode.JPG
Views: 5843
Size:  22.3 KBName:  SD-Mode.JPG
Views: 2892
Size:  21.7 KB

    What mode should I use? How do you relate the pin functions to the schematics in the SDFS help file?


    Robert

  4. #4
    Join Date
    Oct 2004
    Posts
    440


    Did you find this post helpful? Yes | No

    Default

    Just a guess but use an adapter and SPI mode is by far most common.

    Norm

  5. #5
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Doh.... I was thinking regular SD cards.

    The only time I have used them was with an adapter so using one straight should not be a problem.

    Looking at the pin outs between the two it appears pin 9 has been dropped and pin 1 is not used on the micros. Pin 2 on the micro is the same as pin 1 on the full size, I think. Just compare the pin names and functions between the two.

    SPI.... That is what SDFS uses. The only option it hardware SPI or not. Testing for speed between the two I have not seen a difference. Hardware SPI on the chip I use is also one of the USART pins so I have been using software SPI.
    Dave
    Always wear safety glasses while programming.

  6. #6
    Join Date
    Jan 2009
    Location
    Miami, Florida USA
    Posts
    699


    Did you find this post helpful? Yes | No

    Default

    Hi,

    I will use the SPI mode for the SDFS as you guys suggested. I've already ordered my MicroSD socket from mouser. So, I will keep you posted if I get it to work or not.

    About all the extra pins that the MicroSD card doesn't use like the WP, I guess that I can comment out these lines of code that I don't need in the SDFS program. I'm going to have to study this SDFS code to see how it works.

    Robert

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts