k for interrupts and do other hardware emulation here */
    ...
    Counter+=InterruptPeriod;
    if(ExitRequired) break;
  }
}
</PRE>
</FONT>
First, we assign initial values to the CPU cycle counter 
(<CODE>Counter</CODE>), and the program counter (<CODE>PC</CODE>):
<FONT COLOR=#000080>
<PRE>
Counter=InterruptPeriod;
PC=InitialPC;
</PRE>
</FONT>
The <CODE>Counter</CODE> contains the number of CPU cycles left to the
next suspected interrupt. Note that interrupt should not necessarily
occur when this counte