Video hustler dissasembly listing with bluemsx debugger.question about im 1 instruction

صفحة 2/2
1 |

بواسطة ARTRAG

Enlighted (6923)

صورة ARTRAG

07-04-2008, 14:04

Well, the LSB byte of the called address is almost 'unknown'.

It should be 0xFF in 99,9% of the cases, iirc the sole known exception is the Gradiente Expert (Brazilian machine).
So, if you want to be sure to work even in those cases,
you need to waste 256+1 bytes of ram for each interrupt routine to be pointed.

بواسطة nikodr

Paladin (748)

صورة nikodr

08-04-2008, 02:06

I am somewhat confused,what if someone uses the hardware to generate interrupts in im2.Wouldn't that be so much faster than interrupt mode 1?In the sense that a vector table could be used for the keyboard,another for a controller,or mouse,or cartridge that would be connected to msx,or another one for midi.Am i saying something wrong?
can something like this be done?

بواسطة dvik

Prophet (2200)

صورة dvik

08-04-2008, 07:37

The Yamaha CX5M does this. The software can set the value to be put on the data bus for midi interrupts and timer interrupts iirc. So the yamaha software uses this to determine what type of interrupt occurred. Note though, that the software disables the VDP interrupts, probably because the VDP doesn't put a well known value on the databus when interrupt occur.

بواسطة jltursan

Prophet (2619)

صورة jltursan

08-04-2008, 10:58

Wouldn't that be so much faster than interrupt mode 1?

Of course it is, IM2 interrupts are usually faster (or at least easier) because in MSX the IM1 mode is used commonly through hooks or page 0 swapping strategies.
For a plain use, if you don't mind to loose those 257 bytes and can live with the weird ISR allocation address (LSB=MSB), IM2 is indeed a very powerful interrupt mode. When dealing with specialized hardware, this mode has no rivals, it was designed for this kind of tasks Smile

بواسطة NYYRIKKI

Enlighted (6016)

صورة NYYRIKKI

08-04-2008, 22:05

If you need to read the LSB value of IM2 mode interrupt, you can use this Z80 databus monitor program:
http://www.msx.org/forumtopic3816.html

بواسطة nikodr

Paladin (748)

صورة nikodr

11-06-2008, 03:30

BUMP!

In most konami roms and megaroms the main loop of the game is something like

LOOP: JR Loop

Wouldn't it be better if it was something like this?
Loop:Halt
Jr loop

بواسطة turbor

Hero (519)

صورة turbor

11-06-2008, 15:14

It would be better on modern architecture (power savings while waiting are possible) or for emulators (needs less cpu power when waiting for the next calculated interrupt).

However, on the real Z80 the 'JR loop' use as much CPU power as the HALT and is smaller in memmory usage, therefore I would even prefer that short one instead of including the unneeded HALT.

بواسطة hap

Paragon (2042)

صورة hap

11-06-2008, 16:40

though including the halt would have a faster IRQ response

بواسطة nikodr

Paladin (748)

صورة nikodr

12-06-2008, 02:29

So the faster irq response would mean more speed in the custom interrupt handler?

صفحة 2/2
1 |