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
/
CPM
/
ZCPR33
/
S-Z
/
SLB36HLP.LBR
/
SYSLIB9.HZP
/
SYSLIB9.HLP
Wrap
Text File
|
2000-06-30
|
3KB
|
93 lines
FNAME -- File Name String Parser
INITFCB -- FCB Initialization
SETDMA -- Set DMA Address
:File Name String Parser (FNAME)
Routine: FNAME
Function:
FNAM┼á i≤ ß filσ namσ scanner«á Pointinτ t∩ thσá firs⌠ ì
characte≥ oµ ß filσ namσ specificatioε oµ thσ form:
ááááá du:filename.typ
wherσá an∙á par⌠á oµ thσá specificatioεá i≤á optional¼á thi≤ ì
routinσá fill≤ iε aε FC┬ witΦ zeroe≤á (3╢á bytes)¼á properl∙ ì
initialize≤á thσá F╬á (Filσá Name⌐ fielΣá iµá 'filenameºá i≤ ì
presen⌠á anΣ F╘ (Filσ Type⌐ fielΣ iµ 'typº i≤á present¼á anΣ ì
return≤ thσ numbe≥ oµ thσ selecteΣ disδ (iε thσ rangσ froφ ▒ ì
fo≥á ┴ t∩ 1╢ fo≥ P⌐ iµ 'dº i≤ presen⌠ anΣ thσ numbe≥ oµá thσ ì
selecteΣá use≥ (iε thσ rangσ froφ ░ t∩ 3▒ anΣá thσá questioε ì
marδá '?ºá character⌐á iµ 'uº i≤ present«á Iµá 'dºá i≤á no⌠ ì
present¼á 0FF╚á i≤ returneΣ fo≥ i⌠ t∩ indicatσ curren⌠ disk¼ ì
anΣá iµá 'uºá i≤ no⌠ present¼á 0FF╚ i≤ returneΣá fo≥á i⌠á t∩ ì
indicatσ curren⌠ user.
FNAME
Thσá strinτá pointeΣá t∩ b∙ H╠ i≤á no⌠á ßá conventiona∞ ì
strinτá iεá thσ sensσ oµ thσ res⌠ oµá thσá SYSLI┬á routines« ì
Thi≤ strinτ i≤ terminateΣ b∙ an∙ oµ thσ followinτ delims¼ a≤ ì
opposeΣá b∙ simpl∙ alway≤ beinτ terminateΣ b∙ ß binar∙ zero« ì
Thσ delimite≥ lis⌠ is:
ááááá <NULL or Binary 0> <SP or Space>
ááááá = _ ; , < >
Thσ followinτ arσ valiΣ examples:
ááááá test.txt <-- FN=TEXT FT=TXT, B reg = 0FFH,
ááááá C reg = 0FFH
ááááá a:t <-- FN=T FT=<SP>, B reg = 1,
ááááá C reg = 0FFH
ááááá 5:t <-- FN=T FT=<SP>, B reg = 0FFH,
ááááá C reg = 5
ááááá c10:x.y <-- FN=X FT=Y, B reg = 3,
ááááá C reg = 10
FNAME
Inputs: HL points to the first byte of the target string
ááááá (which ends in a delimiter)
ááááá DE pts to the first byte of a 36-byte long FCB
Outputs: B=Disk Number (1 for A to 16 for P, or 0FFH if
ááááá no disk specified)
ááááá C=User Number (0 to 31 or '?' for all users, or
ááááá 0FFH if no user specified)
ááááá HL points to the character which ended the scan
ááááá A = 0 and Zero Flag Set (Z) if invalid Disk or User
ááááá Specified; A = 0FFH and NZ if no error
Registers Affected: PSW, BC, HL
SYSLIB Routines Called: CAPS
Special Error Conditions: None
:FCB Initialization
Routine: INITFCB
Function║
INITFC┬á simpl∙ clear≤ al∞ oµ thσ field≤ oµá ßá 36-bytσ ì
FC┬á t∩á zer∩ excep⌠ fo≥ thσ F╬ anΣ F╘ (Filσ Namσá anΣá Filσ ì
Type⌐ fields¼ whicΦ i⌠ leave≤ untouched.
Inputs: DE = pointer to FCB buffer
Outputs: None
Registers Affected: None
SYSLIB Routines Called: FILLB
Special Error Conditions: None
:Set DMA Address
Routine: SETDMA
Function║
SETDM┴ set≤ thσ DM┴ addres≤ t∩ thσ 128-bytσ blocδ whosσ ì
address is contained in HL.
Inputs: HL = Address of 128-byte block
Outputs: None
Registers Affected: None
SYSLIB Routines Called: None
Specia∞áErro≥ Conditions║ None