修改PLC信号读取

This commit is contained in:
liuhanqing
2025-11-21 10:47:05 +08:00
parent e710639b11
commit 7b1b773030
2 changed files with 3 additions and 1 deletions

View File

@@ -40,6 +40,8 @@ public class DeviceSsj extends BaseEntity
@Excel(name = "设备IP")
private String ipAddress;
private String port;
/** PLC读取地址 */
@Excel(name = "PLC读取地址")
private String plcDbReadAddress;

View File

@@ -93,7 +93,7 @@ public class ScheduleThread {
//plc输送机读取线程
PlcSsjRead plcSsjRead = new PlcSsjRead(ssjList, new PlcConnectInfo("127.0.0.1", 102));
PlcSsjRead plcSsjRead = new PlcSsjRead(ssjList, new PlcConnectInfo(deviceSsjs.get(0).getIpAddress(), Convert.toInt(deviceSsjs.get(0).getPort())));
Thread plcSsjReadThread = new Thread(plcSsjRead);
plcSsjReadCustomThread = new CustomThread<PlcSsjRead>(plcSsjReadThread, plcSsjRead);