CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

first sector (sector 0) in SD card

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
martind1983



Joined: 22 Mar 2013
Posts: 16

View user's profile Send private message

first sector (sector 0) in SD card
PostPosted: Thu Apr 04, 2013 12:30 am     Reply with quote

Hello.

I want to ask. Each time when I use fat_init() function, where function mmcsd_init() is built for initialization and loading buffer I seen, that mmcsd_init() function passes well. But in general I don't get correct values to fat_init() function variables (bytes per sector, sectors per cluster, Root_dir all those values necessary for FAT32 format). I see mmcsd_init() function always set "g_mmcsdBufferAddress" to 0 and it causes that data are loaded from first sector(block) of SDcard, but I think on first sector (sector 0) there are saved native data for SD card not FAT32. And it causes fault loading of FAT32 values to variables in fat_init() function.
So how can I find out sector address for FAT32 values on SD card or is able to set any sectors to which shouldn't be able to access in SD card registers? In SD card specs, I read that in CSD register is saved value for WP_GROUP (write_protected_group) sectors, but I don't know if those are first sectors I should jump over and behind them will finally be FAT32 sectors.
L.W. I am sure that card reading is correct, because I also read SD card with disk investigator application and it finds all data on SD card which I was able to find too by passing function mmcsd_load_buffer() when I was changing addresses. Only initial address in mmcsd_init() function for buffer loading is not set correct. How to solve it?

Thanks for your help.

Thanks for your help
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group