GetCurrentFan

概述

获取风扇速度。

补充

获取风扇速度:转数/分钟(rpm)。

VC++ .NET VC# .NET VB .NET


VC++ .NET

GetCurrentFan
调用方法 BOOL GetCurrentFan(int iSelect, int *iFan);
返回值
TRUE : 正常
FALSE : 错误
参数 int iSelect
MONITOR_FAN1 : CPU风扇(PS-3710A)
保留(PS-3711A)
MONITOR_FAN2 : 电源风扇(PS-3710A)
保留(PS-3711A)
MONITOR_FAN3 : 硬盘风扇(PS-3710A)
保留(PS-3711A)
int *iFan 风扇速度
示例 int ret, iFan;
ret = GetCurrentVolt(MONITOR_FAN2, &iFan);
必要条件
Header : iocif.h/iocifconst.h
Library : ioctl.lib

页面顶端

VC# .NET

GetCurrentFan
调用方法 [DllImport("Ioctl.dll")] static extern int GetCurrentFan(int iSelect, ref int iFan);
返回值
非0 : 正常
0 : 错误
参数 int iSelect
MONITOR_FAN1 : CPU风扇(PS-3710A)
保留(PS-3711A)
MONITOR_FAN2 : 电源风扇(PS-3710A)
保留(PS-3711A)
MONITOR_FAN3 : 硬盘风扇(PS-3710A)
保留(PS-3711A)
ref int iFan 风扇速度
示例 int ret, iFan;
ret = GetCurrentFan(MONITOR_FAN2, ref iFan);

页面顶端

VB .NET

GetCurrentFan
调用方法 Declare Function GetCurrentFan Lib "Ioctl.dll"(ByVal iSelect As Integer, ByRef iFan As Integer)As Integer
返回值
非0 : 正常
0 : 错误
参数 ByVal iSelect As Integer
MONITOR_FAN1 : CPU风扇(PS-3710A)
保留(PS-3711A)
MONITOR_FAN2 : 电源风扇(PS-3710A)
保留(PS-3711A)
MONITOR_FAN3 : 硬盘风扇(PS-3710A)
保留(PS-3711A)
ByRef iFan As Integer 风扇速度
示例 Dim ret As Integer
Dim iFan As Integer
ret = GetCurrentFan(MONITOR_FAN2, iFan)

页面顶端