Re: A86: more interupt probs
[Prev][Next][Index][Thread]
Re: A86: more interupt probs
heres the best protection program that theres ever been, it shuts down
your calc and doesnt turn back on until you take out ALL 5 of the
batteries :)
#include "asm86.h"
#include "ti86asm.inc"
_user_int_ram EQU $d2fd
.org _asm_exec_ram
res 2,(iy+$23) ;turn user int off so it won't get called by
;accident before we're ready
ld hl,int ;copy prog to user int buffer
ld de,_user_int_ram+1
ld bc,int_end-int
ldir
ld a,(_user_int_ram+1) ;set up checksum byte
ld hl,_user_int_ram+($28*1)
add a,(hl)
ld hl,_user_int_ram+($28*2)
add a,(hl)
ld hl,_user_int_ram+($28*3)
add a,(hl)
ld hl,_user_int_ram+($28*4)
add a,(hl)
ld hl,_user_int_ram+($28*5)
add a,(hl)
ld (_user_int_ram),a
set 2,(iy+$23) ;turn it on
ret
int:
push af
push bc
push hl
call $0C29
i0:
pop hl
pop bc
pop af
ret
int_end:
.end
References: