Jump to content

Shutdown PC on cpu heat


Recommended Posts

Hello,
I have a PC in my living room, it is used as a media hub on my home TV.

The computer is hidden in a 'closet' .... it happens to forget the computer turned on after using it and the wardrobe door is closed.
In these cases the danger is to leave it on and risk damaging it.

Is it possible to intercept the temperatures of the computer (CPU, motherboard) and turn it off at a certain heat threshold?

m.

Link to comment
Share on other sites

Here what I could find :

#RequireAdmin

Opt("MustDeclareVars", 1)

Example()

Func Example()
  Local $objWMIService = ObjGet("winmgmts:\\" & @ComputerName & "\root\wmi")
  Local $colItems = $objWMIService.ExecQuery('SELECT * FROM MSAcpi_ThermalZoneTemperature')
  If Not IsObj($colItems) Then Exit MsgBox(0, "", "Not an object")
  If Not $colItems.count Then Exit MsgBox(0, "", "Not found")
  For $oItem In $colItems
    ConsoleWrite ("InstanceName = " & $oItem.InstanceName & @TAB & _
      "CriticalTripPoint = " & $oItem.CriticalTripPoint/10-273.15 & " C" & @TAB & _
      "CurrentTemperature = " & $oItem.CurrentTemperature/10-273.15 & " C" & @CRLF)
  Next
EndFunc

 

Link to comment
Share on other sites

14 hours ago, myspacee said:

it seems that #RequireAdmin inhibits ConsoleWrite

You must have a really old version of autoIt...Make sure you got also full version of Scite...

Edited by Nine
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...