Function 58 - work with file system.
Parameters:
- eax = 58
- ebx = pointer to the information structure
Returned value:
General format of the information structure:
- +0: dword: subfunction number
- +4: dword: number of block
- +8: dword: size
- +12 = +0xC: dword: pointer to data
- +16 = +0x10: dword: pointer to a memory for system operations
(4096 bytes)
- +20 = +0x14: n db: ASCIIZ-string with the file name
Specifications - in documentation on the appropriate subfunction.
Filename is case-insensitive for latin letters, russian letters
must be capital.
Format of filename:
/base/number/dir1/dir2/.../dirn/file,
where /base/number identifies device, on which file is located:
one of
- /RD/1 = /RAMDISK/1 to access ramdisk
- /FD/1 = /FLOPPYDISK/1 to access first floppy drive,
/FD/2 = /FLOPPYDISK/2 to access second one
- /HD/x = /HARDDISK/x - obsolete variant of access to hard disk
(in this case base is defined by subfunction 7 of function 21),
x - partition number (beginning from 1)
- /HD0/x, /HD1/x, /HD2/x, /HD3/x to access accordingly to devices
IDE0 (Primary Master), IDE1 (Primary Slave),
IDE2 (Secondary Master), IDE3 (Secondary Slave);
x - partition number on the selected hard drive, varies from 1
to 255 (on each hard drive the indexing starts from 1)
Remarks:
- In the first two cases it is also possible to use FIRST
instead of 1, SECOND instead of 2, but it is not recommended
for convenience of transition to the future extensions.
- Limitation n≤39 is imposed.
- Names of folders and file dir1,...,dirn,file must have the
format 8.3: name no more than 8 characters, dot, extension no
more than 3 characters. Trailing spaces are ignored, no other
spaces is allowed. If name occupies equally 8 characters,
dot may be omitted (though it is not recommended to use this
feature for convenience of transition to the future extensions).
- This function does not support folders on ramdisk.
Examples:
- '/RAMDISK/FIRST/KERNEL.ASM',0
'/rd/1/kernel.asm',0
- '/HD0/1/kernel.asm',0
- '/hd0/1/menuet/pics/tanzania.bmp',0
Existing subfunctions: