set adjust / set save in Assembly without using BIOS calls

Page 1/2
| 2

By edoz

Prophet (2282)

edoz's picture

17-05-2020, 17:43

Hi.. as i'm not a ML programmer could someone help me with a code snipped how to call the basic routine (set adjust and set save) in assembly without using the MSX BIOS? Is this possible?

Login or register to post comments

By Manuel

Ascended (16693)

Manuel's picture

17-05-2020, 21:14

You mean 'set screen'?

By edoz

Prophet (2282)

edoz's picture

17-05-2020, 21:52

Oh yes, sorry, set screen yes (to save the value)

By Daemos

Paragon (1718)

Daemos's picture

17-05-2020, 23:37

DELETED

By Manuel

Ascended (16693)

Manuel's picture

18-05-2020, 00:37

I didn't check, but I would suspect these routines are in the SUBROM (extended BIOS). But, I really didn't check.

By Grauw

Ascended (9156)

Grauw's picture

18-05-2020, 00:44

Since Louthrax made SofaSet, he might be able to assist…

By edoz

Prophet (2282)

edoz's picture

20-05-2020, 16:22

Thanks! For you help.. i created some small test tool that allows you to do this in SymbOS, and when using real hardware i hope it is usefully. I notice it is for me Wink I know.. you can do this in basic as well Wink

I am not a ML coder .. and was not needed as i was I/O Big smile

Set Adjust not in MSX basic ;))


By ericb59

Paladin (961)

ericb59's picture

20-05-2020, 17:46

/* --------------------------------------------------------- */
/* SETADJUST   Adjust screen center.   FUSION-C 1.3        */
/* --------------------------------------------------------- */
void SetAdjust(signed char x, signed char y) // x and y must be between -7 and +6
{
    char vx,vy,value;

      vx=x;
      if (x<0)
        vx=16+x;
        
      vy=y;
      if (y<0)
        vy=16+y;

      value = (vy<<4) | vx ;
      Poke(0xFFF1,value);     // Reg 18 Save
      VDPwrite(18,value);
    
}

By ducasp

Champion (315)

ducasp's picture

20-05-2020, 19:22

Didn't use SYMBOS a lot to know if this is applicable, but if there are full screen applications, those could use the adjust register to implement smooth scrolling on 9938, if that is the case it is probably a good idea to restore it after returning from a full screen application.

By NYYRIKKI

Enlighted (5556)

NYYRIKKI's picture

20-05-2020, 19:42

edoz: I think, all you need can be found here:

https://msx.org/wiki/Ricoh_RP-5C01

(For Adjust, see registers 1 and 2 of block 2)

By edoz

Prophet (2282)

edoz's picture

20-05-2020, 20:43

ducasp wrote:

Didn't use SYMBOS a lot to know if this is applicable, but if there are full screen applications, those could use the adjust register to implement smooth scrolling on 9938, if that is the case it is probably a good idea to restore it after returning from a full screen application.

Of course this is possible.. it's a bit like the screensaver works.. The MSX is not a protected system so you can do what ever you want.. If you do something like this it is probably not compatible anymore with other Z80 systems... but yes, you could build a specific MSX program/game and exit again to SymbOS. But if you do that you have to keep in mind your running a different OS Big smile This has also some benefits.. Lot of thing you can use already, like network , mouse routines.. all kind of objects are there easy to call Big smile Programming in a multitasking environment is different but very cool. At least i like it Big smile

Page 1/2
| 2