public M_Base(string name, C_Base cpu, Mem_Base prgMem, Mem_Base wrkMem , Vid_Base vid, Disp_Base disp) { InitM_Base(name, cpu, prgMem, wrkMem, vid, disp); }
protected virtual void OnMachineChanged(EventArgs e) { _display = machine.display; if(_display != null) { if(_display.Parent != null) _display.Parent.Controls.Remove(_display); groupBox_display.Controls.Add(_display); _display.Dock = DockStyle.Fill; } machine.cpu._console = new consoleRef(consoleControl_main); machine.cpu.SetDoCycle(CPU.DoCycleMode.Debug); }
public M_Base(string name, C_Base cpu, Mem_Base mem , Vid_Base vid, Disp_Base disp) { InitM_Base(name, cpu, mem, mem, vid, disp); }
public M_Base(string name, Disp_Base disp) { InitM_Base(name, null, null, null, null, disp); }
protected virtual void InitM_Base(string name="", C_Base cpu=null , Mem_Base prgMem = null, Mem_Base wrkMem = null , Vid_Base vid=null, Disp_Base disp=null) { _settings = settings.main; _pathSettings = _settings.paths; meta = new metaData(name); _timer = new System.Timers.Timer(); _timer.Elapsed += new ElapsedEventHandler(_timer_Elapsed); m_cpu = cpu; _programMemory = prgMem; _workingMemory = wrkMem; m_video = vid; m_display = disp; //ThreadStart ts = new ThreadStart( interval = 0; _threadStart = new ThreadStart(this.Runner); rewindStates = new state[rewindMax]; }
public virtual void Unload() { if(m_display != null) { if(m_display.Parent != null) m_display.Parent.Controls.Remove(m_display); m_display.Dispose(); m_display = null; } }
public void Init(M_Base _machine, consoleRef _Console) { machine = _machine; cpu = machine.cpu; programMemory = machine.programMemory; workingMemory = machine.workingMemory; video = machine.video; display = machine.display; console = _Console; OnInit(new EventArgs()); }