All of lore.kernel.org
 help / color / mirror / Atom feed
* [lm-sensors] fancontrol with IT8705F
@ 2006-12-06 16:42 flabbergasted at gmx.de
  2006-12-07 10:30 ` Jean Delvare
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: flabbergasted at gmx.de @ 2006-12-06 16:42 UTC (permalink / raw)
  To: lm-sensors

Hi,

I installed lm-sensors on Ubuntu Edgy today. I have an Asus A7V8X-X mobo 
wich has an IT8712F/IT8705F chip (that's what speedfan tells me in Windows).

I was able to set up lm-sensors to get the correct values for the CPU 
fan and the temperatures. However I have problems getting fancontrol to 
run.

pwm2 controls the CPU fan but only for values between 0-10. So for the 
value 10 it already runs at 100%. I can regulate it by setting it 
manually between 0-10 but this is problematic with fancontrol which 
expects to regulate between 0-255. I think I remember that the autor of 
speedfan also had problems with this and then fixed it somehow. So if 
this is of any help I could contact him and ask him to provide information.

I searched for this problem on the mailing list but there I only found 
old and not very helpful entries. Can you tell me what I could do about 
this? I'd really like to get this to work since it is one of the main 
reasons I still don't use Linux at home on a regular basis.

Btw... I am quite good with understanding things but I'm still 
relatively new to Linux so if you try to give me some information don't 
expect too much background knowledge on my side. I'm eager to learn, 
though. :)

I really hope you can help. Thanks so much in advance!

Tobias Fritz


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [lm-sensors] fancontrol with IT8705F
  2006-12-06 16:42 [lm-sensors] fancontrol with IT8705F flabbergasted at gmx.de
@ 2006-12-07 10:30 ` Jean Delvare
  2006-12-07 12:49 ` Jean Delvare
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Jean Delvare @ 2006-12-07 10:30 UTC (permalink / raw)
  To: lm-sensors

Hallo Tobias,

On Wed, 06 Dec 2006 17:42:28 +0100, flabbergasted at gmx.de wrote:
> I installed lm-sensors on Ubuntu Edgy today. I have an Asus A7V8X-X mobo 
> wich has an IT8712F/IT8705F chip (that's what speedfan tells me in Windows).
> 
> I was able to set up lm-sensors to get the correct values for the CPU 
> fan and the temperatures. However I have problems getting fancontrol to 
> run.
> 
> pwm2 controls the CPU fan but only for values between 0-10. So for the 
> value 10 it already runs at 100%. I can regulate it by setting it 
> manually between 0-10 but this is problematic with fancontrol which 
> expects to regulate between 0-255. I think I remember that the autor of 
> speedfan also had problems with this and then fixed it somehow. So if 
> this is of any help I could contact him and ask him to provide information.

Sure, please do. I have some ideas (see below) but additional
information cannot hurt.

> I searched for this problem on the mailing list but there I only found 
> old and not very helpful entries. Can you tell me what I could do about 
> this? I'd really like to get this to work since it is one of the main 
> reasons I still don't use Linux at home on a regular basis.
> 
> Btw... I am quite good with understanding things but I'm still 
> relatively new to Linux so if you try to give me some information don't 
> expect too much background knowledge on my side. I'm eager to learn, 
> though. :)
> 
> I really hope you can help. Thanks so much in advance!

It is probably related to the PWM frequency, i.e. the frequency at
which the chip modulates the fan power source to lower its speed.
Assuming your chip lives at the standard address 0x290, please provide
the output of "isadump 0x295 0x296". Register 0x14 has bits to change
the PWM frequency. Another bit in this register could also affect your
ability to control the fan speed (PWM minimum duty select.)

Right now, the it87 driver doesn't provide ways to change these
parameters, but an interface could be added if it proves useful.

-- 
Jean Delvare


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [lm-sensors] fancontrol with IT8705F
  2006-12-06 16:42 [lm-sensors] fancontrol with IT8705F flabbergasted at gmx.de
  2006-12-07 10:30 ` Jean Delvare
@ 2006-12-07 12:49 ` Jean Delvare
  2006-12-07 12:54 ` Tobias Fritz
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Jean Delvare @ 2006-12-07 12:49 UTC (permalink / raw)
  To: lm-sensors

Tobias,

Please answer to the mailing list rather than to me only.

On Thu, 7 Dec 2006 13:09:48 +0100, Tobias Fritz wrote:
> thanks for your reply. I rewrote fancontrol now and it works ok. But I'd still 
> be interested in a better solution. I'll contact the author of speedfan to 
> see if he really got it to work better or just mapped the 0-10 values to his 
> 0-100% settings (if there are just 10 different speeds I can set my fan to I 
> can live very well with the fancontrol hack. However if it is possible to set 
> it to more values it would be nice because right now it goes from 1500 RPM 
> directly to 2000 and then to 2200 and doesn't change much more after that)

Yes, this is typical of an improper PWM base frequency. When I
experimented with different frequencies on my own system, I drew the
following graph:
http://khali.linux-fr.org/devel/lm-sensors/pwm_response_curves.png

As you can see, at high frequencies, the range where I could actually
control the speed was really small, even though not as small as what
you report on your system.

> Output of the isadump:
> 
>      0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
> 00: 19 10 ff 07 37 ff 07 37 ff 07 1a 09 09 ff ff ff
> 10: ff ff ff 72 87 00 01 00 00 00 00 00 00 00 00 00
> 20: 69 00 cf b1 be 00 00 af ff 2d 1b ff ff ff ff ff
> 30: ff ff ff ff ff ff ff ff ff ff ff ff ff ef ff ff
> 40: ff ff ff ff ff ff ff ff 2d ff ff ff ff ff ff ff
> 50: ff 18 7f 7f 7f ff ff ff 90 56 fb 12 00 00 00 00
> 60: 7f 7f 7f 7f 7f 00 00 00 7f 7f 7f 7f 7f 00 00 00
> 70: 7f 7f 7f 7f 00 00 00 00 ff ff ff ff ff ff ff ff
> 80: 19 10 00 00 37 ff 07 37 ff 07 1a 09 09 ff ff ff
> 90: ff ff ff 72 87 00 01 00 00 00 00 00 00 00 00 00
> a0: 69 00 cf b1 be 00 00 af ff 2d 1b ff ff ff ff ff
> b0: ff ff ff ff ff ff ff ff ff ff ff ff ff ef ff ff
> c0: ff ff ff ff ff ff ff ff 2d ff ff ff ff ff ff ff
> d0: ff 18 7f 7f 7f ff ff ff 90 56 fb 12 00 00 00 00
> e0: 7f 7f 7f 7f 7f 00 00 00 7f 7f 7f 7f 7f 00 00 00
> f0: 7f 7f 7f 7f 00 00 00 00 ff ff ff ff ff ff ff ff

So your current PWM base frequency is 48 MHz (comparing the value of
bits 6-4 of register 0x14 with the IT8705F datasheet) which is the
maximum value. You can use "isaset" to try different frequencies:

isaset 0x295 0x296 0x14 0x00 0x70   # 24 MHz
isaset 0x295 0x296 0x14 0x10 0x70   # 24 MHz
isaset 0x295 0x296 0x14 0x20 0x70   # 12 MHz
isaset 0x295 0x296 0x14 0x30 0x70   # 8 MHz
isaset 0x295 0x296 0x14 0x40 0x70   # 6 MHz
isaset 0x295 0x296 0x14 0x50 0x70   # 3 MHz
isaset 0x295 0x296 0x14 0x60 0x70   # 1.5 MHz
isaset 0x295 0x296 0x14 0x70 0x70   # 0.75 MHz

As a rule of thumb, lower frequencies should give your better control,
but you might also bring annoying sounds. Please experiment with
different values and report.

-- 
Jean Delvare


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [lm-sensors] fancontrol with IT8705F
  2006-12-06 16:42 [lm-sensors] fancontrol with IT8705F flabbergasted at gmx.de
  2006-12-07 10:30 ` Jean Delvare
  2006-12-07 12:49 ` Jean Delvare
@ 2006-12-07 12:54 ` Tobias Fritz
  2006-12-07 13:10 ` Tobias Fritz
  2006-12-08 19:52 ` Jean Delvare
  4 siblings, 0 replies; 6+ messages in thread
From: Tobias Fritz @ 2006-12-07 12:54 UTC (permalink / raw)
  To: lm-sensors

Hi Jean,

thanks for your reply. I rewrote fancontrol now and it works ok. But I'd still 
be interested in a better solution. I'll contact the author of speedfan to 
see if he really got it to work better or just mapped the 0-10 values to his 
0-100% settings (if there are just 10 different speeds I can set my fan to I 
can live very well with the fancontrol hack. However if it is possible to set 
it to more values it would be nice because right now it goes from 1500 RPM 
directly to 2000 and then to 2200 and doesn't change much more after that)

> please provide
> the output of "isadump 0x295 0x296". Register 0x14 has bits to change
> the PWM frequency. Another bit in this register could also affect your
> ability to control the fan speed (PWM minimum duty select.)

Output of the isadump:

? ? ?0 ?1 ?2 ?3 ?4 ?5 ?6 ?7 ?8 ?9 ?a ?b ?c ?d ?e ?f
00: 19 10 ff 07 37 ff 07 37 ff 07 1a 09 09 ff ff ff
10: ff ff ff 72 87 00 01 00 00 00 00 00 00 00 00 00
20: 69 00 cf b1 be 00 00 af ff 2d 1b ff ff ff ff ff
30: ff ff ff ff ff ff ff ff ff ff ff ff ff ef ff ff
40: ff ff ff ff ff ff ff ff 2d ff ff ff ff ff ff ff
50: ff 18 7f 7f 7f ff ff ff 90 56 fb 12 00 00 00 00
60: 7f 7f 7f 7f 7f 00 00 00 7f 7f 7f 7f 7f 00 00 00
70: 7f 7f 7f 7f 00 00 00 00 ff ff ff ff ff ff ff ff
80: 19 10 00 00 37 ff 07 37 ff 07 1a 09 09 ff ff ff
90: ff ff ff 72 87 00 01 00 00 00 00 00 00 00 00 00
a0: 69 00 cf b1 be 00 00 af ff 2d 1b ff ff ff ff ff
b0: ff ff ff ff ff ff ff ff ff ff ff ff ff ef ff ff
c0: ff ff ff ff ff ff ff ff 2d ff ff ff ff ff ff ff
d0: ff 18 7f 7f 7f ff ff ff 90 56 fb 12 00 00 00 00
e0: 7f 7f 7f 7f 7f 00 00 00 7f 7f 7f 7f 7f 00 00 00
f0: 7f 7f 7f 7f 00 00 00 00 ff ff ff ff ff ff ff ff

I'll write more when I have a reply from the speedfan author.

Thanks again,

Tobias


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [lm-sensors] fancontrol with IT8705F
  2006-12-06 16:42 [lm-sensors] fancontrol with IT8705F flabbergasted at gmx.de
                   ` (2 preceding siblings ...)
  2006-12-07 12:54 ` Tobias Fritz
@ 2006-12-07 13:10 ` Tobias Fritz
  2006-12-08 19:52 ` Jean Delvare
  4 siblings, 0 replies; 6+ messages in thread
From: Tobias Fritz @ 2006-12-07 13:10 UTC (permalink / raw)
  To: lm-sensors

Cool, this helps! If I set it to e.g. 3MHz it seems to change pretty smoothly 
over the whole range. I have to test this a little more but I don't know when 
I'll find time for it. 

If I find a value that suits me, how can I set this permanently? 

Thanks so much for your help!

Tobias

> isaset 0x295 0x296 0x14 0x00 0x70   # 24 MHz
> isaset 0x295 0x296 0x14 0x10 0x70   # 24 MHz
> isaset 0x295 0x296 0x14 0x20 0x70   # 12 MHz
> isaset 0x295 0x296 0x14 0x30 0x70   # 8 MHz
> isaset 0x295 0x296 0x14 0x40 0x70   # 6 MHz
> isaset 0x295 0x296 0x14 0x50 0x70   # 3 MHz
> isaset 0x295 0x296 0x14 0x60 0x70   # 1.5 MHz
> isaset 0x295 0x296 0x14 0x70 0x70   # 0.75 MHz
>
> As a rule of thumb, lower frequencies should give your better control,
> but you might also bring annoying sounds. Please experiment with
> different values and report.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [lm-sensors] fancontrol with IT8705F
  2006-12-06 16:42 [lm-sensors] fancontrol with IT8705F flabbergasted at gmx.de
                   ` (3 preceding siblings ...)
  2006-12-07 13:10 ` Tobias Fritz
@ 2006-12-08 19:52 ` Jean Delvare
  4 siblings, 0 replies; 6+ messages in thread
From: Jean Delvare @ 2006-12-08 19:52 UTC (permalink / raw)
  To: lm-sensors

Tobias,

On Thu, 7 Dec 2006 14:10:47 +0100, Tobias Fritz wrote:
> Cool, this helps! If I set it to e.g. 3MHz it seems to change pretty smoothly 
> over the whole range. I have to test this a little more but I don't know when 
> I'll find time for it. 

Great. So I created a patch which will let the user change the PWM
frequency through a device sysfs file. The patch is against 2.6.18 as
this is what the machine I had for testing was running. The it87 driver
was significantly modified since then so this patch will need to be
rewritten for 2.6.20, I'll do that later.

If you give a try to this patch, note that the frequency you control
through pwm1_freq is the real PWM base frequency, while the values I
gave you before were internal frequencies, which are 128 times greater.
In other words, if "3 MHz" was working for you, you'll need to write
23437 (3000000/128) to pwm1_freq.

> If I find a value that suits me, how can I set this permanently?

You can't, as the IT8705F chip will lose its settings on power-off and
most probably on reboot as well. So you'll have to make sure the
frequency is set again at boot time. Without the patch, this can be
done by calling isaset with the right parameters in one of your system
boot scripts. With the patch, echo the wanted frequency
to /sys/devices/platform/i2c-9191/9191-0290/pwm1_freq instead (make
sure the script is called after the it87 driver is loaded.)

-- 
Jean Delvare
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: hwmon-it87-pwm-freq.patch
Url: http://lists.lm-sensors.org/pipermail/lm-sensors/attachments/20061208/b2353c17/attachment.pl 

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2006-12-08 19:52 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-12-06 16:42 [lm-sensors] fancontrol with IT8705F flabbergasted at gmx.de
2006-12-07 10:30 ` Jean Delvare
2006-12-07 12:49 ` Jean Delvare
2006-12-07 12:54 ` Tobias Fritz
2006-12-07 13:10 ` Tobias Fritz
2006-12-08 19:52 ` Jean Delvare

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.