mirror of
https://github.com/JorjBauer/aiie.git
synced 2024-07-07 15:29:11 +00:00
disable debugging; lock screen while updating to avoid tearing
This commit is contained in:
parent
c46f81ca58
commit
dd523aac98
@ -207,14 +207,15 @@ void biosInterrupt()
|
|||||||
Timer1.start();
|
Timer1.start();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool debugState = false;
|
//bool debugState = false;
|
||||||
bool debugLCDState = false;
|
//bool debugLCDState = false;
|
||||||
|
|
||||||
void runCPU()
|
void runCPU()
|
||||||
{
|
{
|
||||||
if (micros() >= nextInstructionMicros) {
|
if (micros() >= nextInstructionMicros) {
|
||||||
debugState = !debugState;
|
// Debugging: to watch when the CPU is triggered...
|
||||||
digitalWrite(56, debugState);
|
//debugState = !debugState;
|
||||||
|
// digitalWrite(56, debugState);
|
||||||
|
|
||||||
g_cpu->Run(24);
|
g_cpu->Run(24);
|
||||||
|
|
||||||
@ -244,16 +245,19 @@ void loop()
|
|||||||
|
|
||||||
g_keyboard->maintainKeyboard();
|
g_keyboard->maintainKeyboard();
|
||||||
|
|
||||||
debugLCDState = !debugLCDState;
|
//debugLCDState = !debugLCDState;
|
||||||
digitalWrite(57, debugLCDState);
|
//digitalWrite(57, debugLCDState);
|
||||||
|
|
||||||
doDebugging();
|
doDebugging();
|
||||||
|
|
||||||
|
// Only redraw if the CPU is caught up; and then we'll suspend the
|
||||||
|
// CPU to draw a full frame.
|
||||||
|
Timer1.stop();
|
||||||
g_vm->vmdisplay->needsRedraw();
|
g_vm->vmdisplay->needsRedraw();
|
||||||
AiieRect what = g_vm->vmdisplay->getDirtyRect();
|
AiieRect what = g_vm->vmdisplay->getDirtyRect();
|
||||||
g_vm->vmdisplay->didRedraw();
|
g_vm->vmdisplay->didRedraw();
|
||||||
g_display->blit(what);
|
g_display->blit(what);
|
||||||
|
Timer1.start();
|
||||||
|
|
||||||
static unsigned long nextBattCheck = 0;
|
static unsigned long nextBattCheck = 0;
|
||||||
static int batteryLevel = 0; // static for debugging code! When done
|
static int batteryLevel = 0; // static for debugging code! When done
|
||||||
|
Loading…
Reference in New Issue
Block a user