| | |
| | | // // TODO: handle exception
|
| | | // }
|
| | |
|
| | | if (S7control.getinstance().CheckConnected() == true) {
|
| | | // if (S7control.getinstance().CheckConnected() == true) {
|
| | | // 获取当前扫码方式
|
| | | List<Short> Scanningmethod = S7control.getinstance().ReadWord("DB103.255", 1);
|
| | |
|
| | | List<Boolean> Scanningmethods = S7control.getinstance().ReadBits("DB101.11.4", 1);
|
| | | if (Scanningmethods != null) {
|
| | | for (Boolean Scanningmethod : Scanningmethods) {
|
| | | jsonObject.append("Scanningmethod", Scanningmethod);
|
| | | }
|
| | | }
|
| | |
|
| | | String CurrrentGlassId = spianService.queGlassid("DB103.256", 14).toString();
|
| | | jsonObject.append("CurrrentGlassId", CurrrentGlassId);
|
| | |
|
| | | // 获取D01-D06,A01,A02,B01,B02状态
|
| | | List<Short> DeviceList = S7control.getinstance().ReadWord("DB103.0", 10);
|
| | | jsonObject.append("DeviceList", DeviceList);
|
| | | // 获取D01-D06,A01,A02,B01,B02玻璃id
|
| | | List<String> GlassIdList = new ArrayList<String>();
|
| | | GlassIdList.add(spianService.queGlassid("DB103.40", 14).toString());
|
| | | GlassIdList.add(spianService.queGlassid("DB103.44", 14).toString());
|
| | | GlassIdList.add(spianService.queGlassid("DB103.58", 14).toString());
|
| | |
|
| | | GlassIdList.add(spianService.queGlassid("DB103.184", 14).toString());
|
| | |
| | | // }
|
| | |
|
| | | // }
|
| | | }
|
| | | // }
|
| | |
|
| | | storageCageService = WebSocketServer.applicationContext.getBean(StorageCageService.class);
|
| | | dbserve = WebSocketServer.applicationContext.getBean(JdbcConnections.class);
|