CPU负载和CPU温度的C ++代码 [英] C++ code for CPU load and CPU temperature

查看:598
本文介绍了CPU负载和CPU温度的C ++代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在Windows中看到CPU临时和CPU负载。我必须自己编写,而不是使用像 Core Temp 这样的软件。如何访问此信息?

I want to see CPU temporary and CPU load in Windows. I have to write it myself not using software like Core Temp. How can I access this information?

我读了一个类似的问题,但没有有用的答案:(。

I read a similar question to mine, but there was no useful answer:(.

推荐答案

最近我开始了一个类似的项目,我需要读取cpu温度和控制风扇在Linux和Windows。我不知道C ++和VS, DDK,但我想出了如何编写一个简单的内核驱动程序和一个简单的程序与winring0在我的笔记本电脑(和大多数其他)的温度和风扇由嵌入式控制器控制你有两个选择,你可以写一个内核驱动程序或者你可以使用库访问嵌入式控制器,这是因为Windows保护ec不被正常的用户权限访问一个好的(和工作)库是winring0(WinRing0_1_3_1b)。一个有用的程序检查ec和其他一切Windows是RW工具。

Recently I have started a similar project. I needed to read the cpu temperature and to control the fan in Linux and Windows. I don't know much about C++ and VS and DDK but I figured how to write a simple kernel driver and a simple program with winring0. In my laptop (and most other) the temperature and the fan is controled by the embedded controller. You have 2 choices, either you can write a kernel driver or you can use a library to access the embedded controller. It's because Windows protect the ec from being accessed with normal user rights. A good (and working) library is winring0 (WinRing0_1_3_1b). A useful program to check the ec and everything else in Windows is the RW tool.

这篇关于CPU负载和CPU温度的C ++代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆