public void SetCellByAddress(string address, IMemoryCell cellContent)
        {
            // Nonsignificant zeroes deleting
            address = Convert.ToInt32(address).ToString();

            TestForAddressCorrectness(address);

            mMemoryCellList[address] = cellContent;
        }
예제 #2
0
        public void AssertMemoryCellProperties()
        {
            _memoryCell = new MemoryCell(0x0012, 0xF5);

            Assert.Equal(0x012, _memoryCell.Address);
            Assert.Equal(0xF5, _memoryCell.Value);
            Assert.Equal("0xF5", _memoryCell.HexValue);
            Assert.Equal("0x0012", _memoryCell.HexAddress);
        }
예제 #3
0
        public IMemoryCell[] GetMemoryCells(int startIndex, int endIndex)
        {
            var cells = new IMemoryCell[endIndex - startIndex + 1];

            for (int i = startIndex; i <= endIndex; i++)
            {
                cells[i - startIndex] = new MemoryCell(i, Memory.ReadByte((ushort)i));
            }

            return(cells);
        }
예제 #4
0
 public void SetCellByAddress(string address, IMemoryCell cell)
 {
     mLM2Memory.SetCellByAddress(address, cell);
 }
예제 #5
0
 public void SetCellByAddress(string address, IMemoryCell cell)
 {
     throw new NotImplementedException();
 }