This page (revision-9) was last changed on 03-Feb-2023 15:21 by Gromit 

This page was created on 26-Jan-2011 09:54 by Gromit

Only authorized users are allowed to rename pages.

Only authorized users are allowed to delete pages.

Page revision history

Version Date Modified Size Author Changes ... Change note
9 03-Feb-2023 15:21 10 KB Gromit to previous
8 27-Jan-2011 11:24 10 KB Gromit to previous | to last
7 26-Jan-2011 15:31 10 KB Gromit to previous | to last
6 26-Jan-2011 15:14 10 KB Gromit to previous | to last
5 26-Jan-2011 15:08 10 KB Gromit to previous | to last
4 26-Jan-2011 14:19 7 KB Gromit to previous | to last
3 26-Jan-2011 10:04 267 bytes Gromit to previous | to last
2 26-Jan-2011 09:56 267 bytes Gromit to previous | to last
1 26-Jan-2011 09:54 192 bytes Gromit to last

Page References

Incoming links Outgoing links

Version management

Difference between version and

At line 6 added one line
----
At line 8 removed 2 lines
At line 43 added 137 lines
{{{
;************************************
;VERTICAL-BLANK INTERRUPT IN ACTION!
;
;P.FINZEL 1987
;************************************
DEFINE JMP ="$4C",
XITVBV ="$E462"
;------------------------------------
;Hardware- & Schattenregister
;------------------------------------
CARD Vvblkd=$0224, Vvblki=$0222
BYTE
Dmactl=$D400, Prior =$026F,
Nmien =$D40E, Colbk =$D01A,
Gractl=$D01D, Pmbase=$D407,
Curinh=$02F0, SDmctl=$022F
BYTE ARRAY
Color(5)=$02C4, PColr(4)=$02C0,
Hposp(4)=$D000, Sizep(4)=$D008,
Trig(4) =$D010, Grafp(4)=$D00D
;------------------------------------
;Graphik-Daten
;------------------------------------
BYTE ARRAY Shape(0)=
[ $80 $F0 $60 $50 $08 $04 $02 $01 ]
CARD ARRAY PMAdr(4)=[0 0 0 0]
BYTE ZeigerX, ZeigerY
;------------------------------------
;PM-Graphik einschalten
;------------------------------------
PROC Pmgraphics(BYTE Basis)
BYTE i
CARD Adr
BYTE Adrhi=Adr+1
Pmbase=Basis
Adr =0
Adrhi =Basis+4
Gractl=3
SDMCTL=$3A
FOR i=0 to 3
DO
Zero(Adr,256)
Pmadr(i)=Adr
Adr ==+256
Sizep(i)=0
OD
RETURN
;------------------------------------
;Einbinden von Interrupt-Routinen
;------------------------------------
PROC Setvbi(BYTE POINTER Vektor)
Nmien=0 Vvblkd=Vektor Nmien=$40
RETURN
;------------------------------------
;VBI-Routine
;------------------------------------
PROC Vbipgm=*()
;zuerst Register retten
[ $A2 $07 $B5 $C0 $48 $B5 $A8
$48 $B5 $A0 $48 $B5 $B0 $48
$CA $10 $F1 ]
Zero(PMAdr(0)+ZeigerY,8)
IF (Stick(0)&1)=0 THEN
IF ZeigerY>32 THEN
ZeigerY==-1
FI
ELSEIF (Stick(0)&2)=0 THEN
IF ZeigerY<224 THEN
ZeigerY==+1
FI
FI
IF (Stick(0)&4)=0 THEN
IF ZeigerX>48 THEN
ZeigerX==-1
FI
ELSEIF (Stick(0)&8)=0 THEN
IF ZeigerX<208 THEN
ZeigerX==+1
FI
FI
MoveBlock(PMAdr(0)+ZeigerY,Shape,8)
Hposp(0)=ZeigerX
;Register holen...
[ $A2 $00 $68 $95 $80 $68 $95 $A0 $68
$95 $A8 $68 $95 $C0 $E8 $E0 $08 $D0
$EF ]
;...und VBI beenden
[JMP XITVBV]
;------------------------------------
;Das Hauptprogramm
;------------------------------------
PROC HAUPT()
Pmgraphics($80) ;PMG ab Adr. $8000
Prior=1 ;Prioritaet
PColr(0)=$CE ;Farbe Player
ZeigerX=120 ;Startpunkt
ZeigerY=120
SetVBI(VBIPgm) ;Interrupt
PUT($7D) ;Bildschirm loeschen
Curinh=1 ;Cursor aus
POSITION(10,8) ;Kasten zeichnen
Put(17) Put(18) Put(18) Put(5)
POSITION(10,9)
Put(124) Put(79) Put(75) Put(124)
POSITION(10,10)
Put(26) Put(18) Put(18) Put(3)
DO
IF TRIG(0)=0 THEN
IF (ZeigerX>88) AND
(ZeigerX<104) THEN
IF (ZeigerY>96) AND
(ZeigerY<120) THEN
EXIT
FI
FI
FI
OD
SETVBI(XITVBV)
RETURN
}}}