Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!gatech!rayssd!unisec!mark From: mark@unisec.usi.com (Mark Rinfret) Newsgroups: comp.sys.cbm Subject: C64 C-Power (tm) Compatible Assembler Message-ID: <495@unisec.usi.com> Date: Fri, 8-May-87 16:40:26 EDT Article-I.D.: unisec.495 Posted: Fri May 8 16:40:26 1987 Date-Received: Sat, 9-May-87 21:13:24 EDT Organization: UniSecure Systems, Inc. Newport, RI Lines: 1069 Keywords: C64 assembler C-Power The following shell archive contains a C-Power (tm) compatible assembler and an unformatted document (run it through the format program). The assembler was adapted to C-Power by myself and later refined and enhanced by Ray Zarling. I will be posting the source and other goodies over the coming weeks as time permits. Please note that the file assmdoc.fo must be converted to the Commodore character set prior to use. Also, the program file (assm.sh) is to be run on a Commodore 64 under the C-Power shell. Let me know if there are any problems encountered with this archive. Mark Rinfret #---------------------------cut here----------------------------------- #! /bin/sh # This is a shell archive, meaning: # 1. Remove everything above the #! /bin/sh line. # 2. Save the resulting text in a file. # 3. Execute the file with /bin/sh (not csh) to create the files: # assmdoc.fo # assm.uue # This archive created: Fri May 8 16:31:21 1987 export PATH; PATH=/bin:$PATH if test -f 'assmdoc.fo' then echo shar: will not over-write existing file "'assmdoc.fo'" else cat << \SHAR_EOF > 'assmdoc.fo' .in 10 .rm 75 .he /C-ASSM/6502 Assembler for C-Power/V 2.0/ .fo //-#-// Disclaimer: .sp 1 .ti +5 This program is hereby given into the hands of the public, and is considered to be public domain. You may use it for any non-profit purpose. Feel free to alter it as you see fit. If you modify and redistribute this program, please give credit to the prior authors (original: J.H. Van Ornum, George V. Wilder; C-Power version: Mark R. Rinfret, revision 2.0: R. L. Zarling) as well as taking the blame/glory for any changes that you should make. Please report any enhancements to: .nf .sp 1 .in +5 Mark R. Rinfret and Raymond L. Zarling 348 Indian Ave. 245 Wiley Ct. Portsmouth, RI 02871 Turlock, CA 95380 (401)-846-7639 (209)-634-4106 .in -5 .fi .sp No warranties are made with regard to the use of this program, nor is any support pledged (but you might ask). Use it/abuse it at your own risk. .sp 2 Introduction .sp 1 .ti +5 C-ASSM is a 6502 assembler specifically targeted to the Commodore 64 computer running Pro-Line's C-power (tm) C language development system. C-ASSM is derived from a generic 6502 assembler which was contributed to USENET by J. H. van Ornum of AT&T Bell Laboratories. Without that head start, this program would still be in the design stages. .sp 2 .ti +5 Anyone familiar with the original source will, however, observe that major changes were made to tailor the source to fit the constraints of the C-Power compiler, such as changing ints to unsigned's where possible. The opcode tables were split apart into two separate pieces. Also, an #INCLUDE facility has been added as a convenience. Other minor enhancements like additional expression handling capabilities and conditional assembly will also be apparent. This assembler will generate C-Power compatible object files which can be linked to C language programs, if the proper parameter passing conventions are observed, or the objects can be linked into a stand-alone assembly language program, while using the excellent environment of the C-Power shell , editor and linker. .ti +5 Although it is tailored for the C-Power environment, the code is highly standard, portable C. This is demonstrated by the minimal number of changes that need to be made to port the code to Unix (#ifdef UNIX). .ti +5 This document is about as terse as they come. If you're looking for a tutorial on assembly language, it ain't here. The accompanying test programs should be sufficient to illustrate the various syntax elements for a moderately experienced programmer. .bp SOURCE LINE FORMAT .sp 1