Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'CPU temperature check' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
CPU temperature check
Authored by: dgerman on Jul 24, '09 12:08:46PM
After revising script on my iBook G4
was: ioreg changed to: /usr/sbin/ioreg and named it sensors.sh

I created the script sensorChk.sh:
export hisensor=`/Users/me/sensors.sh | sort | tail -n1`
export hidigits=`echo $hisensor | cut -c1-2`
if [ $hidigits -gt 50 ]; then
echo $hisensor
say "Pardon me! , I'm hot, and I need a break!"
fi

Then added this to crontab:
* * * * * /Users/me/sensorChk.sh

This checks the sensors every minute.
You might need to tweak the 50

[ Reply to This | # ]