6800_AS(6ACK)

NAME
6800_as - assembler for Motorola 6800

SYNOPSIS
~em/lib/6800/as [options] argument ...

DESCRIPTION
This assembler is made with the general framework described in uni_ass(6). It is an assembler generating relocatable object code in Ack.out(5) format.

SYNTAX

registers
    The 6800 has two accumulator registers, A and B. An instruction that refers to accumulator A, has an "a" as last character. In the same way a "b" means that the instruction uses B as accumulator.

addressing modes
    syntax		meaning (name)
    #expr		with cpx, ldx, lds a 2-byte value,
    		otherwise a 1-byte value (immediate)
    <expr		1-byte address.  Not allowed with:
    		asl, asr, clr, com, dec, inc, lsl, lsr,
    		neg, rol, ror, tst (base page direct)
    expr		2-byte address (extended direct)
    expr, x		1-byte expr + contents of x
    		yields address (indexed)

SEE ALSO
uni_ass(6), ack(1), ack.out(5)
A. Osborne, 6800 programming for logic design, Adam Osborne and Associates Inc., 1977

EXAMPLE
An example of Motorola 6800 assembly code.

	.sect .text; .sect .data
	val:	0
	.sect .text
		ldx	<val
		com	val, x
		bhs	someplace	! branch on carry clear
		sta	<val
		adda	#18		! add 18 to accumulator A