BizHawk/BizHawk.Emulation.Cores/Consoles/Nintendo/GBA/MGBAHawk.IDebuggable.cs

75 lines
1.4 KiB
C#
Raw Normal View History

2017-04-25 16:42:03 +00:00
using System;
using System.Collections.Generic;
using BizHawk.Emulation.Common;
namespace BizHawk.Emulation.Cores.Nintendo.GBA
{
public partial class MGBAHawk : IDebuggable
{
2017-04-25 17:00:50 +00:00
public IDictionary<string, RegisterValue> GetCpuFlagsAndRegisters()
2017-04-25 16:42:03 +00:00
{
2017-04-25 17:00:50 +00:00
var values = new int[RegisterNames.Length];
LibmGBA.BizGetRegisters(_core, values);
var ret = new Dictionary<string, RegisterValue>();
for (var i = 0; i < RegisterNames.Length; i++)
2017-04-25 16:42:03 +00:00
{
2017-04-25 17:00:50 +00:00
ret[RegisterNames[i]] = new RegisterValue(values[i]);
2017-04-25 16:42:03 +00:00
}
2017-04-25 17:00:50 +00:00
return ret;
}
[FeatureNotImplemented]
public void SetCpuRegister(string register, int value)
{
throw new NotImplementedException();
2017-04-25 16:42:03 +00:00
}
2017-04-25 17:00:50 +00:00
[FeatureNotImplemented]
public IMemoryCallbackSystem MemoryCallbacks
{
get { throw new NotImplementedException(); }
}
public bool CanStep(StepType type)
{
return false;
}
[FeatureNotImplemented]
public void Step(StepType type)
{
throw new NotImplementedException();
}
[FeatureNotImplemented]
2017-04-25 16:42:03 +00:00
public int TotalExecutedCycles
{
2017-04-25 17:00:50 +00:00
get { throw new NotImplementedException(); }
2017-04-25 16:42:03 +00:00
}
private static readonly string[] RegisterNames =
{
"R0",
"R1",
"R2",
"R3",
"R4",
"R5",
"R6",
"R7",
"R8",
"R9",
"R10",
"R11",
"R12",
"R13",
"R14",
"R15",
"CPSR",
"SPSR"
};
}
}