Robert Murrell
|
Re: How to know the sector size of a disk programmatically
|
Robert Murrell
12/09/2014 8:39 AM
post112579
|
Re: How to know the sector size of a disk programmatically
I had a similar requirement to determine the amount of RAM, Disk size, and video modes. I wrote this test program to
look for this information. The first part walks the memory descriptor of SYSPAGE and adds up the total RAM. Next I use
statvfs64 to get the file system size. The third section is what you are interested in. It walks the hardware
section of SYSPAGE looking specifically for filestore devices and printing info about them. The last section is using
the BIOS INT10H to interrogate the VESA information.
|
|
|