0 Members and 1 Guest are viewing this topic.
move.b #$cc,($600017) ;restore timer speed
int5move.w (a7)+,d0 move.l (a7)+,a6 lea core0(PC),a6 ;modify return point move.l a6,-(a7) move.w d0,-(a7)
move.w (a1)+,d0 ;skip ctrl word
Bug report:Code: [Select]move.b #$cc,($600017) ;restore timer speed
Bug report: setting the SR to 0x0400
Bug report: the AUTO_INT_5 handler starts by clobbering d0 and a6.
Minor optimization in the init codeCode: [Select]move.w (a1)+,d0 ;skip ctrl word
I gather AUTO_INT_3 fires at OSC2/2¹⁹ on HW2, but how often does it fire on HW3/4?
Also, what's the proper way to detect HW3/4?
Aww, thanks you guys, and thanks @DJ Omnimaga or whoever it was for posting this on the front page! That's a great motivation to keep going with this "nonsense" In theory it would be trivial to port this to 89/89T. The frequencies in the converter will probably have to be adjusted, but otherwise it might very well run out of the box.I'm attaching a test build (run with "digiplay()"), give it a try if you like.
I tend to use 0xCE instead of 0xCC on my 89 HW2 calculator, which yields 1024/51 Hz instead of 1024/53 Hz AUTO_INT_5 rate - an order of magnitude closer to 20 Hz. On my calculator running AMS 2.05, after changing the initial value in port 600017 and enabling AUTO_INT_3 until the next power off (port 600015, bit 2), the default APD time, as measured by AUTO_INT_3 ticks stored in the OS's internal variables, is ~299s, instead of ~310-311s.You need to obtain the initial timer value through a waiting loop, then save and restore that. See PRG_getStart in intr.h, https://debrouxl.github.io/gcc4ti/intr.html#PRG_getStart .
PRG_getStart lea.l ($600017),a0 bset #3,-2(a0)\ne_loop tst.b (a0) bne.s \ne_loop\eq_loop move.b (a0),d2 beq.s \eq_loop
Page created in 0.037 seconds with 51 queries.