Login
Back to forumSee the full topicGo to last reply

Posted By

SukkoPera
on 2025-09-15
08:39:38
 Re: Mouse Extension v1.0

I think I have found out why the mouse driver does not work with JiffyDOS:

jsr judt2

This is the first instruction of the KERNAL vBlank hander and is replicated in the vBlank handler of the mouse driver (judt2 = $cfbf).

The judt2 routine seems to have been originally meant to update the KERNAL jiffy counter but apparently it was later patched to check if any key is pressed on the Datassette before doing that. JiffyDOS removed all of the Datassette code and therefore they had to alter this call to jump directly to udtim ($cef0, line 97 of the original handler - on a side note, this makes me wonder if JiffyDOS handles the jiffy counter correctly on PAL machines... - EDIT: No, it doesn't!). So, if the mouse handler unconditionally jumps to $cfbf, it will make a mess with JiffyDOS.

The solution is to take the destination address for this jump from $ce43, which is the address of the argument of the jsr call in the KERNAL vBlank handler. Either patch it into your code before enabling it or use an indirect jump.

So now you see why having access to the sources is useful. Maybe there will be other problems, but let's start fixing this one.
bszggg1


Back to top


Copyright © Plus/4 World Team, 2001-2025. Support Plus/4 World on Patreon