[fpc-pascal] RAW sector read...

Felipe Monteiro de Carvalho felipemonteiro.carvalho at gmail.com
Tue Apr 4 15:48:17 CEST 2006


On 4/3/06, Michael Van Canneyt <michael at freepascal.org> wrote:
> I'd like to read raw sectors (blocks) from removable devices (such as
> USB drives) from Linux and/or Windows. Is there any possibility to use
> FPC with that?

On Linux you can read the device like a normal file.

On Windows there is probably a API function to do this. Do some
googling to find it.

And then use {$ifdef Win32} and other conditional compiles to ensure
it compiles across all platforms.

There is some explanation on how to use the conditional compiles here:

http://wiki.lazarus.freepascal.org/index.php/Hardware_Access

--
Felipe Monteiro de Carvalho



More information about the fpc-pascal mailing list