This commit is contained in:
dinkc64 2019-05-10 23:17:50 -04:00
parent a581e52f29
commit c273fe8325
2 changed files with 22 additions and 21 deletions

View File

@ -115,6 +115,26 @@ void M6809NewFrame()
nM6809CyclesTotal = 0;
}
INT32 M6809TotalCycles()
{
#if defined FBA_DEBUG
if (!DebugCPU_M6809Initted) bprintf(PRINT_ERROR, _T("M6809TotalCycles called without init\n"));
#endif
return nM6809CyclesTotal + m6809_get_segmentcycles();
}
INT32 M6809Idle(INT32 cycles)
{
#if defined FBA_DEBUG
if (!DebugCPU_M6809Initted) bprintf(PRINT_ERROR, _T("M6809Idle called without init\n"));
#endif
nM6809CyclesTotal += cycles;
return cycles;
}
UINT8 M6809CheatRead(UINT32 a)
{
return M6809ReadByte(a);

View File

@ -35,6 +35,8 @@ INT32 M6809GetActive();
void M6809SetIRQLine(INT32 vector, INT32 status);
INT32 M6809Run(INT32 cycles);
void M6809RunEnd();
INT32 M6809TotalCycles();
INT32 M6809Idle(INT32 cycles);
INT32 M6809MapMemory(UINT8* pMemory, UINT16 nStart, UINT16 nEnd, INT32 nType);
INT32 M6809UnmapMemory(UINT16 nStart, UINT16 nEnd, INT32 nType);
void M6809SetReadHandler(UINT8 (*pHandler)(UINT16));
@ -48,27 +50,6 @@ UINT16 M6809GetPrevPC();
UINT8 M6809ReadByte(UINT16 Address);
void M6809WriteByte(UINT16 Address, UINT8 Data);
inline static INT32 M6809TotalCycles()
{
#if defined FBA_DEBUG
if (!DebugCPU_M6809Initted) bprintf(PRINT_ERROR, _T("M6809TotalCycles called without init\n"));
#endif
return nM6809CyclesTotal + m6809_get_segmentcycles();
}
inline static INT32 M6809Idle(INT32 cycles)
{
#if defined FBA_DEBUG
if (!DebugCPU_M6809Initted) bprintf(PRINT_ERROR, _T("M6809Idle called without init\n"));
#endif
nM6809CyclesTotal += cycles;
return cycles;
}
void M6809WriteRom(UINT32 Address, UINT8 Data); // cheat core
UINT8 M6809CheatRead(UINT32 Address);