wangxinhui
2024-11-06 8f392cc88b0768b74efca3b68785cf5aa1c38e70
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
using HslCommunication;
using Quartz;
using System;
using System.Threading.Tasks;
using WIDESEA_WCS.Jobs;
using WIDESEA_WCS.WCSClient;
 
namespace WIDESEA_WCS
{
    /// <summary>
    /// 负极涂布下料任务
    /// </summary>
    [DisallowConcurrentExecution]
    public class F_TBSB_DownTaskJob : JobBase, IJob
    {
        public Task Execute(IJobExecutionContext context)
        {
            try
            {
                ExecuteJob(context, DoAction);
            }
            catch { }
            return Task.FromResult(string.Empty);
        }
 
 
        private void DoAction(IJobExecutionContext context)
        {
            try
            {
                StackerExecutor.F_TBSB_DownTask(); //负极涂布下料任务
                PLCClient agvplcF = WCSService.Clients.Find(v => v.PLCName == "负极AGV调度");
                if (agvplcF != null)
                {
                    OperateResult W_AGV_XTF = agvplcF.SiemensPLCClient.SiemensS7NetClient.Write("DB1000.306.0", true);
                }
            }
            catch (Exception) { }
        }
    }
}