Jump to content
IGNORED

How to get max free ram and use custom charset above $d800?


Recommended Posts

How to get max free ram and use custom charset above $d800?

I've tried different settings of portb and can't get it to work...

Chars keep looking chaotic whenever I put them in upper part of ram.

What am I missing?

Could it be something in altirra's settings?

Link to comment
Share on other sites

If you're using the default OS charset and want to swap the Ram in/out at adhoc times then it's a good idea to copy the default charset to the 1K at $E000.

 

The PORTB bits -

bit 0 - set to 0 to replace the OS with Ram. Note this includes the $C000-$CFFF area as well as $D800-$FFFF. Also note the IO area $D000-$D7FF 2K Ram is never accessable on a standard system. Some mods and 3rd party Ram expansions allow you to access it, usually as part of a 16K bank @ $4000.

 

bit 1 - set to 1 to replace Basic with Ram. Note the opposite to bit 0, this is because powerup default of PORTB output should be all ones, so the desired startup state is only the main portion of the OS visible.

 

bit 2,3 - usual function on 130XE to select which one of 4 extended memory banks is made available in the 16K area @ $4000.

 

bit 4,5 - usual function on 130XE to determine if the CPU (4) and Antic (5) see main or extended Ram in the 16K @ $4000 (1=main).

 

bit 6 - usually provides extra bank selection for systems with >128K Ram.

 

bit 7 - usually 1, set to 0 will make the Self-Test 2K Rom segment visible at $5000. If the OS is switched out, it will override and also switch out the Self-Test Rom.

 

 

 

With Altirra settings, just ensure your machine type is XL/XE and the system memory is 64K or more.

  • Like 2
Link to comment
Share on other sites

Thanks for nice info !

 

"Once you eliminate the impossible, whatever remains, no matter how improbable, must be the truth."

 

It's exactly how I thought - I'm not crazy, it's just that bug was in another place :)

Once I got info from you I was sure I'm setting correct bits. So I've started looking for error in different places and to my amusement found it rather quickly. Guess I was to tired last night so didn't see the obvious problem:

jsr copy_charset
jsr disable_roms

Should've been this instead :D

jsr disable_roms
jsr copy_charset

Thanks!

 

  • Like 1
Link to comment
Share on other sites

And of course the thing I forgot to add - unlike C64 there's no write-thru feature to Ram under the Rom. And also unlike C64, Rom present at a given location will take precedence for graphics accesses by Antic.*

 

* though unsure of what happens in the case of 130XE Antic enabled for extended Ram but Self-Test Rom also swapped in.

  • Like 2
Link to comment
Share on other sites

And of course the thing I forgot to add - unlike C64 there's no write-thru feature to Ram under the Rom. And also unlike C64, Rom present at a given location will take precedence for graphics accesses by Antic.*

 

* though unsure of what happens in the case of 130XE Antic enabled for extended Ram but Self-Test Rom also swapped in.

Exactly why I thought it doesn't matter when I was copying data "under" rom...

 

Decades of c64 coding left some cognitive biases I guess :)

Link to comment
Share on other sites

One thing I've heard but not verified is switching an XL/XE to a 400/800 OS gives you 4k of extra RAM above $C000 to play with. I'm weak on details, something like FixXL boot disk or Ominview OS give you the extra memory and allow you to change the built in character set in the OS RAM. Some severe limits of course like anything that relies on PBI or XL OS features will not work.

Link to comment
Share on other sites

* though unsure of what happens in the case of 130XE Antic enabled for extended Ram but Self-Test Rom also swapped in.

 

The self-test ROM has priority over the extended memory window on a stock 130XE. Expansions that reuse bit 7 as a bank bit may have the priority reversed.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...