New in SOURCGEN V. 3.2
SOURCGEN V.3.2 requires an XL or XE ATARI.
The Fram-disk: not just for SOURCGEN users
If you've been using the SOURCGEN re-assembler without a ram-disk, you
know how much stress this program can put on a disk drive. If SOURCGEN
is creating a source code listing to a file and writing it to the same
disk, the read/write head of the disk drive must continually shift from
one file to another. Even if you have been using a ram-disk you will have
encountered the problem that SOURCGEN will only read from a file that
exists as a continuous block on the disk. You may sometimes have had to
first copy the file to an empty disk before you could work with it.
FRAMDISK contains the most important routines used by disk oriented programs: OPEN, CLOSE, GETBYTE, PUTBYTE, NOTE and POINT.
FRAMDISK resides in RAM at $540 to $573 and $600 to $6FF.
Under SOURCGEN the Fram-disk remains intact after pressing <RESET>. In all other cases, the Fram-disk can be reactivated after a reset by a jump through $600 (JSR $600). The content of the Fram-disk remains intact.
If you want to use the Fram-disk without SOURCGEN, you need only load the file FRAMDISK to initialise the Fram-disk !
When you load SOURCGEN V.3.2 you will see the new menu item U. UTILITY.
The U. UTILITY function serves two purposes:
After hitting <U> you can enter any command chain by using the following syntax:
The command chain will be executed by hitting <RETURN> and can be repeated any time by hitting <@> (<SHIFT-8>).
For example, entering /;FD:FRAMDISK^OD:FRAMDISK^P540^H540 6FE/F: will do the following:
The file "FRAMDISK" is opened.
The character "^" is interpreted by SOURCGEN as "<RETURN>".
Command chains can easily be entered into the symbol table and then saved
as an SMB file. You can use the addresses $100 to $1FF for this; since
the 6502 stack is located in this address area, it is unlikely that there
will be any normal symbol entries there.
To call an already existing command chain:
Hit <@> (<SHIFT-8>) any time to re-execute the command chain.
You might wish to save all your command chains to the AUTOLOAD.SMB file so that they will always be accessible immediately after loading SOURCGEN.
After hitting <U>, you can enter a command with the following syntax:
Type the name of a disk file and hit <RETURN>. The file will now be copied into the Fram-disk .
By entering a value for <SIZE>, you determine the number of double-density sectors in the ram-disk . (A double density sector comprises 253 ($FD) Bytes.)
Entering a value less than $39 or entering nothing at all will cause
the size of the ram-disk to be $38. This corresponds exactly to the free
memory under the operating system (from $C000) and suffices for a file
with 113 ($71) single density sectors. (A single density sectors has 125
If no file name is entered the last file opened using F. FILE will be loaded into the Fram-disk.
When a file is loaded, the start address of the Fram-disk is displayed. $BC00 to $C000 remain unused since this is usually the location of the Display List and the screen RAM.
If you simply want to set the size of the ram-disk without loading a
file, just enter <SIZE>
followed by the character "/".
A larger text buffer for ATMAS-II
When using ATMAS together with SOURCGEN it may be a good idea to configure ATMAS-II to have a larger text buffer. For this the following ATMAS addresses are important:
$38CD: copy register - begin ($60)
The numbers in brackets are the original values. Thus the text buffer
usually occupies the addresses $6400 to $A800.
If you use SOURCGEN to initialize the Fram-disk to $4A, you will see that the begin address of the Fram-disk is $AA00. Thus via the Fram-disk you can easily transfer a listing of length $4920 to ATMAS. Of course you must not try to assemble the listing as usual at $A800 but at $AA00, (and don't be surprised that the content of the Fram-disk initialized with $4A will then be lost!)
SOURCGEN now reads any type of file.
<NUM> <ADR1> [<ADR2>]/D<x>:<FILENAME>.<EXT>
Any disk file is opened. <ADR1>
is the start address. The value for <NUM>
is unimportant but a value must be entered.
This option can be used when a machine language program is not in the form of a load-file. Sometimes a larger file will be loaded into RAM by means of a small loader program. Only the loader program is in the form of a load file. In this case, you must find the address (<ADR1>) of the main program by first investigating the loader.
<NUM> <ADR1> [<ADR2>]
The file name need not re-entered when you repeat the function.
<ADR1> <ADR2> <WORD> /W
Searches from <ADR1> to <ADR2> for the double byte <WORD>. This function is much faster than the other two CODE-search functions because it does not take into account the way the code is displayed.
The H. HEAD function now works correctly when the address range of a load-file spans several segments. Let us assume for instance that the following segments are displayed when a LOAD-File is opened:
4DOO 4EOO 1
When you use H. HEAD you can now enter 600 573 as an address range.. It doesn't matter that the second address is lower than the first. (The same applies to the functions P. PREPARE labels, G. GO and J. JUNK?)
<ADR1> <ADR2> A/D<x>:<FILENAME>
The "A" after ADR2 causes the listing to be saved as an ATARI ST or PC-compatible ASCI-file.
From address <ADR1>
the code will be displayed according to <CHAR>.
:Normal code. E.g. LDA #LABEL
<SPACE> lists the next line.