summaryrefslogtreecommitdiff
path: root/eater_cpu/cpp/simpc_term.cpp
diff options
context:
space:
mode:
authoruvok2026-01-22 19:37:00 +0100
committeruvok2026-01-22 19:37:00 +0100
commit48d11484cc6e0b26627af6259e238fe29421962c (patch)
treef3462f365ddcaba10fd5a9b69ac667b655590bf4 /eater_cpu/cpp/simpc_term.cpp
parent32dab1dcf0f70af7e987a4532724d6e055533764 (diff)
Implement STA
Diffstat (limited to 'eater_cpu/cpp/simpc_term.cpp')
-rw-r--r--eater_cpu/cpp/simpc_term.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/eater_cpu/cpp/simpc_term.cpp b/eater_cpu/cpp/simpc_term.cpp
index c08deed..2ac3895 100644
--- a/eater_cpu/cpp/simpc_term.cpp
+++ b/eater_cpu/cpp/simpc_term.cpp
@@ -1,4 +1,5 @@
#include "Veater_computer_eater_register.h"
+#include "Veater_computer_my_mem__DB10.h"
#include "simpc_ui.h"
#define NCUR_X 5
@@ -35,7 +36,7 @@ static void handle_key();
void simpc_ui_write(const std::unique_ptr<Veater_computer> &topp, uint64_t i) {
// clk hi->lo doesn't do anything, just skip this.
- if (i !=0 && !topp->clk_in)
+ if (i != 0 && !topp->clk_in)
return;
// uint16_t opcode = topp->eater_computer->;
uint8_t opcode = topp->eater_computer->INS->r_datastore;
@@ -109,6 +110,11 @@ void simpc_ui_finish_message(const std::unique_ptr<VerilatedContext> &contextp,
PRINT_ME_W(status_top, 1, xpos, "%s", msg);
attroff(A_BOLD);
+
+ for (int idx = 0; idx < topp->eater_computer->RAM->r_datastore.size();
+ idx++) {
+ printf("Mem[%2d] = 0X%02X\n", idx, topp->eater_computer->RAM->r_datastore[idx]);
+ }
}
void simpc_ui_init(void) {}