Commit ec29faf8 authored by 周磊's avatar 周磊

1.版本变更为1.8.3

2.辅助工具增加温度趋势功能
3.部分涉及ini读取写入,统一到sys_ini类处理(外部校准,免密登录等)
4.log增加debug,温控debug,反控三类
5.增加反控功能(反控触发,日志记录,弹窗提示等)
6.合并三个检测的绘图类ckvocupdata
7.优化联机以前是限定时长分配每个IP,搜索固定时长,各搜索一次,现在是限定时间内2S扫描一个IP,可重复扫描
parent cc9d2033
...@@ -269,3 +269,4 @@ VocsMonitor/ ...@@ -269,3 +269,4 @@ VocsMonitor/
/VocsSetup/临时测试文件/SysConfigSecondary.en.resx /VocsSetup/临时测试文件/SysConfigSecondary.en.resx
/VocsSetup/临时测试文件/SysConfigSecondary.resx /VocsSetup/临时测试文件/SysConfigSecondary.resx
/VocsSetup/临时测试文件/SysConfigsecondary.Designer.cs /VocsSetup/临时测试文件/SysConfigsecondary.Designer.cs
/VocsSetup/GC_Control/zs.rtf
...@@ -11,6 +11,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VocsMonitor", "VocsMonitor\ ...@@ -11,6 +11,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VocsMonitor", "VocsMonitor\
EndProject EndProject
Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "VocAnalyzer", "VocAnalyzer\VocAnalyzer.vdproj", "{9A8B92E2-7CFA-43AE-8EC6-561827F41EF4}" Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "VocAnalyzer", "VocAnalyzer\VocAnalyzer.vdproj", "{9A8B92E2-7CFA-43AE-8EC6-561827F41EF4}"
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SamplerCounterControl", "SamplerCounterControl\SamplerCounterControl.csproj", "{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WindowsFormsControlLibrary_PopUp", "..\WindowsFormsControlLibrary_PopUp\WindowsFormsControlLibrary_PopUp.csproj", "{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}"
EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU Debug|Any CPU = Debug|Any CPU
...@@ -66,6 +70,30 @@ Global ...@@ -66,6 +70,30 @@ Global
{9A8B92E2-7CFA-43AE-8EC6-561827F41EF4}.Release|Mixed Platforms.Build.0 = Release {9A8B92E2-7CFA-43AE-8EC6-561827F41EF4}.Release|Mixed Platforms.Build.0 = Release
{9A8B92E2-7CFA-43AE-8EC6-561827F41EF4}.Release|x86.ActiveCfg = Release {9A8B92E2-7CFA-43AE-8EC6-561827F41EF4}.Release|x86.ActiveCfg = Release
{9A8B92E2-7CFA-43AE-8EC6-561827F41EF4}.Release|x86.Build.0 = Release {9A8B92E2-7CFA-43AE-8EC6-561827F41EF4}.Release|x86.Build.0 = Release
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Debug|x86.ActiveCfg = Debug|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Debug|x86.Build.0 = Debug|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Release|Any CPU.Build.0 = Release|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Release|x86.ActiveCfg = Release|Any CPU
{AD1C51CD-86B5-416B-9708-0EA7C2414EDC}.Release|x86.Build.0 = Release|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Debug|Any CPU.Build.0 = Debug|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Debug|x86.ActiveCfg = Debug|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Debug|x86.Build.0 = Debug|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Release|Any CPU.ActiveCfg = Release|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Release|Any CPU.Build.0 = Release|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Release|x86.ActiveCfg = Release|Any CPU
{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection EndGlobalSection
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE
......
...@@ -42,7 +42,7 @@ namespace GcDevicePc ...@@ -42,7 +42,7 @@ namespace GcDevicePc
this.fid1ver.Text = this.FID1version; this.fid1ver.Text = this.FID1version;
this.fid2ver.Text = this.FID2version; this.fid2ver.Text = this.FID2version;
this.tcdver.Text = this.TCD1version; this.tcdver.Text = this.TCD1version;
this.PCver.Text = this.Hmiversion + "/1.8.2"; this.PCver.Text = this.Hmiversion + "/1.8.3";
} }
} }
} }
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<configuration> <configuration>
<configSections> <configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" /> <section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net"/>
</configSections> </configSections>
<startup> <startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" /> <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5"/>
</startup> </startup>
<runtime> <runtime>
<legacyUnhandledExceptionPolicy enabled="true" /> <legacyUnhandledExceptionPolicy enabled="true"/>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly> <dependentAssembly>
<assemblyIdentity name="System.Data.SQLite" publicKeyToken="db937bc2d44ff139" culture="neutral" /> <assemblyIdentity name="System.Data.SQLite" publicKeyToken="db937bc2d44ff139" culture="neutral"/>
<bindingRedirect oldVersion="0.0.0.0-1.0.104.0" newVersion="1.0.104.0" /> <bindingRedirect oldVersion="0.0.0.0-1.0.104.0" newVersion="1.0.104.0"/>
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
</runtime> </runtime>
<log4net> <log4net>
<logger name="Log"> <logger name="Log">
<level value="INFO" /> <level value="INFO"/>
<appender-ref ref="RollingLog" /> <appender-ref ref="RollingLog"/>
</logger> </logger>
<logger name="Err"> <logger name="Err">
<level value="ERROR" /> <level value="ERROR"/>
<appender-ref ref="RollingErr" /> <appender-ref ref="RollingErr"/>
</logger> </logger>
<logger name="HmiInfo"> <logger name="HmiInfo">
<level value="INFO" /> <level value="INFO"/>
<appender-ref ref="HmiRollingLog" /> <appender-ref ref="HmiRollingLog"/>
</logger>
<logger name="DebugInfo">
<level value="INFO"/>
<appender-ref ref="DebugRollingLog"/>
</logger>
<logger name="TempDebugInfo">
<level value="INFO"/>
<appender-ref ref="TempDebugRollingLog"/>
</logger>
<logger name="AntiControlLog">
<level value="INFO"/>
<appender-ref ref="AntiControlRollingLog"/>
</logger> </logger>
<appender name="RollingLog" type="log4net.Appender.RollingFileAppender"> <appender name="RollingLog" type="log4net.Appender.RollingFileAppender">
<file value="..\GC_User\Logs\InfoLog_" /> <file value="..\GC_User\Logs\InfoLog_"/>
<appendToFile value="true" /> <appendToFile value="true"/>
<rollingStyle value="Date" /> <rollingStyle value="Date"/>
<datePattern value="yyyyMMdd'.txt'" /> <datePattern value="yyyyMMdd'.txt'"/>
<staticLogFileName value="false" /> <staticLogFileName value="false"/>
<layout type="log4net.Layout.PatternLayout"> <layout type="log4net.Layout.PatternLayout">
<conversionPattern value="Record Time:%d Thread ID:[%thread]- Info:%m%n" /> <conversionPattern value="Record Time:%d Thread ID:[%thread]- Info:%m%n"/>
</layout> </layout>
<filter type="log4net.Filter.LevelRangeFilter"> <filter type="log4net.Filter.LevelRangeFilter">
<param name="LevelMin" value="INFO" /> <param name="LevelMin" value="INFO"/>
<param name="LevelMax" value="INFO" /> <param name="LevelMax" value="INFO"/>
</filter> </filter>
</appender> </appender>
<appender name="HmiRollingLog" type="log4net.Appender.RollingFileAppender"> <appender name="HmiRollingLog" type="log4net.Appender.RollingFileAppender">
<file value="..\GC_User\Logs\HmiLog_" /> <file value="..\GC_User\Logs\HmiLog_"/>
<appendToFile value="true" /> <appendToFile value="true"/>
<rollingStyle value="Date" /> <rollingStyle value="Date"/>
<datePattern value="yyyyMMdd'.txt'" /> <datePattern value="yyyyMMdd'.txt'"/>
<staticLogFileName value="false" /> <staticLogFileName value="false"/>
<layout type="log4net.Layout.PatternLayout"> <layout type="log4net.Layout.PatternLayout">
<conversionPattern value="Record Time:%d Info:%m%n" /> <conversionPattern value="Record Time:%d Info:%m%n"/>
</layout> </layout>
<filter type="log4net.Filter.LevelRangeFilter"> <filter type="log4net.Filter.LevelRangeFilter">
<param name="LevelMin" value="INFO" /> <param name="LevelMin" value="INFO"/>
<param name="LevelMax" value="INFO" /> <param name="LevelMax" value="INFO"/>
</filter> </filter>
</appender> </appender>
<appender name="RollingErr" type="log4net.Appender.RollingFileAppender"> <appender name="RollingErr" type="log4net.Appender.RollingFileAppender">
<file value="..\GC_User\Logs\ErrLog_" /> <file value="..\GC_User\Logs\ErrLog_"/>
<appendToFile value="true" /> <appendToFile value="true"/>
<rollingStyle value="Date" /> <rollingStyle value="Date"/>
<datePattern value="yyyyMMdd'.txt'" /> <datePattern value="yyyyMMdd'.txt'"/>
<staticLogFileName value="false" /> <staticLogFileName value="false"/>
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="Record Time:%d Thread ID:[%thread]- Error:%m%n"/>
</layout>
<filter type="log4net.Filter.LevelRangeFilter">
<param name="LevelMin" value="ERROR"/>
<param name="LevelMax" value="ERROR"/>
</filter>
</appender>
<appender name="DebugRollingLog" type="log4net.Appender.RollingFileAppender">
<file value="..\GC_User\Logs\Debug_"/>
<appendToFile value="true"/>
<rollingStyle value="Date"/>
<datePattern value="yyyyMMdd'.txt'"/>
<staticLogFileName value="false"/>
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="Record Time:%d Thread ID:[%thread]- Info:%m%n"/>
</layout>
<filter type="log4net.Filter.LevelRangeFilter">
<param name="LevelMin" value="INFO"/>
<param name="LevelMax" value="INFO"/>
</filter>
</appender>
<appender name="TempDebugRollingLog" type="log4net.Appender.RollingFileAppender">
<file value="..\GC_User\Logs\TempDebug_"/>
<appendToFile value="true"/>
<rollingStyle value="Date"/>
<datePattern value="yyyyMMdd'.txt'"/>
<staticLogFileName value="false"/>
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="Record Time:%d Thread ID:[%thread]- Info:%m%n"/>
</layout>
<filter type="log4net.Filter.LevelRangeFilter">
<param name="LevelMin" value="INFO"/>
<param name="LevelMax" value="INFO"/>
</filter>
</appender>
<appender name="AntiControlRollingLog" type="log4net.Appender.RollingFileAppender">
<file value="..\GC_User\Logs\AntiControl_"/>
<appendToFile value="true"/>
<rollingStyle value="Date"/>
<datePattern value="yyyyMMdd'.txt'"/>
<staticLogFileName value="false"/>
<layout type="log4net.Layout.PatternLayout"> <layout type="log4net.Layout.PatternLayout">
<conversionPattern value="Record Time:%d Thread ID:[%thread]- Error:%m%n" /> <conversionPattern value="Record Time:%d Thread ID:[%thread]- Info:%m%n"/>
</layout> </layout>
<filter type="log4net.Filter.LevelRangeFilter"> <filter type="log4net.Filter.LevelRangeFilter">
<param name="LevelMin" value="ERROR" /> <param name="LevelMin" value="INFO"/>
<param name="LevelMax" value="ERROR" /> <param name="LevelMax" value="INFO"/>
</filter> </filter>
</appender> </appender>
</log4net> </log4net>
</configuration> </configuration>
using Ini.Net; using GcDevicePc.Common;
using Ini.Net;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel; using System.ComponentModel;
...@@ -20,29 +21,18 @@ namespace GcDevicePc.CK_UI ...@@ -20,29 +21,18 @@ namespace GcDevicePc.CK_UI
public static bool IsPasswordFree;//勾选"当天启用免密码登录"是否有效 public static bool IsPasswordFree;//勾选"当天启用免密码登录"是否有效
public static bool IsUpdataPass = false;//是否更新密码时效 public static bool IsUpdataPass = false;//是否更新密码时效
private string dt;//密码 private string dt;//密码
private string file;//路径
private IniFile infile;//IniFile
private string strTemp = "0";//ini中勾选类型 private string strTemp = "0";//ini中勾选类型
private string strCurData;//当前日期 private string strCurData;//当前日期
private string strIniData;//ini中锚定日期 private string strIniData;//ini中锚定日期
CKVocAnalyzer.NumForm form; CKVocAnalyzer.NumForm form;//小键盘
public LandIn(string userstr, string pwd) public LandIn(string userstr, string pwd)
{ {
InitializeComponent(); InitializeComponent();
#if Use_English_Folder
this.file = Path.Combine(Path.GetDirectoryName(System.Windows.Forms.Application.StartupPath), "GC_Config\\GC_Set\\Startup\\sys.ini");
#else
file = Path.Combine(Path.GetDirectoryName(System.Windows.Forms.Application.StartupPath), "GC_Config\\GC_Set\\启动参数\\sys.ini");
#endif
this.infile = new IniFile(file);
strCurData = DateTime.Now.ToShortDateString().ToString(); strCurData = DateTime.Now.ToShortDateString().ToString();
strIniData = infile.ReadString("免登录", "锚点日期"); strIniData = Sys_ini.Get_Sys_NoLogin_AnchorDate();
strTemp = this.infile.ReadString("免登录", "勾选类型"); strTemp =Sys_ini.Get_Sys_NoLogin_CheckType();
if (strTemp == "") if (strTemp == "0")
{ {
//应对旧版本没有这些参数
this.infile.WriteString("免登录", "勾选类型", "0");
this.infile.WriteString("免登录", "锚定日期", "n/a");
this.PasswordFree.Checked = false; this.PasswordFree.Checked = false;
} }
else if (strTemp == "1" || strTemp == "2") else if (strTemp == "1" || strTemp == "2")
...@@ -54,11 +44,10 @@ namespace GcDevicePc.CK_UI ...@@ -54,11 +44,10 @@ namespace GcDevicePc.CK_UI
} }
else else
{ {
this.infile.WriteString("免登录", "勾选类型", "0"); Sys_ini.Set_Sys_NoLogin_AnchorDate("n/a");
this.infile.WriteString("免登录", "锚定日期", "n/a"); Sys_ini.Set_Sys_NoLogin_CheckType( "0");
this.PasswordFree.Checked = false; this.PasswordFree.Checked = false;
} }
} }
else else
{ {
...@@ -81,7 +70,7 @@ namespace GcDevicePc.CK_UI ...@@ -81,7 +70,7 @@ namespace GcDevicePc.CK_UI
} }
else else
{ {
this.infile.WriteString("免登录", "锚定日期", "n/a"); Sys_ini.Set_Sys_NoLogin_AnchorDate("n/a");
} }
} }
...@@ -107,8 +96,8 @@ namespace GcDevicePc.CK_UI ...@@ -107,8 +96,8 @@ namespace GcDevicePc.CK_UI
} }
else else
{ {
infile.WriteString("免登录", "勾选类型", "0"); Sys_ini.Set_Sys_NoLogin_CheckType( "0");
this.infile.WriteString("免登录", "锚定日期", "n/a"); Sys_ini.Set_Sys_NoLogin_AnchorDate("n/a");
MessageBox.Show("密码已失效"); MessageBox.Show("密码已失效");
} }
...@@ -138,8 +127,8 @@ namespace GcDevicePc.CK_UI ...@@ -138,8 +127,8 @@ namespace GcDevicePc.CK_UI
} }
else else
{ {
infile.WriteString("免登录", "勾选类型", "0"); Sys_ini.Set_Sys_NoLogin_CheckType( "0");
this.infile.WriteString("免登录", "锚定日期", "n/a"); Sys_ini.Set_Sys_NoLogin_AnchorDate("n/a");
MessageBox.Show("密码已失效"); MessageBox.Show("密码已失效");
} }
} }
...@@ -150,11 +139,6 @@ namespace GcDevicePc.CK_UI ...@@ -150,11 +139,6 @@ namespace GcDevicePc.CK_UI
{ {
LoginDecision(); LoginDecision();
} }
if (form != null) if (form != null)
{ {
form.Close(); form.Close();
...@@ -174,20 +158,20 @@ namespace GcDevicePc.CK_UI ...@@ -174,20 +158,20 @@ namespace GcDevicePc.CK_UI
Island = true;//显示菜单其他选项 Island = true;//显示菜单其他选项
if (IsPasswordFree) if (IsPasswordFree)
{ {
infile.WriteString("免登录", "勾选类型", "1"); Sys_ini.Set_Sys_NoLogin_CheckType( "1");
infile.WriteString("免登录", "锚点日期", DateTime.Now.ToShortDateString().ToString()); Sys_ini.Set_Sys_NoLogin_AnchorDate(DateTime.Now.ToShortDateString().ToString());
}//更新免登录信息 }//更新免登录信息
else else
{ {
infile.WriteString("免登录", "勾选类型", "0"); Sys_ini.Set_Sys_NoLogin_CheckType( "0");
this.infile.WriteString("免登录", "锚定日期", "n/a"); Sys_ini.Set_Sys_NoLogin_AnchorDate("n/a");
} }
} }
else else
{ {
infile.WriteString("免登录", "勾选类型", "0"); Sys_ini.Set_Sys_NoLogin_CheckType( "0");
this.infile.WriteString("免登录", "锚定日期", "n/a"); Sys_ini.Set_Sys_NoLogin_AnchorDate("n/a");
Island = false; Island = false;
} }
} }
...@@ -200,19 +184,19 @@ namespace GcDevicePc.CK_UI ...@@ -200,19 +184,19 @@ namespace GcDevicePc.CK_UI
Issa = true;//显示超级选项 Issa = true;//显示超级选项
if (IsPasswordFree) if (IsPasswordFree)
{ {
infile.WriteString("免登录", "勾选类型", "2"); Sys_ini.Set_Sys_NoLogin_CheckType( "2");
infile.WriteString("免登录", "锚点日期", DateTime.Now.ToShortDateString().ToString()); Sys_ini.Set_Sys_NoLogin_AnchorDate( DateTime.Now.ToShortDateString().ToString());
}//写入免登录信息 }//写入免登录信息
else else
{ {
infile.WriteString("免登录", "勾选类型", "0"); Sys_ini.Set_Sys_NoLogin_CheckType( "0");
this.infile.WriteString("免登录", "锚定日期", "n/a"); Sys_ini.Set_Sys_NoLogin_AnchorDate("n/a");
} }
} }
else else
{ {
infile.WriteString("免登录", "勾选类型", "0"); Sys_ini.Set_Sys_NoLogin_CheckType( "0");
this.infile.WriteString("免登录", "锚定日期", "n/a"); Sys_ini.Set_Sys_NoLogin_AnchorDate("n/a");
Issa = false; Issa = false;
} }
} }
......
This diff is collapsed.
...@@ -9,6 +9,9 @@ namespace GcDevicePc.Common ...@@ -9,6 +9,9 @@ namespace GcDevicePc.Common
private static readonly ILog logInfo = LogManager.GetLogger("Log"); private static readonly ILog logInfo = LogManager.GetLogger("Log");
private static readonly ILog hmiInfo = LogManager.GetLogger("HmiInfo"); private static readonly ILog hmiInfo = LogManager.GetLogger("HmiInfo");
private static readonly ILog logErr = LogManager.GetLogger("Err"); private static readonly ILog logErr = LogManager.GetLogger("Err");
private static readonly ILog debugInfo = LogManager.GetLogger("DebugInfo");
private static readonly ILog tempdebugInfo = LogManager.GetLogger("TempDebugInfo");
private static readonly ILog antiControlLog = LogManager.GetLogger("AntiControlLog");
/// <summary> /// <summary>
/// 记录正常的消息 /// 记录正常的消息
...@@ -20,6 +23,28 @@ namespace GcDevicePc.Common ...@@ -20,6 +23,28 @@ namespace GcDevicePc.Common
logInfo.Info(msg); logInfo.Info(msg);
} }
/// <summary>
/// 记录debug信息(也是依据是否勾选min记录)
/// </summary>
public static void DebugInfo(string msg)
{
if(globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.info_log)
debugInfo.Info(msg);
}
/// <summary>
/// 记录温控debug信息(全局记录)
/// </summary>
public static void TempDebugInfo(string msg)
{
tempdebugInfo.Info(msg);
}
/// <summary>
/// 记录反控信息(全局记录)
/// </summary>
public static void AntiControlLog(string msg)
{
antiControlLog.Info(msg);
}
/// <summary> /// <summary>
/// 记录HMI的消息 /// 记录HMI的消息
/// </summary> /// </summary>
......
This diff is collapsed.
This diff is collapsed.
...@@ -16,7 +16,7 @@ using GcDevicePc.ProThread; ...@@ -16,7 +16,7 @@ using GcDevicePc.ProThread;
namespace GcDevicePc.ConfigMethod namespace GcDevicePc.ConfigMethod
{ {
public partial class MethodMain : Form public partial class MethodMain : Form
{ {//打开方法
public delegate void SendUpdateCMD(bool flag); public delegate void SendUpdateCMD(bool flag);
public delegate void Up_MethodMain(); public delegate void Up_MethodMain();
......
...@@ -343,6 +343,7 @@ namespace GcDevicePc.Controls ...@@ -343,6 +343,7 @@ namespace GcDevicePc.Controls
private void btn_MouseLeave(object sender, EventArgs e) private void btn_MouseLeave(object sender, EventArgs e)
{ {
PictureBox ordbtn = sender as PictureBox; PictureBox ordbtn = sender as PictureBox;
//输出字符串格式不正确57:62:507:3:9
int tagnum = Convert.ToInt32(ordbtn.Tag); int tagnum = Convert.ToInt32(ordbtn.Tag);
ordbtn.Image = pmordimage.Images[tagnum]; ordbtn.Image = pmordimage.Images[tagnum];
} }
......
...@@ -59,6 +59,5 @@ ...@@ -59,6 +59,5 @@
#endregion #endregion
private ListViewNF datalist; private ListViewNF datalist;
} }
} }
\ No newline at end of file
...@@ -945,6 +945,8 @@ using GcDevicePc.ProThread; ...@@ -945,6 +945,8 @@ using GcDevicePc.ProThread;
using System.Globalization; using System.Globalization;
using System.Collections.Generic; using System.Collections.Generic;
using System.IO; using System.IO;
using GcDevicePc.Common;
using GcDevicePc.CK_UI;
namespace GcDevicePc namespace GcDevicePc
{ {
...@@ -967,8 +969,8 @@ namespace GcDevicePc ...@@ -967,8 +969,8 @@ namespace GcDevicePc
hmiopt = new HMIControl(globaldata.connection_ip, globaldata.datamodbusport); hmiopt = new HMIControl(globaldata.connection_ip, globaldata.datamodbusport);
datalist.Scroll += new EventHandler(datalist_Scroll); datalist.Scroll += new EventHandler(datalist_Scroll);
} }
private void datalist_Scroll(object sender, EventArgs e) private void datalist_Scroll(object sender, EventArgs e)
{ {
lvindex = datalist.TopItem.Index; lvindex = datalist.TopItem.Index;
...@@ -1101,20 +1103,24 @@ namespace GcDevicePc ...@@ -1101,20 +1103,24 @@ namespace GcDevicePc
else else
{ {
tempshow.SubItems.Add("0.00 /" + (globaldata.m_dpbuffer.ShowList.showtime.alltime / 60.0f).ToString("0.0")); tempshow.SubItems.Add("0.00 /" + (globaldata.m_dpbuffer.ShowList.showtime.alltime / 60.0f).ToString("0.0"));
//修改为提交方法的总时间(原先是读取HMI总时间
//参考柱箱温度
// CProfileDevice.m_DevParam.col.fColTempSet.ToString("0"));;
} }
this.datalist.Items.Add(tempshow); this.datalist.Items.Add(tempshow);
//功率测试 //功率测试
DateTime dt = DateTime.Now;
DateTime dt = DateTime.Now; /*
string err11 = "前进样口:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.bSPower); string err11 = "前进样口:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.bSPower);
string err21 = "后进样口:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.fSPower); string err21 = "后进样口:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.fSPower);
string err31 = "柱箱:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.CbPower); string err31 = "柱箱:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.CbPower);
string err41 = "前检测:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.fDPower); string err41 = "前检测:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.fDPower);
string err51 = "中检测:"+ Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.iDPower); string err51 = "中检测:"+ Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.iDPower);
string err61 = "后检测:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.bDPower); string err61 = "后检测:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.bDPower);
File.AppendAllText(@"./功率.txt", dt.ToLocalTime().ToString()+ err11 + err21 + err31 + err41 + err51 + err61 + " \r\n"); File.AppendAllText(@"./功率.txt", dt.ToLocalTime().ToString()+ err11 + err21 + err31 + err41 + err51 + err61 + " \r\n");
//功率测试 */
//功率测试
#region #region
//tempshow = new ListViewItem(); //tempshow = new ListViewItem();
...@@ -1174,7 +1180,7 @@ namespace GcDevicePc ...@@ -1174,7 +1180,7 @@ namespace GcDevicePc
#endregion #endregion
//errinfo = null; //errinfo = null;
//ABCD异常
if (globaldata.m_hmibuffer.gcinfo.HmiAbnormal[0] != 0 || globaldata.m_hmibuffer.gcinfo.HmiAbnormal[1] != 0 || globaldata.m_hmibuffer.gcinfo.HmiAbnormal[2] != 0 || globaldata.m_hmibuffer.gcinfo.HmiAbnormal[3] != 0) if (globaldata.m_hmibuffer.gcinfo.HmiAbnormal[0] != 0 || globaldata.m_hmibuffer.gcinfo.HmiAbnormal[1] != 0 || globaldata.m_hmibuffer.gcinfo.HmiAbnormal[2] != 0 || globaldata.m_hmibuffer.gcinfo.HmiAbnormal[3] != 0)
{ {
tempshow = new ListViewItem(); tempshow = new ListViewItem();
...@@ -1247,17 +1253,17 @@ namespace GcDevicePc ...@@ -1247,17 +1253,17 @@ namespace GcDevicePc
List<ListViewItem> list = new List<ListViewItem>(); List<ListViewItem> list = new List<ListViewItem>();
for (int cw = 0; cw < globaldata.m_hmibuffer.gcinfo.HmiAbnormal.Length; cw++) for (int cw = 0; cw < globaldata.m_hmibuffer.gcinfo.HmiAbnormal.Length; cw++)
{ {
if (globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw] != 0) if (globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw] != 0)
{ {
ListViewItem lvItems0 = new ListViewItem("XA00" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw].ToString()); lvItems0.BackColor = Color.FromArgb(0, 255, 255, 0); ListViewItem lvItems0 = new ListViewItem("XA00" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw].ToString()); lvItems0.BackColor = Color.FromArgb(0, 255, 255, 0);
ListViewItem lvItems1 = new ListViewItem("XB00" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw].ToString()); lvItems1.BackColor = Color.FromArgb(0, 255, 255, 0); ListViewItem lvItems1 = new ListViewItem("XB00" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw].ToString()); lvItems1.BackColor = Color.FromArgb(0, 255, 255, 0);
ListViewItem lvItems2 = new ListViewItem("XC00" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw].ToString()); lvItems2.BackColor = Color.FromArgb(0, 255, 255, 0); ListViewItem lvItems2 = new ListViewItem("XC00" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw].ToString()); lvItems2.BackColor = Color.FromArgb(0, 255, 255, 0);
ListViewItem lvItems3 = new ListViewItem("XD00" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw].ToString()); lvItems3.BackColor = Color.FromArgb(0, 255, 255, 0); ListViewItem lvItems3 = new ListViewItem("XD00" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw].ToString()); lvItems3.BackColor = Color.FromArgb(0, 255, 255, 0);
switch (cw) switch (cw)
...@@ -1269,19 +1275,21 @@ namespace GcDevicePc ...@@ -1269,19 +1275,21 @@ namespace GcDevicePc
} }
if (tempcs) if (tempcs)
{ {
string err ="第"+globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw]+ "路"+"\t"+"错误类型"+(cw+1);
string err = "第" + globaldata.m_hmibuffer.gcinfo.HmiAbnormal[cw] + "路" + "\t" + "错误类型" + (cw + 1);
string err1 = "前进样口:" + globaldata.m_dpbuffer.ShowList.showtemp.FPActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.FPSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.bSPower); string err1 = "前进样口:" + globaldata.m_dpbuffer.ShowList.showtemp.FPActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.FPSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.bSPower);
string err2 = "后进样口:" + globaldata.m_dpbuffer.ShowList.showtemp.BPActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.BPSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.fSPower); string err2 = "后进样口:" + globaldata.m_dpbuffer.ShowList.showtemp.BPActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.BPSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.fSPower);
string err3 = "柱箱:" + globaldata.m_dpbuffer.ShowList.showtemp.ColActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.ColSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.CbPower); string err3 = "柱箱:" + globaldata.m_dpbuffer.ShowList.showtemp.ColActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.ColSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.CbPower);
string err4 = "前检测:" + globaldata.m_dpbuffer.ShowList.showtemp.fDetActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.fDetSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.fDPower); string err4 = "前检测:" + globaldata.m_dpbuffer.ShowList.showtemp.fDetActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.fDetSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.fDPower);
string err5 = "中检测:" + globaldata.m_dpbuffer.ShowList.showtemp.iDetActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.iDetSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.iDPower); string err5 = "中检测:" + globaldata.m_dpbuffer.ShowList.showtemp.iDetActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.iDetSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.iDPower);
string err6 = "后检测:" + globaldata.m_dpbuffer.ShowList.showtemp.bDetActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.bDetSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.bDPower); string err6 = "后检测:" + globaldata.m_dpbuffer.ShowList.showtemp.bDetActualTemp.ToString("#0.00") + " / " + globaldata.m_dpbuffer.ShowList.showtemp.bDetSetTemp.ToString("0") + "功率:" + Getpower(globaldata.m_dpbuffer.ShowList.pwmInfo.bDPower);
File.AppendAllText(@"./温控报错.txt", dt.ToLocalTime().ToString()+ err + "\t" + err1 + err2 + err3 + err4 + err5 + err6 + " \r\n"); Log.TempDebugInfo(dt.ToLocalTime().ToString() + err + "\t" + err1 + err2 + err3 + err4 + err5 + err6 + " \r\n");
// File.AppendAllText(@"./温控报错.txt", dt.ToLocalTime().ToString()+ err + "\t" + err1 + err2 + err3 + err4 + err5 + err6 + " \r\n");
tempcs = false; tempcs = false;
}//每次出现报错时,打印当前六路温度和功率 }//每次出现报错时,打印当前六路温度和功率
} }
} }
this.datalist.Items.AddRange(list.ToArray()); this.datalist.Items.AddRange(list.ToArray());
...@@ -1310,8 +1318,8 @@ namespace GcDevicePc ...@@ -1310,8 +1318,8 @@ namespace GcDevicePc
{ {
tempshow = new ListViewItem(); tempshow = new ListViewItem();
tempshow.Text = bEnglishLanguage == false ? "前进样口" : "Front INJ"; tempshow.Text = bEnglishLanguage == false ? "前进样口" : "Front INJ";
tempshow.SubItems.Add(IsException(globaldata.m_dpbuffer.ShowList.showtemp.FPActualTemp) + " / " + globaldata.m_dpbuffer.ShowList.showtemp.FPSetTemp.ToString("0")); // tempshow.SubItems.Add(IsException(globaldata.m_dpbuffer.ShowList.showtemp.FPActualTemp) + " / " + globaldata.m_dpbuffer.ShowList.showtemp.FPSetTemp.ToString("0"));
//tempshow.SubItems.Add(IsException(globaldata.m_dpbuffer.ShowList.showtemp.FPActualTemp) + " / " + CProfileDevice.m_DevParam.port[0].fHeaterSetTemp.ToString("0")); tempshow.SubItems.Add(IsException(globaldata.m_dpbuffer.ShowList.showtemp.FPActualTemp) + " / " + CProfileDevice.m_DevParam.port[0].fHeaterSetTemp.ToString("0"));
if (globaldata.m_dpbuffer.ShowList.showtemp.FPActualTemp < globaldata.m_hwconfig.hwconfiginfo.u16InjPortFPTemp + 1) if (globaldata.m_dpbuffer.ShowList.showtemp.FPActualTemp < globaldata.m_hwconfig.hwconfiginfo.u16InjPortFPTemp + 1)
{ {
...@@ -2521,6 +2529,5 @@ namespace GcDevicePc ...@@ -2521,6 +2529,5 @@ namespace GcDevicePc
return (num / 10.0f).ToString(); return (num / 10.0f).ToString();
} }
} }
} }
...@@ -117,46 +117,47 @@ ...@@ -117,46 +117,47 @@
<resheader name="writer"> <resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader> </resheader>
<data name="&gt;&gt;datalist.Name" xml:space="preserve"> <assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<value>datalist</value> <data name="datalist.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
<value>Top, Bottom, Left, Right</value>
</data> </data>
<data name="&gt;&gt;$this.Type" xml:space="preserve"> <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<value>WeifenLuo.WinFormsUI.Docking.DockContent, WeifenLuo.WinFormsUI.Docking, Version=2.9.0.0, Culture=neutral, PublicKeyToken=5cded1a1a0a7b481</value> <data name="datalist.Location" type="System.Drawing.Point, System.Drawing">
<value>0, 0</value>
</data> </data>
<data name="&gt;&gt;datalist.Type" xml:space="preserve"> <data name="datalist.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>GcDevicePc.ListViewNF, GcDevicePc, Version=1.0.0.1, Culture=neutral, PublicKeyToken=null</value> <value>0, 0, 0, 0</value>
</data> </data>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="datalist.Size" type="System.Drawing.Size, System.Drawing"> <data name="datalist.Size" type="System.Drawing.Size, System.Drawing">
<value>286, 330</value> <value>286, 330</value>
</data> </data>
<data name="$this.ClientSize" type="System.Drawing.Size, System.Drawing"> <assembly alias="mscorlib" name="mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<value>284, 325</value> <data name="datalist.TabIndex" type="System.Int32, mscorlib">
<value>0</value>
</data>
<data name="&gt;&gt;datalist.Name" xml:space="preserve">
<value>datalist</value>
</data>
<data name="&gt;&gt;datalist.Type" xml:space="preserve">
<value>GcDevicePc.ListViewNF, GcDevicePc, Version=1.0.0.1, Culture=neutral, PublicKeyToken=null</value>
</data> </data>
<data name="&gt;&gt;datalist.Parent" xml:space="preserve"> <data name="&gt;&gt;datalist.Parent" xml:space="preserve">
<value>$this</value> <value>$this</value>
</data> </data>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <data name="&gt;&gt;datalist.ZOrder" xml:space="preserve">
<data name="datalist.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms"> <value>0</value>
<value>0, 0, 0, 0</value>
</data> </data>
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing"> <data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing">
<value>6, 12</value> <value>6, 12</value>
</data> </data>
<data name="datalist.Location" type="System.Drawing.Point, System.Drawing"> <data name="$this.ClientSize" type="System.Drawing.Size, System.Drawing">
<value>0, 0</value> <value>284, 325</value>
</data>
<data name="&gt;&gt;$this.Name" xml:space="preserve">
<value>DataState</value>
</data>
<data name="datalist.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
<value>Top, Bottom, Left, Right</value>
</data>
<data name="&gt;&gt;datalist.ZOrder" xml:space="preserve">
<value>0</value>
</data> </data>
<data name="$this.Text" xml:space="preserve"> <data name="$this.Font" type="System.Drawing.Font, System.Drawing">
<value>GC 显示系统</value> <value>宋体, 9pt</value>
</data> </data>
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
...@@ -324,17 +325,13 @@ ...@@ -324,17 +325,13 @@
AAA= AAA=
</value> </value>
</data> </data>
<data name="$this.Font" type="System.Drawing.Font, System.Drawing"> <data name="$this.Text" xml:space="preserve">
<value>宋体, 9pt</value> <value>GC 显示系统</value>
</data> </data>
<assembly alias="mscorlib" name="mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <data name="&gt;&gt;$this.Name" xml:space="preserve">
<data name="datalist.TabIndex" type="System.Int32, mscorlib"> <value>DataState</value>
<value>0</value> </data>
<data name="&gt;&gt;$this.Type" xml:space="preserve">
<value>WeifenLuo.WinFormsUI.Docking.DockContent, WeifenLuo.WinFormsUI.Docking, Version=2.9.0.0, Culture=neutral, PublicKeyToken=5cded1a1a0a7b481</value>
</data> </data>
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="$this.Language" type="System.Globalization.CultureInfo, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>en</value>
</metadata>
</root> </root>
\ No newline at end of file
...@@ -15,6 +15,7 @@ using GcDevicePc.GCBuffer; ...@@ -15,6 +15,7 @@ using GcDevicePc.GCBuffer;
namespace GcDevicePc.DeviceConfigUI namespace GcDevicePc.DeviceConfigUI
{ {
//仪器配置界面
public delegate void UpdataHMIOP(ushort val); public delegate void UpdataHMIOP(ushort val);
public partial class ConfigDevice : Form public partial class ConfigDevice : Form
{ {
...@@ -347,25 +348,10 @@ namespace GcDevicePc.DeviceConfigUI ...@@ -347,25 +348,10 @@ namespace GcDevicePc.DeviceConfigUI
private void savebtn_Click(object sender, EventArgs e) private void savebtn_Click(object sender, EventArgs e)
{ {
//Console.WriteLine(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.StatusFolder);
//SaveDialog saveDialog = new SaveDialog(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.SubStatusFolder, 2);
//DialogResult dr = saveDialog.ShowDialog();
//if (dr == DialogResult.OK)
Task.Run(() => { SaveSetting(); });
backgroundWorker1.DoWork += new DoWorkEventHandler(backgroundWorker1_DoWork);
this.backgroundWorker1.RunWorkerAsync(); //运行backgroundWorker组件
WaitForm form = new WaitForm(this.backgroundWorker1); //显示进度条窗体
form.ShowDialog(this);
form.Close();
}
private void SaveSetting()
{
try try
{ {
sendfilename = Path.Combine(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.SubStatusFolder, sendfilename = Path.Combine(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.SubStatusFolder,"DevStatus.ini");
"DevStatus.ini");
if (File.Exists(sendfilename)) if (File.Exists(sendfilename))
{ {
...@@ -376,68 +362,14 @@ namespace GcDevicePc.DeviceConfigUI ...@@ -376,68 +362,14 @@ namespace GcDevicePc.DeviceConfigUI
hWConfig.SavaHWConfig(); hWConfig.SavaHWConfig();
string ip = globaldata.connection_ip;
if (globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.system_Statue == false) if (globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.system_Statue == false)
{ {
savebtn.Enabled = false; Task.Run(() => { SaveSetting(); });
backgroundWorker1.DoWork += new DoWorkEventHandler(backgroundWorker1_DoWork);
SCclient.WtClientInit(ip, globaldata.fileserverport); this.backgroundWorker1.RunWorkerAsync(); //运行backgroundWorker组件
//#if Use_English_Folder WaitForm form = new WaitForm(this.backgroundWorker1); //显示进度条窗体
// SCclient.WtClientCopytoServer("DevStatus.ini", sendfilename, globaldata.remoteFolder + "Instrument Status\\"); form.ShowDialog(this);
//#else form.Close();
SCclient.WtClientCopytoServer("DevStatus.ini", sendfilename, globaldata.remoteFolder + "仪器状态\\");
//#endif
upho(1);
try
{
string tmpname = "";
//globaldata.m_appinit.InitDeviceInfo();
globaldata.m_appinit.InitAppFolder(globaldata.DeviceName);
//globaldata.m_appinit.InitAppFolder(this.hwconfiginfo.GCName);//因为都是以name来决定文件夹名称,这里需要保证实时性
globaldata.m_appinit.SyncConfigFiles();
globaldata.m_appinit.InitAppDefaultConfig();//复制到SingleAnal.ini
globaldata.m_profileMethod.SetStatusFullName(globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_StatusName);//复制SingleAnal.ini到方法新文件
globaldata.m_profileMethod.GetDevState();
tmpname = globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.RunType == 2 ?
globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_BATMethodName :
globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_MethodName;
if (!String.IsNullOrEmpty(tmpname))
{
globaldata.show_MethodName = tmpname;
globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_MethodName = Path.Combine(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.MethodFolder, tmpname.ToString());
if (globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.RunType == 2)
globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_BATMethodName = Path.Combine(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.MethodFolder, tmpname.ToString());
globaldata.m_profileMethod.SetMethodFullName(globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_MethodName);
globaldata.m_profileMethod.GetDevInjPortAllPara();
globaldata.m_profileMethod.GetSampleAllPara("前进样器");
globaldata.m_profileMethod.GetInjValveAllPara();
globaldata.m_profileMethod.GetChromAllPara();
globaldata.m_profileMethod.GetColTableElseAllPara();
globaldata.m_profileMethod.GetFidAllPara();
globaldata.m_profileMethod.GetTcdAllPara();
globaldata.m_profileMethod.GetAuxiliaryAllPara();
}
else
{
}
}
catch
{
}
// MessageBox.Show(bEnglishLanguage == false ? "更新配置成功!" : "Update configuration successfully!");
// this.Close();
if (MessageBox.Show("下发完成,需要重启色谱和软件,是否马上重启软件?\n建议等色谱重启完成后再点击\"是(Y)\"", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question,MessageBoxDefaultButton.Button1, MessageBoxOptions.DefaultDesktopOnly) == DialogResult.Yes)
{
Process.Start(Application.ExecutablePath);
Process.GetCurrentProcess().Kill();
}
} }
else else
{ {
...@@ -449,6 +381,74 @@ namespace GcDevicePc.DeviceConfigUI ...@@ -449,6 +381,74 @@ namespace GcDevicePc.DeviceConfigUI
} }
//Console.WriteLine(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.StatusFolder);
//SaveDialog saveDialog = new SaveDialog(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.SubStatusFolder, 2);
//DialogResult dr = saveDialog.ShowDialog();
//if (dr == DialogResult.OK)
}
private void SaveSetting()
{
savebtn.Enabled = false;
string ip = globaldata.connection_ip;
SCclient.WtClientInit(ip, globaldata.fileserverport);
//#if Use_English_Folder
// SCclient.WtClientCopytoServer("DevStatus.ini", sendfilename, globaldata.remoteFolder + "Instrument Status\\");
//#else
SCclient.WtClientCopytoServer("DevStatus.ini", sendfilename, globaldata.remoteFolder + "仪器状态\\");
//#endif
upho(1);
try
{
string tmpname = "";
//globaldata.m_appinit.InitDeviceInfo();
globaldata.m_appinit.InitAppFolder(globaldata.DeviceName);
//globaldata.m_appinit.InitAppFolder(this.hwconfiginfo.GCName);//因为都是以name来决定文件夹名称,这里需要保证实时性
globaldata.m_appinit.SyncConfigFiles();
globaldata.m_appinit.InitAppDefaultConfig();//复制到SingleAnal.ini
globaldata.m_profileMethod.SetStatusFullName(globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_StatusName);//复制SingleAnal.ini到方法新文件
globaldata.m_profileMethod.GetDevState();
tmpname = globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.RunType == 2 ?
globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_BATMethodName :
globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_MethodName;
if (!String.IsNullOrEmpty(tmpname))
{
globaldata.show_MethodName = tmpname;
globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_MethodName = Path.Combine(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.MethodFolder, tmpname.ToString());
if (globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.RunType == 2)
globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_BATMethodName = Path.Combine(globaldata.m_pcbuffer.gcpcinfo.pcfolderinfo.MethodFolder, tmpname.ToString());
globaldata.m_profileMethod.SetMethodFullName(globaldata.m_pcbuffer.gcpcinfo.pcfileinfo.cur_MethodName);
globaldata.m_profileMethod.GetDevInjPortAllPara();
globaldata.m_profileMethod.GetSampleAllPara("前进样器");
globaldata.m_profileMethod.GetInjValveAllPara();
globaldata.m_profileMethod.GetChromAllPara();
globaldata.m_profileMethod.GetColTableElseAllPara();
globaldata.m_profileMethod.GetFidAllPara();
globaldata.m_profileMethod.GetTcdAllPara();
globaldata.m_profileMethod.GetAuxiliaryAllPara();
}
else
{
}
}
catch
{
}
// MessageBox.Show(bEnglishLanguage == false ? "更新配置成功!" : "Update configuration successfully!");
// this.Close();
if (MessageBox.Show("下发完成,需要重启色谱和软件,是否马上重启软件?\n建议等色谱重启完成后再点击\"是(Y)\"", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button1, MessageBoxOptions.DefaultDesktopOnly) == DialogResult.Yes)
{
Process.Start(Application.ExecutablePath);
Process.GetCurrentProcess().Kill();
}
} }
private void backgroundWorker1_DoWork(object sender, DoWorkEventArgs e) private void backgroundWorker1_DoWork(object sender, DoWorkEventArgs e)
{//配置进度条,这里暂用for来代替执行进度 {//配置进度条,这里暂用for来代替执行进度
......
This diff is collapsed.
This diff is collapsed.
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="cms_Chart.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>367, 22</value>
</metadata>
<metadata name="tim_UpdateState.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="tim_ReadInterval.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>216, 22</value>
</metadata>
<metadata name="cms_file.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>480, 22</value>
</metadata>
<metadata name="tip_.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>578, 22</value>
</metadata>
</root>
\ No newline at end of file
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WindowsFormsControlLibrary_PopUp;
namespace GcDevicePc.ExpansionMethod
{
public static class SelfAdaption
{
public static Point NewSize(this UserControl_PopUp UserControl_PopUp1, Size oldSize, Size newSize, Point oldtextPoint)
{
double scale = 0;
Point location = new Point();
scale = (double)((double)newSize.Height / (double)oldSize.Height);
location.Y = (int)(oldtextPoint.Y * scale)+newSize.Height*2/3;
scale = (double)((double)newSize.Width / (double)oldSize.Width);
location.X = (int)(oldtextPoint.X * scale);
return location;
}
}
}
...@@ -24,7 +24,7 @@ namespace GcDevicePc ...@@ -24,7 +24,7 @@ namespace GcDevicePc
CurveDisPlay2 curdisplay2 = new CurveDisPlay2(); CurveDisPlay2 curdisplay2 = new CurveDisPlay2();
CurveDisPlay3 curdisplay3 = new CurveDisPlay3(); CurveDisPlay3 curdisplay3 = new CurveDisPlay3();
DataState dataleft = new DataState();//状态显示 DataState dataleft = new DataState();//右侧状态显示窗口
private bool bEnglishLanguage = (Thread.CurrentThread.CurrentUICulture == CultureInfo.GetCultureInfo("en")) ? true:false; private bool bEnglishLanguage = (Thread.CurrentThread.CurrentUICulture == CultureInfo.GetCultureInfo("en")) ? true:false;
public Formdebug() public Formdebug()
{ {
...@@ -50,26 +50,104 @@ namespace GcDevicePc ...@@ -50,26 +50,104 @@ namespace GcDevicePc
//dataleft.Close_Threading(); //dataleft.Close_Threading();
//dataleft.Close(); //dataleft.Close();
} }
/// <summary>
/// 前检测对应检测器名称
/// </summary>
private string strDetNameFront;
/// <summary>
/// 中检测对应检测器名称
/// </summary>
private string strDetNameInter;
/// <summary>
/// 后检测对应检测器名称
/// </summary>
private string strDetNameBehind;
/// <summary>
/// 获取检测器对应名称
/// </summary>
private void DetName()
{
if (CProfileDevice.m_DevParam.syspara.u16DetFront == 1)
{
{
if (CProfileDevice.m_DevParam.syspara.u16DetFrontType == 0) //TCD
{
strDetNameFront = "TCD1";
}
else if (CProfileDevice.m_DevParam.syspara.u16DetFrontType == 1)
{
strDetNameFront = "FID1";
}
else if (CProfileDevice.m_DevParam.syspara.u16DetFrontType == 3)
{
strDetNameFront = "FPD1";
}
}
}
if (CProfileDevice.m_DevParam.syspara.u16AuxHeater1 != 1)
{
if (CProfileDevice.m_DevParam.syspara.u16DetInter == 1)
{
{
if (CProfileDevice.m_DevParam.syspara.u16DetInterType == 0) //TCD
{
strDetNameInter = "TCD2";
}
else if (CProfileDevice.m_DevParam.syspara.u16DetInterType == 1)
{
strDetNameInter = "FID2";
}
else if (CProfileDevice.m_DevParam.syspara.u16DetInterType == 3)
{
strDetNameInter = "FPD2";
}
}
}
}
if (CProfileDevice.m_DevParam.syspara.u16AuxHeater2 != 1)
{
if (CProfileDevice.m_DevParam.syspara.u16DetBehind == 1)
{
{
if (CProfileDevice.m_DevParam.syspara.u16DetBehindType == 0)
{
strDetNameBehind = "TCD3";
}
else if (CProfileDevice.m_DevParam.syspara.u16DetBehindType == 1)
{
strDetNameBehind = "FID3";
}
else if (CProfileDevice.m_DevParam.syspara.u16DetBehindType == 3)
{
strDetNameBehind = "FPD3";
}
}
}
}
}
private void Load_Win() private void Load_Win()
{ {
DetName();
if (!String.IsNullOrEmpty(globaldata.connection_ip)) if (!String.IsNullOrEmpty(globaldata.connection_ip))
{ {
if (CProfileDevice.m_DevParam.syspara.u16DetFront == 1) if (CProfileDevice.m_DevParam.syspara.u16DetFront == 1)
{ {
curdisplay.Text = bEnglishLanguage == false?"前检测器":"Front DET"; curdisplay.Text = bEnglishLanguage == false ? "前检测器"+ "("+strDetNameFront+")": "Front DET";
} }
if (CProfileDevice.m_DevParam.syspara.u16DetInter == 1) if (CProfileDevice.m_DevParam.syspara.u16DetInter == 1)
{ {
curdisplay2.Text = bEnglishLanguage == false ? "中检测器":"Middle DET"; curdisplay2.Text = bEnglishLanguage == false ? "中检测器" + "("+strDetNameInter+")": "Middle DET";
} }
if (CProfileDevice.m_DevParam.syspara.u16DetBehind == 1) if (CProfileDevice.m_DevParam.syspara.u16DetBehind == 1)
{ {
curdisplay3.Text = bEnglishLanguage == false ?"后检测器":"Back DET"; curdisplay3.Text = bEnglishLanguage == false ? "后检测器" + "("+strDetNameBehind+")": "Back DET";
} }
} }
...@@ -78,21 +156,23 @@ namespace GcDevicePc ...@@ -78,21 +156,23 @@ namespace GcDevicePc
if (CProfileDevice.m_DevParam.syspara.u16DetFront == 1) if (CProfileDevice.m_DevParam.syspara.u16DetFront == 1)
{ {
curdisplay.Text = bEnglishLanguage == false ? "前检测器":"Front DET"; curdisplay.Text = bEnglishLanguage == false ? "前检测器" : "Front DET";
} }
if (CProfileDevice.m_DevParam.syspara.u16DetInter == 1) if (CProfileDevice.m_DevParam.syspara.u16DetInter == 1)
{ {
curdisplay2.Text = bEnglishLanguage == false ? "中检测器":"Middle DET"; curdisplay2.Text = bEnglishLanguage == false ? "中检测器" : "Middle DET";
} }
if (CProfileDevice.m_DevParam.syspara.u16DetBehind == 1) if (CProfileDevice.m_DevParam.syspara.u16DetBehind == 1)
{ {
curdisplay3.Text = bEnglishLanguage == false ? "后检测器":"Back DET"; curdisplay3.Text = bEnglishLanguage == false ? "后检测器" : "Back DET";
} }
} }
if (CProfileDevice.m_DevParam.syspara.u16DetFront == 1) if (CProfileDevice.m_DevParam.syspara.u16DetFront == 1)
{ {
...@@ -105,7 +185,7 @@ namespace GcDevicePc ...@@ -105,7 +185,7 @@ namespace GcDevicePc
curdisplay.Dispose(); curdisplay.Dispose();
} }
if (CProfileDevice.m_DevParam.syspara.u16DetInter == 1) if (CProfileDevice.m_DevParam.syspara.u16DetInter == 1)
{ {
this.dockPanel1.Contains(curdisplay2); this.dockPanel1.Contains(curdisplay2);
curdisplay2.Show(this.dockPanel1); curdisplay2.Show(this.dockPanel1);
...@@ -116,7 +196,8 @@ namespace GcDevicePc ...@@ -116,7 +196,8 @@ namespace GcDevicePc
curdisplay2.Dispose(); curdisplay2.Dispose();
} }
if (CProfileDevice.m_DevParam.syspara.u16DetBehind == 1)
if (CProfileDevice.m_DevParam.syspara.u16DetBehind == 1)
{ {
this.dockPanel1.Contains(curdisplay3); this.dockPanel1.Contains(curdisplay3);
curdisplay3.Show(this.dockPanel1); curdisplay3.Show(this.dockPanel1);
...@@ -126,14 +207,25 @@ namespace GcDevicePc ...@@ -126,14 +207,25 @@ namespace GcDevicePc
{ {
curdisplay3.Dispose(); curdisplay3.Dispose();
} }
//前中后检测窗口,激活已有的最前面一个
if (!curdisplay.IsDisposed)
{
curdisplay.Show();
}
else
{
if (!curdisplay2.IsDisposed)
{
curdisplay2.Show();
}
}
//Start_Thread(); //Start_Thread();
//dockPanelSideLeft.Show(this.dockPanel1, WeifenLuo.WinFormsUI.Docking.DockState.DockRight); //dockPanelSideLeft.Show(this.dockPanel1, WeifenLuo.WinFormsUI.Docking.DockState.DockRight);
//dockPanelSideLeft.CloseButtonVisible = false; //dockPanelSideLeft.CloseButtonVisible = false;
} }
public void CloseThread() public void CloseThread()
{ {
try try
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
<DebugSymbols>true</DebugSymbols> <DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath> <OutputPath>..\VocsSetup\GC_Control\</OutputPath>
<DefineConstants>TRACE;DEBUG;ENABLE_DOUBLEST_STARTUP Use_English_Folder</DefineConstants> <DefineConstants>TRACE;DEBUG;ENABLE_DOUBLEST_STARTUP Use_English_Folder</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
...@@ -110,7 +110,13 @@ ...@@ -110,7 +110,13 @@
<Reference Include="AutoClosingMessageBox, Version=1.0.0.2, Culture=neutral, processorArchitecture=MSIL"> <Reference Include="AutoClosingMessageBox, Version=1.0.0.2, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\AutoClosingMessageBox.1.0.0.2\lib\net40\AutoClosingMessageBox.dll</HintPath> <HintPath>..\packages\AutoClosingMessageBox.1.0.0.2\lib\net40\AutoClosingMessageBox.dll</HintPath>
</Reference> </Reference>
<Reference Include="C1.C1DataExtender.2, Version=2.0.20113.81, Culture=neutral, PublicKeyToken=7c4b5683f80b910e, processorArchitecture=MSIL" />
<Reference Include="C1.Win.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=944ae1ea0e47ca04" />
<Reference Include="C1.Win.C1Chart.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=a22e16972c085838, processorArchitecture=MSIL" /> <Reference Include="C1.Win.C1Chart.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=a22e16972c085838, processorArchitecture=MSIL" />
<Reference Include="C1.Win.C1Chart3D.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=a22e16972c085838, processorArchitecture=MSIL" />
<Reference Include="C1.Win.C1Command.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=e808566f358766d8" />
<Reference Include="C1.Win.C1Command.4, Version=4.0.20201.416, Culture=neutral, PublicKeyToken=e808566f358766d8, processorArchitecture=MSIL" />
<Reference Include="C1.Win.C1Input.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=7e7ff60f0c214f9a, processorArchitecture=MSIL" />
<Reference Include="CKVocAlgorithm"> <Reference Include="CKVocAlgorithm">
<HintPath>..\dll\CKVocAlgorithm.dll</HintPath> <HintPath>..\dll\CKVocAlgorithm.dll</HintPath>
</Reference> </Reference>
...@@ -134,6 +140,10 @@ ...@@ -134,6 +140,10 @@
<HintPath>..\packages\NModbus4.2.1.0\lib\net40\NModbus4.dll</HintPath> <HintPath>..\packages\NModbus4.2.1.0\lib\net40\NModbus4.dll</HintPath>
</Reference> </Reference>
<Reference Include="PresentationFramework" /> <Reference Include="PresentationFramework" />
<Reference Include="SamplerCounterControl, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>C:\Users\a\Desktop\自动进样器\headspace\packages\202112dl\SamplerCounterControl.dll</HintPath>
</Reference>
<Reference Include="SpaceM"> <Reference Include="SpaceM">
<HintPath>..\dll\SpaceM.dll</HintPath> <HintPath>..\dll\SpaceM.dll</HintPath>
</Reference> </Reference>
...@@ -144,7 +154,9 @@ ...@@ -144,7 +154,9 @@
<HintPath>..\dll\SQLiteOperate.dll</HintPath> <HintPath>..\dll\SQLiteOperate.dll</HintPath>
</Reference> </Reference>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Configuration" />
<Reference Include="System.Core" /> <Reference Include="System.Core" />
<Reference Include="System.Data.OracleClient" />
<Reference Include="System.Data.SQLite, Version=1.0.104.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL"> <Reference Include="System.Data.SQLite, Version=1.0.104.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion> <SpecificVersion>False</SpecificVersion>
<HintPath>bin\x86\Debug\System.Data.SQLite.dll</HintPath> <HintPath>bin\x86\Debug\System.Data.SQLite.dll</HintPath>
...@@ -155,6 +167,7 @@ ...@@ -155,6 +167,7 @@
<Reference Include="System.Design" /> <Reference Include="System.Design" />
<Reference Include="System.Drawing.Design" /> <Reference Include="System.Drawing.Design" />
<Reference Include="System.Management" /> <Reference Include="System.Management" />
<Reference Include="System.Runtime.Serialization.Formatters.Soap" />
<Reference Include="System.Web" /> <Reference Include="System.Web" />
<Reference Include="System.Windows.Forms.DataVisualization" /> <Reference Include="System.Windows.Forms.DataVisualization" />
<Reference Include="System.Xml.Linq" /> <Reference Include="System.Xml.Linq" />
...@@ -254,6 +267,7 @@ ...@@ -254,6 +267,7 @@
<Compile Include="Common\MoudbusOperation.cs" /> <Compile Include="Common\MoudbusOperation.cs" />
<Compile Include="Common\NModbusSlave.cs" /> <Compile Include="Common\NModbusSlave.cs" />
<Compile Include="Common\RunTableHelper.cs" /> <Compile Include="Common\RunTableHelper.cs" />
<Compile Include="Common\Sys_ini.cs" />
<Compile Include="Common\TWFile.cs" /> <Compile Include="Common\TWFile.cs" />
<Compile Include="Compound.cs"> <Compile Include="Compound.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
...@@ -556,6 +570,12 @@ ...@@ -556,6 +570,12 @@
<Compile Include="DeviceConfigUI\Sampling.Designer.cs"> <Compile Include="DeviceConfigUI\Sampling.Designer.cs">
<DependentUpon>Sampling.cs</DependentUpon> <DependentUpon>Sampling.cs</DependentUpon>
</Compile> </Compile>
<Compile Include="DrawUI\TempTrend.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="DrawUI\TempTrend.Designer.cs">
<DependentUpon>TempTrend.cs</DependentUpon>
</Compile>
<Compile Include="EPCTips.cs"> <Compile Include="EPCTips.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
...@@ -657,9 +677,7 @@ ...@@ -657,9 +677,7 @@
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="ProThread\ChannelDataSaveSum.cs" /> <Compile Include="ProThread\ChannelDataSaveSum.cs" />
<Compile Include="ProThread\ChannelDataTh.cs" /> <Compile Include="ProThread\ChannelDataTh.cs" />
<Compile Include="ProThread\CKvocUpdata.cs" /> <Compile Include="ProThread\CKvocUpdataSum.cs" />
<Compile Include="ProThread\CKvocUpdata2.cs" />
<Compile Include="ProThread\CKvocUpdata3.cs" />
<Compile Include="ProThread\CPipeCtl.cs" /> <Compile Include="ProThread\CPipeCtl.cs" />
<Compile Include="ProThread\DataOutput.cs" /> <Compile Include="ProThread\DataOutput.cs" />
<Compile Include="ProThread\DataRcv.cs" /> <Compile Include="ProThread\DataRcv.cs" />
...@@ -763,6 +781,9 @@ ...@@ -763,6 +781,9 @@
<DependentUpon>AboutForm.cs</DependentUpon> <DependentUpon>AboutForm.cs</DependentUpon>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="auxtool.byn.resx">
<DependentUpon>auxtool.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="auxtool.en.resx"> <EmbeddedResource Include="auxtool.en.resx">
<DependentUpon>auxtool.cs</DependentUpon> <DependentUpon>auxtool.cs</DependentUpon>
<SubType>Designer</SubType> <SubType>Designer</SubType>
...@@ -1027,6 +1048,9 @@ ...@@ -1027,6 +1048,9 @@
<EmbeddedResource Include="DeviceConfigUI\Sampling.resx"> <EmbeddedResource Include="DeviceConfigUI\Sampling.resx">
<DependentUpon>Sampling.cs</DependentUpon> <DependentUpon>Sampling.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="DrawUI\TempTrend.resx">
<DependentUpon>TempTrend.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="EPCTips.resx"> <EmbeddedResource Include="EPCTips.resx">
<DependentUpon>EPCTips.cs</DependentUpon> <DependentUpon>EPCTips.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
...@@ -1093,6 +1117,7 @@ ...@@ -1093,6 +1117,7 @@
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="QuitForm.resx"> <EmbeddedResource Include="QuitForm.resx">
<DependentUpon>QuitForm.cs</DependentUpon> <DependentUpon>QuitForm.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="RestartHmi.resx"> <EmbeddedResource Include="RestartHmi.resx">
<DependentUpon>RestartHmi.cs</DependentUpon> <DependentUpon>RestartHmi.cs</DependentUpon>
...@@ -1133,6 +1158,9 @@ ...@@ -1133,6 +1158,9 @@
<DependentUpon>SysConfigSecondary.cs</DependentUpon> <DependentUpon>SysConfigSecondary.cs</DependentUpon>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="SysConfigSecondary.iu-Cans-CA.resx">
<DependentUpon>SysConfigSecondary.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="SysConfigSecondary.resx"> <EmbeddedResource Include="SysConfigSecondary.resx">
<DependentUpon>SysConfigSecondary.cs</DependentUpon> <DependentUpon>SysConfigSecondary.cs</DependentUpon>
<SubType>Designer</SubType> <SubType>Designer</SubType>
...@@ -1209,6 +1237,7 @@ ...@@ -1209,6 +1237,7 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Folder Include="Components\" /> <Folder Include="Components\" />
<Folder Include="ExpansionMethod\" />
<Folder Include="UI\configmenu\" /> <Folder Include="UI\configmenu\" />
<Folder Include="UI\ico\" /> <Folder Include="UI\ico\" />
<Folder Include="UI\menu\" /> <Folder Include="UI\menu\" />
...@@ -1223,6 +1252,10 @@ ...@@ -1223,6 +1252,10 @@
<Content Include="UI\picture\色谱3.png" /> <Content Include="UI\picture\色谱3.png" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ProjectReference Include="..\..\WindowsFormsControlLibrary_PopUp\WindowsFormsControlLibrary_PopUp.csproj">
<Project>{AFC4DDC8-D40D-481E-AE7A-5AFB73C88E78}</Project>
<Name>WindowsFormsControlLibrary_PopUp</Name>
</ProjectReference>
<ProjectReference Include="..\SharedSpace\SharedSpace.csproj"> <ProjectReference Include="..\SharedSpace\SharedSpace.csproj">
<Project>{5498f944-5721-461b-b07f-3105ef0bf643}</Project> <Project>{5498f944-5721-461b-b07f-3105ef0bf643}</Project>
<Name>SharedSpace</Name> <Name>SharedSpace</Name>
......
...@@ -71,6 +71,7 @@ ...@@ -71,6 +71,7 @@
this.statusStrip = new System.Windows.Forms.StatusStrip(); this.statusStrip = new System.Windows.Forms.StatusStrip();
this.toolStripStatusLabelusertime = new System.Windows.Forms.ToolStripStatusLabel(); this.toolStripStatusLabelusertime = new System.Windows.Forms.ToolStripStatusLabel();
this.toolStripStatusLabelText = new System.Windows.Forms.ToolStripStatusLabel(); this.toolStripStatusLabelText = new System.Windows.Forms.ToolStripStatusLabel();
this.tool_CounterControlStatus = new System.Windows.Forms.ToolStripStatusLabel();
this.HmiStatus = new System.Windows.Forms.ToolStripStatusLabel(); this.HmiStatus = new System.Windows.Forms.ToolStripStatusLabel();
this.AdjustStat = new System.Windows.Forms.ToolStripStatusLabel(); this.AdjustStat = new System.Windows.Forms.ToolStripStatusLabel();
this.workProgress = new System.Windows.Forms.ToolStripProgressBar(); this.workProgress = new System.Windows.Forms.ToolStripProgressBar();
...@@ -80,6 +81,7 @@ ...@@ -80,6 +81,7 @@
this.backgroundWorker2 = new System.ComponentModel.BackgroundWorker(); this.backgroundWorker2 = new System.ComponentModel.BackgroundWorker();
this.timerWorker = new System.Windows.Forms.Timer(this.components); this.timerWorker = new System.Windows.Forms.Timer(this.components);
this.timer2 = new System.Windows.Forms.Timer(this.components); this.timer2 = new System.Windows.Forms.Timer(this.components);
this.userControl_PopUp1 = new WindowsFormsControlLibrary_PopUp.UserControl_PopUp();
this.menuStrip.SuspendLayout(); this.menuStrip.SuspendLayout();
this.statusStrip.SuspendLayout(); this.statusStrip.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
...@@ -348,6 +350,7 @@ ...@@ -348,6 +350,7 @@
this.statusStrip.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.statusStrip.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.toolStripStatusLabelusertime, this.toolStripStatusLabelusertime,
this.toolStripStatusLabelText, this.toolStripStatusLabelText,
this.tool_CounterControlStatus,
this.HmiStatus, this.HmiStatus,
this.AdjustStat, this.AdjustStat,
this.workProgress, this.workProgress,
...@@ -368,6 +371,12 @@ ...@@ -368,6 +371,12 @@
this.toolStripStatusLabelText.BorderSides = ((System.Windows.Forms.ToolStripStatusLabelBorderSides)((System.Windows.Forms.ToolStripStatusLabelBorderSides.Left | System.Windows.Forms.ToolStripStatusLabelBorderSides.Right))); this.toolStripStatusLabelText.BorderSides = ((System.Windows.Forms.ToolStripStatusLabelBorderSides)((System.Windows.Forms.ToolStripStatusLabelBorderSides.Left | System.Windows.Forms.ToolStripStatusLabelBorderSides.Right)));
this.toolStripStatusLabelText.Name = "toolStripStatusLabelText"; this.toolStripStatusLabelText.Name = "toolStripStatusLabelText";
// //
// tool_CounterControlStatus
//
resources.ApplyResources(this.tool_CounterControlStatus, "tool_CounterControlStatus");
this.tool_CounterControlStatus.BorderSides = ((System.Windows.Forms.ToolStripStatusLabelBorderSides)((System.Windows.Forms.ToolStripStatusLabelBorderSides.Left | System.Windows.Forms.ToolStripStatusLabelBorderSides.Right)));
this.tool_CounterControlStatus.Name = "tool_CounterControlStatus";
//
// HmiStatus // HmiStatus
// //
resources.ApplyResources(this.HmiStatus, "HmiStatus"); resources.ApplyResources(this.HmiStatus, "HmiStatus");
...@@ -425,10 +434,17 @@ ...@@ -425,10 +434,17 @@
this.timer2.Interval = 1000; this.timer2.Interval = 1000;
this.timer2.Tick += new System.EventHandler(this.timer2_Tick); this.timer2.Tick += new System.EventHandler(this.timer2_Tick);
// //
// userControl_PopUp1
//
resources.ApplyResources(this.userControl_PopUp1, "userControl_PopUp1");
this.userControl_PopUp1.Name = "userControl_PopUp1";
this.userControl_PopUp1.PopUpMsg = "cs2";
//
// MDIBase // MDIBase
// //
resources.ApplyResources(this, "$this"); resources.ApplyResources(this, "$this");
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.userControl_PopUp1);
this.Controls.Add(this.statusStrip); this.Controls.Add(this.statusStrip);
this.Controls.Add(this.menuStrip); this.Controls.Add(this.menuStrip);
this.DoubleBuffered = true; this.DoubleBuffered = true;
...@@ -499,6 +515,8 @@ ...@@ -499,6 +515,8 @@
private System.Windows.Forms.ToolStripProgressBar workProgress; private System.Windows.Forms.ToolStripProgressBar workProgress;
private System.Windows.Forms.ToolStripStatusLabel MacToolStripStatusLabel1; private System.Windows.Forms.ToolStripStatusLabel MacToolStripStatusLabel1;
private System.Windows.Forms.ToolStripMenuItem sysconfigpSec; private System.Windows.Forms.ToolStripMenuItem sysconfigpSec;
private System.Windows.Forms.ToolStripStatusLabel tool_CounterControlStatus;
private WindowsFormsControlLibrary_PopUp.UserControl_PopUp userControl_PopUp1;
} }
} }
......
This diff is collapsed.
This diff is collapsed.
...@@ -29,28 +29,42 @@ ...@@ -29,28 +29,42 @@
private void InitializeComponent() private void InitializeComponent()
{ {
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm)); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm));
this.userControl_PopUp1 = new WindowsFormsControlLibrary_PopUp.UserControl_PopUp();
this.SuspendLayout(); this.SuspendLayout();
// //
// userControl_PopUp1
//
this.userControl_PopUp1.Location = new System.Drawing.Point(12, 487);
this.userControl_PopUp1.Name = "userControl_PopUp1";
this.userControl_PopUp1.PopUpMsg = "cs2";
this.userControl_PopUp1.Size = new System.Drawing.Size(251, 70);
this.userControl_PopUp1.TabIndex = 7;
this.userControl_PopUp1.Visible = false;
//
// MainForm // MainForm
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.White; this.BackColor = System.Drawing.Color.White;
this.ClientSize = new System.Drawing.Size(1008, 730); this.ClientSize = new System.Drawing.Size(1008, 730);
this.Controls.Add(this.userControl_PopUp1);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Name = "MainForm"; this.Name = "MainForm";
// this.Text = "-1.5.9 用户界面"; this.Text = "";
this.Controls.SetChildIndex(this.userControl_PopUp1, 0);
this.ResumeLayout(false); this.ResumeLayout(false);
this.PerformLayout(); this.PerformLayout();
} }
private WindowsFormsControlLibrary_PopUp.UserControl_PopUp userControl_PopUp1;
#endregion #endregion
//private System.Windows.Forms.TabPage tabPage1; //private System.Windows.Forms.TabPage tabPage1;
//private System.Windows.Forms.TabPage tabPage2; //private System.Windows.Forms.TabPage tabPage2;
// private GcDevicePc.statuswindow gcstatuswindow; // private GcDevicePc.statuswindow gcstatuswindow;
} }
......
...@@ -8,6 +8,8 @@ using System.Diagnostics; ...@@ -8,6 +8,8 @@ using System.Diagnostics;
using GcDevicePc.IniParam; using GcDevicePc.IniParam;
using System.IO; using System.IO;
using System.Windows.Forms; using System.Windows.Forms;
using GcDevicePc.Common;
namespace GcDevicePc.ProThread namespace GcDevicePc.ProThread
{ {
class CKvocUpdata class CKvocUpdata
...@@ -71,7 +73,7 @@ namespace GcDevicePc.ProThread ...@@ -71,7 +73,7 @@ namespace GcDevicePc.ProThread
{ {
CurveDisPlay.curdisp.cleardata(); CurveDisPlay.curdisp.cleardata();
globaldata.starttimer = ((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[0]).ctimer; globaldata.starttimer = ((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[0]).ctimer;
time = 0; time = 0;//表示开始计时
globaldata.startimerIsSet1 = false; globaldata.startimerIsSet1 = false;
}//是否清空绘图的标志,外部触发(物理按钮和无源输入)不会更新这个状态为true;或者累计时长大于600min }//是否清空绘图的标志,外部触发(物理按钮和无源输入)不会更新这个状态为true;或者累计时长大于600min
...@@ -82,6 +84,7 @@ namespace GcDevicePc.ProThread ...@@ -82,6 +84,7 @@ namespace GcDevicePc.ProThread
#if (debug) #if (debug)
st.Start(); //计时开始 st.Start(); //计时开始
#endif #endif
for (int i = 0; i < globaldata.m_signalbuffer.Draw_Port.Count; i++) for (int i = 0; i < globaldata.m_signalbuffer.Draw_Port.Count; i++)
{ {
if (globaldata.MethodRun_Statue == 4 || globaldata.MethodRun_Statue == 5) if (globaldata.MethodRun_Statue == 4 || globaldata.MethodRun_Statue == 5)
...@@ -97,7 +100,7 @@ namespace GcDevicePc.ProThread ...@@ -97,7 +100,7 @@ namespace GcDevicePc.ProThread
{ {
CKVocAnalyzer.GlobalCKV.debugwork = 4; CKVocAnalyzer.GlobalCKV.debugwork = 4;
isstart = 2; isstart = 2;
time = 0; time = 0;//重新开始计时
drbool = false; drbool = false;
globaldata.starttimer = globaldata.m_hmibuffer.gcinfo.NowStartTime; globaldata.starttimer = globaldata.m_hmibuffer.gcinfo.NowStartTime;
NowTimeOld = globaldata.m_hmibuffer.gcinfo.NowStartTime; NowTimeOld = globaldata.m_hmibuffer.gcinfo.NowStartTime;
...@@ -109,7 +112,7 @@ namespace GcDevicePc.ProThread ...@@ -109,7 +112,7 @@ namespace GcDevicePc.ProThread
CurveDisPlay.curdisp.SetAxisX( CurveDisPlay.curdisp.SetAxisX(
(double)globaldata.m_dpbuffer.ShowList.showtime (double)globaldata.m_dpbuffer.ShowList.showtime
.alltime / 60.0); .alltime / 60.0);
time = 0; time = 0;//重新开始计时
drbool = false; drbool = false;
globaldata.starttimer = globaldata.m_hmibuffer.gcinfo.NowStartTime; globaldata.starttimer = globaldata.m_hmibuffer.gcinfo.NowStartTime;
NowTimeOld = globaldata.m_hmibuffer.gcinfo.NowStartTime; NowTimeOld = globaldata.m_hmibuffer.gcinfo.NowStartTime;
...@@ -198,14 +201,12 @@ namespace GcDevicePc.ProThread ...@@ -198,14 +201,12 @@ namespace GcDevicePc.ProThread
if (time > 0xFFFF) if (time > 0xFFFF)
{ {
// Console.WriteLine("data err"); // Console.WriteLine("data err");
File.AppendAllText(@"./timeErr.txt", time + "\t");//异常time Log.DebugInfo("前检测异常time:"+time );
// File.AppendAllText(@"./timeErr.txt", );//异常time
} }
//time += 0.00083; //time += 0.00083;
globaldata.starttimer = globaldata.starttimer =((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]) .ctimer;
((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]) value = (((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]) .cdata * 1000.0f);
.ctimer;
value = (((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i])
.cdata * 1000.0f);
if (time < 600) if (time < 600)
{ {
listPoint.Add(new double[] { Math.Round(time, 4), Math.Round(value, 6) }); listPoint.Add(new double[] { Math.Round(time, 4), Math.Round(value, 6) });
...@@ -216,7 +217,7 @@ namespace GcDevicePc.ProThread ...@@ -216,7 +217,7 @@ namespace GcDevicePc.ProThread
Math.Round(value, 6) Math.Round(value, 6)
}); });
} }
//时间判断终点 //时间判断终点
// if ((globaldata.MethodRun_Statue == 4 || globaldata.MethodRun_Statue == 5)) // if ((globaldata.MethodRun_Statue == 4 || globaldata.MethodRun_Statue == 5))
if (globaldata.m_hmibuffer.gcinfo.methodstatus < 4 || if (globaldata.m_hmibuffer.gcinfo.methodstatus < 4 ||
...@@ -230,6 +231,7 @@ namespace GcDevicePc.ProThread ...@@ -230,6 +231,7 @@ namespace GcDevicePc.ProThread
.ctimer) && isstart == 2) .ctimer) && isstart == 2)
{ {
drbool = true; drbool = true;
Log.DebugInfo("前检测终点判断,更改drbool为true");//debug
isstart = 0; isstart = 0;
break; break;
} }
...@@ -237,6 +239,7 @@ namespace GcDevicePc.ProThread ...@@ -237,6 +239,7 @@ namespace GcDevicePc.ProThread
//已停止(运行)状态 //已停止(运行)状态
if (bBeforeStopFlag != bNowStopFlag) if (bBeforeStopFlag != bNowStopFlag)
{ {
Log.DebugInfo("前检测已停止状态,更改drbool为true");//debug
if (drbool == false && bBeforeStopFlag == false && bNowStopFlag == true) if (drbool == false && bBeforeStopFlag == false && bNowStopFlag == true)
{ {
drbool = true; drbool = true;
...@@ -247,9 +250,11 @@ namespace GcDevicePc.ProThread ...@@ -247,9 +250,11 @@ namespace GcDevicePc.ProThread
} }
} }
else else
globaldata.starttimer = {
((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]) Log.DebugInfo("前检测未满足重置条件"+"---globaldata.starttimer="+globaldata.starttimer+"---((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]).ctimer="+((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]).ctimer);//debug
.ctimer; globaldata.starttimer = ((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]).ctimer;
}
// Log.DebugInfo("前检测未满足重置条件"+"---globaldata.starttimer="+globaldata.starttimer+"---((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]).ctimer="+((SignalBuffer.Channel_XY)globaldata.m_signalbuffer.Draw_Port[i]).ctimer);//测试能否打印
} }
//读取数据完毕 //读取数据完毕
// Console.WriteLine(globaldata.m_signalbuffer.Draw_Port.Count); // Console.WriteLine(globaldata.m_signalbuffer.Draw_Port.Count);
...@@ -284,6 +289,7 @@ namespace GcDevicePc.ProThread ...@@ -284,6 +289,7 @@ namespace GcDevicePc.ProThread
//lr.Clear(); //lr.Clear();
if (drbool) if (drbool)
{ {
Log.DebugInfo("前检测进入时间戳重置");//debug
time = 0; time = 0;
CurveDisPlay.curdisp.cleardata(); CurveDisPlay.curdisp.cleardata();
} }
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
using SpaceM; using GcDevicePc.DrawUI;
using SpaceM;
using System; using System;
using System.Globalization; using System.Globalization;
using System.Threading; using System.Threading;
...@@ -29,6 +30,8 @@ namespace GcDevicePc ...@@ -29,6 +30,8 @@ namespace GcDevicePc
Thread.CurrentThread.CurrentUICulture = CultureInfo.GetCultureInfo("en"); Thread.CurrentThread.CurrentUICulture = CultureInfo.GetCultureInfo("en");
} }
Application.Run(new StartForm()); Application.Run(new StartForm());
// Application.Run(new TempTrend());
mutex.ReleaseMutex(); mutex.ReleaseMutex();
} }
else else
......
...@@ -12,7 +12,7 @@ namespace GcDevicePc.Properties { ...@@ -12,7 +12,7 @@ namespace GcDevicePc.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "12.0.0.0")] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.3.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
......
C1.Win.C1Input.C1CheckBox, C1.Win.C1Input.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=7e7ff60f0c214f9a
C1.Win.C1Command.C1CommandDock, C1.Win.C1Command.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=e808566f358766d8
C1.Win.C1Input.C1Button, C1.Win.C1Input.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=7e7ff60f0c214f9a
C1.Win.C1Chart.C1Chart, C1.Win.C1Chart.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=a22e16972c085838 C1.Win.C1Chart.C1Chart, C1.Win.C1Chart.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=a22e16972c085838
C1.Win.C1Input.C1SplitButton, C1.Win.C1Input.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=7e7ff60f0c214f9a
C1.Win.C1Chart3D.C1Chart3D, C1.Win.C1Chart3D.2, Version=2.0.20201.416, Culture=neutral, PublicKeyToken=a22e16972c085838
C1.C1DataExtender.C1DataViewSet, C1.C1DataExtender.2, Version=2.0.20113.81, Culture=neutral, PublicKeyToken=7c4b5683f80b910e
...@@ -28,6 +28,7 @@ namespace GcDevicePc ...@@ -28,6 +28,7 @@ namespace GcDevicePc
private static Thread _tPreload; private static Thread _tPreload;
private static Thread SearchHMIThread; private static Thread SearchHMIThread;
private MainForm _mMainForm; private MainForm _mMainForm;
// private MDIBase _mMainForm;
private bool bBindOK = false; private bool bBindOK = false;
private bool bStartSearchOK = false; private bool bStartSearchOK = false;
private bool bWaitOver = false; private bool bWaitOver = false;
...@@ -46,10 +47,11 @@ namespace GcDevicePc ...@@ -46,10 +47,11 @@ namespace GcDevicePc
{ {
//如果当前已经完全不透明,则停止timer //如果当前已经完全不透明,则停止timer
_opacityTimer.Stop(); _opacityTimer.Stop();
System.Timers.Timer t = new System.Timers.Timer(StayTime); //设置时间间隔为5秒 // System.Timers.Timer t = new System.Timers.Timer(StayTime);
t.Elapsed += new System.Timers.ElapsedEventHandler(Timer_TimesUp); // t.Elapsed += new System.Timers.ElapsedEventHandler(Timer_TimesUp);
t.AutoReset = false; //每到指定时间Elapsed事件是触发一次(false),还是一直触发(true) // t.AutoReset = false; //每到指定时间Elapsed事件是触发一次(false),还是一直触发(true)
t.Start(); // t.Start();
Timer_TimesUp();
} }
} }
...@@ -80,7 +82,7 @@ namespace GcDevicePc ...@@ -80,7 +82,7 @@ namespace GcDevicePc
this.Opacity = this._mCurrentOpacity; this.Opacity = this._mCurrentOpacity;
} }
private void Timer_TimesUp(object sender, System.Timers.ElapsedEventArgs e) private void Timer_TimesUp()
{ {
_opacityTimer = new System.Timers.Timer(); _opacityTimer = new System.Timers.Timer();
_opacityTimer.Interval = 30; _opacityTimer.Interval = 30;
...@@ -162,6 +164,7 @@ namespace GcDevicePc ...@@ -162,6 +164,7 @@ namespace GcDevicePc
{ {
_tPreload.Join(); _tPreload.Join();
_mMainForm = new MainForm(); _mMainForm = new MainForm();
//_mMainForm = new MDIBase();
StartFormbgWorker.CancelAsync(); StartFormbgWorker.CancelAsync();
Hide(); Hide();
_mMainForm.Show(); _mMainForm.Show();
...@@ -355,7 +358,7 @@ namespace GcDevicePc ...@@ -355,7 +358,7 @@ namespace GcDevicePc
{ {
// Thread.Sleep(10000); //延时10S等待HMI开机,改为用户指定(选项) // Thread.Sleep(10000); //延时10S等待HMI开机,改为用户指定(选项)
HMISearch mysearch = new HMISearch(globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.hmimac); HMISearch mysearch = new HMISearch(globaldata.m_pcbuffer.gcpcinfo.pcworkinfo.hmimac);
mysearch.bSearch_Bind_HMI(); // mysearch.bSearch_Bind_HMI();
bStartSearchOK = true; bStartSearchOK = true;
mysearch.ThStart(); mysearch.ThStart();
// mysearch.ThStart(); // mysearch.ThStart();
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的一般信息由以下
// 控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle("SamplerCounterControl")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("SamplerCounterControl")]
[assembly: AssemblyCopyright("Copyright © 2022")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// 将 ComVisible 设置为 false 会使此程序集中的类型
//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型
//请将此类型的 ComVisible 特性设置为 true。
[assembly: ComVisible(false)]
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
[assembly: Guid("ad1c51cd-86b5-416b-9708-0ea7c2414edc")]
// 程序集的版本信息由下列四个值组成:
//
// 主版本
// 次版本
// 生成号
// 修订号
//
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
//通过使用 "*",如下所示:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
[SYSINFO]
ECOUNT=1
[ENTITY0]
ECC=Default,0,0,0,0,0,0,0,0,0,0,,1000,,,0,0,0,0,0
ECCD0=1,Ũ1,0,,0,,1
ECCD0_Orig0=0,uV*sec,Default,...\Default.raw
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment