Changeset 4440
- Timestamp:
- 06/12/07 13:34:19 (6 years ago)
- Location:
- lm-sensors/branches/lm-sensors-3.0.0
- Files:
-
- 2 modified
-
CHANGES (modified) (1 diff)
-
prog/pwm/fancontrol (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
lm-sensors/branches/lm-sensors-3.0.0/CHANGES
r4434 r4440 20 20 Fix Super-I/O exit sequence for Winbond/Fintek chips 21 21 Program mkpatch: Delete 22 Program fancontrol: Use let for arithmetic evaluation 22 23 Program pwmconfig: Use smaller steps for low PWM values 23 24 Program rrd: Support only hwmon class devices -
lm-sensors/branches/lm-sensors-3.0.0/prog/pwm/fancontrol
r4286 r4440 3 3 # Simple script implementing a temperature dependent fan speed control 4 4 # 5 # Version 0.6 35 # Version 0.64 6 6 # 7 7 # Usage: fancontrol [CONFIGFILE] … … 189 189 pwmo=${AFCPWM[$fcvcount]} 190 190 pwmdisable $pwmo 191 fcvcount=$fcvcount+1191 let fcvcount=$fcvcount+1 192 192 done 193 193 echo 'Verify fans have returned to full speed' … … 288 288 echo "new pwmval=$pwmval" 289 289 fi 290 fcvcount=$fcvcount+1290 let fcvcount=$fcvcount+1 291 291 done 292 292 } … … 303 303 restorefans 304 304 fi 305 fcvcount=$fcvcount+1305 let fcvcount=$fcvcount+1 306 306 done 307 307 … … 314 314 sleep $INTERVAL 315 315 done 316 317 # some old stuff/missing features, will clean this up soon318 #if ( test "$regulationtype" = "quad" ) ; then319 # while true ; do320 # temp=`cat ${temp1} | cut -b 12-13`321 # if (( ${temp} < ${mintemp} )) ;322 # then pwm=0323 # elif (( ${temp} > ${maxtemp} )) ;324 # then pwm=255325 # else326 # pwm=`calc "((10/(${maxtemp}-${mintemp})*(${temp}-${mintemp}))^2/1000*(${maxtemp}-${mintemp})*(255-${minspeed})+${minspeed})"`327 # #no optimization here for readability (or sloth :))328 # fi ;329 # echo $pwm > ${pwm1} ;330 #331 # sleep 10 ;332 # done ;333 334 #elif ( test "$regulationtype" = "exp" ) ; then335 #add support for exponential calculation here336 337 #else338 # pwmconst=$[(255-${minspeed})/(${maxtemp}-${mintemp})]339 # while true ; do340 # let temp=`cat temp1 | cut -b 12-13` ;341 # if (( ${temp} < ${mintemp} )) ;342 # then pwm=0343 # elif (( ${temp} > ${maxtemp} )) ;344 # then pwm=255345 # else346 # pwm=$[(${temp}-${mintemp})*${pwmconst}+${minspeed}]347 # fi ;348 # echo $pwm > pwm2 ;349 #350 # sleep 10 ;351 # done ;352 #fi
