From 434921a55c97c84f899b81b88b5618b857be5ce7 Mon Sep 17 00:00:00 2001 From: "Christian A. Weber" Date: Tue, 30 Jun 2020 04:07:24 +0200 Subject: =?UTF-8?q?Aufger=C3=A4umt,=20VBR-Code=20implementiert,=20Chip-Sav?= =?UTF-8?q?e=20repariert,=20Debug-Output=20hinzugef=C3=BCgt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- VBR.S | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 VBR.S (limited to 'VBR.S') diff --git a/VBR.S b/VBR.S new file mode 100644 index 0000000..b6979a3 --- /dev/null +++ b/VBR.S @@ -0,0 +1,49 @@ + IDNT VBR + SECTION text,CODE + + INCLUDE "exec/execbase.i" + + MACHINE MC68010 + + + XREF _RawPrintfFunc + + XDEF @GetVBR,@SetVBR + +@GetVBR: movem.l d1/a0-a1/a5/a6,-(SP) + moveq.l #0,d0 ; Default-Resultat + lea GetSupie(PC),a5 + bra.s CommCont + + +@SetVBR: movem.l d1/a0-a1/a5/a6,-(SP) + lea SetSupie(PC),a5 + +CommCont: movea.l 4.W,a6 + btst.b #AFB_68010,AttnFlags+1(a6) ; 68010 oder neuer + beq.s 1$ ; nein ---> + jsr -30(a6) ; Supervisor ; Get/Set VBR +1$: + movem.l (SP)+,d1/a0-a1/a5/a6 + rts + +GetSupie: movec.l vbr,d0 + move.l d0,-(SP) + pea GetText(PC) + bsr _RawPrintfFunc + addq.w #8,SP + rte + +SetSupie: movec.l a0,vbr + move.l d0,-(SP) + pea SetText(PC) + bsr _RawPrintfFunc + addq.w #8,SP + rte + + +GetText: dc.b "GetVBR -> $%08lx",10,0 +SetText: dc.b "SetVBR($%08lx)",10,0 + + + END -- cgit v1.2.3