/// <summary> /// 执行所有任务 /// </summary> void ExecuteAllTask() { #region #1汽车机械采样机 EquCarJXSamplerDAO carJXSamplerDAO1 = new EquCarJXSamplerDAO(GlobalVars.MachineCode_QCJXCYJ_1, new DapperDber.Dbs.SqlServerDb.SqlServerDapperDber(CommonDAO.GetInstance().GetCommonAppletConfigString("#1汽车机械采样机接口连接字符串"))); taskSimpleScheduler.StartNewTask("#1汽车机械采样机-快速同步", () => { carJXSamplerDAO1.SyncBarrel(this.rTxtOutputer.Output); carJXSamplerDAO1.SyncQCJXCYJError(this.rTxtOutputer.Output); carJXSamplerDAO1.SyncSignal(this.rTxtOutputer.Output); }, 2000, OutputError); this.taskSimpleScheduler.StartNewTask("#1汽车机械采样机-上位机心跳", () => { carJXSamplerDAO1.SyncHeartbeatSignal(); }, 30000, OutputError); #endregion #region #2汽车机械采样机 EquCarJXSamplerDAO carJXSamplerDAO2 = new EquCarJXSamplerDAO(GlobalVars.MachineCode_QCJXCYJ_2, new DapperDber.Dbs.SqlServerDb.SqlServerDapperDber(CommonDAO.GetInstance().GetCommonAppletConfigString("#2汽车机械采样机接口连接字符串"))); taskSimpleScheduler.StartNewTask("#2汽车机械采样机-快速同步", () => { carJXSamplerDAO2.SyncBarrel(this.rTxtOutputer.Output); carJXSamplerDAO2.SyncQCJXCYJError(this.rTxtOutputer.Output); carJXSamplerDAO2.SyncSignal(this.rTxtOutputer.Output); }, 2000, OutputError); this.taskSimpleScheduler.StartNewTask("#2汽车机械采样机-上位机心跳", () => { carJXSamplerDAO2.SyncHeartbeatSignal(); }, 30000, OutputError); #endregion #region #3汽车机械采样机 EquCarJXSamplerDAO carJXSamplerDAO3 = new EquCarJXSamplerDAO(GlobalVars.MachineCode_QCJXCYJ_3, new DapperDber.Dbs.SqlServerDb.SqlServerDapperDber(CommonDAO.GetInstance().GetCommonAppletConfigString("#3汽车机械采样机接口连接字符串"))); taskSimpleScheduler.StartNewTask("#3汽车机械采样机-快速同步", () => { carJXSamplerDAO3.SyncBarrel(this.rTxtOutputer.Output); carJXSamplerDAO3.SyncQCJXCYJError(this.rTxtOutputer.Output); carJXSamplerDAO3.SyncSignal(this.rTxtOutputer.Output); }, 2000, OutputError); this.taskSimpleScheduler.StartNewTask("#3汽车机械采样机-上位机心跳", () => { carJXSamplerDAO3.SyncHeartbeatSignal(); }, 30000, OutputError); #endregion }
/// <summary> /// 执行所有任务 /// </summary> void ExecuteAllTask() { #region #3汽车机械采样机 EquCarJXSamplerDAO carJXSamplerDAO3 = new EquCarJXSamplerDAO(GlobalVars.MachineCode_QCJXCYJ_3, new DapperDber.Dbs.SqlServerDb.SqlServerDapperDber(CommonDAO.GetInstance().GetCommonAppletConfigString("#3汽车机械采样机接口连接字符串"))); taskSimpleScheduler.StartNewTask("#3汽车机械采样机-快速同步", () => { carJXSamplerDAO3.SyncBarrel(this.rTxtOutputer.Output); carJXSamplerDAO3.SyncSampleCmd(this.rTxtOutputer.Output); //carJXSamplerDAO3.SyncJXCYControlUnloadCMD(this.rTxtOutputer.Output); carJXSamplerDAO3.SyncUnloadResult(this.rTxtOutputer.Output); carJXSamplerDAO3.SyncQCJXCYJError(this.rTxtOutputer.Output); carJXSamplerDAO3.SyncSignal(this.rTxtOutputer.Output); }, 2000, OutputError); this.taskSimpleScheduler.StartNewTask("#3汽车机械采样机-上位机心跳", () => { carJXSamplerDAO3.SyncHeartbeatSignal(); }, 30000, OutputError); #endregion #region #4汽车机械采样机 EquCarJXSamplerDAO carJXSamplerDAO4 = new EquCarJXSamplerDAO(GlobalVars.MachineCode_QCJXCYJ_4, new DapperDber.Dbs.SqlServerDb.SqlServerDapperDber(CommonDAO.GetInstance().GetCommonAppletConfigString("#4汽车机械采样机接口连接字符串"))); taskSimpleScheduler.StartNewTask("#4汽车机械采样机-快速同步", () => { carJXSamplerDAO4.SyncBarrel(this.rTxtOutputer.Output); carJXSamplerDAO4.SyncSampleCmd(this.rTxtOutputer.Output); //carJXSamplerDAO3.SyncJXCYControlUnloadCMD(this.rTxtOutputer.Output); carJXSamplerDAO4.SyncUnloadResult(this.rTxtOutputer.Output); carJXSamplerDAO4.SyncQCJXCYJError(this.rTxtOutputer.Output); carJXSamplerDAO4.SyncSignal(this.rTxtOutputer.Output); }, 2000, OutputError); this.taskSimpleScheduler.StartNewTask("#4汽车机械采样机-上位机心跳", () => { carJXSamplerDAO4.SyncHeartbeatSignal(); }, 30000, OutputError); #endregion #region #5汽车机械采样机 EquCarJXSamplerDAO carJXSamplerDAO5 = new EquCarJXSamplerDAO(GlobalVars.MachineCode_QCJXCYJ_5, new DapperDber.Dbs.SqlServerDb.SqlServerDapperDber(CommonDAO.GetInstance().GetCommonAppletConfigString("#5汽车机械采样机接口连接字符串"))); taskSimpleScheduler.StartNewTask("#5汽车机械采样机-快速同步", () => { carJXSamplerDAO5.SyncBarrel(this.rTxtOutputer.Output); carJXSamplerDAO5.SyncSampleCmd(this.rTxtOutputer.Output); //carJXSamplerDAO1.SyncJXCYControlUnloadCMD(this.rTxtOutputer.Output); carJXSamplerDAO5.SyncUnloadResult(this.rTxtOutputer.Output); carJXSamplerDAO5.SyncQCJXCYJError(this.rTxtOutputer.Output); carJXSamplerDAO5.SyncSignal(this.rTxtOutputer.Output); }, 2000, OutputError); this.taskSimpleScheduler.StartNewTask("#5汽车机械采样机-上位机心跳", () => { carJXSamplerDAO5.SyncHeartbeatSignal(); }, 30000, OutputError); #endregion }