Ejemplo n.º 1
0
        public void UpdateProperties(Interop.InteropProcessorStatus newStatus)
        {
            Accumulator = newStatus.accumulator;
            IndexX = newStatus.index_x;
            IndexY = newStatus.index_y;
            StackPointer = newStatus.stack_pointer;
            ProgramCounter = newStatus.program_counter;
            Cycles = newStatus.cycles;

            model.FLAG_BREAKPOINT = newStatus.FLAG_BREAKPOINT == 0x01 ? true : false;
            model.FLAG_CARRY = newStatus.FLAG_CARRY == 0x01 ? true : false;
            model.FLAG_DECIMAL = newStatus.FLAG_DECIMAL == 0x01 ? true : false;
            model.FLAG_INTERRUPT = newStatus.FLAG_INTERRUPT == 0x01 ? true : false;
            model.FLAG_OVERFLOW = newStatus.FLAG_OVERFLOW == 0x01 ? true : false;
            model.FLAG_SIGN = newStatus.FLAG_SIGN == 0x01 ? true : false;
            model.FLAG_ZERO = newStatus.FLAG_ZERO == 0x01 ? true : false;
            OnPropertyChanged("Flags");
        }
Ejemplo n.º 2
0
        public void UpdateModelDirectly(Interop.InteropProcessorStatus newStatus)
        {
            model.accumulator = newStatus.accumulator;
            model.indexX = newStatus.index_x;
            model.indexY = newStatus.index_y;
            model.stackPointer = newStatus.stack_pointer;
            model.programCounter = newStatus.program_counter;
            model.lastOpcode = newStatus.lastOpcodeAsString;
            model.cycles = newStatus.cycles;

            model.FLAG_BREAKPOINT = newStatus.FLAG_BREAKPOINT == 0x01 ? true : false;
            model.FLAG_CARRY = newStatus.FLAG_CARRY == 0x01 ? true : false;
            model.FLAG_DECIMAL = newStatus.FLAG_DECIMAL == 0x01 ? true : false;
            model.FLAG_INTERRUPT = newStatus.FLAG_INTERRUPT == 0x01 ? true : false;
            model.FLAG_OVERFLOW = newStatus.FLAG_OVERFLOW == 0x01 ? true : false;
            model.FLAG_SIGN = newStatus.FLAG_SIGN == 0x01 ? true : false;
            model.FLAG_ZERO = newStatus.FLAG_ZERO == 0x01 ? true : false;
        }