From 7a8d2bcd75d88a5429937bf551878c55e1dcf0fd Mon Sep 17 00:00:00 2001 From: Melodi <62381002+Melodi17@users.noreply.github.com> Date: Wed, 6 Aug 2025 22:36:34 +1000 Subject: moved everything to seperate projects, and started compiler work + push and pop instructions added --- Chip/RamDevice.cs | 36 ------------------------------------ 1 file changed, 36 deletions(-) delete mode 100644 Chip/RamDevice.cs (limited to 'Chip/RamDevice.cs') diff --git a/Chip/RamDevice.cs b/Chip/RamDevice.cs deleted file mode 100644 index 509a2df..0000000 --- a/Chip/RamDevice.cs +++ /dev/null @@ -1,36 +0,0 @@ -namespace Q1Emu.Chip; - -using System; -using System.Runtime.CompilerServices; - -public class RamDevice : BusDevice -{ - public u8[] Memory; - - public RamDevice(u16 start, u16 size) : base(start, (u16) (start + size)) - { - this.Memory = new u8[size]; - } - - public override void Reset() - { - this.Memory = new u8[this.AddressableEnd - this.AddressableStart]; - } - - public override void Clock() - { - // No clocking needed for RAM - } - - public override u8 Read(u16 address) - { - u16 relativeAddress = this.GetRelativeAddress(address); - return this.Memory[relativeAddress]; - } - - public override void Write(u16 address, u8 value) - { - u16 relativeAddress = this.GetRelativeAddress(address); - this.Memory[relativeAddress] = value; - } -} \ No newline at end of file -- cgit v1.3.1