This file is indexed.

/usr/share/z88dk/lib/int82.asm is in z88dk-data 1.8.ds1-10.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
; Ti82 interrupt loader - by Henk Poley
; Based upon several sources, uses APD_BUF to put the IV-table and interrupt
;-----------------------------------------------------------------------------
; You only need to have an interrupt marked with IntProcStart
;  at the beginning, and IntProcEnd at the end of your interrupt.
; Since CrASH moves your program when executing the TIOS keyhandler,
;  we need to put the interrupt into a safe RAM area, here we use
;  the APD_BUF for that. (you need to enable IM2 yourself)
;
; NEW:
;  - Interrupt won't go 'boom' because of CR_KHAND relocation.
;  - Uses the CrASH protocol for installing interrupts.
;-----------------------------------------------------------------------------

;defc INT_STATE  = $8D72 ; 1   byte  - Interrupt status (0 = no running interrupt)
;defc CURSOR_POS = $800C ; 2   bytes - Cursor Position

	ld	a,(INT_STATE)		; Find the Interrupt State
	or	a			;
	jr	z,OK			; If clear, install interrupt
					;
	ld	hl,$0002		; Display starting second row
	ld	(CURSOR_POS),hl		;
	ld	hl,UnloadStr		; Display the UnloadStr
	call	$8D74			; ROM_CALL(D_ZT_STR)
	defw	$38FA			;
	call	$8D91			; CALL CR_KHAND (Wait for a key)
	jp	cleanup			;  -> quit
					;
.UnloadStr				;
	defm	"Please disable  "	;
	defm	"the interrupt   "	;
	defm	"that is running."	;
	defb	0
					;
.OK					;
	im	1			; For safety reasons...
	ld	a,$84			;
	ld	i,a			; IV table will be at $8400-$8500
	ld	bc,$0100		; IV table is 256 bytes long
	ld	h,a			;
	ld	l,c			; HL = $8400
	ld	d,a			;
	ld	e,b			; DE = $8401
	dec	a			;
	dec	a			; A  = $82
	ld      (hl),a			; Set first number of IV table
	ldir				; Copy from HL to DE, BC bytes

	; Now, we DON'T setup a JP IntProcStart, because when CR_KHAND
	;  relocates this code, things will go horribly wrong. So we
	;  just put the whole interrupt (about 92 bytes) into APD_RAM
	
	ld	hl,IntProcStart		;
	ld	d,a			;
	ld	e,a			; DE = $8282
	ld	bc,IntProcEnd-IntProcStart
	ldir				;

; Registers by now:
; ------------------------------------------------------
; A  = $82
; HL = IntProcStart + (IntProcEnd-IntProcStart)
; DE = $8282        + (IntProcEnd-IntProcStart)
; BC = $0000
; F  = destroyed
; ------------------------------------------------------
; Memory usage in APD_BUF:
; ------------------------------------------------------
; $8228 / $8281 -  90 bytes - free
; $8282 / $83FF - 382 bytes - partialy used by interrupt
; $8400 / $8500 - 256 bytes - IV table
; $8501 / $8528 -  40 bytes - free
; ------------------------------------------------------
; See the interrupt routines themselves for
;  further info of memory useage.