| | |
| | | { |
| | | if (action) |
| | | { |
| | | int[] num = new int[3] {1,1,1}; |
| | | int[] num = new int[3] {1,0,1}; |
| | | var writeRes = OITcpHelper.RegisterWriteOutPutMulti(new OITcpHelper.RegisterWriteOutPutModelMulti |
| | | { |
| | | host = plc.ip, |
| | |
| | | { |
| | | //推送小车进入 |
| | | TSHelper.GoToAGV(taskNo, 10, 3); |
| | | writeRes = OITcpHelper.RegisterWriteOutPut(new OITcpHelper.RegisterWriteOutPutModel |
| | | |
| | | int[] num1 = new int[2] { 1, 2}; |
| | | writeRes = OITcpHelper.RegisterWriteOutPutMulti(new OITcpHelper.RegisterWriteOutPutModelMulti |
| | | { |
| | | host = plc.ip, |
| | | addr = plc.writeAddr + 2, |
| | | data = 2, |
| | | addr = plc.writeAddr + 1, |
| | | data = num1, |
| | | port = plc.port |
| | | }); |
| | | CMMLog.Debug($"写入设备{plc.location}通道{plc.writeAddr + 2}里面数据为2."); |
| | | |
| | | //writeRes = OITcpHelper.RegisterWriteOutPut(new OITcpHelper.RegisterWriteOutPutModel |
| | | //{ |
| | | // host = plc.ip, |
| | | // addr = plc.writeAddr + 2, |
| | | // data = 2, |
| | | // port = plc.port |
| | | //}); |
| | | CMMLog.Debug($"写入设备{plc.location}通道{plc.writeAddr + 1}里面数据为{JsonConvert.SerializeObject(num1)}."); |
| | | } |
| | | } |
| | | } |