!lm12
!rm75
S-C Macro Assembler........................Bob Sander-Cederlof

The printer has delivered the manuals (five days early!), the bugs are exterminated, the UPS driver went back to the depot and got a bigger truck, and we are now shipping S-C Macro Assembler.

Here is a brief summary of the new features the S-C Macro Assembler has that S-C Assembler II Version 4.0 did not.  The highlights are of course macros, conditional assembly and the new commands EDIT, COPY and REPLACE.  But they are not all!


Commands

There are 10 new commands:

!lm17
EDIT         Select a line, a range of lines, or a range
             of lines that contain a particular string.
             Edit the lines using some of the 15
             convenient sub-commands.

TEXT         Write source program to disk, as a TEXT
             file, with or without line numbers.

REPLACE      Global search and replace. Your search
             string can include wildcards; you can limit
             the search to a line, a range of lines,
             or search the entire program.  The search
             can be made sensitive or insensitive to
             upper/lower case distinctions.  And you can
             select Auto or Verify mode for replacement.

COPY         Copy one or more lines from one place to
             another in the source code.  Rearrange your
             code as you please!

AUTO         Generate automatic line numbers after
             every carriage return.  Allows ordinary
             TEXT files to be EXECed into S-C Macro
             Assembler!  You still can use the Version
             4.0 form of automatic line numbers.
             Now you have a choice!

MANUAL       Turn off automatic line numbering.

SYMBOLS      Print out the symbol table, in case you
             missed it the first time.

MNTR         Enter the system monitor (just like CALL
             -151 in BASIC).  Of course all the
             Monitor commands can be executed within
             S-C Macro Assembler, but if you really
             WANT to leave....

RST          Change the Autostart Monitor RESET vector
             to the specified address.

"            Send setup control strings to your printer.
!np
!lm12
There are also improvements in some of the older commands.

The spelling of commands is now checked.  In older versions, only the first three characters were tested.  The first three are still all that are necessary, but any additional letters you type must be correct.  For example, LIS will list your program, and so will LIST.  But, LISX will give a syntax error.

LIST and FIND now have the same syntax (in fact, they are processed by the same routine.)  They may now specify either a line range, a search string, or both.  The search string now requires a delimiter.

Line ranges in the LIST, FIND, COPY, EDIT, and DELETE commands may be written with a leading or trailing comma (as in Applesoft):

     LIST ,2500      List from beginning through 2500.
     LIST 2500,      List from 2500 through end.

The NEW command now restarts the automatic line numbering at 1000, rather than continuing from the last line number you entered.

The SLOW and FAST commands no longer use the Monitor output hooks at $36 and $37.

To leave the Macro Assembler, type FP or INT.   You no longer have to also type PR#0.

After using the PR#slot command to run your printer, use PR#0 to turn it off.  FAST won't do it anymore.


Directives

There are 7 new directives:

!lm17
.MA and .EM    For macro definition.

.DO expr       Start conditional block.
.ELSE          Toggle condition flag.
.FIN           End conditional block.

.TI num,title  Title and number each page of the
               assembly listing.

.AT string     Like .AS, but the last character has the
               high-bit set opposite from the rest.
!lm12

The .DA directive may now have a list of expressions.

The .EQ directive may now be used with local labels.

The .LIST directive has new options to control listing of macro expansions.
!np
Source Entry

Control-O (Override) will allow any control character to be typed into a source line in the normal input mode or in edit mode.  The control character will appear in inverse video.

The editor no longer double spaces after each line is entered.

The escape-L comment line produces one less dash, so that the line lists on the screen without a blank line after it.

Operand expressions can now include * and / as operators, as well as + and -.  The relational operators (<, =, and >) may also be used.

The tab routine has been changed to include up to five tab stops.  The stop values are kept in a user-modifiable list starting at $1010.  These are the actual column numbers (not 3 less, as in version 4.0).  You may use any values up to column 248.

The tab character (control-I, $89) is kept at $100F now, so you can change it if you like some other character better.

Any sequence of the same character repeated 4 or more times in the source code is replaced by a token $C0, the character code, and the repeat count.  (multiple blanks are still replaced by a single byte between $80 and $BF.)  This reduces both the memory requirements and disk file size for your source programs.

If you want to shrink your source file a little, and if you have been using the Escape-L to generate comment lines that have all those dashes in them, type "EDIT" and hold down the RETURN and REPEAT keys until the entire program has been scanned.  Type MEM before you do it, and after it is finished; you will probably notice a significant saving!

A parameter at location $1017 allows the extra compression to be turned on or off.  If the contents of $1017 is $04, compression is on.  If it is $FF, compression is off.  You can experiment with this parameter to see what effect it has on program size.


Reference Manual

The S-C Macro Assembler comes with an all-new, 100-page manual.  (At last!  All the information in one place!)  The manual includes chapters on source program format, commands, directives, operand expressions, macros, 6502 programming, SWEET-16, and a tutorial on using the Macro Assembler.
!np
Assembly

Older versions of the assembler terminated assembly after finding one error.  The S-C Macro Assembler keeps going, but rings the bell and prints an error message, so you know about it.  If any errors are found during pass one, assembly terminates before doing pass two.  At the end of assembly, the number of errors found is printed.

Typing the RETURN key during assembly will abort the assembly (even if the listing has been turned off with .LIST OFF directive).

Believe it or not, the new version assembles slightly faster than version 4.0!  I measured about a 10% improvement on a large program.

All previous versions had difficulty handling forward references to variables which turned out to be in page zero.  (Described on page 22 of the old blue manual.)  That problem has been solved, so with S-C Macro Assembler it does not matter where you put your page-zero definitions.


Memory Usage

All page zero variables used by the assembler have been concentrated, so $00 through $1F are completely free for the user.

The standard version of the S-C Macro Assembler now occupies $1000 through $31FF.  The symbol table starts at $3200 and grows upward; the source code still starts at $9600 and grows downward.

Included on the disk with the Macro Assembler is a Language Card version and a short EXEC file to load the card.  This version fills the 16K RAM card from $D000 through about $F300.   The symbol table begins at $1000 rather than $3200.  The EXEC file configures things so that the language card contents appear to DOS as the opposite language to the one on the mother board.  For example, if Applesoft is on the mother board, you type INT to get into the S-C Macro Assembler.

There are no variables within the body of the assembler.  The Language Card version could be burned into ROM and placed on a firmware card, if you so desire.


Ordering

You can order the S-C Macro Assembler by phone or mail.  We accept cash, checks, money orders, Visa, Mastercard, or COD.  The price of the Macro Assembler is $80.00.  Registered owners of S-C Assembler II Version 4.0 may upgrade to the S-C Macro Assembler for only $27.50.
