Skip to content

Commit

Permalink
Fixed deprecation: multirobot.py (#329)
Browse files Browse the repository at this point in the history
Signed-off-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
  • Loading branch information
ahcorde authored Jan 23, 2024
1 parent b9b20c7 commit 69743c5
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions drake_ros_examples/examples/multirobot/multirobot.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,11 @@ def main():
for y in range(NUM_COLS):
# Load the model from the file and give it a name based on its X
# and Y coordinates in the array
models[x].append(parser.AddModelFromFile(
model_file_path,
model_name + str(x) + '_' + str(y)))
(iiwa,) = parser.AddModels(model_file_path)
models[x].append(iiwa)
plant.RenameModelInstance(model_instance=iiwa,
name=model_name + str(x) + '_' + str(y))


# Weld the robot to world so it doesn't fall through floor
base_frame = plant.GetFrameByName("base", models[x][y])
Expand Down

0 comments on commit 69743c5

Please sign in to comment.