You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
TwoLaserHead-PushJig/LaiPuLaser/CreaterPciPortCheck.cpp

30 lines
731 B
C++

#include "StdAfx.h"
#include "CreaterPciPortCheck.h"
#include "WorkCmdPciPortCheck.h"
#include "GlobalFunction.h"
#include "CStringFuc.h"
CCreaterPciPortCheck::CCreaterPciPortCheck(const CString &str)
:CCreaterWorkCmd(str)
{
}
CCreaterPciPortCheck::~CCreaterPciPortCheck(void)
{
}
void CCreaterPciPortCheck::Creat()
{
//参数1 表示端口控制的内容
CString CtrlContent = GetPar(1);
//参数2 表示希望这个端口是开还是关
bool NeedState = Str2Bool(GetPar(2));
//最大检测时间
int MaxDelay = CStringToInt(GetPar(3));
CWorkCmdPciPortCheck *pCmd = new CWorkCmdPciPortCheck(CtrlContent,NeedState);
if(MaxDelay>0)
{
pCmd->SetMaxCheckDelay(MaxDelay);
}
AddCmd(pCmd);
}