This Java-based simulator is a low-level cycle-accurate pipelined MIPS datapath simulator that simulates the datapath including all of its storage components (register file, memories, and pipeline registers) and all of its control signals.
Fix memory to be 2048 in size total.
Now data are stored from addresses 1024 to 2047 inclusive you need to always offset and give an error if memory is out of bound.For instance if you want to read/write from address 8 it should be read/write in address 1024+8 (1032). Also don't forget to handle the case that the address is given already >1024 in the case a Memory out of bound message should be displayed telling user an error has occurred. For instance a user trying to read from 1025 should get an error since offsetting 1025 with 1024 is out of the range.