Interrupts and gfx9000

Page 2/5
1 | | 3 | 4 | 5

By assembler

Champion (378)

assembler's picture

29-07-2012, 11:22

O_O

openMSX is veeeery powerful

By PingPong

Prophet (3451)

PingPong's picture

29-07-2012, 12:29

wouter_ wrote:

You could use the following script in openMSX to show the exact reason why the Z80/R800 enters the IRQ routine.

@wouter: do you know what is the exact procedure when dealing with v9990 in order to aknowledge it?

By Manuel

Ascended (15763)

Manuel's picture

29-07-2012, 13:20

By wouter_

Champion (418)

wouter_'s picture

29-07-2012, 20:05

PingPong wrote:

@wouter: do you know what is the exact procedure when dealing with v9990 in order to aknowledge it?

Yes, but I can't really add more info than what has already been said in this thread:
- In the interrupt routine, read port 0x66 to check which IRQ is active. If you're 100% sure there's only one IRQ source active
in the whole MSX machine, you can skip this step. But since you're debugging a problem it's a very good idea to verify that this value is the value you expect.
- Before returning from the IRQ routine you MUST clear the IRQ by writing to port 0x66.

By assembler

Champion (378)

assembler's picture

31-07-2012, 08:58

problem solved.

To enable interrupts:

ld a,9
out (0x64),a
ld a,00000011b ; <- bit 0: vertical retrace. bit 1: horizontal position (for screensplit)
out (0x63),a

In the interruption routine:

in a,[0x66]
and 00000011b
out [0x66],a
bit 1,a
jp nz,.horz_int
bit 0,a
jp nz,.vert_int
jp .interruption_end

I had several errors, one of them was in handling the interruption hook.

Now I have all I need (for now) to continue developing a game for GFX9000

Thanks!

By Manuel

Ascended (15763)

Manuel's picture

31-07-2012, 23:13

Cool, looking forward for the (intermediate) result!

By assembler

Champion (378)

assembler's picture

01-08-2012, 09:51

First test.

http://youtu.be/Lfolbfnl2f4

One layer scroll with scoreboard. The second layer is available for parallax.
In next versions, multidirectional, multilayer and multispeed will be possible. The scroll in the video is from 1x to 8x, but faster speeds are possible.

The graphics are taken from internet only for the test. The development project has nothing to do with bubble bobble.

By Huey

Prophet (2644)

Huey's picture

01-08-2012, 10:31

assembler wrote:

First test.

http://youtu.be/Lfolbfnl2f4

Video is private ;)

By assembler

Champion (378)

assembler's picture

01-08-2012, 10:35

ups...

solved

oO

By anonymous

incognito ergo sum (109)

anonymous's picture

01-08-2012, 14:02

Would've been nice if Assembler had mentioned he received the solution to his problem in #msxdev @ Rizon IRC :)

Although I must say the exact code above is assembler's own variation. I'd never write code that could ignore interrupts like that. :P

Page 2/5
1 | | 3 | 4 | 5