woring on 0.2 of fancontrol script
This commit is contained in:
parent
bc7a8067c9
commit
64890504aa
|
@ -1,9 +1,28 @@
|
|||
#!/bin/bash
|
||||
|
||||
#
|
||||
# Odroid HC4 fan control script
|
||||
#
|
||||
|
||||
# Information (don't touch unless you're me)
|
||||
AUTHOR="david@socialnerds.org"
|
||||
VERSION="0.2.0"
|
||||
LICENSE="GPLv3"
|
||||
|
||||
# Configuration
|
||||
THRESHOLD=42000
|
||||
DISTANCE=2000
|
||||
INTERVAL=30
|
||||
STEPS=(120 160 210 255)
|
||||
FAN="/sys/class/hwmon/hwmon2/pwm1"
|
||||
|
||||
function get_temp() {
|
||||
local TEMP=($(cat /sys/devices/virtual/thermal/thermal_zone*/temp))
|
||||
for I in ${TEMP[@]}; do
|
||||
echo "temp: $I"
|
||||
done
|
||||
}
|
||||
|
||||
# set fan mode to manual
|
||||
echo "disabled" | tee /sys/class/thermal/thermal_zone{0,1}/mode > /dev/null
|
||||
|
||||
|
|
Loading…
Reference in New Issue