Exemple #1
0
        public virtual bool Execute(Clock clock, out ClockEntry next)
        {
            _op.Execute(clock, 0);
            next = _next;

            return(_comboNext);
        }
Exemple #2
0
        public void Prolong(byte cycles, byte phase)
        {
            if (cycles > 0)
            {
                ClockEntry stall = cycles > 1 ? new ClockEntryRep(new StallOp(), cycles) : new ClockEntry(new StallOp());

                stall.Next = _currentOps[phase].Next;
                _currentOps[phase].Next = stall;
            }
        }
Exemple #3
0
        protected void WritePhaseToDeviceState(C64Interfaces.IFile stateFile, byte phase)
        {
            byte opCount = 0;

            for (ClockEntry op = _currentOps[phase]; op != null; op = op.Next)
            {
                opCount++;
            }

            stateFile.Write(opCount);

            for (ClockEntry op = _currentOps[phase]; op != null; op = op.Next)
            {
                op.WriteToStateFile(stateFile);
            }
        }
Exemple #4
0
        public override bool Execute(Clock clock, out ClockEntry next)
        {
            _op.Execute(clock, _cycle);

            _cycle = (byte)((_cycle + 1) % _length);
            if (_cycle == 0)
            {
                next = _next;
                return(_comboNext);
            }
            else
            {
                next = this;
                return(false);
            }
        }
Exemple #5
0
        protected void ReadPhaseFromDeviceState(C64Interfaces.IFile stateFile, byte phase)
        {
            ClockEntry previousOp = null;
            byte       opCount    = stateFile.ReadByte();

            for (byte i = 0; i < opCount; i++)
            {
                ClockEntry op = stateFile.ReadByte() == 0 ? new ClockEntry(stateFile, _opFactory) : new ClockEntryRep(stateFile, _opFactory);

                if (previousOp == null)
                {
                    _currentOps[phase] = op;
                }
                else
                {
                    previousOp.Next = op;
                }

                previousOp = op;
            }
        }
Exemple #6
0
        public override bool Execute(Clock clock, out ClockEntry next)
        {
            _op.Execute(clock, _cycle);

            _cycle = (byte)((_cycle + 1) % _length);
            if (_cycle == 0)
            {
                next = _next;
                return _comboNext;
            }
            else
            {
                next = this;
                return false;
            }
        }
Exemple #7
0
        public virtual bool Execute(Clock clock, out ClockEntry next)
        {
            _op.Execute(clock, 0);
            next = _next;

            return _comboNext;
        }
Exemple #8
0
 public void QueueOpsStart(ClockEntry first, byte phase)
 {
     _currentOps[phase] = first;
 }
Exemple #9
0
 public void QueueOps(ClockEntry ops, byte phase)
 {
     _currentOps[phase].Next = ops;
 }
Exemple #10
0
 public void QueueOps(ClockEntry ops, byte phase)
 {
     _currentOps[phase].Next = ops;
 }
Exemple #11
0
 public void QueueOpsStart(ClockEntry first, byte phase)
 {
     _currentOps[phase] = first;
 }