Internal SD Card Information
hi all
I want this information : Internal SD Card Information But I do not know what kind of Linux distributions I should use to do this ( for run this code /sys/block/mmcblk0/device/ ) Please test it first and then introduce what you have done. It's really hard to learn and work with Linux guide : Internal SD Card Information Information about an SD card is encoded in its internal card registries. One of these is the Card Identification (CID) Register, a 16 byte code that contains information that uniquely identifies the SD card, including the card serial number (PSN), manufacturer ID number (MID) and manufacture date (MDT). The CID register is set when the card is manufactured and cannot be changed after it is set. (According to SD card specification the information is only to be written once, however if a card does not conform to the specification this information could be changed!) How to read the CID from an SD card One way to read the CID is to use a laptop with an SD card slot. Card readers in laptops are usually connected directly through the PCI bus (or IDE bus). This will not work through a USB card reader because the command to retrieve the card information is intercepted and not understood by card readers. Not all computers with built-in card slots will work, some internal card readers are connected through a USB bus. Assuming you have the proper hardware, there are several methods you can use to get the card information. With Linux, reading the internal SD card information is simple. Insert the card and look under /sys/block/mmcblk0/device/ (this location may change depending on your platform, it may be mmcblk1 or in a different location). Under this location you will see several attributes available that include the CID and CSD registers and the information inside it. To view the CID, the command is cat /sys/block/mmcblk0/device/cid (the exact location may be different) What information is in the CID? The following information is stored in the CID: Name Field Linux attribute* Description Manufacturer ID MID manfid Assigned by SD-3C, LLC. OEM/Application ID OID oemid Identifies the card OEM and/or the card contents. Assigned by SD-3C, LLC. Product Name PNM name 5 characters long (ASCII) Product Revision PRV hwrev, fwrev Two binary coded decimal (BCD) digits. Each is four bits. The PRV is in the form x.y. The PRV can also be found by using the hwrev and fwrev, where x=hwrev and y=fwrev Serial Number PSN serial This 32 bit field is intended to be read as an unsigned integer Manufacture Date Code MDT date Manufacture date is stored in the form yym (offset from 2000) CRC7 checksum CRC 7 bit code used for checking errors in the card register * these are the attribute titles used for the card in Linux For more information, refer to the SD Association Simplified Specifications. How can I use the information from the CID? The CID information can be helpful in identifying counterfeit memory cards. We include the CID data in our SD card reviews so you may compare it with your cards. https://www.cameramemoryspeed.com/sd...ernal-numbers/ |
Linux is actually Gnu/Linux, and things like this have been working on computers since the earliest days.
It's a learning curve. Have you run lspci or lsusb? |
I have not implemented any command in Linux yet
The only command that told me is the following command /sys/block/mmcblk0/device/ Which I did at Kali terminal but did not have any result But according to the site's claims, these commands mentioned above are running on Linux, but I can not run. --------------------------------------------- |
Quote:
lspci or lsusb !!! I connected my SD card to the laptop's SD card, which goes directly to the main board of my laptop ) That pci interface ( |
What is the make and model of your laptop? Some SD card readers require special drivers which are probably not included by default with kali.
lspci is a command that will display all devices connected to the PCI bus which should show the card reader. |
Yes it is a learning curve.
Your "command" of "/sys/block/mmcblk0/device/" is the address for a file. All your usb ports connect directly to your MB too. This is a different type of interface than a pci interface. I have a very nice card reader but it plugs into an extra usb connection on my MB. I don't have anything in my card reader but you can check on what is in your /sys directory with; Code:
$ ls /sys Code:
tom@stoned:~$ ls /sys Code:
tom@stoned:~$ ls /sys/block ls is "list". lsusb will list things connected to usb. lspci will list pci connected things. There is very little danger in running commands at the $ prompt when dealing with system files. They belong to the user "root". The $ prompt only gives you the power that you as a normal user have. You can find who owns files easily (everything is a file in Linux including directories and devices) using; Code:
tom@stoned:~$ ls -l /sys Any actual damage needs permissions to write and that will require using sudo or logging into the terminal as root and using the # prompt. That is where the FUN begins. |
and now how i can find my sd card drive ?
sda sdb sdc sdd sde sdf sdg sdh sdi sr0 |
please read this instrumnet :
Project: Read, Collect & Decode SD Card CID Register Data Buying flash memory from poorly reputed places, such as Chinese computer markets, and online auction sites is an often known way to collect BAD flash memory cards that fall short on performance, longevity and data security. SD cards, along with their “counterparts” mini and microSD cards, all contain manufacturer defined information in a set of registers. One is known as the CID, short for Card Identification Register. There is also another called the CSD or Card Specific Data Register. These can only be accessed directly via hardware and not via most card readers. I am aware that it was possible to do this via the SD Card Shield and Arduino, but since I have a Chromebook, things got really easy. Under the Chromebook, the SD reader slot on the side is directly connected to the SD bus of the ARM CPU and is not a USB based reader. By running Chrubuntu, getting the CID or CSD data from a card is as simple as: cat /sys/block/mmcblk1/device/cid cat /sys/block/mmcblk1/device/csd Et voila! You will be rewarded with a hexadecimal string with the data in it. By comparing some cards that you own with the known signatures, you can have some reassurance whether your cards are similar, or genuine. Unfortunately, I haven’t seen a large CID database online, nor have I seen a CID decoder that will decode the hex string into the component parts (some BCD, some ASCII, others Unsigned Int or best as Hex), so I went on a journey to code one up for CID. I used this reference by Sandisk for the data field lengths and types. The CIDs for the cards I have in my possession that are in reach are as follows: 45010053454d31364790e03506aebf4d CHROMEBOOK INTERNAL EMMC 1b534d3030303030100337410200d13b RASPBMC SDHC CARD 1b534d3030303030107d11463800c199 SAMSUNG 32Gb CLASS 10 SDHC 8903034e43617264000000667000b285 TEAM 32Gb CLASS 10 41343253443132383002b800b600da6f KINGSTON 128Gb SDXC CLASS 10 02544d534430324728ad78243300793d KINGSTON 2Gb SDSC 035344534430324780019acc7600844b SANDISK 2Gb Blue SDSC 275048534433324730b018bd6700abe5 PATRIOT 32Gb CLASS 10 SDHC 035344535533324780718848c800b7fb SANDISK 32Gb CLASS 4 MicroSDHC 035344535530314780401c751300637d SANDISK ULTRA II 1Gb MicroSDSC 0353445355363447801013d98600d6d3 SANDISK ULTRA 64Gb UHS-I MicroSDXC 1234564d532020201000004c6300c853 UNBRANDED 2Gb MicroSDSC 8803023132333220100000cea40071b9 PRETEC 2Gb MicroSDSC Please note, while the code below works using the Javascript of your browser, I have no prior Javascript coding until today, with much help from Google searches and W3schools. I won’t warrant the below decoder as being bug free, but it’s free so give it a whirl! how i can recive this result ? plz help :(( |
No Body Any Body Here ??
C a n Y o u h e a r M E !!!!! |
I think so, but I don't think it's necessary to reinvent the wheel. Lsusb. Reads and interprets all that (gory details card details). The kernel reads it. We don't as a rule. You're boldly going where none of us have gone before. Please post your results.
|
Hi to everybody,
I'm new in this kind of things .... I'd like to change CID for an SD card, but before this I'd like to know if my SD has a editable CID. I used a live version of UBUNTU mounted on USB pen I inserted the SD card and opened a terminal Quote:
When I list the /sys/block folder I have this http://i65.tinypic.com/wu1btc.jpg Anyone can help? How can I see if my Samsung EVO SD card has editable CID? Thanks in advance |
i don't know what an editable CID is, but you can find out the name and path of the partition you want info about:
Code:
sudo fdisk -l |
Quote:
I Need It I Dont Like Lnux It is Very HARD LEARNING... |
At the level you're trying to go in at (Low Level) Linu8x is not easy, and this is not for the faint of heart.
Use the SD card as standard, and stop trying to tweak stupid details when you don't understand the implications. Why do you want to change the CID for the card? What is the CID anyhow? What effects will it have. There's no low hanging fruit in the way of performance waiting to be picked by fiddling a few numbers. Forget that. Now please answer the questions you were asked, and post the results you were asked for and stop wasting everyone's time. That's how we make progress: our knowledge, & your work. |
All times are GMT -5. The time now is 05:13 AM. |