From f9af0db23791ba1c5b451408aa5b9c635b1d356e Mon Sep 17 00:00:00 2001 From: d0p1 Date: Fri, 23 Feb 2024 01:35:53 +0100 Subject: [PATCH] typo --- disas/main.c | 2 +- doc/isa.org | 18 +++++------------- 2 files changed, 6 insertions(+), 14 deletions(-) diff --git a/disas/main.c b/disas/main.c index ebac269..4b41cf7 100644 --- a/disas/main.c +++ b/disas/main.c @@ -118,7 +118,7 @@ decode_imm(uint8_t opcode) fprintf(output, "W #$%hX\n", readu16()); break; case 0x2: - fprintf(output, "D #$%X\n", readu32()); + fprintf(output, "L #$%X\n", readu32()); break; default: break; diff --git a/doc/isa.org b/doc/isa.org index be27e21..8e6521f 100644 --- a/doc/isa.org +++ b/doc/isa.org @@ -34,6 +34,8 @@ Status register flags *** Implied Addressing +*** Remative Addressing + *** Immediate Addressing A size and a literal operand is given immediately after the instruction. @@ -41,7 +43,9 @@ A size and a literal operand is given immediately after the instruction. #+begin_src asm LDA.B #7 LDA.W #300 - LDA.D #$DEADBEEF + LDA.L #$DEADBEEF + LDA.SB #-5 ! sign extended + LDA.SW #-5367 ! sign extended #+end_src *** Absolute Addressing @@ -85,15 +89,3 @@ A size and a literal operand is given immediately after the instruction. |--------|------|-------| | opcode | attr | value | -* Instruction Set - -| OP | ATTR | IMM | Size | Note | -|----|------|----------|------|-------------------------------------| -| 00 | | | 1 | Break | -| 01 | | XXXX | 3 | Or with accumulator | -| 08 | | | 1 | Push processor status | -| 09 | 01 | XX | 3 | Or with accumulator | -| 09 | 02 | XXXX | 4 | Or with accumulator | -| 09 | 03 | XXXXXXXX | 6 | Or with accumulator | -| 0A | | | 1 | Shift Left One Bit with accumulator | -| 10 | | XXXX | 3 | Branch on plus |