Emfile and micro Sdcard In psoc5lp

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
song_285461
Level 3
Level 3
First like received

Hello every one, I have a problem about connecte micro Sdcard. I use FS_Init() then:

   

Firstly, I use funtion :  FS_GetVolumeName(0u, &sdVolName[0], 9u), I have name Sdcard is "mmc".

   

Secondely. I use funtion: FS_Mount("mmc") , I have value -1 (Erro, Volume can not be mounted)

   

Please Tell me why? I dont read or write any file to/ from micro sd.

   

Thank so much!

0 Likes
2 Replies
EvPa_264126
Level 7
Level 7
500 replies posted 250 replies posted 100 likes received

Probably not all MicroSD cards support SPI
https://en.wikipedia.org/w/index.php?title=Secure_Digital&diff=412862593&oldid=412855668
My microSD cards (> = 16Gb) also do not work with SPI
I use the SD <= 4Gb

0 Likes

Hello pavloven, New start, I think like you, MicroSd cards not support spi or zerror spi.

   

But Then, I conneted MCU with Microsd card  by spi protocol, and send some command to Micro Sd, Micro Sd return true. so, spi of Micro Sd card  alway run. :)) 

0 Likes