On Thu, 18 Mar 1999, shevek wrote:

> On Wed, 17 Mar 1999, Marco Antonio Simon dal Poz wrote:
> 
> > How can 64kb of RAM be memory mapper? Memory Mapper with only 4 memory
> > blocks is a bit unuseful!
> 
> Not at all. With a mapper every 16kB page can be switched on 0000, 4000,
> 8000 or C000. This is useful for example when you want to use a lot of
> memory under BASIC. You can lift the bottom of your program to C000 (F676
> if I remember correctly) and then use page 2 as data-area. With a 64kB
> mapper this still gives you 48kB to use, in stead of the 16kB you would
> have without a mapper.

Yes, it's F676h that points to the bottom of the basic program.

But the main utility of the Memory Mapper is to create a block switching
system that allows the slot to contain much more than 64kb of RAM. Using
Memory Mapper only to exchange memory contents isn't a big deal, because
you still can do it using LDIR (or using a famous technique called swap,
like this:)
        LD HL,source
        LD DE,destination
        LD BC,4000h
LOOP:   LD A,(HL)
        EX AF,AF'
        LD A,(DE)
        LD (HL),A
        EX AF,AF'
        LD (DE),A
        INC HL
        INC DE
        DEC BC
        LD A,B
        OR C
        JR NZ,LOOP
        RET

Of course Memory Mapper if much faster, but it's not much flexible,
because the block size to be exchanged is fixed in 16kb. If you want to
change 8kb basic programs, you'll need to use the above technique.

Is there a program that takes profit of the 64kb memory mapped?

Greetings from Brazil!

-----------------------------------------------------------------
Marco Antonio Simon Dal Poz        http://www.lsi.usp.br/~mdalpoz
[EMAIL PROTECTED]   "Apple" (c) Copyright 1767, Sir Isaac Newton

    /"\
    \ / CAMPANHA DA FITA ASCII - CONTRA MAIL HTML
     X  ASCII RIBBON CAMPAIGN - AGAINST HTML MAIL
    / \


****
MSX Mailinglist. To unsubscribe, send an email to [EMAIL PROTECTED] and put
in the body (not subject) "unsubscribe msx [EMAIL PROTECTED]" (without the
quotes :-) Problems? contact [EMAIL PROTECTED] (www.stack.nl/~wiebe/mailinglist/)
****

Reply via email to