77786f17ec
Add fancontroled (fancontrol for embedded devices) package. fancontroled is linux daemon written in C implementing a temperature dependent fan speed control. fancontroled provides similar functionalities like fancontrol script from lm-sensors; but fancontroled does not need bash or other dependencies (except lm-sensors library). That makes it suitable for embedded devices. More info here: http://fancontroled.lukaperkov.net/ fancontroled.init file contains parameters for D-Link DNS323 device. Signed-off-by: Luka Perkov <openwrt@lukaperkov.net> git-svn-id: svn://svn.openwrt.org/openwrt/packages@24070 3c298f89-4303-0410-b956-a3cf2f4a3e73
23 lines
466 B
Bash
23 lines
466 B
Bash
#!/bin/sh /etc/rc.common
|
|
|
|
START=75
|
|
STOP=75
|
|
|
|
TEMP_SENSOR_CHIP=lm75
|
|
TEMP_READ_FIELD=temp1_input
|
|
MIN_TEMP=30
|
|
MAX_TEMP=50
|
|
FAN_SENSOR_CHIP=g760a
|
|
FAN_CONTROL_FIELD=pwm1
|
|
PWM_FAN_MIN=1
|
|
PWM_FAN_MAX=180
|
|
PID_FILENAME=/var/run/fancontroled.pid
|
|
|
|
start() {
|
|
/usr/sbin/fancontroled -t $TEMP_SENSOR_CHIP -r $TEMP_READ_FIELD -m $MIN_TEMP -M $MAX_TEMP -f $FAN_SENSOR_CHIP -c $FAN_CONTROL_FIELD -p $PWM_FAN_MIN -P $PWM_FAN_MAX -z $PID_FILENAME
|
|
}
|
|
|
|
stop() {
|
|
kill $(cat $PID_FILENAME)
|
|
}
|