From 24c328db90627881d7c293e1ba481c6bd96e31da Mon Sep 17 00:00:00 2001 From: ryo Date: Mon, 30 Dec 2024 16:11:32 +0000 Subject: Initial commit --- README | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 README (limited to 'README') diff --git a/README b/README new file mode 100644 index 0000000..5554aef --- /dev/null +++ b/README @@ -0,0 +1,37 @@ +morris mano assembler +===================== + +it reads the input file and output the hex equivalent +of the instructions. list of pseudoinstructions: +- ORG - DEC - HEX - END +instead of make decision based on counting words, i +made a general structure called token. + +LOOP, STA SUM2 I / AC TO SUM2 +----- --- ---- - ------------ + 0 1 2 3 4 + +0: label: ends with ',' -> lab[10] +1: symbol: check out the opcode.txt -> sym[3] +2: operand: cant start with digit -> opr[10] +3: indirect-address: opcode plus 8 -> ind +4: comment: starts with '/' !> not a part +!) just read the line till that. + +or maybe we have something like this: + + HEX B2D7 + --- ---- + 0 1 + +0: pseudo-ops: put the !code -> psu +1: number: string for now -> opr[10] +!code) + ORG -> 1 + DEC -> 2 + HEX -> 3 + END -> 4 + +i used stb_ds.h for hash table, please check out +the website nothings.org for more amazing projects. + -- cgit v1.2.3