aboutsummaryrefslogtreecommitdiffstats
path: root/src/ucode.py
diff options
context:
space:
mode:
authorJan Tuomi <jans.tuomi@gmail.com>2023-04-11 14:05:41 +0300
committerJan Tuomi <jans.tuomi@gmail.com>2023-04-11 14:05:41 +0300
commitda14e7ca7f31cb4b9a975dbe349fb4d385592b9c (patch)
treeea60a83ccb64af33a48f13839e6145b7c97236d2 /src/ucode.py
parent9a6001ad380e83a545188b58145387593b117b48 (diff)
Fix bugs
Diffstat (limited to 'src/ucode.py')
-rwxr-xr-xsrc/ucode.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ucode.py b/src/ucode.py
index 9745a7e..1d050c8 100755
--- a/src/ucode.py
+++ b/src/ucode.py
@@ -20,9 +20,9 @@ MEM_IE = 0b0000_0000_0001_0000
MEM_OE = 0b0000_0000_0010_0000
RW_IE = 0b0000_0000_0100_0000
R1_OE = 0b0000_0000_1000_0000
-IM_M = 0b0000_0001_0000_0000
+R2_OE = 0b0000_0001_0000_0000
IR_IE = 0b0000_0010_0000_0000
-unused = 0b0000_0100_0000_0000
+IM_M = 0b0000_0100_0000_0000
LI_OE = 0b0000_1000_0000_0000
ALU_OE = 0b0001_0000_0000_0000
FR_IE = 0b0010_0000_0000_0000
@@ -51,8 +51,8 @@ ucode = [
not_branch([*fetch, IM_M|ALU_OE|FR_IE|RW_IE, US_RS, 0, 0, 0, 0]),
# LDR 0010 TTTR RRXX XXXX
not_branch([*fetch, R1_OE|MAR_IE, MEM_OE|RW_IE, US_RS, 0, 0, 0]),
- # STR 0011 TTTR RRXX XXXX
- not_branch([*fetch, R1_OE|MAR_IE, R1_OE|MEM_IE, US_RS, 0, 0, 0]),
+ # STR 0011 XXXL LLRR RXXX
+ not_branch([*fetch, R1_OE|MAR_IE, R2_OE|MEM_IE, US_RS, 0, 0, 0]),
# LDI 0100 TTTI IIII IIII
not_branch([*fetch, LI_OE|RW_IE, US_RS, 0, 0, 0, 0]),
# JPR 0101 XXXR RRXX XXXX