Paolo Amoroso's Journal

Suite8080

I extended the Suite8080 assembler to allow the ds directive to take a label as an operand. The label, which must be defined before use, may be in uppercase. I also broke into subsections the section of the documentation about the assembler limitations, as well as mentioning the limitations of org and ds.

This hopefully concludes the work to make the assembler accept uppercase identifiers such as instruction mnemonics, labels, and constants.

Suite8080 is a suite of Intel 8080 Assembly cross-development tools I'm writing in Python.

#Suite8080 #Python

Discuss... Email | Reply @amoroso@fosstodon.org

Once I fixed the Suite8080 assembler to let db accept uppercase symbols, I was ready to work on a similar fix for dw.

But I got dw uppercase support for free as a side effect of canonicalizing symbols to lowercase when adding 16-bit words to the symbol table, as dw already converted symbols to lowercase before checking for inclusion in the table. This unlocked uppercase symbol support, again for free, for most other 8080 instructions that take an address operand such as lhld, shld, lda, sta, jmp, and more.

#Suite8080 #Python

Discuss... Email | Reply @amoroso@fosstodon.org

I resumed working on Suite8080 and fixed the assembler's db directive to accept uppercase symbols as in this example:

SYM		equ	1
label:  	db	SYM

I changed the code that adds symbols to the symbol table to canonicalize to lowercase, and the db processing code to convert symbols to lowercase before checking if they're in the table.

Suite8080 is a suite of Intel 8080 Assembly cross-development tools I'm writing in Python.

#Suite8080 #Python

Discuss... Email | Reply @amoroso@fosstodon.org