Do not use python or WMI.
If you have Windows, and if you cannot use speedfan, it is best to do this at the BIOS level, Microsoft ASL Compiler . Using this, you can set temperature thresholds for different fan speeds. It works beautifully. Be careful. This will void your warranty for good reason. Using this tool incorrectly or carelessly, you can configure the fan so that it never turns on, which immediately prepares your components. Therefore, read it and get a temperature monitor (software application) before using this tool.
I had this problem on my laptop, waaay too much heat. After the investigation, it turned out that the main culprit was a graphics chip that was ALWAYS configured with the default Windows Vista driver installed. It was not a processor that generated heat. It was a GPU. It appears to have been tuned to support Aero graphics. So, in addition to doing ASL speed / fan speed, I abandoned the GPU. I also turned off the clock frequency, because for me silence and steep tempo are more important than the potential processor speed.
This superuser entry describes the problem and solutions that I used in more detail.
source share