_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ THIS DON'T IN ANY WAY REPLACE THE ORIGINAL OVERSCAN RELEASE. PLEASE-_ READ THE ORIGINAL BEFORE THIS!!!_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ This version of the Overscan software, is written by Klaus Pedersen (micro@imada.ou.dk). Thanks to Bernd Gebauer and Karsten Isakovic, Berlin for the original. I don't in any way take any credit or blame for this (but bug reports are welcome). If the original writers are pissed, I will do mine to make it good again... What then have been fixed? o a bug that ment that some programs wrote one pixel outside the screen, have been fixed. o the software is 68010/20/30/40 clean. (see techincal bits) o the software works on TOS 1.4 and __later__! (it don't use undocumented system variables to enlarge the screen memory any more!) o it is now possible to disable Overscan, from within a bad program (last resort, as it is not possible to tell accs and the AES about the new screen size). o it is also possible to enable/disable Overscan form the desktop (general, because it is possible to init. AES and accs). o the driver is now 3700 bytes, of which 3000 stays in memory, (not counting the larger screen (68Kb)). I have added a new menu to the the Setup menu. Press UNDO and the software asks you to filp the overscan switch. When you have done that, the software makes the nesseary changes and returns. It is possible to call the Setup menu from the Set Pref. menu and change back to Overscan! (this might not work on new TOSes as it depends on a strange feature in the Desktop!) The CLEANUP switch (ALT-[R-SHIFT]-HELP) now checks if the Overscan switch is active or not, and make the nessary changes! This is a last resort to run bad programs, because it is not possible to tell accs and the AES about the new screen size. TECHINCAL BITS - move SR,Dx - have been removed, the instruction was used to check if the CPU was in USER or SUPER mode!!! The instruction can be used to that on all 680x0 cpus, but cpu's later than the 68000 tells you with a PRIVILEGE VIALTION exception, if the CPU was in USER mode. - the offsets to parameters from within the TOS dispatchers have been fixed so that it works on all 680x0 CPUs. This is how you should link into the GEMDOS trap: - remember that GEMDOS, XBIOS, BIOS is documented to change D0-D2/A0-A2, this means that you should be able to use them too, If is wasn't for TurboC and many other applications, that consider A2 safe! (use as few registers as possible and don't use D3-D7/ A2-A7)! AES and the VDI are special! Here you can't even A0 and A1 and D0 and D1 is used to pass parameters! (Save all registers!) LINK INTO GEMDOS ===================== longframe EQU $059E DC.B "XBRAnnnn" ; This is all XBRA is about OldDos: DC.L 0 ; place the old address here! MyDos: move USP,A0 btst #5,(SP) ; called from Supervisor- or User-mode? beq.s tst_funcs ; Parameter is on USER stack lea 6(SP),A0 ; Old (small) stack frame. tst.w longframe.w ; Is this running on a CPU beq.s tst_funcs ; with a long stackframe? addq.w #2,A0 ; -then add 2 more bytes. tst_funcs: cmpi.w #Pterm0,(A0) ; Check the FUNCTION numbers! bne.s notmine ... here do the stuff you need to do ... notmine: movea.l OldDos(PC),A0 ; Now return to the original! jmp (A0) LINK INTO VDI/AES ====================== magicAES EQU 200 magicVDI EQU 115 DC.B "XBRAnnnn" OldVec: DC.L 0 MyGem: cmpi.w #magicVDI,D0 ; Is it a [VDI]-call ? bne.s NotMyGem1 ; no -> continue movem.l A0-A1,-(SP) ; preserve all A-Regs! movea.l D1,A1 ; Address of VDI-Parameters movea.l (A1)+,A0 ; Control[0] = function number cmpi.w #func,(A0) ; Check the FUNCTION numbers! bne.s NotMyGem ; not mine -> next; ... here do the stuff you need to do ... NotMyGem: movem.l (SP)+,A0-A1 NotMyGem1: move.l OldVec(PC),-(SP) ; call Orginal GEM-dispatcher rts ; ... call