as504 - an alternative assembler for the Siemens SAB-C504

View this page in Dutch.
Jump to the download section.

Features

Usage

You can assemble a file called test.asm using
as504 test.asm
In windows you can just drop the .asm-file on the as504 executable to assemle it. Error messages, if any, will be shown in the DOS-box that pops up. In order to prevent it from closing immediately, you will have to press enter to close it (this can be disabled by recompiling as504 and removing "-D WIN32" from the Makefile).
The options -l and -d may be added as commandline arguments and do, respectively, generate a listfile (like the one from ASM504) and print extra debug information.

as31

as504 is an extension of as31, an 8031/8051 assembler by Ken Stauffer. Apart from a few bugfixes, we added some extra compiler directives and aliases for them as to make it more compatible with ASM504. Retrospectively, I found a second version of as31 which also incorporated a few bugfixes, see also the download section below.

Problems in ASM504

I started writing as504 because there was no assembler running on Linux for the SAB-C504. Apparently it is a 8051 variant, such that the open source as31 assembler can be used, although it is not source-compatible with ASM504. Furthermore, we found a few problems with ASM504 while testing (mostly in the handling of assembly-errors), being: These problems were all discovered accidentally and do not rule out the possibility of more problems in ASM504 that can lead to some nasty debugging.

Differences between as504 and ASM504

Advantages: Most important implementation differences:

Download

See the ChangeLog (mostly Dutch) for a list of changes per version-date.

Compiling

Using a standard UNIX system with a C compiler, make and yacc, you should be able to compile as504 as follows (provided that the as504 archive is in the current working directory):
tar -xvjf as504*.tar.bz2
cd as504*/
make
make man

Now as504 is the assembler and as504.cat is the manpage. Compiletime options can be changed in the Makefile:
-D OS_linux, replace with -D WIN32 to build for windows.
-D WINDOWS_QUOTING, remove this to return to the standard C syntax for using single characters.

License

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. See http://www.gnu.org/copyleft/gpl.html

Bugs/Contact

Known bug: included files should always end with a newline (will be fixed if the assembler is being used, so report that please).

Please send any other bugs you may find to me: freek -at- vanwal -dot- nl.