If you are experiencing problems using the driver in your project the following tips may help:-
Double check IO pin definitions in the driver header file.
Verify with a scope that all of the control and data pins to the MMC or SD card are working correctly.
Check that no other device on the SPI bus is outputting while the driver is trying to communicate with the MMC or SD card.
Single step through the initialise new card part of the ffs_process function. There are several points at which the driver verifies the correct value is returned by the MMC or SD card and if the correct value is not being returned this may point to the cause of a problem.
Try using a different MMC or SD card made by a different manufacturer. We have occasionally come across faulty cards or cards that do not properly conform to the MMC or SD standard, even from reputable manufacturers.
Check that your microcontroller is not resetting due to a watchdog timer timeout. Read and write operations to MMC or SD cards can sometimes take time to complete that may exceed your watchdog timer setting?
If you are using a write protect input (FFS_WP_PIN_REGISTER is defined in mem-mmcsd.h) check that it is not configured incorrectly and blocking write operations.
See the:
‘Signal Noise Issues With MMC & SD Memory Cards (& Clocked Devices In General)
page in the resources area of our web site for details of a common signal noise problem experienced when using MMC and SD memory cards.
Check that you have enough stack space allocated. This driver uses a moderate amount of ram from the stack and if your application is already using large amounts of the stack before calling driver functions this may be causing a stack overrun?
If you are using a 32bit device ensure that for the driver files WORD = 16 bits and DWORD = 32 bits.


