[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Applesoft Basic size limitations?



On May 27, 12:07 pm, Brian <bpic...@gmail.com> wrote:
> I seem to be doing something wrong.  I created a hello file with the
> following code:
>
> 1  REM BWAS 16384
> 10 B = 24576
> 20 HOME : TEXT : PRINT "ADDRESS TO LOAD NEXT BASIC PROGRAM IS:": PRINT
> B
> 30 POKE 103,(B + 1) -  INT ((B + 1) / 256) * 256
> 40 POKE 104, INT ((B + 1) / 256):
> 50 POKE B,0
> 60 PRINT chr$(4);"run file"
>
> I tried a few different memory location values for B (although 24576
> is what I should use for an hgr2 program thats about 14-15k correct?
> I replaced "file" with the name of my bas file.  Is there anything
> else I'm forgetting.  Never loaded a program from a different address
> location than its default.


A way simpler method of running an applesoft program above Hires

10  if peek(104)<>64 then poke 106,4: poke 16384,0: print chr$(4)"run
aplsoft.pgrm"
20  if peek(104)=64 then print chr$(4)"bload shape.tables,a$800":?chr
$(4)"bload fonts,a$c00"

change the 64 to 96 to move program above Hires page 2 and the 16384
becomes 24576.

Also when moving a program, the poke 16384,0 is necessary to ensure
that the first byte of the applesoft program IS A zero.

If shape tables, fonts or other hires screen data needs to be loaded,
then the $800 to $1FFF space is now available for that and does not go
to waste.

Rob