-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
ZdenekM
committed
Oct 1, 2024
1 parent
cc5490a
commit 7ef7061
Showing
10 changed files
with
114 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# UR Demo | ||
|
||
To use with simulator, run: | ||
|
||
```bash | ||
docker compose -f docker-compose.yml -f docker-compose.sim.yml up | ||
``` | ||
|
||
For the real robot, use the following command: | ||
|
||
```bash | ||
docker compose -f docker-compose.yml -f docker-compose.lab.yml up | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
services: | ||
ur-demo-robot-api: | ||
ports: | ||
- "50002:50002" # robot connects to this port | ||
environment: | ||
- ROBOT_CONTAINER_NAME=ur-20245500974 | ||
- ROBOT_IP=192.168.104.149 | ||
volumes: | ||
- ./robot_calibration.yaml:/root/robot_calibration.yaml | ||
network_mode: host # ObjectType has to connect to localhost:5012 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
services: | ||
ur-demo-ursim: | ||
image: universalrobots/ursim_e-series:5.17.2 | ||
container_name: ur-demo-ursim | ||
ports: # network_mode: host can't be (easily) used as ursim starts its own X server | ||
- "5900:5900" # VNC port | ||
- "6080:6080" # web VNC | ||
# - "30001:30001" | ||
# - "30002:30002" | ||
# - "30004:30004" | ||
# - "29999:29999" | ||
networks: | ||
- ur-demo-network | ||
environment: | ||
- ROBOT_MODEL=UR5 | ||
volumes: | ||
- ursim-gui-cache:/ursim/GUI | ||
- urcap-build-cache:/ursim/.urcaps | ||
- ursim-programs:/ursim/programs | ||
ur-demo-robot-api: | ||
environment: | ||
- ROBOT_IP=ur-demo-ursim | ||
- SLEEP=10 | ||
networks: | ||
- ur-demo-network # ObjectType has to connect to ur-demo-ursim:5012 | ||
|
||
volumes: | ||
ursim-gui-cache: | ||
urcap-build-cache: | ||
ursim-programs: | ||
ur-demo-asset: | ||
ur-demo-execution: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
kinematics: | ||
shoulder: | ||
x: 0 | ||
y: 0 | ||
z: 0.16253268591029907 | ||
roll: -0 | ||
pitch: 0 | ||
yaw: -3.9706105474032749e-07 | ||
upper_arm: | ||
x: 5.9721945474714789e-05 | ||
y: 0 | ||
z: 0 | ||
roll: 1.5694161246097016 | ||
pitch: 0 | ||
yaw: 3.8856764585994165e-07 | ||
forearm: | ||
x: -0.42536553582483921 | ||
y: 0 | ||
z: 0 | ||
roll: 3.1411247028186096 | ||
pitch: 3.1406202190734502 | ||
yaw: 3.141591474472873 | ||
wrist_1: | ||
x: -0.39236572259516306 | ||
y: -0.00038526533421009263 | ||
z: 0.13417899372885142 | ||
roll: 0.0028712711637521563 | ||
pitch: 3.3546609413013983e-05 | ||
yaw: 1.2608447936119974e-06 | ||
wrist_2: | ||
x: 5.7243914837099386e-05 | ||
y: -0.099710274078176342 | ||
z: 5.5554929734187943e-05 | ||
roll: 1.5702391633079928 | ||
pitch: 0 | ||
yaw: 4.5241975821577735e-07 | ||
wrist_3: | ||
x: 9.4768738018291456e-05 | ||
y: 0.099660684607093819 | ||
z: 3.0152958512421488e-05 | ||
roll: 1.5710988829905641 | ||
pitch: 3.1415926535897931 | ||
yaw: 3.1415926477648899 | ||
hash: calib_15111234226826911485 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
shell_source(name="start.sh", source="start.sh") | ||
docker_image(name="arcor2_ur", repository="arcor2/arcor2_ur", dependencies=[":start.sh", "build-support:install_ur_dependencies.sh"], image_tags=["1.2.1"]) | ||
docker_image(name="arcor2_ur", repository="arcor2/arcor2_ur", dependencies=[":start.sh", "build-support:install_ur_dependencies.sh"], image_tags=["1.3.0"]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,20 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
# shellcheck source=/dev/null | ||
source /opt/ros/jazzy/setup.bash | ||
|
||
: "${UR_TYPE:=ur5e}" | ||
: "${ROBOT_CONTAINER_NAME:=ur-demo-ursim}" | ||
|
||
ROBOT_CONTAINER_IP=$(getent hosts "$ROBOT_CONTAINER_NAME" | awk '{ print $1 }') | ||
# simulator needs some time to get running... | ||
if [[ -n "$SLEEP" && "$SLEEP" =~ ^[0-9]+$ ]]; then | ||
echo "Waiting for $SLEEP seconds..." | ||
sleep "$SLEEP" | ||
fi | ||
|
||
sleep 10s # TODO find a way how to detect that the robot is up and running (test if some port is opened?) | ||
cp --update=none "$(ros2 pkg prefix --share ur_description)/config/$UR_TYPE/default_kinematics.yaml" /root/robot_calibration.yaml | ||
|
||
ros2 launch ur_robot_driver ur_control.launch.py ur_type:="$UR_TYPE" robot_ip:="$ROBOT_CONTAINER_IP" launch_rviz:=false & | ||
ros2 launch ur_robot_driver ur_control.launch.py ur_type:="$UR_TYPE" robot_ip:="$ROBOT_IP" launch_rviz:=false kinematics_params_file:="/root/robot_calibration.yaml" & | ||
|
||
PEX_EXTRA_SYS_PATH=/opt/ros/jazzy/lib/python3.12/site-packages PYTHONOPTIMIZE=1 /bin/app/pex |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
docker_image(name="arcor2_ur_ot", repository="arcor2/arcor2_ur_ot", image_tags=["1.2.1"]) | ||
docker_image(name="arcor2_ur_ot", repository="arcor2/arcor2_ur_ot", image_tags=["1.3.0"]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
1.2.1 | ||
1.3.0 |