예제 #1
0
void ApuCA()
{
   // MOV1 membit,C
   MemBit();
   if (APUCheckCarry())
      S9xAPUSetByte(S9xAPUGetByte(IAPU.Address) | (1 << IAPU.Bit), IAPU.Address);
   else
      S9xAPUSetByte(S9xAPUGetByte(IAPU.Address) & ~(1 << IAPU.Bit), IAPU.Address);
   IAPU.PC += 3;
}
예제 #2
0
void Apu6A()
{
   // AND1 C, not membit
   MemBit();
   if (APUCheckCarry())
   {
      if ((S9xAPUGetByte(IAPU.Address) & (1 << IAPU.Bit)))
         APUClearCarry();
   }
   IAPU.PC += 3;
}
예제 #3
0
void Apu2A()
{
   // OR1 C,not membit
   MemBit();
   if (!APUCheckCarry())
   {
      if (!(S9xAPUGetByte(IAPU.Address) & (1 << IAPU.Bit)))
         APUSetCarry();
   }
   IAPU.PC += 3;
}
예제 #4
0
void ApuB0()
{
   // BCS
   Relative();
   if (APUCheckCarry())
   {
      IAPU.PC = IAPU.RAM + (uint16_t) Int16;
      APU.Cycles += IAPU.TwoCycles;
      APUShutdown();
   }
   else
      IAPU.PC += 2;
}
예제 #5
0
void Apu90()
{
   // BCC
   Relative();
   if (!APUCheckCarry())
   {
      IAPU.PC = IAPU.RAM + (uint16) Int16;
      CPU.APU_Cycles += IAPU.TwoCycles;
      APUShutdown();
   }
   else
      IAPU.PC += 2;
}
예제 #6
0
void Apu8A()
{
   // EOR1 C, membit
   MemBit();
   if (APUCheckCarry())
   {
      if (S9xAPUGetByte(IAPU.Address) & (1 << IAPU.Bit))
         APUClearCarry();
   }
   else
   {
      if (S9xAPUGetByte(IAPU.Address) & (1 << IAPU.Bit))
         APUSetCarry();
   }
   IAPU.PC += 3;
}