#
DELL
2025-09-18 3d10ceed030be39cc520aa453e36e695b1638b81
#
1个文件已修改
48 ■■■■■ 已修改文件
src/main/java/com/zy/core/thread/impl/NyLiftThread.java 48 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/zy/core/thread/impl/NyLiftThread.java
@@ -114,60 +114,48 @@
        if (commandObj.getInteger("mode") == 3) {
            //取放货
            short[] array = new short[4];
            array[0] = commandObj.getShort("taskNO");//任务号
            array[1] = commandObj.getShort("mode");//任务模式
            array[2] = commandObj.getShort("pick");//取货数据
            array[3] = commandObj.getShort("put");//放货数据
            array[0] = 1;//任务类型
            array[1] = commandObj.getShort("pick");//源站
            array[2] = commandObj.getShort("put");//目标站
            array[3] = commandObj.getShort("taskNo");//任务号
            resultData.put("commandData", array);
            result = siemensS7Net.Write("DB103.0", array);
            result = siemensS7Net.Write("DB83.0", array);
            if (result.IsSuccess) {
                result2 = siemensS7Net.Write("DB103.8", (short) 1);
                if (result2.IsSuccess) {
                    resultData.put("result", "success");
                }
                resultData.put("result", "success");
            }
            resultData.put("commandResult1", JSON.toJSONString(result));
            resultData.put("commandResult2", JSON.toJSONString(result2));
        } else if (commandObj.getInteger("mode") == 4) {
            //小车换层
            short[] array = new short[4];
            array[0] = commandObj.getShort("taskNO");//任务号
            array[1] = commandObj.getShort("mode");//任务模式
            array[2] = commandObj.getShort("pick");//取货数据
            array[3] = commandObj.getShort("put");//放货数据
            array[0] = 2;//任务类型
            array[1] = commandObj.getShort("pick");//源站
            array[2] = commandObj.getShort("put");//目标站
            array[3] = commandObj.getShort("taskNo");//任务号
            resultData.put("commandData", array);
            result = siemensS7Net.Write("DB103.0", array);
            result = siemensS7Net.Write("DB83.0", array);
            if (result.IsSuccess) {
                result2 = siemensS7Net.Write("DB103.8", (short) 1);
                if (result2.IsSuccess) {
                    resultData.put("result", "success");
                }
                resultData.put("result", "success");
            }
            resultData.put("commandResult1", JSON.toJSONString(result));
            resultData.put("commandResult2", JSON.toJSONString(result2));
        } else if (commandObj.getInteger("mode") == 5) {
            //提升机移动
            short[] array = new short[4];
            array[0] = commandObj.getShort("taskNO");//任务号
            array[1] = commandObj.getShort("mode");//任务模式
            array[2] = commandObj.getShort("pick");//取货数据
            array[3] = commandObj.getShort("put");//放货数据
            array[0] = 2;//任务类型
            array[1] = commandObj.getShort("pick");//源站
            array[2] = commandObj.getShort("put");//目标站
            array[3] = commandObj.getShort("taskNo");//任务号
            resultData.put("commandData", array);
            result = siemensS7Net.Write("DB103.0", array);
            result = siemensS7Net.Write("DB83.0", array);
            if (result.IsSuccess) {
                result2 = siemensS7Net.Write("DB103.8", (short) 1);
                if (result2.IsSuccess) {
                    resultData.put("result", "success");
                }
                resultData.put("result", "success");
            }
            resultData.put("commandResult1", JSON.toJSONString(result));
            resultData.put("commandResult2", JSON.toJSONString(result2));
        } else if (commandObj.getInteger("mode") == 9996) {
            //复位
            short[] array = new short[1];