EasyManua.ls Logo

Husky Hunter - Page 175

Husky Hunter
499 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
BASIC FUNCTIONS
SECTION 5.2
5.2.2
Function ARG is used for passing parameters to machine ccxle subroutines.
Syntax
D=ARG(N)
Where Dis a Dummy Variable
N is the number to be passed
Examples P=ARG(10) Passes 10
P=ARG(V) Passes V
Remarks ARG loads the Z80 E and C registers.
VER.V09F
They are loaded with the higher and lower byte portions of
a 16 bit representation of the ARG argument.
For example if V in the example above was 4100 then:
E=16 C=4
NOTE: 16x256+4 = 4100
This function is useful when making CP/M system calls to
set the C register before a call to location 5. See
section 4.8, MACHINE CODE CALLS.
PAGE 5 - 6