Disk operations
When SD has been initialized properly, pointers can be used to access partition, file system and root directory. There are some functions that return information about the SD card.
Disk information
Stores all the data containing the disk info into the buffer. It returns a filled buffer if success on getting disk info and an empty string if not.
Example of use
Available Information
SD.buffer
→ stores the data received as a human-readable encoded string.
diskInfo
→ pointer to SD.buffer
An example of the output by this system would be:
manuf: 0x1b oem: SM prod: 21e7 rev: 1.0 serial: 0xedb6c604 date: 11/10
Disk Size
Gets the total size of the SD card.
It returns ‘diskSize’ variable and updates its value. Size is stored and returned in Bytes.
Example of use
Related Variables
SD.diskSize
→ stores the total size of the SD card.
An example of the value would be: SD.diskSize=992608256
Last updated