How to import a 3D CAD on simulink , if I am using Apple Macbook ?

I want to import a 3D CAD of my inverted pendulum on Simulink with SimMechanics. I have a bootcamp windows 10 installed and I work on 3D modelling over there. I have tried saving the CAD file of SolidWorks in the form of .step file but it does not works on simulink .

4 Comments

Please provide more information about the problem.
  • When exactly does the problem happen?
  • Are you getting any error message? If so, post the complete error message.
When I used VR Sink in Matlab and browsed my step. file
Warning: Virtual Reality engine warning: XML Parser fatal error: line: 1, column: 1, message: invalid document structure. [3 similar] Error reported by S-function 'vrsfunc' in 'untitled/VR Sink': Error reading virtual world file: invalid document structure. Component:Simulink | Category:Block error
It sounds as if it is not a STEP-XML file
VR Sink would be for writing files. You would need VR Source, which can handle VRML and X3D files.
The same message shows up for VR Source as well .

Sign in to comment.

 Accepted Answer

To export a CAD assembly from SolidWorks to Simscape Multibody (formerly SimMechanics), you can use Simscape Multibody Link.
The following documentation page provides information on how to install and enable the plug-in: https://www.mathworks.com/help/physmod/smlink/ug/installing-and-linking-simmechanics-link-software.html
Once Simscape Multibody Link is installed and enabled, you can refer to this documentation page to export the CAD model: https://www.mathworks.com/help/physmod/smlink/ref/exporting-assemblies-to-physical-modeling-xml-format_brnjwi7-1.html

2 Comments

I am using macOS, thus I don't have access to Solidworks on the macOS where I have my Matlab application . While I have a bootcamp to work on Windows, there I have my Solidworks application. Can these two be still related ?
Unfortunately the Multibody Link uses ActiveX, which is not available on MacOS, so even if you used Parallels to be able to run the Windows version of Solidworks at the same time you were running MATLAB on MacOS, you would not be able to make the link.
About the only thing I can suggest is that you can run Parallels to not have to boot into bootcamp to run MS Windows. It runs acceptably well (but it cannot have direct access to the graphics hardware or any GPU.)

Sign in to comment.

More Answers (0)

Categories

Find more on Simscape Multibody in Help Center and File Exchange

Products

Community Treasure Hunt

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

Start Hunting!