PINE64
Tool to Control Fan - fanctl - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: ROCKPRO64 (https://forum.pine64.org/forumdisplay.php?fid=98)
+--- Forum: Linux on RockPro64 (https://forum.pine64.org/forumdisplay.php?fid=101)
+--- Thread: Tool to Control Fan - fanctl (/showthread.php?tid=6489)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20


RE: Tool to Control Fan - fanctl - stFfn - 11-15-2018

(11-15-2018, 11:39 AM)tuxd3v Wrote:
(11-15-2018, 10:19 AM)stFfn Wrote: Thank you. Now it shows a status.

Code:
root@rockpro64Nas:~# service ats status
● ats.service - ATS - Active Thermal Service
  Loaded: loaded (/lib/systemd/system/ats.service; enabled; vendor preset: enabled)
  Active: active (running) since Thu 2018-11-15 16:18:13 UTC; 23s ago
Main PID: 924 (lua)
   Tasks: 1 (limit: 4915)
  CGroup: /system.slice/ats.service
          └─924 lua /usr/local/sbin/ats

Nov 15 16:18:13 rockpro64Nas systemd[1]: Started ATS - Active Thermal Service.
Now what do i have to do exactly to get the fan started Big Grin

You need to plug the fan 2 pin conector in the board, red wire is(+), black is(-).  Shy
It should start automatically, when temps above 40C

I´ve attached the fan to Port Nr. 4 (http://wiki.pine64.org/index.php/ROCKPro64_Main_Page)
but it´s still not spinning.
What has to be above 40c?
The CPU or the HDD´s? because the HDD´s are at 44c right now.
And i cannot see the CPU temp right now. dont know why.

dont i have to install your programm again? because in the beginning i had errors while installing...


RE: Tool to Control Fan - fanctl - tuxd3v - 11-15-2018

(11-15-2018, 01:39 PM)stFfn Wrote:
(11-15-2018, 11:39 AM)tuxd3v Wrote:
(11-15-2018, 10:19 AM)stFfn Wrote: Thank you. Now it shows a status.

Code:
root@rockpro64Nas:~# service ats status
● ats.service - ATS - Active Thermal Service
  Loaded: loaded (/lib/systemd/system/ats.service; enabled; vendor preset: enabled)
  Active: active (running) since Thu 2018-11-15 16:18:13 UTC; 23s ago
Main PID: 924 (lua)
   Tasks: 1 (limit: 4915)
  CGroup: /system.slice/ats.service
          └─924 lua /usr/local/sbin/ats

Nov 15 16:18:13 rockpro64Nas systemd[1]: Started ATS - Active Thermal Service.
Now what do i have to do exactly to get the fan started Big Grin

You need to plug the fan 2 pin conector in the board, red wire is(+), black is(-).  Shy
It should start automatically, when temps above 40C

I´ve attached the fan to Port Nr. 4 (http://wiki.pine64.org/index.php/ROCKPro64_Main_Page)
but it´s still not spinning.
What has to be above 40c?
The CPU or the HDD´s? because the HDD´s are at 44c right now.
And i cannot see the CPU temp right now. dont know why.

dont i have to install your programm again? because in the beginning i had errors while installing...

Do this,
You can install again, the process is automatic.
It will remove the other version and install a new one..you can repeat the amount of times you want..

But ats starts the Fan when CPU, or GPU is above or equal to 40C.

One way to test is, starting ats in test mode:
Code:
service ats stop
ats --test

It will print Temps, and the Power it apply to the fan.
After testing,

Then when you want the service up:
Code:
service ats start



RE: Tool to Control Fan - fanctl - stFfn - 11-15-2018

Ok the Test started the fan.... can i change it that it does not start at 40 but at like 30 oder something? i want to cool the HDD´s...  or is there any other way? can i somehow change it, that the fan starts when the HDD´s get like 40c?


RE: Tool to Control Fan - fanctl - stFfn - 11-17-2018

Hello tuxd3v are you still there? Smile


RE: Tool to Control Fan - fanctl - Girbur - 11-17-2018

[quote pid='42306' dateline='1542241470']

[quote pid='42293' dateline='1542221439']
[quote pid='42288' dateline='1542216018']

also you could change the profile, be default it his on profile 1, which is for smaller fans,
you could change for profile2, or profile3,
But first it would be nice to have the output of that command.
[/quote]
###################
#How do we change profile?##
###################


[/quote]

[/quote]


RE: Tool to Control Fan - fanctl - tuxd3v - 11-18-2018

(11-15-2018, 05:02 PM)stFfn Wrote: Ok the Test started the fan.... can i change it that it does not start at 40 but at like 30 oder something? i want to cool the HDD´s...  or is there any other way? can i somehow change it, that the fan starts when the HDD´s get like 40c?

Hello stFfn,

You can change it, but you would not be able to get CPU lower than lets say 37C..
The block driver, I think it doesn't provide sysfs SMART, capabilities..

You need to me querying them constantly, and for that a lot of changes need to be done.
I don't know if exists, any god way for that..

You can change what you want, because the code is opensource  Shy 
One simple way would be to adjust the timers, for the triggers, so that the fan would be more time running..
but, for that you need to go into the code and adapt it..

Or follow romtorwator, advice.

(11-13-2018, 05:42 PM)romtorwator Wrote:
(11-13-2018, 03:26 PM)stFfn Wrote: the HDD´s getting to 60°C

For a fan on the chassis, install a thermostat eg KSD9700-60-NO, in the fan circuit, when the fan is powered by +12V,
on datasheet KSD9700-60-NO, he close the contact at +60°С, will open at a temperature of +35°С, or KSD9700-55-NO - close +55°С, open +30°С
in reality (burst tolerance), these thermostats is better to choose, KSD9700-40-NO in reality it close 41.8°С, open 36.1°С
they have a hysteresis of about 5 degrees
I personally used a programmable thermostat based on DS1821

(11-17-2018, 11:52 PM)Girbur Wrote: [quote pid='42293' dateline='1542221439']
also you could change the profile, be default it his on profile 1, which is for smaller fans,
you could change for profile2, or profile3,
But first it would be nice to have the output of that command.

[/quote]
Hello Girbur,
Like I said, its in line 68:
Code:
68         FANSPEC                         = "profile1",

profile 1, for 10mm fan
profile2, for 20 mm fan
profile3, for Bigger Fan
Only the pwm is adjusted, here the triggers, remain the same..
Ofcourse you can also adapt the triggers, starts in line 91:
Code:
97         setTriggers     = function( self, x )

You can adapt those timers, Shy
For example to run for longer time, or to stop for longer periods of time..


RE: Tool to Control Fan - fanctl - Girbur - 11-18-2018

(11-18-2018, 10:36 AM)tuxd3v Wrote:
(11-15-2018, 05:02 PM)stFfn Wrote: Ok the Test started the fan.... can i change it that it does not start at 40 but at like 30 oder something? i want to cool the HDD´s...  or is there any other way? can i somehow change it, that the fan starts when the HDD´s get like 40c?

Hello stFfn,

You can change it, but you would not be able to get CPU lower than lets say 37C..
The block driver, I think it doesn't provide sysfs SMART, capabilities..

You need to me querying them constantly, and for that a lot of changes need to be done.
I don't know if exists, any god way for that..

You can change what you want, because the code is opensource  Shy 
One simple way would be to adjust the timers, for the triggers, so that the fan would be more time running..
but, for that you need to go into the code and adapt it..

Or follow romtorwator, advice.

(11-13-2018, 05:42 PM)romtorwator Wrote:
(11-13-2018, 03:26 PM)stFfn Wrote: the HDD´s getting to 60°C

For a fan on the chassis, install a thermostat eg KSD9700-60-NO, in the fan circuit, when the fan is powered by +12V,
on datasheet KSD9700-60-NO, he close the contact at +60°С, will open at a temperature of +35°С, or KSD9700-55-NO - close +55°С, open +30°С
in reality (burst tolerance), these thermostats is better to choose, KSD9700-40-NO in reality it close 41.8°С, open 36.1°С
they have a hysteresis of about 5 degrees
I personally used a programmable thermostat based on DS1821

(11-17-2018, 11:52 PM)Girbur Wrote: [quote pid='42293' dateline='1542221439']
also you could change the profile, be default it his on profile 1, which is for smaller fans,
you could change for profile2, or profile3,
But first it would be nice to have the output of that command.
Hello Girbur,
Like I said, its in line 68:
Code:
68         FANSPEC                         = "profile1",

profile 1, for 10mm fan
profile2, for 20 mm fan
profile3, for Bigger Fan
Only the pwm is adjusted, here the triggers, remain the same..
Ofcourse you can also adapt the triggers, starts in line 91:
Code:
97         setTriggers     = function( self, x )

You can adapt those timers, Shy
For example to run for longer time, or to stop for longer periods of time..
[/quote]
I forgot where is the file located to change those profiles?

I know it is obvious for you but where is this file with line 68 etc/ or usr?

/usr/local/sbin/ats
nothing there no ats!


RE: Tool to Control Fan - fanctl - tuxd3v - 11-18-2018

(11-18-2018, 01:14 PM)Girbur Wrote: I forgot where is the file located to change those profiles?

I know it is obvious for you but where is this file with line 68 etc/ or usr?

/usr/local/sbin/ats
nothing there no ats!

No problem,  Shy

do this:
Code:
luarocks build https://raw.githubusercontent.com/tuxd3v/ats/master/ats-master-0.rockspec

Then edit file: /usr/local/sbin/ats


RE: Tool to Control Fan - fanctl - Girbur - 11-18-2018

(11-18-2018, 01:57 PM)tuxd3v Wrote:
(11-18-2018, 01:14 PM)Girbur Wrote: I forgot where is the file located to change those profiles?

I know it is obvious for you but where is this file with line 68 etc/ or usr?

/usr/local/sbin/ats
nothing there no ats!

No problem,  Shy

do this:
Code:
luarocks build https://raw.githubusercontent.com/tuxd3v/ats/master/ats-master-0.rockspec

Then edit file: /usr/local/sbin/ats

Got it sorry


RE: Tool to Control Fan - fanctl - tuxd3v - 11-19-2018

(11-18-2018, 01:59 PM)Girbur Wrote: Got it sorry

No problem,
You welcome Shy

In fact I have not yet documented it, sorry for that. 



Choose if you want one of those 3 profiles,
And adapt the timers in the line 97, in this function :
setTriggers     = function( self, x )

You will see  that for each range of temps are there some timers.
Quiet(the fan is stoped by this time in Seconds)
Run( The fan will run for that specified time in seconds )

You only need to change and then start ats again, and test the best option for your setup [Image: shy.png]