自动化立体仓库 - WCS系统
#
Junjie
2023-09-18 b7cbb2a30125285eade6a26c9f3d39363c65481c
#
1个文件已修改
16 ■■■■■ 已修改文件
src/main/java/com/zy/core/thread/SiemensDevpThread.java 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/zy/core/thread/SiemensDevpThread.java
@@ -43,9 +43,15 @@
    private short heartBeatVal = 1;
    private int barcodeSize = 1;
    public static final ArrayList<Integer> staNos = new ArrayList<Integer>() {{
        add(100);add(101);add(102);
        add(103);add(104);add(105);
        add(106);add(107);add(108);
        add(100);add(101);
        add(102);add(103);
        add(104);add(105);
        add(200);add(201);
        add(202);add(203);
        add(204);add(205);
        add(300);add(301);
        add(340);add(341);
        add(345);add(346);
    }};
    public static final ArrayList<Integer> outInStaNos = new ArrayList<Integer>() {{
@@ -126,7 +132,7 @@
     * 读取状态 ====> 整块plc
     */
    private void read() throws InterruptedException {
        OperateResultExOne<byte[]> result = siemensS7Net.Read("DB100.0", (short) (staNos.size()*4));
        OperateResultExOne<byte[]> result = siemensS7Net.Read("DB1000.0", (short) (staNos.size()*4));
        if (result.IsSuccess) {
            for (int i = 0; i < staNos.size(); i++) {
                Integer siteId = staNos.get(i); // 站点编号
@@ -141,7 +147,7 @@
            }
        }
        Thread.sleep(200);
        OperateResultExOne<byte[]> result1 = siemensS7Net.Read("DB101.0", (short) (staNos.size()));
        OperateResultExOne<byte[]> result1 = siemensS7Net.Read("DB1001.0", (short) (staNos.size()));
        if (result1.IsSuccess) {
            for (int i = 0; i < staNos.size(); i++) {
                Integer siteId = staNos.get(i); // 站点编号