[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to make an Applesoft Basic program Brun-able
On Thursday, July 19, 2012 5:30:50 PM UTC-7, (unknown) wrote:
> I've searched to no avail, and am wondering if anyone can tell me a nifty way or provide the code to append to an Applesoft file to make it a self-executable BINary file. I remember reading that there is a way, but after 20+ years have forgotten that magical code. The reason is that I want to make self-contained Basic files which will execute from Beautiful Boot, and other similar binary-loading programs. I know location $801 has be modified, and probably location 64 also, but how to sandwitch the machine language code together with the tokenized Applesoft code?
>
> I'm NOT talking about an Applesoft compiler!
find start address (http://rich12345.tripod.com/prog/relocatebasic.html) this would be peek(103) and (104)
9000 lo=peek(103):hi=peek(104)
9005 addr = (hi*256)+lo
9010 length = (you need to find out where this is)
10000 print chr$(4);"bsave file,a";addr;",l";length:rem bsave the applesoft program
10010 print chr$(4);"bload file.start,a$2000":rem load the start program which sets up applesoft start, length
10020 print chr$(4);"bload file,a";8192+FS":rem load the bsaved applesoft program after file.start in RAM
10030 print chr$(4);"bsave file.brnable,a$2000,l";length +fs:rem bsave the applesoft program with the