CAD Import

CAD Import is the second and final step of CAD translation. During CAD import, SimMechanics™ interprets the SimMechanics Import XML file generated during CAD Export. Then, based on the structure and parameters that the XML file provides, SimMechanics automatically generates model that replicates the original CAD assembly.

Importing a Model

CAD Import does not require access to the original CAD assembly or associated CAD platform. Access to the surface-geometry files is not required for simulation, but it is required for visualization. You can simulate an imported model that contains no geometry files. However, the Mechanics Explorer visualization utility cannot display a representation of a model without the geometry files.

In the model, each CAD part maps into a rigid body subsystem. Each CAD constraint or set of CAD constraints, map into a joint. Block names for SimMechanics subsystems are based on the original CAD parts and subassemblies which the subsystems represent. SimMechanics appends the suffix RIGID to the stem of a rigid body name. For example, CAD part base translates into rigid body subsystem base_RIGID. The following figure shows the imported SimMechanics model of a CAD robot assembly.

Modify SimMechanics model to fit the needs of your application.

Generating Import Files

To import a multibody model into SimMechanics, you must first generate the SimMechanics Import XML file. You can generate this file automatically, using the SimMechanics Link utility, or manually, using the XML schema that MathWorks® provides. The method that you use depends on the type of model that you want to import. The table summarizes the two methods and their limitations.

Import File Generation MethodLimitations
SimMechanics LinkWorks only for CAD assemblies. CAD assembly must come from one of three supported CAD platforms.
XML SchemaRequires knowledge of XML file generation based on XML schema

SimMechanics Link is a free utility that MathWorks provides. Use this utility to generate the SimMechanics Import XML file that you need to import a CAD assembly into SimMechanics. For more information about SimMechanics Link , see Install and Register SimMechanics Link Software.

SimMechanics XML Schema

The XML Schema is a set of files written according to the W3C XML Schema specification. MathWorks provides these files so that you can generate a SimMechanics Import XML file manually or using an external application. Use the XML Schema to generate the SimMechanics Import XML file for a CAD assembly or other multibody model.

The XSD files describe the elements and attributes that a SimMechanics Import XML file can contain and the order in which they must appear. Generating an XML file in accordance with the XML schema ensures that SimMechanics can successfully import it. Once you have generated the XML file, validate it against the schema to ensure SimMechanics can import it without issue.

To access the SimMechanics XML schema, visit the SimMechanics product website. Follow instructions to download the XSD files.

See Also

Related Examples

More About

Was this topic helpful?