フィルターのクリア

How to add .stl file to a robot?

18 ビュー (過去 30 日間)
Valeria Leto
Valeria Leto 2021 年 5 月 12 日
移動済み: Remo Pillat 2024 年 3 月 29 日
Hi! I would like to add an .stl file to a robot link created with the robotic toolbox. I checked the Visuals field of the body and the model has been loaded properly, but when I use show(robot) nothing happens. How can I fix it?
%body1
body1 = rigidBody('body1');
addVisual(body1, "Mesh", 'IRB 910SC_IRC5C_Arm1_450_rev0.STL');
  3 件のコメント
Valeria Leto
Valeria Leto 2021 年 5 月 13 日
Hi! I thought it was a mesh problem. I can't loas my stl file at the moment, don't know why. I took it from ABB site.
Valeria Leto
Valeria Leto 2021 年 5 月 13 日
the output to body1.Visuals is 1x1 cell array

サインインしてコメントする。

回答 (1 件)

Yiping Liu
Yiping Liu 2021 年 5 月 13 日
移動済み: Remo Pillat 2024 年 3 月 29 日
Valeria,
It might be a scaling issue, i.e. the dimension of the meshes is too small to be seen when rendered.
If you importrobot from URDF, and if the URDF file specifies the scaling for the mesh, the scaling of the mesh will be handled automatically. But if you do it from addVisual, you have to do the scaling on the mesh file yourself, which is not that straighforward.
But that's just a guess, please share your mesh file and the robot description, so we can take a closer look.

カテゴリ

Help Center および File ExchangeRobotics System Toolbox についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by