home *** CD-ROM | disk | FTP | other *** search
/ CP/M / CPM_CDROM.iso / jsage / zsus / z3help / z.lbr / ZSDOS.HZP / ZSDOS.HLP
Encoding:
Text File  |  1991-11-18  |  3.3 KB  |  106 lines

  1.  Device I/O Functions      -- ZSDOS FUNCTIONS --
  2.  File I/O Functions
  3.  Other File Functions
  4.  Other Disk Functions
  5.  Miscellaneous Functions
  6.  BIOS Functions
  7.  File Control Block        -- ZSDOS STRUCTURES --
  8.  Directory Record
  9.  Disk Parameter Block
  10.  Date Specification
  11.  File Stamp
  12. ::ZSDOS1
  13. ::ZSDOS2
  14. ::ZSDOS3
  15. ::ZSDOS4
  16. ::ZSDOS5
  17. ::ZSDOS6
  18. :
  19.                             FILE CONTROL BLOCK
  20.  
  21. A file control block (FCB) is a 36-byte data area used for most file 
  22. operations:
  23.  
  24.      offset        use
  25.         0   drive (0=default, 1=A, 2=B, etc.)
  26.        1-8  filename in ASCII (upper-case)
  27.       9-11  filetype in ASCII (upper-case)
  28.        12   logical extent number
  29.        13   user number (S1)
  30.        14   data module number (S2)
  31.        15   record count
  32.      16-31  allocation map for this physical extent
  33.        32   current record
  34.        33   random record number (least significant byte)
  35.        34   random record number (intermediate significant byte)
  36.        35   random record number (most significant byte)
  37.  
  38. When initializing the FCB, offsets 12, 14, and 32 are normally set to 0.
  39. :
  40.                              DIRECTORY RECORD
  41.  
  42. A directory record contains four 32-byte directory entries, which are 
  43. similar to a file control block:
  44.  
  45.      offset        use
  46.         0   user number
  47.        1-8  filename in ASCII (upper-case)
  48.       9-11  filetype in ASCII (upper-case)
  49.        12   logical extent number
  50.        13   S1 system byte (set to 0)
  51.        14   data module number (S2)
  52.        15   record count
  53.      16-31  allocation map for this physical extent
  54. :
  55.                            DISK PARAMETER BLOCK
  56.  
  57. A disk parameter block (DPB) defines the logical format of a disk drive:
  58.  
  59.      offset        use
  60.        0-1  number of 128-byte records per track
  61.         2   block shift
  62.         3   block mask
  63.         4   extent mask
  64.        5-6  maximum allocation block number
  65.        7-8  number of directory entries minus one
  66.       9-10  bitmap of directory and reserved allocation blocks
  67.      11-12  directory checksum buffer size
  68.      13-14  number of reserved tracks before directory
  69. :
  70.                             DATE SPECIFICATION
  71.  
  72. A date specification of six packed BCD bytes is used to pass the system 
  73. time to and from ZSDOS:
  74.  
  75.      offset        use
  76.         0   last two digits of year
  77.         1   month (1-12)
  78.         2   day (1-31)
  79.         3   hours (0-23)
  80.         4   minutes (0-59)
  81.         5   seconds (0-59)
  82.  
  83. Years 78-99 are assumed to be in the 20th (19xx).  Otherwise, the 21st 
  84. century (20xx) is assumed.
  85. :
  86.                                 FILE STAMP
  87.  
  88. A file stamp consists of 15 packed BCD bytes divided into three fields:
  89.  
  90.      offset        use
  91.        0-4  date file was created
  92.        5-9  date file was last accessed
  93.      10-14  date file was last modified
  94.  
  95. Each five-byte field consists of a modified date specification:
  96.  
  97.      offset        use
  98.         0   last two digits of year
  99.         1   month (1-12)
  100.         2   day (1-31)
  101.         3   hours (0-23)
  102.         4   minutes (0-59)
  103.  
  104. Years 78-99 are assumed to be in the 20th (19xx).  Otherwise, the 21st 
  105. century (20xx) is assumed.
  106.