본문 바로가기

모바일지식/SD

SD Memory Card Identification

SD Memory Card Identification 

Adding more info to the SD card Identification process:
1. It is a stack of the drivers:
  ---------------------------------
  |  Clientdriver : SDMemory.dll
  ---------------------------------
  | BusDriver   : SDBus.dll  
  -------------------------------------------------
  | Host Controller Driver (HCD): myhcd.dll <---Card detection IST runs here.
  -------------------------------------------------
  | Host Controller Hardware.                     |          
  -------------------------------------------------

2. When the Card detection Interrupt comes Bus driver is notified by calling
SDHCDIndicateSlotStateChange(pHCContext, 0, DeviceInserted ); from HCD.

3. Then Bus Driver will start the Card Identificaction process for the Card 
present in the SD Slot by sending the sequence of commands to the HCD.

4. First command is CMD5
  If the Response of this command is RSP_TIMEOUT that means the card 
present in the slot is the Memory card and if the respose is RSP_DONE then it 
is IO card.

5. So, Bus Driver sends further commands like CMD0, CMD1, ACMD41, CMD2, 
CMD3, CMD7, ACMD51, ACMD42, CMD6 to read the Internal registers present in 
the SD card and initialise the card thorough HCD.

6. At this point SD Bus driver loads the ClientDriver that is SDMemory.dll

7. Then this will be informed to the Storage Manager to mount this device.

8. Then FSD reads first sector present on the card thorough this stack and 
knows the File system,  FAT32 and sector info also.

9. By successsively reading the volume info from the card it will enumerated 
in the File sytem.

10. You can see as "Storage Card" when you open the file explorer.

11. Finally, if you remove the card from the slot, card removal interrupt 
comes in the HCD's IST.

12. This need to be informed to the Bus Driver by calling
    SDHCDIndicateSlotStateChange(pHCContext, 0, DeviceEjected);

13. At this point Bus Driver mark's the slotstate as not ready so that no 
furhter command will be sent to the HCD.
   And Bus Driver unloads the SDMemory.dll

'모바일지식 > SD' 카테고리의 다른 글

SD/MMC에 대한 자료  (0) 2011.08.15
SD(Secure Digital) 카드  (0) 2011.08.15
SD카드에 대한 기본 지식  (0) 2011.08.15
SD 카드 개요  (0) 2011.08.15
갤럭시S II 분해  (0) 2011.08.15