MSX2 palette that copies MSX1 palette / interlaced support in SCREEN 4

By salutte

Master (136)

salutte의 아바타

10-03-2021, 14:41

Hi all,

While working on my game with interlaced scroll I am considering to add support for MSX2 computers by using SCREEN4 instead of SCREEN2, mainly to support more simultaneous sprites. I have two questions in this regard.

I understand that in SCREEN4 I need to set up the color palette myself, but I am pretty happy with the MSX1 palette. Is there code that helps setting the SCREEN4 palette as if it was SCREEN2? I would appreciate it much!

Also, a more tricky question, is there any guide that tells how SCREEN4 behaves when the Interlaced bit is set? I hoped that when the Interlaced bit is set, but the OddEven bit is reset, I could use my current trick of swapping the name table at every frame to show an image with less flicker (having twice the vertical resolution). But the behavior I observe does not match my expectations (the resolution does not seem to change).

Thanks!

Login or 등록 to post comments

By salutte

Master (136)

salutte의 아바타

10-03-2021, 18:27

Nevermind. I just realized that I don't need to do anything to replace the deafult palette. It is working now! Big smile

By wolf_

Ambassador_ (9887)

wolf_의 아바타

10-03-2021, 18:37

The default MSX2 interpretation of the TMS-palette is a bit more saturated/darker though. A better approximation could be made, though it won't be a perfect match.

By Grauw

Ascended (10018)

Grauw의 아바타

10-03-2021, 18:59

There are two flags, EO and IL, the one to alternate pages and the other to interlace. See the “Special Functions” section of the V9938 application manual (p. 103).

On MSX2 the palette register settings apply globally, not just to specific screen modes.

By salutte

Master (136)

salutte의 아바타

10-03-2021, 19:50

Thanks for the feedback!

My understanding is that SCREEN4 is not paged, so EO flag shouldn't do much. But I can't get to duplicate the vertical resolution using the interlaced mode.

By Grauw

Ascended (10018)

Grauw의 아바타

10-03-2021, 21:15

The IL function changes the TV output signal from 240p to 480i, however it relies on EO to switch the page for each field to actually double the resolution rather than repeatedly outputting the same frame. If the EO function doesn’t work in screen 4, then in the vertical blank you must switch the table addresses manually based on the EO flag in status register 2.