|
@@ -21,18 +21,11 @@ namespace OTSSysMgrApp
|
|
|
#region 全部变量声明
|
|
|
//连接状态
|
|
|
bool ConnectionState = false;
|
|
|
- // 判断是否是模拟状态 FASE: 不是在模拟环境下 True: 在模拟环境下
|
|
|
- //bool IsSimulationStatus = false;
|
|
|
- //获取当前电镜的ID号
|
|
|
- int SemType = 0;
|
|
|
- //获取XML 路径
|
|
|
+
|
|
|
static string xmlFilePath = System.Configuration.ConfigurationManager.ConnectionStrings["XMLFilePath"].ConnectionString;
|
|
|
- //日志路径
|
|
|
- //static string LogPath = System.Configuration.ConfigurationManager.ConnectionStrings["LogPath"].ConnectionString;
|
|
|
-
|
|
|
+
|
|
|
static NLog.Logger log = NLog.LogManager.GetCurrentClassLogger();
|
|
|
- //电镜设置对象
|
|
|
- //OTSCLRINTERFACE.COTSControlFunExport cfun = null;
|
|
|
+
|
|
|
SemController m_SemHardwareMgr = null;
|
|
|
//国际化
|
|
|
Language lan;
|
|
@@ -143,25 +136,23 @@ namespace OTSSysMgrApp
|
|
|
|
|
|
public void GetBtnState(bool btnState)
|
|
|
{
|
|
|
- //循环窗体中
|
|
|
+
|
|
|
foreach (Control item in gbGetMethods.Controls)
|
|
|
{
|
|
|
if (item is Button)
|
|
|
{
|
|
|
- //if(!(((Button)item).Name== "btnGLineTime"))
|
|
|
- //{
|
|
|
+
|
|
|
((Button)item).Enabled = btnState;
|
|
|
- //}
|
|
|
+
|
|
|
}
|
|
|
}
|
|
|
foreach (Control item in gbSetMethods.Controls)
|
|
|
{
|
|
|
if (item is Button)
|
|
|
{
|
|
|
- //if (!(((Button)item).Name == "btnGLineTime"))
|
|
|
- //{
|
|
|
+
|
|
|
((Button)item).Enabled = btnState;
|
|
|
- //}
|
|
|
+
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -1293,18 +1284,15 @@ namespace OTSSysMgrApp
|
|
|
{
|
|
|
bool a_HTValue = true;
|
|
|
bool result = m_SemHardwareMgr.SetSemBeamCurrent(a_HTValue);
|
|
|
- //bool result = cfun.SetSemBeamBlank(a_HTValue);
|
|
|
- //bool result = cfun.SetSemHTOnOff(a_HTValue);
|
|
|
- //MessageBox.Show("Whether the shutdown voltage was successful:" + Convert.ToBoolean(result).ToString());
|
|
|
+
|
|
|
}
|
|
|
|
|
|
private void bVoltageStatus_Click(object sender, EventArgs e)
|
|
|
{
|
|
|
bool a_HTValue = true;
|
|
|
- //bool result = cfun.SetSemBeamCurrent(a_HTValue);
|
|
|
+
|
|
|
bool result = m_SemHardwareMgr.SetSemBeamBlank(a_HTValue);
|
|
|
- //bool result = cfun.SetSemHTOnOff(a_HTValue);
|
|
|
- //MessageBox.Show("Whether the shutdown voltage was successful:" + Convert.ToBoolean(result).ToString());
|
|
|
+
|
|
|
}
|
|
|
|
|
|
private void button1_Click(object sender, EventArgs e)
|