Пример #1
0
 public void UpdateValues()
 {
     lblPC.Text         = string.Format("0x{0:X2}", PC);
     lblI.Text          = string.Format("0x{0:X2}", I);
     lblOpCode.Text     = string.Format("0x{0:X2}", OpCode);
     lblCycle.Text      = Cycle.ToString();
     lblSP.Text         = SP.ToString();
     lblSoundTimer.Text = SoundTimer.ToString();
     lblDelayTimer.Text = DelayTimer.ToString();
     lbStackList.Items.Clear();
     foreach (short sItem in Stack)
     {
         lbStackList.Items.Add(string.Format("0x{0:X4}", sItem));
     }
     for (int i = 0; i < Registers.Length; i++)
     {
         ((Label)gbRegistersGroupBox.Controls["lblRegister_" + i]).Text = string.Format("0x{0:X2}", Registers[i]);
     }
 }
Пример #2
0
 public void Timer()
 {
     DelayTimer.Enabled = true;
     textBox1.Text      = DelayTimer.ToString();
 }