Sunday, 2 October 2011

Effect of CPU parameters as monitored by embedded sensors

A sensor is a device which measures a physical quantity and converts it into a meaningful signal which can be read or observed by a machine or a person. We all use different sensors in our everyday life. Most basic example is of biological sensors like our eyes which convert the light coming from outside into electrical signals which are then interpreted by our brain and thus we are able to see the world around us. There are several other other biological sensors like ears, nose, etc which help us to monitor different information such as sound, smell. 

Like we have sensors to monitor our surroundings and act accordingly, similarily computers also have different sensors for monitoring different information to act accordingly. There are several sensors which are nowadays embedded into cpu, motherboard and connecting devices like temperature sensors, fan speed sensors, clock speed sensors, voltage sensors etc in cpu and gpu, acclerometer sensors, temperature sensors, fan speed sensors,etc on motherboards and temperature or sometimes acclerometer sensors in hardisks. 

Now let us see how the diiferent sensor values are correlated that is how the values of one sensor affect the values of other sensors and explore some softwares that help us monitor them.

When we exercise, we use energy and some of it get converted in the form of heat and thus we feel hot and body temperature starts rising and at that moment the heat detecting cells in our skin  start sending signals to our brain and we start sweating so that body temperature gets lower. Similarily in computers, devices such as hard disk, cpu, have their own temperature sensors so that when the load on these devices increases, computer can monitor it and send signal to the cooling fans to increase their speed  so that the temperature can be brought down.

Controlling fan speed also have some other benefits like reducing power consumption, reducing fan noise and also increasing fan’s life. Although nowadays, most device drivers and OS by themselves also automatically monitor fan speed, there are several other softwares in both windows and linux which can control fan speed based on temperature.


In windows, softwares like HWMonitor, SiSoft sandra, core temp can monitor different sensor readings . To override the default fan speed setting, you may install speed fan which have its own algorithms to control fan speed. Softwares we used were as follows -

To download more such softwares, one can go to

First, we monitor how the change in cpu load have effect on its sensors. We used software prime 95 to put cpu in complete load and observed different sensors readings. Instead of prime 95, one can also compress a large file to put cpu under full load.

Initially there was no load on the system and below are screenshots after we had just run prime 95.

As one can clearly see in the above screenshot, as the time passed with cpu under complete load, its temperature kept on rising.

Now after sometime, we closed prime 95 and below are screenshots after closing it.

As you can see, after there was no load on cpu, its temperature rapidly came down and also if you carefully observe the readings given by HWMonitor, you will notice that voltage readings also came down.

Secondly, we used MSI Kombuster to put 100% load on graphic card and after sometime closed it and observed its readings.
You can see in the above screenshots how the fan speed (top) varied with the temperature(bottom). Initially when gpu was in load, both fan speed and temperature went up and when we removed load from gpu, both started coming down.

We also overclocked our system's gpu using built in software AMD Overide and noticed an increase in temperature and fan speed and also in performance which we measured using 3DMark 2011 PRO (see frame rates at bottom of pic)(note that 3D Mark is a paid software but we used it to just show that the performance also increases after overclocking)

Before overclocking,

After overclocking,

Lastly, we put load on the hard disk by runnig disk defragmentator. 

As in the computer in which we were working had very good cooling system, temperature only changed a bit ( see min and current reading )

Software used in linux were as follows -
  • hddtemp
  • lm-sensors
  • xsensors

In linux for seeing hard disk’s temperature, one have to install a package named ‘hddtemp’. Just go to terminal and type -
sudo apt-get install hddtemp

After installing is done, type
hddtemp /dev/sda   
in the terminal to view your hard disk’s temperature. For more information, click here

Now going to monitoring of other sensors like fan speeds, cpu temperature, voltage, etc we used package named lm-sensors
sudo apt-get install lm-sensors

Now lm-sensors has to detect the sensors. For it, run
sudo sensors-detect
in terminal and answer yes for all the sensors which you want to detect.

After you have detected all the sensors, run in terminal
sudo service module-init-tools start

Now, all of your computer sensors are configured. To see sensor readings, run command sensors
in the terminal or if you want graphical interface, you can install package xsensors as
sudo apt-get install xsexsors and then run command xsensors in terminal. xsensors use the readings generated by lm-sensors and just shows them graphically   

Note - Sometimes you may see a negative or zero temperature, fan readings which means either that temperature or fan sensor is not present in your system or lm-sensors does not support your chipset completely.

In above screenshot, the system was not under any load. Now we ran an infinite loop in terminal, opened up about 10 tabs in firefox and opened open office word to put load on the system and we obtained the following readings.

As you can see as the load on the system increased, the temperature readings went up, fan speed increased and some of the voltage readings also became higher.

If someone is interested to manually configure his system’s fans  then he can try
sudo pwmconfig  

For more details about how to manually configure your fan speed, click here
For more details on how different types of fan speed control mechanism works, click here

  Another sensor - ACCLEROMETER

An accelerometer is a device that measures the vibration or acceleration of motion of a structure which may be static - like the force of gravity or dynamic - like sudden movement. By measuring the amount of static acceleration due to gravity, one can find out the angle the device is tilted at with respect to the earth. By sensing the amount of dynamic acceleration, one can analyze the way the device is moving. They are used to detect car crashes and activate air-bags in time, for image stablisation  in digital cameras, etc.

Now some of you must be wondering what this all have to do with embedded sensors in cpu.
Well, most of you would have heard of using accelerometers in newer mobile phones to increase user experience and are also used to play motion sensing games. Similarily in recent times laptop manufacturing companies have started including a ‘ Hard disk Protection ’ system in their laptops which is nothing but an accelerometer sensor embedded on motherboard so that if ever a laptop falls, it can record a sudden change in the movement and park or stop the heads of the hard disk to minimize data loss.

Another very interesting use of accelerometers in laptops that have come up with time is implemented by quake catcher network which uses them to detect earthquakes. The quake catcher network uses a software that taps into the accelerometer sensor’s reading, transmit them over the network and use that data to detect earthquakes. Its software can record the acceleration along different axises that is the x, y and z axis and thus can also be used to sensor accelerometer sensor’s values. The software can be found on . Download QCNlive from there.

 We hope you enjoyed reading our blog.

For interesting application of accelerometer's reading in linux( only for thinkpads ), click here 
For monitoring accelerometer's reading in Mac, click here

Sahil Mahajan and Jatin Sindhu

No comments:

Post a Comment