83Plus:Software:usb8x/Asm Interface/MSD/DOS createDirectory

From WikiTI
Revision as of 01:20, 17 August 2006 by Brandonw (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Synopsis

Name: DOS_createDirectory

Minimum usb8x version: 0.10

Creates a new directory within specified directory.

Inputs

  • HL points to the starting cluster of the directory to create this directory in (obtained with [[../FAT_getStartingCluster|FAT_getStartingCluster]])
  • DE points to an ASCIIZ string of the directory (ex. "folder2")

Outputs

  • Empty directory is created
  • HL contains starting cluster of this directory
  • C set if problems

Destroys

  • AF, BC, DE, HL

Notes

The directory's created date/time attributes are set according to the 84+/SE clock. Example code to create "folder2" inside "folder1" directory:

ld hl,sDirectory
U_CALL FAT_getStartingCluster
;HL contains starting cluster
ld de,sNew
U_CALL DOS_createDirectory
...
sNew: DB "folder2",0
sDirectory: DB "/folder1",0

See Also

  • [[../FAT_getStartingCluster|FAT_getStartingCluster]] - Get starting cluster of specified directory