예제 #1
0
파일: RTI.cs 프로젝트: dseller/NESCove
        public override int Execute(C6502 cpu, byte operand)
        {
            cpu.State.ProcessorStatus = cpu.Pop();
            byte b1 = cpu.Pop();
            byte b2 = cpu.Pop();

            cpu.State.ProgramCounter = (ushort)((b2 << 8) | b1);
            return(6);
        }
예제 #2
0
        public override int Execute(C6502 cpu, byte operand)
        {
            byte b1 = cpu.Pop();
            byte b2 = cpu.Pop();

            // low byte first, b1 is low byte
            ushort address = (ushort)((b2 << 8) | b1);

            cpu.State.ProgramCounter = (ushort)(address + 1);

            return(6);
        }
예제 #3
0
파일: PLA.cs 프로젝트: dseller/NESCove
 public override int Execute(C6502 cpu, byte operand)
 {
     cpu.State.RegA = cpu.Pop();
     SetNegative(cpu, () => Helper.IsSigned(cpu.State.RegA));
     SetZero(cpu, () => cpu.State.RegA == 0);
     return(4);
 }
예제 #4
0
 public override int Execute(C6502 cpu, byte operand)
 {
     cpu.State.ProcessorStatus = cpu.Pop();
     return(4);
 }