summaryrefslogtreecommitdiff
path: root/Emulator/Chip/DebugDevice.cs
diff options
context:
space:
mode:
authorMelodi <62381002+Melodi17@users.noreply.github.com>2025-08-06 22:36:34 +1000
committerMelodi <62381002+Melodi17@users.noreply.github.com>2025-08-06 22:36:34 +1000
commit7a8d2bcd75d88a5429937bf551878c55e1dcf0fd (patch)
tree81bc1f259fb8678513aa8b214df4ef72720bb585 /Emulator/Chip/DebugDevice.cs
parent16f3cb74564cf7c19da6e13666c98aca36094716 (diff)
moved everything to seperate projects, and started compiler work + push and pop instructions added
Diffstat (limited to 'Emulator/Chip/DebugDevice.cs')
-rw-r--r--Emulator/Chip/DebugDevice.cs13
1 files changed, 13 insertions, 0 deletions
diff --git a/Emulator/Chip/DebugDevice.cs b/Emulator/Chip/DebugDevice.cs
new file mode 100644
index 0000000..4e869bb
--- /dev/null
+++ b/Emulator/Chip/DebugDevice.cs
@@ -0,0 +1,13 @@
+namespace Q1.Emulator.Chip;
+
+using System;
+
+public class DebugDevice(u16 addressPoint)
+ : BusDevice(addressPoint, (u16) (addressPoint + 2))
+{
+ public override u8 Read(u16 address) => throw new Exception("DebugDevice.Read not permitted");
+ public override void Write(u16 address, u8 value)
+ {
+ Console.WriteLine($"DebugDevice.Write: x{value:X4} b{value:b8}");
+ }
+} \ No newline at end of file