public TemperatureTargetedPowerMode() { _previousReading = new CPUReading(); _currentReading = new CPUReading(); _sensorCollection = CPUSensorsFactory.GetCPUZeroSensor(); _timer = new Timer(); _timer.Interval = 500; _timer.Tick += (sender, e) => { DoCycle(); _onTick(_currentReading.ProcessorState); }; }
private void SetupPeriodicInformationPanel() { _cpuSensorCollection = CPUSensorsFactory.GetCPUZeroSensor(); System.Windows.Forms.Timer timer = new System.Windows.Forms.Timer(); timer.Interval = 500; timer.Tick += (sender, e) => { _cpuSensorCollection.PackageSensor.Hardware.Update(); cpuPackageTemperatureLabelValue.Text = _cpuSensorCollection.PackageSensor.Value + "C"; }; timer.Start(); }