Skip to content

Instantly share code, notes, and snippets.

@alepez
Created September 26, 2017 11:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alepez/1b22543a4a4dbc643dd93dc1e04fd66f to your computer and use it in GitHub Desktop.
Save alepez/1b22543a4a4dbc643dd93dc1e04fd66f to your computer and use it in GitHub Desktop.
android sdcard cid
try {
BufferedReader input = new BufferedReader(new FileReader("/sys/block/mmcblk1/device/cid"));
String sd_cid = input.readLine();
Log.i(TAG, "cid:");
Log.i(TAG, sd_cid);
} catch (Exception e) {
Log.e(TAG, "Can not read SD-card cid");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment