Friday, April 15, 2011

SDCARD

1) How we setup sdcard and copy data into sdcard in emulator ?
Answer :-
Setup sdcard :-
Step 1 :- Open a command promt. Go to android-sdk\tools and run following command there.
mksdcard 64M MyNewSdCard


Step 2 :- Go to Eclipse-> Window -> Android SDK and AVD Manager
Step 3:- Select a emulator in which you want to add sdcard and click on “Edit”












Step 4 :- Select the “File” option button from SD Card. Give the path where you save the sdcard “MyNewSdCard”. In my case “ C:\Program Files\Android\android-sdk\tools\MyNewSdCard ”























 Step 5 :- Press Edit AVD.

  • Push the file on sdcard. Here I puch iamme.mp3 on sdcard.
Step 1 :- Run the Emulator.

Step 2 :- Run ddms.bat from “C:\Program Files\Android\android-sdk\tools\ddms.bat”.
Step 3 :- Select the Emulator and after then press on Device-> File Explorer

Step 4 :- In File Explorer select sdcard then select “Push file onto Device”
It will show a progress dialog box like


After then it will show like this.