public virtual bool Execute(Clock clock, out ClockEntry next) { _op.Execute(clock, 0); next = _next; return(_comboNext); }
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; } }
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); } }
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); } }
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; } }
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; } }
public virtual bool Execute(Clock clock, out ClockEntry next) { _op.Execute(clock, 0); next = _next; return _comboNext; }
public void QueueOpsStart(ClockEntry first, byte phase) { _currentOps[phase] = first; }
public void QueueOps(ClockEntry ops, byte phase) { _currentOps[phase].Next = ops; }