| | |
| | |
|
| | | import cn.hutool.json.JSONObject;
|
| | |
|
| | | import java.io.IOException;
|
| | | import java.sql.SQLException;
|
| | | import java.util.ArrayList;
|
| | | import java.util.Arrays;
|
| | | import java.util.List;
|
| | |
|
| | | import org.springframework.beans.factory.annotation.Autowired;
|
| | |
| | | private JdbcConnections dbserve;
|
| | | // 出片队列是否允许出片
|
| | | public static Boolean isAllowQueue = true;
|
| | | public static Boolean isAllowReordering = true;
|
| | | // 铝框id
|
| | | public static String FrameNo="";
|
| | | // 是否需要手动确认玻璃
|
| | | public static Boolean isConfirm = false;
|
| | |
|
| | | private Configuration config;
|
| | |
|
| | |
|
| | |
|
| | |
|
| | | public Plchome() throws IOException {
|
| | | config = new Configuration("config.properties");
|
| | | }
|
| | |
|
| | | // public static Map b=new HashMap<>();
|
| | | // b.put()
|
| | |
| | | // 获取出片队列信息
|
| | | List<Out_slice> listoutslice = outSliceServive.SelectProductionqueue();
|
| | | jsonObject.append("listoutslice", listoutslice);
|
| | | // 获取当前出片队列状态
|
| | | // 获取当前出片队列出片状态
|
| | | jsonObject.append("isAllowQueue", Plchome.isAllowQueue);
|
| | | // 获取当前出片队列调序状态
|
| | | jsonObject.append("isAllowReordering", Plchome.isAllowReordering);
|
| | | // 是否需要人工确认上片玻璃
|
| | | jsonObject.append("isConfirm", isConfirm);
|
| | |
|
| | |
| | | jsonObject.append("emergencystop", emergencystop);
|
| | | }
|
| | |
|
| | | //终止继续按钮
|
| | | List<String> niuanaddressList3 = Arrays.asList(config.getProperty("Parameter2.stop").split(","));
|
| | | List<Boolean> anniuread = S7control.getinstance().readBits(niuanaddressList3);
|
| | |
|
| | | short[] anniuparams = new short[anniuread.size()];
|
| | | for (int i = 0; i < anniuread.size(); i++) {
|
| | | boolean value = anniuread.get(i);
|
| | | anniuparams[i] = value ? (short) 1 : (short) 0;
|
| | | }
|
| | | jsonObject.append("Abort", anniuparams);
|
| | | // 铝框线交互
|
| | |
|
| | | // //铝框id请求字
|