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
/
ZSYS
/
ZSYSARK
/
Z3HLP01.ARK
/
A.LBR
/
ARRINTFN.HZP
/
ARRINTFN.HLP
Wrap
Text File
|
1990-03-23
|
4KB
|
113 lines
DESCRIPTION & GENERAL NOTES FOR INTERNAL FUNCTIONS
ARMIRROR -- Invert the bit order at (hl)
ARRFR0$E -- Write (A) into the array from row 1, col 0 to the end
ARRFRC$E -- Write (A) into (BC) through end of array. BC=row,col
ARRC1$C2 -- Perform a function on elements C through D in row B
ARRVISIT -- Perform a function on elements (HL) through (DE)
:Internal Functions --
The routines documented in this file are part of ARRAYFN.Z80.
They are not declared public, but are used by those others that are
Public. To make them public, edit the Public declarations as needed
in the ARRAYFN.Z80 file and reassemble to make a new .REL file. Copies
of the following help screens and of the titles from the main screen
can then be edited into ARRAYLIB.HLP and dependant help files as
required.
:Invert the bit order at (hl)
Routine: ARMIRROR
Function: Invert the order of the bits at (hl)
(swap bits 0-7,1-6,2-5,3-4)
Inputs: hl = addr of byte to invert
Outputs: mirror image in (hl)
Registers Affected: reg A is destroyed
all other registers preserved
Error Conditions: NONE
:-- Write (A) into the array from row 1, col 0 to the end
Routine: ARRFR0$E
Function: Write the contents of A into the array, starting
with row 0, column 0 and ending with the last byte in the array
Inputs: A = value with which to fill array
Outputs: AF = Completion status. 0, Z, NC = normal return.
Registers Affected: AF, AF',BC,DE,HL
Error Conditions:
if error: A = error code, carry set
A = 1 if bitmap not yet defined
:-- Write (A) into (BC) through end of array. BC=row,col
Routine: ARRFRC$E
Function: Write the contents of A into the array, starting
with row B, column C and ending with the last byte in the array
Inputs:
A = value with which to fill array
B = starting row number
C = starting column number
Outputs: AF = Completion status. 0, Z, NC = normal return.
Registers Affected: AF, AF',BC,DE,HL
Error Conditions:
on error: AF returns with carry set and error code in A
A = 1 if bitmap not yet defined
A = 2 if address is out of range
:Perform a function on elements C through D in row B
Routine: ARRC1$C2
Function: Visit 1 or more contiguous columns in a row, from
column c1 through column c2. ARVISITI must have already been called
to establish the function to perform.
Inputs:
B = starting row number
C = starting column number
E = ending column number
Outputs:
Registers Affected: AF, HL
Error Conditions:
on error: AF returns with carry set and error code in A
A = 1 if bitmap not yet defined
A = 2 if address is out of range
A = 3 if ending address < starting address
:Perform a function on elements (HL) through (DE)
Routine: ARRVISIT
Function: Visit all bytes in an address range, performing
a specified function on the contents of each address. Data in support
of the function may be in reg A and BC. The function to be performed is
specified by passing its address to ARRVISIT by a call to ARVISITI before
calling ARRVISIT.
When a new function is required, ARVISITI is called again.
Inputs:
HL = first address
DE = last address
Outputs:
HL = last address+1
Registers Affected: DE and BC are preserved
Error Conditions:
if ARVISITI has never been called, this routine will return
having done nothing.
rns with c