add: 关联站点开发

This commit is contained in:
2023-12-08 17:13:46 +08:00
parent d27528644e
commit d06fcdbe0e
11 changed files with 745 additions and 64 deletions

View File

@@ -42,7 +42,8 @@ public enum DriverTypeEnum {
DOUBLE_STATION_STACKER(16, "double_station_stacker", "标准版-双工位堆垛机", "double_station_stacker"),
DOUBLE_BELT_CONVEYOR(17, "double_belt_conveyor", "双工位输送线", "double_belt_conveyor");
DOUBLE_BELT_CONVEYOR(17, "double_belt_conveyor", "双工位输送线", "conveyor"),
WITH_STATION_DEVICE_DRIVER(18, "with_station_device_driver", "输送线关联站点", "conveyor");
/**

View File

@@ -1,4 +1,4 @@
package org.nl.acs.device_driver.basedriver.belt_with_station;
package org.nl.acs.device_driver.conveyor.belt_with_station;
import org.nl.acs.device.domain.Device;
import org.nl.acs.device.enums.DeviceType;
@@ -16,17 +16,17 @@ import java.util.List;
public class WithStationDefination implements DeviceDriverDefination {
@Override
public String getDriverCode() {
return "hailiang_with_station";
return "with_station_device";
}
@Override
public String getDriverName() {
return "关联驱动";
return "输送线关联站点";
}
@Override
public String getDriverDescription() {
return "关联驱动";
return "输送线关联站点";
}

View File

@@ -1,6 +1,5 @@
package org.nl.acs.device_driver.basedriver.belt_with_station;
package org.nl.acs.device_driver.conveyor.belt_with_station;
import cn.hutool.core.collection.CollectionUtil;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.util.IdUtil;
import cn.hutool.core.util.ObjectUtil;
@@ -16,8 +15,7 @@ import org.nl.acs.device.domain.Device;
import org.nl.acs.device.service.DeviceService;
import org.nl.acs.device_driver.DeviceDriver;
import org.nl.acs.device_driver.RouteableDeviceDriver;
import org.nl.acs.device_driver.basedriver.belt_conveyor.BeltConveyorDeviceDriver;
import org.nl.acs.device_driver.basedriver.double_belt_conveyor.DoubleBeltConveyorDeviceDriver;
import org.nl.acs.device_driver.conveyor.double_belt_conveyor.DoubleBeltConveyorDeviceDriver;
import org.nl.acs.device_driver.driver.AbstractOpcDeviceDriver;
import org.nl.acs.device_driver.driver.ExecutableDeviceDriver;
import org.nl.acs.ext.wms.service.AcsToWmsService;
@@ -43,6 +41,7 @@ import java.util.*;
@Data
@RequiredArgsConstructor
public class WithStationDeviceDriver extends AbstractOpcDeviceDriver implements DeviceDriver, ExecutableDeviceDriver, RouteableDeviceDriver, DeviceStageMonitor {
@Autowired
DeviceAppService deviceAppservice = SpringContextHolder.getBean(DeviceAppService.class);
@Autowired
@@ -382,4 +381,5 @@ public class WithStationDeviceDriver extends AbstractOpcDeviceDriver implements
option = Integer.parseInt(flag);
}
}
}

View File

@@ -1,4 +1,4 @@
package org.nl.acs.device_driver.basedriver.double_belt_conveyor;
package org.nl.acs.device_driver.conveyor.double_belt_conveyor;
import org.nl.acs.device.device_driver.standard_inspect.ItemDto;
import org.nl.acs.device.domain.Device;
@@ -17,17 +17,17 @@ import java.util.List;
public class DoubleBeltConveyorDefination implements OpcDeviceDriverDefination {
@Override
public String getDriverCode() {
return "belt_conveyor";
return "double_belt_conveyor";
}
@Override
public String getDriverName() {
return "标准版-输送机";
return "双工位-输送机";
}
@Override
public String getDriverDescription() {
return "标准版-输送机";
return "双工位-输送机";
}
@Override

View File

@@ -1,4 +1,4 @@
package org.nl.acs.device_driver.basedriver.double_belt_conveyor;
package org.nl.acs.device_driver.conveyor.double_belt_conveyor;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.util.IdUtil;
@@ -293,7 +293,7 @@ public class DoubleBeltConveyorDeviceDriver extends AbstractOpcDeviceDriver impl
public void writing(int command) {
String to_command = this.getDevice().getOpc_server_code() + "." + this.getDevice().getOpc_plc_code() + "." + this.getDevice().getDevice_code()
+ "." + org.nl.acs.device_driver.basedriver.standard_conveyor_control_with_scanner.ItemProtocol.item_to_command;
+ "." +ItemProtocol.item_to_command;
Map<String, Object> itemMap = new HashMap<String, Object>();
this.control(itemMap);

View File

@@ -1,4 +1,4 @@
package org.nl.acs.device_driver.basedriver.double_belt_conveyor;
package org.nl.acs.device_driver.conveyor.double_belt_conveyor;
import cn.hutool.core.util.ObjectUtil;
import cn.hutool.core.util.StrUtil;

View File

@@ -1,4 +1,4 @@
package org.nl.acs.device_driver.basedriver.double_belt_conveyor;
package org.nl.acs.device_driver.conveyor.double_belt_conveyor;
import lombok.AllArgsConstructor;
import lombok.Data;

View File

@@ -17,53 +17,31 @@ import org.nl.acs.device.service.DeviceService;
import org.nl.acs.device_driver.FeedLmsRealFailed;
import org.nl.acs.device_driver.agv.ndcone.AgvNdcOneDeviceDriver;
import org.nl.acs.device_driver.agv.ndctwo.AgvNdcTwoDeviceDriver;
import org.nl.acs.device_driver.basedriver.cargo_lift_conveyor.CargoLiftConveyorDeviceDriver;
import org.nl.acs.device_driver.basedriver.casing_station.CasingStationConveyorDeviceDriver;
import org.nl.acs.device_driver.basedriver.device_status.DeviceStatusDeviceDriver;
import org.nl.acs.device_driver.basedriver.empty_vehicle_stacking_position.EmptyVehicleStackingPositionDeviceDriver;
import org.nl.acs.device_driver.conveyor.hongxiang_conveyor.HongXiangStationDeviceDriver;
import org.nl.acs.device_driver.conveyor.hongxiang_device.HongXiangConveyorDeviceDriver;
import org.nl.acs.device_driver.basedriver.indoor_manipulator.IndoorManipulatorDeviceDriver;
import org.nl.acs.device_driver.three_color.lamp_three_color.LampThreecolorDeviceDriver;
import org.nl.acs.device_driver.conveyor.oven_manipulator.OvenGantryManipulatorDeviceDriver;
import org.nl.acs.device_driver.basedriver.paper_tube_device.PaperTubeConveyorDeviceDriver;
import org.nl.acs.device_driver.basedriver.paper_tube_device2.Paper;
import org.nl.acs.device_driver.basedriver.paper_tube_device2.PaperTubeConveyor2DeviceDriver;
import org.nl.acs.device_driver.conveyor.plug_pull_device_site.PlugPullDeviceSiteDeviceDriver;
import org.nl.acs.device_driver.basedriver.plugging_unplugging_machine.PluggingUnpluggingMachineDeviceDriver;
import org.nl.acs.device_driver.conveyor.siemens_conveyor.SiemensConveyorDeviceDriver;
import org.nl.acs.device_driver.conveyor.siemens_conveyor_ckk.SiemensConveyorCkkDeviceDriver;
import org.nl.acs.device_driver.conveyor.siemens_conveyor_labeling.SiemensConveyorLabelingDeviceDriver;
import org.nl.acs.device_driver.basedriver.siemens_onefloor_agv_conveyor.SiemensOneFloorAGVConveyorDeviceDriver;
import org.nl.acs.device_driver.conveyor.slit_two_manipulator.SlitTwoManipulatorDeviceDriver;
import org.nl.acs.device_driver.conveyor.standard_conveyor_control_with_scanner.StandardCoveyorControlWithScannerDeviceDriver;
import org.nl.acs.device_driver.conveyor.standard_ordinary_site.StandardOrdinarySiteDeviceDriver;
import org.nl.acs.ext.wms.data.*;
import org.nl.acs.ext.wms.liKuData.OutConfirmReportResponse;
import org.nl.acs.ext.wms.liKuData.OutConfirmRequest;
import org.nl.acs.ext.wms.liKuData.Resp;
import org.nl.acs.ext.wms.service.AcsToLiKuService;
import org.nl.acs.ext.wms.service.WmsToAcsService;
import org.nl.acs.history.ErrorUtil;
import org.nl.acs.instruction.service.InstructionService;
import org.nl.acs.instruction.service.dto.Instruction;
import org.nl.acs.monitor.DeviceStageMonitor;
import org.nl.acs.opc.Device;
import org.nl.acs.opc.DeviceAppService;
import org.nl.acs.opc.DeviceExtraManageDto;
import org.nl.acs.opc.DeviceType;
import org.nl.acs.route.service.RouteLineService;
import org.nl.acs.task.service.TaskService;
import org.nl.acs.task.service.dto.TaskDto;
import org.nl.modules.common.exception.BadRequestException;
import org.nl.modules.system.domain.Dict;
import org.nl.modules.system.service.DictDetailService;
import org.nl.modules.system.service.DictService;
import org.nl.modules.system.service.ParamService;
import org.nl.modules.system.service.dto.DictDetailDto;
import org.nl.modules.wql.core.bean.WQLObject;
import org.nl.modules.wql.exception.WDKException;
import org.nl.modules.wql.util.SpringContextHolder;
import org.slf4j.MDC;
import org.springframework.context.ApplicationContext;
import org.springframework.http.HttpStatus;
@@ -79,7 +57,61 @@ import java.util.stream.Collectors;
@RequiredArgsConstructor
@Slf4j
public class WmsToAcsServiceImpl implements WmsToAcsService {
@Override
public CreateTaskResponse crateTask(String param) {
return null;
}
@Override
public org.nl.acs.ext.wms.data.one.CreateTaskResponse crateTask(List<org.nl.acs.ext.wms.data.one.CreateTaskRequest> reqs) {
return null;
}
@Override
public org.nl.acs.ext.wms.data.one.CancelTaskResponse cancelFromWms(List<org.nl.acs.ext.wms.data.one.CancelTaskRequest> reqs) throws Exception {
return null;
}
@Override
public Map<String, Object> updateDeviceGoodsFromWms(String jsonObject) {
return null;
}
@Override
public Map<String, Object> areaControl(JSONObject jsonObject) {
return null;
}
@Override
public PutActionResponse putAction(String jsonObject) throws Exception {
return null;
}
@Override
public Map<String, Object> queryDevice(String jsonObject) throws Exception {
return null;
}
@Override
public Map<String, Object> queryDeviceDBValue(String whereJson) {
return null;
}
@Override
public Map<String, Object> querydevice(String whereJson) {
return null;
}
@Override
public Map<String, Object> putPlusPullAction(String whereJson) {
return null;
}
@Override
public JSONObject notifyAcs(JSONObject param) {
return null;
}
/**
private final ApplicationContext applicationContext;
private final InstructionService instructionService;
@@ -1367,5 +1399,6 @@ public class WmsToAcsServiceImpl implements WmsToAcsService {
resp.put("message", "操作成功");
return resp;
}
**/
}