Re: CBM-II/B series questions

From: William Levak (wlevak_at_cyberspace.org)
Date: 2001-01-05 22:09:54

On Fri, 5 Jan 2001, Andre Fachat wrote:

> > 2. Are Basic programs relocated on loading or are they loaded onl at their
> >    saved address?
> 
> If I change the load address in the file 
> (;0000  13 00 19 00 0a 00 8f 00 00 00   )
> it is still loaded at the same address, using both 'load"bar",8' and
> 'load"bar",8,1'

How about if you poke a new load address into 2D & 2E, bank 15 (start of
Basic), do a NEW and CLR, and then load the program?  This should load at
the new address.  The question is then;  will Basic see it?
Suggested new load address: 1025, the same as the PET.

> > 4. How much memory is available for Basic in the 128K and 256K version?
> >    If the bytes free is not given on power-up, then do the following:
> >       NEW:CLR:PRINT FRE(0)
> Hm, this does print "0". Does not help much, but:
>            128k      256k
> fre(0) -> 0          0
> fre(1) -> 64089      64089
> fre(2) -> 64187      64253
> fre(3) -> 0          31487
> fre(4) -> 0          64187
> fre(5) -> 0          0

This is very confusing!  In "The Complete Commodore Inner Space Anthology"
it says Basic programs are located at 2-61439, bank 1.  This would make
61437 free.  Arrays are at 2-65535, bank 2.  Variables are at 32768-65535,
bank 3.  Strings are at 2-64511, bank 4.  This is obviously for the 256K
machine, assuming bank 3 and 15 are actually the same, otherwise it would 
take 320K. Are all the arrays, variables, and strings in bank 3 on the
128K machine? 
 
Does FRE(x) give the amount of free memory in bank x?  This would be
different than other Commodore Basics, where the variable is ignored.
If this is so, does FRE(0) cause the "garbage collection" routine to run
only in the bank specified??


Note to Ruud

It has been several months since I looked at this.  I think Andre's
message contains the list of questions.  I will try to make a new list
when I have evaluated these answers.  

-
This message was sent through the cbm-hackers mailing list.
To unsubscribe: echo unsubscribe | mail cbm-hackers-request@dot.tml.hut.fi.

Archive generated by hypermail 2.1.1.