How can I model a nearly complicated robotic system?

1 view (last 30 days)
I am trying to model a 5 DOF robotic system to evaluate my driven kinematic and geometric modelling but this robot includes 5 kinematic chains that makes it somekind of complicated. Also the fact that I am new to robotic modelling adds up to it. I tried to design cad model of robot in Solidworks and import it to matlab simulink using
smimport
command but without getting any errors, my model doesn't work properly. Everytime I try to fix the model and run the simulink model, I face new problems such as most of the joints not moving or broken assembly. Also I cannot add it to workspace with the command
importrobot
I get some errors like "Targets or motion inputs are specified for every joint around a kinematic loop". I'll attach the picture of robot model, its simulink generated model and file of simulink and Solidworks model. I'll be so grateful if anyone could help me or give me a hint.
Robot model in Solidworks (1)Robot model in Solidworks (2)
and all of the related files are in a attached zip file

Answers (1)

Hannes Daepp
Hannes Daepp on 5 Aug 2024
Hi Ehsan,
I understand you are trying to import a robot from CAD to Rigid Body Tree via Simscape. If you are unable to model the system correctly in Simscape, then you will not be able to import it into rigidBodyTree, as it must successfully compile in order to be imported (hence the errors you currently see).
If your ultimate goal is to get your model into a Rigid Body Tree object, you can alternatively use a third-party SolidWorks-to-URDF tool like SW2URDF. An exporter like that will guide you through the steps to eliminate closed loop kinematic chains so a URDF can be created. Then you can import the file directly to rigidBodyTree by calling importrobot on the resultant URDF.
If your primary goal is instead just to get the model into Simscape, then you will need to resolve the specified warnings that you see to get the model to compile there. This may be difficult to do on MATLAB Answers due to model complexity, in which case I would recommend you create a technical support request:
Hope that helps.

Community Treasure Hunt

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

Start Hunting!