Skip to content

Commit

Permalink
[manipulation] Add UR3e model and TRI Homecart
Browse files Browse the repository at this point in the history
This PR only contains a test that verifies that the model can be
parsed correctly (through model directives, etc). But in a follow-up
PR I will use this as a Drake example of bimanual motion planning with
Graph of Convex Sets.

These models were derived from the Anzu versions; with a few changes:
- Anzu has "left/right" variants of the ur3e models, which set tighter
joint limits for the homecart configuration.  I felt that it was a
little inelegant to put those in the ur3e directory (they should be
homecart specific).  We can add them later if need be.

- I've used the simple wsg gripper models that were already in Drake
instead of the fancier models in anzu.

- I've named the directory `tri_homecart` instead of `homecart`.
  • Loading branch information
RussTedrake committed Jul 6, 2022
1 parent 32e1c6f commit bc3d665
Show file tree
Hide file tree
Showing 22 changed files with 1,848 additions and 8 deletions.
10 changes: 5 additions & 5 deletions doc/_pages/model_version_control.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ See below for the suggested workflow.
1. Clone ``RobotLocomotion/models`` locally
2. Create a Git branch in your local checkouts of *both* ``models`` and
``drake``.
3. Update ``drake/tools/workspace/models/repository.bzl`` to point to your
3. Update ``drake/tools/workspace/models_internal/repository.bzl`` to point to your
``models`` checkout using
``github_archive(..., local_repository_override = <path>)``.
4. Update ``drake/tools/workspace/models/files.bzl`` to incorporate the models
4. Update ``drake/tools/workspace/models_internal/files.bzl`` to incorporate the models
you want.
5. Update ``drake/tools/workspace/models/package.BUILD.bazel`` to export the
5. Update ``drake/tools/workspace/models_internal/package.BUILD.bazel`` to export the
models.
6. Ensure that you use ``forward_files`` to make the files available inside
the Drake bazel workspace. For an example, see
Expand All @@ -42,7 +42,7 @@ See below for the suggested workflow.
## Submit Changes in a Pull Request

1. Push your changes to your fork of ``RobotLocomotion/models``. Make a PR.
2. Update ``drake/tools/workspace/models/models/repository.bzl`` to use the
2. Update ``drake/tools/workspace/models_internal/repository.bzl`` to use the
commit you pushed.
3. Submit a PR to Drake, and add a self-blocking discussion thread, such as
``"Working temporary SHA1 until the models PR <LINK> is merged."``,
Expand All @@ -51,6 +51,6 @@ See below for the suggested workflow.
request review for your ``models`` PR.
5. Once both PRs are approved:
1. Merge your ``models`` PR.
2. Update ``drake/tools/workspace/models/repository.bzl`` to the latest
2. Update ``drake/tools/workspace/models_internal/repository.bzl`` to the latest
merge commit on ``master`` for ``RobotLocomotion/models``.
3. Merge your ``drake`` PR.
2 changes: 2 additions & 0 deletions manipulation/models/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ install(
"//manipulation/models/iiwa_description:install_data",
"//manipulation/models/jaco_description:install_data",
"//manipulation/models/realsense2_description:install_data",
"//manipulation/models/tri_homecart:install_data",
"//manipulation/models/ur3e:install_data",
"//manipulation/models/wsg_50_description:install_data",
"//manipulation/models/ycb:install_data",
],
Expand Down
59 changes: 59 additions & 0 deletions manipulation/models/tri_homecart/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# -*- python -*-

load(
"@drake//tools/skylark:drake_cc.bzl",
"drake_cc_googletest",
)
load("//tools/install:install_data.bzl", "install_data")
load("//tools/lint:lint.bzl", "add_lint_tests")
load("@drake//tools/workspace/ros_xacro_internal:defs.bzl", "xacro_file")
load("@drake//tools/workspace:forward_files.bzl", "forward_files")
load("//tools/workspace/models_internal:files.bzl", "tri_homecart_mesh_files")

# This package is public so that other packages can refer to
# individual files in model from their bazel rules.
package(
default_visibility = ["//visibility:public"],
)

# === test/ ===

drake_cc_googletest(
name = "parse_homecart_test",
srcs = ["test/parse_homecart_test.cc"],
data = [
":models",
"//manipulation/models/ur3e:models",
"//manipulation/models/wsg_50_description:models",
],
deps = [
"//common:find_resource",
"//multibody/parsing",
],
)

xacro_file(
name = "homecart_bimanual.urdf",
src = "homecart_bimanual.urdf.xacro",
)

xacro_file(
name = "homecart_cutting_board.sdf",
src = "homecart_cutting_board.sdf.xacro",
)

_TRI_HOMECART_MESHES = forward_files(
srcs = ["@models_internal//:" + x for x in tri_homecart_mesh_files()],
dest_prefix = "",
strip_prefix = "@models_internal//:tri_homecart/",
visibility = ["//visibility:private"],
)

install_data(
extra_prod_models = [
"homecart_bimanual.urdf",
"homecart_cutting_board.sdf",
] + _TRI_HOMECART_MESHES,
)

add_lint_tests()
7 changes: 7 additions & 0 deletions manipulation/models/tri_homecart/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# TRI HomeCart

The HomeCart is a bimanual manipulation station developed at the Toyota
Research Institute (TRI). The model files contained here are all developed by TRI
and distributed under Drake's license. They represent a slightly simplified
version of the model files used internally at TRI (most notably they are using
a simplified version of the grippers).
5 changes: 5 additions & 0 deletions manipulation/models/tri_homecart/homecart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
directives:
- add_directives:
file: package://drake/manipulation/models/tri_homecart/homecart_no_grippers.yaml
- add_directives:
file: package://drake/manipulation/models/tri_homecart/homecart_grippers.yaml
Loading

0 comments on commit bc3d665

Please sign in to comment.