|
@ -123,7 +123,7 @@ BOOL CLKJPortDlg::OnInitDialog() |
|
|
m_RailwayInspect->Start(); |
|
|
m_RailwayInspect->Start(); |
|
|
Logging("轨检初始化成功"); |
|
|
Logging("轨检初始化成功"); |
|
|
|
|
|
|
|
|
m_SubSystemPlugManager.SetPath(FileHelper::GetRootPath()); |
|
|
|
|
|
|
|
|
//m_SubSystemPlugManager.SetPath(FileHelper::GetRootPath());
|
|
|
m_SubSystemPlugManager.InitPlug(); |
|
|
m_SubSystemPlugManager.InitPlug(); |
|
|
TCServer_Initialize(); |
|
|
TCServer_Initialize(); |
|
|
Logging("巡检和限界初始化成功"); |
|
|
Logging("巡检和限界初始化成功"); |
|
@ -349,7 +349,11 @@ LRESULT CLKJPortDlg::OnWM_USER_CORE_DESCRIBLE_LOGIN(WPARAM wp, LPARAM lp) |
|
|
|
|
|
|
|
|
LRESULT CLKJPortDlg::OnHTFun(WPARAM wparam, LPARAM lparam) |
|
|
LRESULT CLKJPortDlg::OnHTFun(WPARAM wparam, LPARAM lparam) |
|
|
{ |
|
|
{ |
|
|
Logging("巡检已连接"); |
|
|
|
|
|
|
|
|
if (m_flagXJ == false) { |
|
|
|
|
|
Logging("巡检已连接"); |
|
|
|
|
|
m_flagXJ = true; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
m_onlineTime = epoch::ms(); |
|
|
m_onlineTime = epoch::ms(); |
|
|
return 1; |
|
|
return 1; |
|
|
} |
|
|
} |
|
@ -363,7 +367,12 @@ void CLKJPortDlg::CheckOnline() |
|
|
int64 ms = epoch::ms() - m_onlineTime; |
|
|
int64 ms = epoch::ms() - m_onlineTime; |
|
|
if (m_onlineTime > 0 && ms > 30000) |
|
|
if (m_onlineTime > 0 && ms > 30000) |
|
|
{ |
|
|
{ |
|
|
Logging("巡检已断开"); |
|
|
|
|
|
|
|
|
if (m_flagXJ) |
|
|
|
|
|
{ |
|
|
|
|
|
Logging("巡检已断开"); |
|
|
|
|
|
m_flagXJ = false; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
sleep::sec(1); |
|
|
sleep::sec(1); |
|
|
} |
|
|
} |
|
@ -582,13 +591,15 @@ void CLKJPortDlg::OnBnClickedButton4() |
|
|
|
|
|
|
|
|
CString cstrLineName; |
|
|
CString cstrLineName; |
|
|
m_editLineName.GetWindowText(cstrLineName); |
|
|
m_editLineName.GetWindowText(cstrLineName); |
|
|
std::string strLineName(cstrLineName.GetString(), cstrLineName.GetLength()); |
|
|
|
|
|
|
|
|
fastring strLineName(cstrLineName.GetString(), cstrLineName.GetLength()); |
|
|
|
|
|
strLineName = strLineName.replace("上行",""); |
|
|
|
|
|
strLineName = strLineName.replace("下行", ""); |
|
|
|
|
|
|
|
|
CString cstrLineCode; |
|
|
CString cstrLineCode; |
|
|
m_editLineCode.GetWindowText(cstrLineCode); |
|
|
m_editLineCode.GetWindowText(cstrLineCode); |
|
|
std::string strLineCode(cstrLineCode.GetString(), cstrLineCode.GetLength()); |
|
|
std::string strLineCode(cstrLineCode.GetString(), cstrLineCode.GetLength()); |
|
|
|
|
|
|
|
|
_command._line._line_name = strLineName; |
|
|
|
|
|
|
|
|
_command._line._line_name = strLineName.c_str(); |
|
|
_command._line._line_code = strLineCode; |
|
|
_command._line._line_code = strLineCode; |
|
|
_command._line._line_xingbie = nCheckType == 0 ? "上行" : "下行"; |
|
|
_command._line._line_xingbie = nCheckType == 0 ? "上行" : "下行"; |
|
|
_command._line._line_name = _command._line.GetDisplayName(); |
|
|
_command._line._line_name = _command._line.GetDisplayName(); |
|
@ -596,7 +607,6 @@ void CLKJPortDlg::OnBnClickedButton4() |
|
|
Logging(fmt::format("_line_name:{0}", _command._line._line_name)); |
|
|
Logging(fmt::format("_line_name:{0}", _command._line._line_name)); |
|
|
Logging(fmt::format("_line_code:{0}", _command._line._line_code)); |
|
|
Logging(fmt::format("_line_code:{0}", _command._line._line_code)); |
|
|
Logging(fmt::format("_line_xingbie:{0}", _command._line._line_xingbie)); |
|
|
Logging(fmt::format("_line_xingbie:{0}", _command._line._line_xingbie)); |
|
|
Logging(fmt::format("_line_name:{0}", _command._line._line_name)); |
|
|
|
|
|
|
|
|
|
|
|
ICTConfigModule::SetTrainCommandParam(_train_number, _command); |
|
|
ICTConfigModule::SetTrainCommandParam(_train_number, _command); |
|
|
if (pTmasTrain->TrainTaskControl(0, _command)) |
|
|
if (pTmasTrain->TrainTaskControl(0, _command)) |
|
|