416 OSBYTE call with A=&83 (131) Read top of OS RAM address (OSHWM) The Machine Operating System uses memory from page zero up to store operating system variables. The exact amount of RAM needed depends, for example, on whether or not the disc operating system is in use. This call is used to return the address of the first free location in memory above that required for the operating system. The value is returned in X and Y with Y containing the most significant byte and X containing the least significant byte. 10A%=131 30PRINT ~USR(&FFF4) >RUN B10E0083 &0E00 is the value returned, &83 is the OSBYTE code.
OSBYTE call with A=&84 (132) Read bottom of display RAM address This call returns, in X and Y, the lowest memory address used by the screen display or by special paged ROMs. It indicates the top of free RAM that BASIC can safely use. HIMEM is normally set to this value when using the MODE statement. As usual, Y contains the most significant byte and X the least significant byte of the result. If this call is made following a *SHADOW command, &8000 will only be returned following a MODE change. (See chapter 42 for details of the shadow screen facility).
OSBYTE call with A=&85 (133) Read lowest address for particular MODE This call returns, in X and Y, the address of the start of memory that would be set aside if a particular display MODE were to be selected. Certain paged ROMs might also affect the value returned. The display MODE to be investigated is passed in X. This call does not change MODE s, it merely investigates the possible consequences of doing so. If this call is made following a *SHADOW command, it will return &8000 without the need for a MODE change. (See chapter 42 for details of the shadow screen facility).
OSBYTE call with A=&86 (134) Read text cursor position This call returns in X and Y the X and Y coordinates of the text cursor. A similar function is performed in BASIC by POS and VPOS . As an OSBYTE call thistakes typically 100 microseconds.