home *** CD-ROM | disk | FTP | other *** search
/ ftp.barnyard.co.uk / 2015.02.ftp.barnyard.co.uk.tar / ftp.barnyard.co.uk / cpm / walnut-creek-CDROM / ENTERPRS / CPM / UTILS / S / ZCNFG21.LZH / CFGLIB.LZH / INIFCB.Z80 < prev    next >
Text File  |  1992-11-03  |  896b  |  30 lines

  1.     ext    fill
  2.     public    inifcb,ifcb
  3.  
  4. ; Initialize complete FCB pointed to by DE
  5. ; INIFCB initializes 32 bytes as fcb1 and fcb2
  6. ; IFCB initializes 16 bytes starting with DE->FN
  7.  
  8. inifcb:
  9.     inc    de        ; Point to file name field
  10.     call    ifcb        ; Fill 1st part of FCB
  11.                 ; Fall through to IFCB to run again
  12.  
  13. ;--------------------
  14.  
  15. ; Initialize part of FCB whose file name field is pointed to by DE on entry.
  16. ; The file name and type are set to space characters; the EX, S2, RC, and the
  17. ; following CR (current record ) or DN (disk number) fields are set to zero.
  18. ; The S1 byte is set to the current user number.  On exit, DE points to the
  19. ; byte at offset 17 in the FCB (two bytes past the record count byte).
  20.  
  21. ifcb:
  22.     ld    b,11        ; Store 11 spaces for file name and type
  23.     ld    a,' '
  24.     call    fill
  25.     ld    b,5        ; Store 5 zeroes
  26.     xor    a        ; Fall thru to fill
  27.     jp    fill        ;
  28.  
  29.     end
  30.