B47B
B47B
OE
15
MACRO-BO
3.44
B47A
11
B52B
8470
CD
0005
B480
C9
8481
8481
OE
10
B483
11
B528
B486
CD
0005
8489
C9
B48A
848A
3E
00
848C
32
F358
848F
CD
B481
8492
8492
OE
13
8494
II
8528
8497
CD
0005
849A
C9
:
HHfH***fHffffffff*****fIUffllfIIHfffffffffffffffffffffffffffffffff
t
,*
Subroutine
Write
the data
block
which
has
been
read
froo the
" screen to the
file
called
VRAMDATA.DAT.
,*
:
*ffHHfHHIHli*****HfHffffffffflffffffffffffffffIHffflffiffffflfff
WRlTE,
09-De(-81
LD
PAGE
LD
CALL
RET
C.21
1-3
DLFCBADR
BDOS
,
Set
up
the
BDOS
lunction
code
that
wi
11
write the data
in
the current
DMA
buller
, to the
next
record
of
the
currenth
open
fiie.
in
this
case
to
·VRAMDATA.DAT'
Set
up
the
FCB
address
60
and
wri
te the data
And
return to the .ain
program
;
HHffffffHffffffffffflffffffffffffffffffftftffffffffffffffffffftffffff
:*
I
,*
;*
Subroutine
Close
the
file
'VRAMDATA.DAT'.
now
the screen
contents
have
been
wri
tten to
it.
:
fffffffffffffffffflffffffffHffllHHfffffflfffffffffUtfUtfHfffffflff
CLOSE,
LD
LD
CALL
RET
C.16
DE.FC8ADR
BDOS
Set
the
BDOS
lunction
code
that closes
a
lile.
Set
UP
the
FC8
address
60
and
close the
file
'VRA"DATA.DAT·
And
return to the lain prooral.
:
fffffffffflHffffffffffffflffffffffffffffffffffffftlffffftffffflflfflfff
•
,t
,I
It
Subroutine
Erase
the
file
we've
written the screen
contents to
because
it
is
lore
than
likelv
that
it
is
incolplete
and
therefore
totally
useless to
anvbodv.
:
fflfffflfllfflffffffffffflffffflfffUffffffffffilfffffiffffflflflffffflf
ERASE,
DELETE,
LD
LD
CALL
LD
LD
CALL
RET
A,OOH
(SLVFLS)
IA
CLOSE
C,19
DE,FCBADR
BDOS
8-9
Disable slave cOllunication
now
becau.e
we
no
longer
need
it.
Close
the
Ii
le
we've
created
We
needn't bother
about
the error that
could
be
returned
because
we
know
it
can't
happen.
Set
up
the
BDOS
function
code
that will
delete the
file
(il
it
exists)
Set
up
the
FCB
address
Execute
function
and
ignore
any
error
code.
It
would
indicate that the
file
didn't
exi
st
whi
ch
is
DK
because
a ne.
one
lUst
be
created.
8498
B49B
B4A3
~ACRO-80
3.
44
B49D
0004
8m
B4A7
B4AI
0079
84A3
B4A3
24
B4A4
00
B4A5
00
B4A6
7B
B4A7
B4A7
00
B4AB
B528
B528
00
8529
S6
52
41
4D
852D
44415441
8531
44
41
54
B534
BS4D
00
014E
~ACRO-BO
3.44
Hacros:
SVlbols:
0005
BDOS
854D
COUNT
B400
DEST
8436
nIT
8418
LOOP
B437
READVRAM
B4A3
SNDPKT
B4A4
XCOORD
ND
Fatal error
(5)
:
fffHH***H***HffffHff*****fHfff***ffHHHIfHHf***fHHHfffHfff
•
,*
Data
storage lor all variables
needed
by
the
prDgra.
I'
;
********ffffff*******HHHtffftff*HfffHf*****fHHffHffHlffffltffff
PACKET:
Sl
ave
CPU's
cD
••
unicati on;
packet
DW
SNDPKT
Address
Df
the
packet
that
wi
II
be
sent
to the slave
CPU
09-Dec-BI
PAGE
1-4
DW
Size
01
the
packet
that will
be
sent
to the slave
CPU
DW
RCVPKT
Address
of
the
packet
that
is
expected
back
frol
the slave
CPU
DW
121
Size
of
the
packet
expected
to
be
be
returned
frol
the slave
CPU
SNDPKT,
Actual
oacket
to
be
sent to the slave
CPU.
It
includes
both
the
co
...
nd
and any
paranters
that are required
DB
024H
Slave
co
••
and
code
that reads the
graphic screens conlents.
ICOORD,
DB
OOH
Starting X coordinate
Irol
which
to
read
the data
YCOORD,
DB
OOH
Starting Y coordinate
frol
which
to
to
read
the data
DB
120
NUlber
of
data bytes to
read
Irol
the
X,V
coordinate specified
above.
RCVPKT,
Packet
returned
bv
the slave
CPU
once
the
Calland
has
been
executed.
DB
OOH
Return
code
that indicates the success
01
the e.ecuti
on
01
the
Calland
D~ABUF,
DS
12B
Space
allocated lor the receipt
01
the
screen data
and
lor the
D~A
buller.
FCBADR:
File control
block
IFCB)
work
area
DB
OOH
Dri
ve
code
in
this
case the currently
logged
in
disk
DB
'VRA"DATA'
The
file
nale to
be
used
DB
'DAT'
1
The
file
e,tension
or
lile
type
DS
25
The
rest
of
the
FCB
is
used
bv
the svste.
and
we
don't
have
to
worrv
about
it
at
all
COUNT:
DB
OOH
Count
used
lor
nUlber
01
blocks to
read
frol
the screens
VRA"
LEN
EQU
$-DEST
END
09-Dec-81
PA6E
0001
BIOS
B4BI
CLOSE
B44F
CREATE
8492
DELETE
B4AB
D"A8UF
848A
ERASE
B528
FCBADR
014E
LEN
8498
PACKET
84A7
RCVPKT
F2C9
SCRMODE
F35B
SLVFLS
OOOE
SOURCE
8478
WRITE
B4A5
VCOORD
8-10