summaryrefslogtreecommitdiff
path: root/lib/debug.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/debug.h')
-rw-r--r--lib/debug.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/debug.h b/lib/debug.h
index af74a502..cbe49fda 100644
--- a/lib/debug.h
+++ b/lib/debug.h
@@ -6,6 +6,7 @@
#define COMMUNICATION_QWORD 0xc0
#define STATE_EU_MSG 0x01f00d10
+#define STATE_CPU_ACK 0x02f00d20
#define STATE_OFFSET 0xc20
#define STATE_QWORD 0xc2
@@ -15,11 +16,17 @@
#define RX_QWORD 0xc6
#ifndef GEN_ASM
-typedef uint8_t grf[32];
-typedef uint8_t mrf[32];
+typedef uint32_t grf[8];
+typedef uint32_t mrf[8];
typedef uint8_t cr[12];
typedef uint32_t sr;
+#define DWORD8(x) {x, x, x, x, x, x, x, x}
+
+const static grf protocol_version = DWORD8(DEBUG_PROTOCOL_VERSION);
+const static grf eu_msg = DWORD8(STATE_EU_MSG);
+const static grf cpu_ack = DWORD8(STATE_CPU_ACK);
+
struct eu_state {
mrf m_regs[15];
grf g_regs[16];