diff --git a/buildSrc/src/main/groovy/ros3rag.java-ragconnect-conventions.gradle b/buildSrc/src/main/groovy/ros3rag.java-ragconnect-conventions.gradle index 5b4612b6ff8f97d705344727f1067689d397922f..9a79e8a0c76f13225d43a099b50167801a62e4e8 100644 --- a/buildSrc/src/main/groovy/ros3rag.java-ragconnect-conventions.gradle +++ b/buildSrc/src/main/groovy/ros3rag.java-ragconnect-conventions.gradle @@ -13,7 +13,7 @@ dependencies { grammar2uml group: 'de.tudresden.inf.st', name: 'grammar2uml', version: '0.2.3' relast group: 'org.jastadd', name: 'relast', version: "0.4.0-143" - ragconnect group: 'de.tudresden.inf.st', name: 'ragconnect', version: '1.0.0-alpha-198' + ragconnect group: 'de.tudresden.inf.st', name: 'ragconnect', version: '1.0.0-alpha-203' implementation group: 'de.tudresden.inf.st', name: 'dumpAst', version: '1.0.2-68' } diff --git a/ros3rag.common/src/main/resources/tasks.gradle b/ros3rag.common/src/main/resources/tasks.gradle index 548c51590c12fcbbba02b054982aa01e333cfd5d..938cb0b6d844fb138245b1cec1b83bc92251af32 100644 --- a/ros3rag.common/src/main/resources/tasks.gradle +++ b/ros3rag.common/src/main/resources/tasks.gradle @@ -36,7 +36,8 @@ task ragConnect(type: JavaExec) { '--List=JastAddList', '--experimental-jastadd-329', '--incremental=param', - "--tracing=cache,flush" + '--tracing=cache,flush', + '--evaluationCounter' ]) } diff --git a/ros3rag.placeA/src/main/resources/config-scene-a-placeworld.json b/ros3rag.placeA/src/main/resources/config-scene-a-placeworld.json index 404df52f51f0b66b874e61d911e7d2a3bdd0e7da..72e01bafaee93e3e2714011fef281903bf357932 100644 --- a/ros3rag.placeA/src/main/resources/config-scene-a-placeworld.json +++ b/ros3rag.placeA/src/main/resources/config-scene-a-placeworld.json @@ -1,6 +1,16 @@ { "objects": [ - { "id": "target_Blue","type": "DROP_OFF_LOCATION","pos": { "x": 8,"y": 3,"z": 0.8325 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, - { "id": "target_Green","type": "DROP_OFF_LOCATION","pos": { "x": 1,"y": 1,"z": 0.8325 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, - { "id": "bigBlue","type": "BOX","pos": { "x": 8,"y": 3,"z": 0.8105 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } }, - { "id": "bigGreen","type": "BOX","pos": { "x": 1,"y": 1,"z": 0.8105 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } } + { "id": "target_blue1","type": "DROP_OFF_LOCATION","pos": { "x": 11,"y": 11,"z": 11 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, + { "id": "target_blue2","type": "DROP_OFF_LOCATION","pos": { "x": 12,"y": 12,"z": 12 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, + { "id": "target_blue3","type": "DROP_OFF_LOCATION","pos": { "x": 13,"y": 13,"z": 13 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, + { "id": "target_green1","type": "DROP_OFF_LOCATION","pos": { "x": 21,"y": 21,"z": 21 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, + { "id": "target_green2","type": "DROP_OFF_LOCATION","pos": { "x": 22,"y": 22,"z": 22 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, + { "id": "target_red1","type": "DROP_OFF_LOCATION","pos": { "x": 31,"y": 31,"z": 31 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, + { "id": "target_red2","type": "DROP_OFF_LOCATION","pos": { "x": 32,"y": 32,"z": 32 },"size": { "length": 0.21,"width": 0.3,"height": 0.165 },"orientation": { "w": 1 },"color": { "r": 1 } }, + { "id": "blue1","type": "BOX","pos": { "x": 11,"y": 11,"z": 11 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } }, + { "id": "blue2","type": "BOX","pos": { "x": 12,"y": 12,"z": 12 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } }, + { "id": "blue3","type": "BOX","pos": { "x": 13,"y": 13,"z": 13 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } }, + { "id": "green1","type": "BOX","pos": { "x": 21,"y": 21,"z": 21 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } }, + { "id": "green2","type": "BOX","pos": { "x": 22,"y": 22,"z": 22 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } }, + { "id": "red1","type": "BOX","pos": { "x": 31,"y": 31,"z": 31 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } }, + { "id": "red2","type": "BOX","pos": { "x": 32,"y": 32,"z": 32 },"size": { "length": 0.031,"width": 0.062,"height": 0.121 },"orientation": { "z": 0.382683,"w": 0.92388 },"color": { "r": 1 } } ] } diff --git a/ros3rag.placeA/src/main/resources/regions-a-placeworld.json b/ros3rag.placeA/src/main/resources/regions-a-placeworld.json index 7b9e155e0f56bc006adb6bb4821ecec998ad74d2..85e557ae1d2dfc7d6d0a618b685fa6f72f5ee58f 100644 --- a/ros3rag.placeA/src/main/resources/regions-a-placeworld.json +++ b/ros3rag.placeA/src/main/resources/regions-a-placeworld.json @@ -1,6 +1,7 @@ { "regions": [ - { "name": "G", "positions": ["target_Blue"] }, - { "name": "G", "positions": ["target_Green"] } + { "name": "B", "positions": ["target_blue1", "target_blue2", "target_blue3"] }, + { "name": "G", "positions": ["target_green1", "target_green2"] }, + { "name": "J", "positions": ["target_red1", "target_red2"] } ] } diff --git a/ros3rag.placeB/src/main/jastadd/BFS/BFS.jrag b/ros3rag.placeB/src/main/jastadd/BFS/BFS.jrag index d59de4fa0aa754a46085e640eff698831da30728..9112eee1dbe640ba6773d56627a8b1d63842dcf0 100644 --- a/ros3rag.placeB/src/main/jastadd/BFS/BFS.jrag +++ b/ros3rag.placeB/src/main/jastadd/BFS/BFS.jrag @@ -54,9 +54,10 @@ aspect BFS { //--- prettyPrint --- public String Graph.prettyPrint() { - StringJoiner sj = new StringJoiner("\n", "Graph {\n", "\n}"); + StringJoiner sj = new StringJoiner(", ", "Graph {\n", "\n}"); if (!hasVertex()) { sj.add("<no vertices>"); } for (Vertex v : getVertexList()) { sj.add(v.toString()); } + sj.add("\n"); if (!hasEdge()) { sj.add("<no edges>"); } for (Edge e : getEdgeList()) { sj.add(e.prettyPrint()); } return sj.toString(); diff --git a/ros3rag.placeB/src/main/jastadd/RobotReachabilityToBFS.jrag b/ros3rag.placeB/src/main/jastadd/RobotReachabilityToBFS.jrag index 11b245a8ce76d5c05cb76824e8bec90cc6d991af..5ec92e5420a08745c4b8807fdab063cc073fea7c 100644 --- a/ros3rag.placeB/src/main/jastadd/RobotReachabilityToBFS.jrag +++ b/ros3rag.placeB/src/main/jastadd/RobotReachabilityToBFS.jrag @@ -63,7 +63,7 @@ aspect RobotReachabilityToBFS { } } -aspect Printint { +aspect Printing { public String VertexWithObjectOfInterest.toString() { return "V(" + getNameOfObjectOfInterest() + ")"; } diff --git a/ros3rag.placeB/src/main/jastadd/WorldModelB.connect b/ros3rag.placeB/src/main/jastadd/WorldModelB.connect index 8d91fc98c41cc625abcea7162bad571c134466d6..9d58814df9fdceb98b96e95dab48754f4bd4ae29 100644 --- a/ros3rag.placeB/src/main/jastadd/WorldModelB.connect +++ b/ros3rag.placeB/src/main/jastadd/WorldModelB.connect @@ -5,6 +5,7 @@ receive Robot.CanReachObjectOfInterestWrapper using ParseReachability, ConvertRe receive Robot.OwnedCollaborationZoneNames using ConfigChangeCommandCheckForOwnedCollaborationZone ; receive Robot.OccupiedCollaborationZoneNames using CommandCheckForOccupiedCollaborationZone ; receive Robot.CurrentPosition ; +receive indexed with add WorldModelB.ExecutedOperation using ParseCommand, ConvertCommand ; ParseReachability maps byte[] bytes to de.tudresden.inf.st.ceti.Reachability {: return de.tudresden.inf.st.ceti.Reachability.parseFrom(bytes); @@ -20,6 +21,28 @@ ConvertReachability maps de.tudresden.inf.st.ceti.Reachability r to CanReachObje return result; :} +ParseCommand maps byte[] bytes to de.tudresden.inf.st.ceti.Command {: + return de.tudresden.inf.st.ceti.Command.parseFrom(bytes); +:} + +ConvertCommand maps de.tudresden.inf.st.ceti.Command command to Operation {: + if (command.hasPickAndPlace()) { + return new PickAndPlace() + .setObjectToPick(worldModelB().getMyScene().getLogicalScene().resolveLogicalObjectOfInterest(command.getPickAndPlace().getIdPick()).asLogicalMovableObject()) + .setTargetLocation(worldModelB().getMyScene().resolveObjectOfInterest(command.getPickAndPlace().getIdPlace()).asDropOffLocation()) + .setRobotToExecute(worldModelB().findRobot(command.getPickAndPlace().getIdRobot()).get()); + } else if (command.hasConfigChange()) { + return new ConfigChange() + .setCollaborationZone(worldModelB().getMyScene().resolveObjectOfInterest(command.getConfigChange().getIdCollaborationZone()).asDropOffLocation().asCollaborationZone()) + .setRobotToExecute(worldModelB().findRobot(command.getConfigChange().getIdRobotNewOwner()).get()); + } else if (command.hasEvacuate()) { + return new Evacuate() + .setCollaborationZone(worldModelB().getMyScene().resolveObjectOfInterest(command.getEvacuate().getIdCollaborationZone()).asDropOffLocation().asCollaborationZone()) + .setRobotToExecute(worldModelB().findRobot(command.getEvacuate().getIdRobot()).get()); + } + return new ErrorOperation().setErrorMessage("Could not parse operation " + command); +:} + // --- sending --- send WorldModelB.NextOperation using PrintOperation ; send Robot.myPosition(String) ; diff --git a/ros3rag.placeB/src/main/jastadd/WorldModelB.jadd b/ros3rag.placeB/src/main/jastadd/WorldModelB.jadd index 420813b65a6093ab57b1d76da4bcca7542db7ebc..d3ec38b27ce84ea484b85e0767ee6638d376452f 100644 --- a/ros3rag.placeB/src/main/jastadd/WorldModelB.jadd +++ b/ros3rag.placeB/src/main/jastadd/WorldModelB.jadd @@ -1,4 +1,6 @@ aspect Computation { + static boolean ASTNode.VERBOSE = false; + //--- unspecifiedRegion --- syn nta LogicalRegion WorldModelB.unspecifiedRegion() = new LogicalRegion().setName("<unspecified>"); @@ -73,13 +75,17 @@ aspect Computation { continue; } if (!myGenericObject.isLogicalMovableObject()) { - System.err.println("MovableObject " + otherObject.getName() + " is not a MovableObject in myScene. Skipping!"); + if (VERBOSE) { + System.err.println("MovableObject " + otherObject.getName() + " is not a MovableObject in myScene. Skipping!"); + } continue; } LogicalMovableObject myObject = myGenericObject.asLogicalMovableObject(); if (myObject.hasLocatedAt() && !otherObject.hasLocatedAt()) { if (myObject.getLocatedAtList().size() > 1) { - System.err.println("More than one region found for my " + myObject.getName() + ", using only first."); + if (VERBOSE) { + System.err.println("More than one region found for my " + myObject.getName() + ", using only first."); + } } var diff = new DifferenceObjectMisplaced(); diff.setObject(myObject); @@ -89,10 +95,14 @@ aspect Computation { continue; } if (myObject.getLocatedAtList().size() > 1) { - System.err.println("More than one region found for my " + myObject.getName() + ", using only first."); + if (VERBOSE) { + System.err.println("More than one region found for my " + myObject.getName() + ", using only first."); + } } if (otherObject.getLocatedAtList().size() > 1) { - System.err.println("More than one region found for other " + otherObject.getName() + ", using only first."); + if (VERBOSE) { + System.err.println("More than one region found for other " + otherObject.getName() + ", using only first."); + } } Set<String> myRegions = myObject.regionNameSet(); Set<String> otherRegions = otherObject.regionNameSet(); @@ -176,7 +186,9 @@ aspect Computation { */ if (sourceLocation.isCollaborationZone()) { CollaborationZone cz = sourceLocation.asCollaborationZone(); - System.out.println("source is cz, occ:" + (cz.hasOccupient() ? cz.occupient().nameAndHash() : "none") + ", owner: " + (cz.hasOwner() ? cz.owner().nameAndHash() : "none")); + if (VERBOSE) { + System.out.println("source is cz, occ:" + (cz.hasOccupient() ? cz.occupient().nameAndHash() : "none") + ", owner: " + (cz.hasOwner() ? cz.owner().nameAndHash() : "none")); + } // order is important here, first add Evacuate, then ConfigChange if (cz.hasOccupient() && !cz.occupient().equals(executingRobot)) { if (cz.occupient().isBusy()) { @@ -195,7 +207,9 @@ aspect Computation { } if (targetLocation.isCollaborationZone()) { CollaborationZone cz = targetLocation.asCollaborationZone(); - System.out.println("target is cz, occ:" + (cz.hasOccupient() ? cz.occupient().nameAndHash() : "none") + ", owner: " + (cz.hasOwner() ? cz.owner().nameAndHash() : "none")); + if (VERBOSE) { + System.out.println("target is cz, occ:" + (cz.hasOccupient() ? cz.occupient().nameAndHash() : "none") + ", owner: " + (cz.hasOwner() ? cz.owner().nameAndHash() : "none")); + } // order is important here, first add Evacuate, then ConfigChange if (cz.hasOccupient() && !cz.occupient().equals(executingRobot)) { if (cz.occupient().isBusy()) { @@ -213,7 +227,7 @@ aspect Computation { } } result.add(PickAndPlace.of(executingRobot, getObject(), targetLocation)); - }, () -> result.add(new ErrorOperation("Could not find robot with name " + edge.asEdgeWithRobot().getNameOfRobot()))); + }, () -> result.add(new ErrorOperation().setErrorMessage("Could not find robot with name " + edge.asEdgeWithRobot().getNameOfRobot()))); transit = target; } return result; @@ -232,7 +246,7 @@ aspect Computation { //--- error --- protected static List<Operation> Difference.error(String message) { - return Collections.singletonList(new ErrorOperation(message)); + return Collections.singletonList(new ErrorOperation().setErrorMessage(message)); } //--- Operation.of --- @@ -265,14 +279,14 @@ aspect Computation { //--- getNextOperation --- syn Operation WorldModelB.getNextOperation() { if (diffToOperations().getNumChild() == 0) { - return new ErrorOperation("No operation computed!"); + return new ErrorOperation().setErrorMessage("No operation computed!"); } for (Operation op : diffToOperations()) { if (!op.isErrorOperation()) { return op; } } - return new ErrorOperation("No executable operation found!"); + return new ErrorOperation().setErrorMessage("No executable operation found!"); } //--- canReach --- @@ -349,7 +363,9 @@ aspect Computation { } private String Robot.logAndReturn(String pre, String returnValue) { - System.out.println(pre + returnValue); + if (VERBOSE) { + System.out.println(pre + returnValue); + } return returnValue; } @@ -362,7 +378,9 @@ aspect AttributeMappings { //--- toProtobufByteArray --- syn byte[] Operation.toProtobufByteArray() = null; eq ErrorOperation.toProtobufByteArray() { - System.err.println(getErrorMessage()); + if (VERBOSE) { + System.err.println(getErrorMessage()); + } return null; } eq Pick.toProtobufByteArray() { diff --git a/ros3rag.placeB/src/main/jastadd/WorldModelB.relast b/ros3rag.placeB/src/main/jastadd/WorldModelB.relast index 821bcca8df42b25ec8c362e3023f98d33517459f..1de1dcc4edb9e8128ef10cfeaf365094858a171e 100644 --- a/ros3rag.placeB/src/main/jastadd/WorldModelB.relast +++ b/ros3rag.placeB/src/main/jastadd/WorldModelB.relast @@ -1,4 +1,4 @@ -WorldModelB ::= Region* Robot* [MyScene:Scene] OtherScene:LogicalScene* /NextOperation:Operation/ TestingOtherScene:LogicalScene* ; +WorldModelB ::= Region* Robot* [MyScene:Scene] OtherScene:LogicalScene* ExecutedOperation:Operation* /NextOperation:Operation/ ; // FIXME inline CanReachObjectOfInterestWrapper Robot ::= <Name:String> CanReachObjectOfInterestWrapper <OwnedCollaborationZoneNames> <OccupiedCollaborationZoneNames> <CurrentPosition> ; diff --git a/ros3rag.placeB/src/main/java/de/tudresden/inf/st/placeB/MainB.java b/ros3rag.placeB/src/main/java/de/tudresden/inf/st/placeB/MainB.java index 52f1a58a07bcf2728f8c0d2f8448e5506d182bf4..c5b8a87adca8e05e3dae099f29421ad33b5aaa84 100644 --- a/ros3rag.placeB/src/main/java/de/tudresden/inf/st/placeB/MainB.java +++ b/ros3rag.placeB/src/main/java/de/tudresden/inf/st/placeB/MainB.java @@ -138,39 +138,27 @@ public class MainB extends SharedMainParts<MqttHandler, WorldModelB> { @Override protected void connectEndpoints() throws IOException { for (String topic : config.forB.topicsSceneUpdate) { - checkSuccess( - model.connectMyScene(mqttUri(topic, config)), - "connectMyScene" - ); + checkSuccess(model.connectMyScene(mqttUri(topic, config)), + "connectMyScene"); } - checkSuccess( - model.connectOtherScene(mqttUri("place-a/logical/update", config), 0), - "OtherScene" - ); - checkSuccess( - model.connectNextOperation(mqttUri(config.forB.topicCommand, config), false), - "NextOperation" - ); + checkSuccess(model.connectOtherScene(mqttUri("place-a/logical/update", config), 0), + "OtherScene"); + checkSuccess(model.connectNextOperation(mqttUri(config.forB.topicCommand, config), false), + "NextOperation"); +// checkSuccess(model.connectExecutedOperation(mqttUri(config.forB.topicCommand, config)), +// "OperationHistory"); for (Robot robot : model.getRobotList()) { // self-loop - checkSuccess( - robot.connectOwnedCollaborationZoneNames(mqttUri(config.forB.topicCommand, config)), - "OwnedCollaborationZoneNames (" + robot.getName() + ")" - ); - checkSuccess( - robot.connectOccupiedCollaborationZoneNames(mqttUri(config.forB.topicCommand, config)), - "OccupiedCollaborationZoneNames (" + robot.getName() + ")" - ); + checkSuccess(robot.connectOwnedCollaborationZoneNames(mqttUri(config.forB.topicCommand, config)), + "OwnedCollaborationZoneNames (" + robot.getName() + ")"); + checkSuccess(robot.connectOccupiedCollaborationZoneNames(mqttUri(config.forB.topicCommand, config)), + "OccupiedCollaborationZoneNames (" + robot.getName() + ")"); String topicPosition = joinTopics("place-b", robot.getName(), "position"); - checkSuccess( - robot.connectCurrentPosition(mqttUri(topicPosition, config)), - "CurrentPosition (" + robot.getName() + ")" - ); - checkSuccess( - robot.connectMyPosition(mqttUri(topicPosition, config), true), - "MyPosition (" + robot.getName() + ")" - ); + checkSuccess(robot.connectCurrentPosition(mqttUri(topicPosition, config)), + "CurrentPosition (" + robot.getName() + ")"); + checkSuccess(robot.connectMyPosition(mqttUri(topicPosition, config), true), + "MyPosition (" + robot.getName() + ")"); } } diff --git a/ros3rag.placeB/src/main/java/de/tudresden/inf/st/placeB/UtilB.java b/ros3rag.placeB/src/main/java/de/tudresden/inf/st/placeB/UtilB.java index 8e4b75ddda9809123c24ced67d23e7b4360b5b60..e66babacbb420fde5b85ee5ff399d72ba2fb79b4 100644 --- a/ros3rag.placeB/src/main/java/de/tudresden/inf/st/placeB/UtilB.java +++ b/ros3rag.placeB/src/main/java/de/tudresden/inf/st/placeB/UtilB.java @@ -130,9 +130,13 @@ public class UtilB { sb.append(" (unset)\n"); } sb.append("Diff: ").append(model.diffScenes().prettyPrint(Difference::prettyPrint)).append("\n"); - sb.append("Graph: ").append(model.toReachabilityGraph().prettyPrint()).append("\n"); + if (detailed) { + sb.append("Graph: ").append(model.toReachabilityGraph().prettyPrint()).append("\n"); + } sb.append("Operations: ").append(model.diffToOperations().prettyPrint(Operation::prettyPrint)).append("\n"); sb.append("Next operation: ").append(model.getNextOperation().prettyPrint()).append("\n"); + sb.append("Operation History: ").append(model.getExecutedOperations().prettyPrint(Operation::prettyPrint)).append("\n"); + sb.append("EvaluationCounter:\n").append(model.ragconnectEvaluationCounterSummary()); return sb.toString(); } diff --git a/ros3rag.placeB/src/main/resources/config-scene-b-placeworld-manual.json b/ros3rag.placeB/src/main/resources/config-scene-b-placeworld-manual.json index 23a488cbb6b890340cf908b83fa194109e95d0d9..61b696ce13d464ac588b8e5828fa10a121d7b550 100644 --- a/ros3rag.placeB/src/main/resources/config-scene-b-placeworld-manual.json +++ b/ros3rag.placeB/src/main/resources/config-scene-b-placeworld-manual.json @@ -1444,11 +1444,11 @@ } }, { - "id": "bigBlue", + "id": "blue1", "type": "BOX", "pos": { "x": 0.1, - "y": -0.25, + "y": -0.7, "z": 0.9355 }, "size": { @@ -1464,11 +1464,71 @@ } }, { - "id": "bigGreen", + "id": "blue2", "type": "BOX", "pos": { - "x": -0.3, - "y": 2.01, + "x": 0.2, + "y": 0.3, + "z": 0.9355 + }, + "size": { + "length": 0.0318, + "width": 0.0636, + "height": 0.091 + }, + "orientation": { + "w": 1 + }, + "color": { + "b": 1 + } + }, + { + "id": "blue3", + "type": "BOX", + "pos": { + "x": 0.2, + "y": -0.1, + "z": 0.9355 + }, + "size": { + "length": 0.0318, + "width": 0.0636, + "height": 0.091 + }, + "orientation": { + "w": 1 + }, + "color": { + "b": 1 + } + }, + { + "id": "green1", + "type": "BOX", + "pos": { + "x": 0.2, + "y": -0.3, + "z": 0.9355 + }, + "size": { + "length": 0.0318, + "width": 0.0636, + "height": 0.091 + }, + "orientation": { + "w": 1 + }, + "color": { + "g": 1 + } + }, + { + "id": "green2", + "type": "BOX", + "pos": { + "x": 0.1, + "y": 1.91, "z": 0.9355 }, "size": { @@ -1483,6 +1543,46 @@ "g": 1 } }, + { + "id": "red1", + "type": "BOX", + "pos": { + "x": -0.3, + "y": -0.6, + "z": 0.9355 + }, + "size": { + "length": 0.0318, + "width": 0.0636, + "height": 0.091 + }, + "orientation": { + "w": 1 + }, + "color": { + "r": 1 + } + }, + { + "id": "red2", + "type": "BOX", + "pos": { + "x": 0.3, + "y": 1.41, + "z": 0.9355 + }, + "size": { + "length": 0.0318, + "width": 0.0636, + "height": 0.091 + }, + "orientation": { + "w": 1 + }, + "color": { + "r": 1 + } + }, { "id": "arm1", "type": "ARM", diff --git a/ros3rag.placeB/src/main/resources/reachability-b-placeworld.json b/ros3rag.placeB/src/main/resources/reachability-b-placeworld.json index 7f5d47fc8419d5d4535944493949f1d1672e651a..0bb43a3528ba9603542817ab1eeabaea9eb9b036 100644 --- a/ros3rag.placeB/src/main/resources/reachability-b-placeworld.json +++ b/ros3rag.placeB/src/main/resources/reachability-b-placeworld.json @@ -3,9 +3,10 @@ { "name": "arm1", "reachableLocations": [ - "A1", + "A1", "A2", "A3", "A4", "B1", "B2", - "C1", + "C1", "C2", "C3", "C4", "C5", "C6", "C7", "C8", "C9", + "D1", "D2", "D3", "D4", "D5", "D6", "D7", "D8", "D9", "cz1" ] }, @@ -13,8 +14,10 @@ "name": "arm2", "reachableLocations": [ "cz1", - "G1", "G2", "G3", "G4", - "I1", "I2", "I3" ,"I4" + "G1", "G2", "G3", "G4", "G5", "G6", "G7", "G8", "G9", + "H1", "H2", "H3", "H4", "H5", "H6", "H7", "H8", "H9", + "I1", "I2", "I3" ,"I4", + "J1", "J2" ] } ] diff --git a/ros3rag.placeB/src/main/resources/regions-b-placeworld.json b/ros3rag.placeB/src/main/resources/regions-b-placeworld.json index 19c849b41643e12b82ebc715c1949b627c37a68a..194764d2366e2e7260b9bb2a10b8890c5ee6f719 100644 --- a/ros3rag.placeB/src/main/resources/regions-b-placeworld.json +++ b/ros3rag.placeB/src/main/resources/regions-b-placeworld.json @@ -1,14 +1,13 @@ { "regions": [ - { "name": "A", "positions": ["A1"] }, + { "name": "A", "positions": ["A1", "A2", "A3", "A4"] }, { "name": "B", "positions": ["B1", "B2"] }, - { "name": "C", "positions": ["C1"] }, - { "name": "D", "positions": ["D1"] }, - { "name": "E", "positions": ["E1"] }, - { "name": "F", "positions": ["F1"] }, - { "name": "G", "positions": ["G1", "G2", "G3", "G4"] }, - { "name": "H", "positions": ["H1"] }, + { "name": "C", "positions": ["C1", "C2", "C3", "C4", "C5", "C6", "C7", "C8", "C9"] }, + { "name": "D", "positions": ["D1", "D2", "D3", "D4", "D5", "D6", "D7", "D8", "D9"] }, + { "name": "G", "positions": ["G1", "G2", "G3", "G4", "G5", "G6", "G7", "G8", "G9"] }, + { "name": "H", "positions": ["H1", "H2", "H3", "H4", "H5", "H6", "H7", "H8", "H9"] }, { "name": "I", "positions": ["I1", "I2", "I3", "I4"] }, + { "name": "J", "positions": ["J1", "J2"] }, { "name": "CZ", "positions": ["cz1"] } ] }