IBM Personal Computer MACRO Assembler
Version 2.00
810S1
----
01/10/86
INTERRUPT 15H 810S ROUTINES
CY FLAG ON I F NO ADAPTER CARD OR I NVALI 0 CALL
;
------
- - - - - - - - - -
-
-- - - --- - - - - - - -
----
- --
---
-
----- --- ------- -
-
--
---
INPUT
(OX) =0 READ THE CURRENT SWITCHES
RETURNS
(AL) = SWITCH SETTINGS
IN 81TS 7-4
STRIP UNWANTED 81TS OFF
FINI SHED
SAVE A(X)
VALUE
SA VE A ( Y ) VALUE
SAVE
8LOCK
INTERRUPTS WH I LE READ I NG
SET UP TO LATCH T I MER 0
READ LOW 8YTE OF T I MER 0
INTERRUPTS 8ACK ON
GET SU8 FUNCT I ON CODE
ADDRESS OF PORT
READ SW ITCHES
READ RES I ST I VE INPUTS
GO TO ERROR RETURN
GO TO COMMON RETURN
SA VE 8 ( Y ) VALUE
GET 8(XI
VALUE
GET A ( Y)
VALUE
GET A ( X ) VALUE
FIN I SHED -
RETURN
READ HIGH 8YTE OF TIMER 0
REARRANGE TO HIGH, LOW
SAVE
SET COUNT
FIRE TIMER
READ HIGH 8YTE OF TIMER 0
REARRANGE TO HIGH, LOW
CHECK FOR COUNTER WRAP
GO IF NO
READ VALUES
HAS PULSE ENDED?
INTERRUPTS 8ACK ON
FLUSH OTHER
INPUTS
; SA VE 8 ( X)
VALUE
; READ LOW 8YTE OF T I MER 0
; ORIGINAL COUNT
SET 0 COUNT FOR RETURN
EX IT WITH COUNT = 0
;
SET UP TO LATCH TI MER 0
; ADJUST
I ADJUST FOR WRAP
; COUNT
AL,O
T IMER+3 ,AL
S+2
AL, TIMER
AH,AL
S+2
AL, TIMER
AH,AL
AL,DX
AL.,8L
TEST CORD 1
CX,O-
-
CX
SHORT TEST CORD 2
CX,CX
-
-
SHORT TEST_CORD_3
8L,1
TEST CORD
CX
-
8L,2
TEST CORD
CX
-
8L,4
TEST CORD
CX
-
8L,8
TEST CORD
DX,CX
CX
8X
AX
JOY_I
PROC
NEAR
OX
AL,DX
AL,OFOH
JOY_l
AX,DX
DX,20lH
AL,AL
JOY 2
AL -
JOY 3
CI -
AL,DX
PROC
NEAR
CX,AX
CX,IFFOH
CX,I
CX,I
CX,I
CX,I
READ THE RES I ST I VE INPUTS
RETURNS
(AX) =A ( x)
VALUE
(8XI=A(y)
VALUE
(CXI=8(x)
VALUE
(DXI=8(y)
VALUE
AL,O
TIMER+3,AL
S+2
AL, TIMER
S+2
AH,AL
AL, TIMER
AH,AL
AX
CX,4FFH
DX,AL
S+2
CX,AX
TEST CORD 4
OX
-
-
DX,-I
DX,201H
CX
AX
CX,4FFH
DX,AX
CX,DX
OX
SHORT TEST_CORD_5
(OX)
=
1
STI
JMP
TEST CORD 4:
-
S08
TEST CORD 5:
-
AND
SHR
SHR
SHR
SHR
TEST CORD
-
PUSH
CLI
MOV
OUT
JMP
IN
JMP
MOV
IN
XCHG
PUSH
MOV
OUT
JMP
TEST CORD II
-
IN
TEST
LOOPNZ
CMP
POP
JNZ
SU8
JMP
TEST CORD 2:
-
MOV
OUT
JMP
IN
MOV
JMP
IN
XCHG
CMP
JAE
PUSH
MOV
SU8
ADD
POP
JMP
JOY STICK
-
STI
MOV
MOV
OR
JZ
DEC
JZ
JMP
TEST CORD 31
-
S1'I
MOV
PUSH
PUSH
MOV
TEST CORD 6:
-
IN
MOV
CALL
PUSH
MOV
CALL
PUSH
MOV
CALL
PUSH
MOV
CALL
MOV
POP
POP
POP
JMP
IN
AND
JMP
PAGE
; --- JOY _ST I CK --------------------------------------------------
TH I S ROUT I NE WILL READ THE JOYST I CK PORT
I
I
I
I
I
I
I
I
I
I
I
I
I
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
0048
205
0048 F8
206
004C 88 C2
207
004E 8A 0201
208
0051
OA CO
209
0053 74 09
210
0055 FE C8
211
0057 74 OA
212
0059 E8 A8
213
0058
214
0058 F8
215
005C E8 A8
216
217
005E
218
005E EC
219
005F 24 FO
220
0061 E8 F8
221
222
0063
223
0063 83 01
224
0065 E8 0081 R
225
0068 51
226
0069 83 02
227
0068 E8 0081 R
228
006E 51
229
006F 83 04
230
0071 E8 0081 R
231
0074 51
232
0075 83 08
233
0077 E8 0081 R
234
007A 88 01
235
007C 59
236
0070 58
237
007E 58
238
007F E8 DA
239
240
0081
241
0081
52
242
0082 FA
243
0083 80 00
244
0085 E6 43
245
0087 E8 00
246
0089 E4 40
247
0088 E8 00
248
0080 8A EO
249
008F E4 40
250
0091
86 EO
251
0093 50
252
0094 89 04FF
253
0097 EE
254
0098 E8 00
255
009A
256
009A EC
257
0098 84 C3
258
0090 EO F8
259
009F 83 F9 00
260
00A2 59
261
00A3 75 04
262
00A5 28 C9
263
OOA 7 E8 20
264
00A9
265
00A9 80 00
266
00A8 E6 43
267
OOAD E8 00
268
OOAF E4 40
269
0081
8A EO
270
0083 E8 00
271
0085 E4 40
272
0087 86 EO
273
274
0089 38 C8
275
0088 73 08
276
0080 52
277
008E 8A FFFF
278
279
OOC I 28 DO
280
00C3 03 CA
281
00C5 5A
282
00C6 E8 02
283
284
00C8
285
00C8 28 C8
286
OOCA
287
OOCA 81
El
lFFO
288
OOCE 01
E9
289
0000 01
E9
290
0002 01
E9
291
0004 01
E9
292
293
0006
294
0006 F8
295
0007 8A 0201
296
OODA 51
297
0008 50
298
OODC 89 04FF
299
OODF
300
OODF EC
5-82
BIOSI (01/10/86)