Thanks for this script, i'm going to run it and i'll tell you how it
works.
On Wed, 2003-12-17 at 23:31, Peter Ruskin wrote:
> Just in case anyone is wondering how to display hardware sensor values
> without using gkrellm and using the 2.6.0-test11 kernel, I've knocked
> up a short bash script that does just that.
>
> All the info comes from that new-fangled /sys directory.
>
> ########################################################################
> #!/bin/bash
> #/usr/local/bin/sensor
>
> # Find your own device - mine is 0-0290
> cd /sys/bus/i2c/devices/0-0290
> echo "CURRENT SENSOR VALUES ($(cat name))"
> # This is the "Factor" (100th of what gkrellm says)----�
> echo " CPU temp: $(echo "scale=1; $(cat temp_input2)*17.22/10000" |
> bc)�C"
> echo " Sys temp: $(echo "scale=1; $(cat temp_input1)/1000" | bc)�C"
> echo
> echo " CPU fan : $(cat fan_input1) RPM"
> echo " Sys fan : $(cat fan_input2) RPM"
> echo
> echo " Vcore : $(echo "scale=2; $(cat in_input0)/1000" | bc) V"
> echo " DDR Vtt : $(echo "scale=2; $(cat in_input1)/1000" | bc) V"
> echo " +3.3V : $(echo "scale=2; $(cat in_input2)/1000" | bc) V"
> # here's that "Factor" again, followed by the "Offset"--�
> echo " +5V : $(echo "scale=2; $(cat in_input3)*1.33/1000+1" | bc) V"
> echo " +12V : $(echo "scale=2; $(cat in_input4)/1000*4" | bc) V"
> echo " +5Vsb : $(echo "scale=2; $(cat in_input7)/1000*1.68" | bc) V"
> echo
> ########################################################################
>
> The output looks like this here:
> $ sensor
> CURRENT SENSOR VALUES (it87)
> CPU temp: 60.2�C
> Sys temp: 46.0�C
>
> CPU fan : 4560 RPM
> Sys fan : 3154 RPM
>
> Vcore : 1.68 V
> DDR Vtt : 1.32 V
> +3.3V : 3.36 V
> +5V : 4.84 V
> +12V : 12.28 V
> +5Vsb : 5.07 V
>
> Peter
--
- = Human knowledge belongs to the world = -
Linux Gentoo PoWeReD
Signed by: Cybercar
--
[EMAIL PROTECTED] mailing list