Quantcast

Documentation Center

  • Trial Software
  • Product Updates

Import Stewart Platform Model

You can import a CAD assembly into a SimMechanics™ model. To do this, you use the SimMechanics command smimport. In this example, you import the CAD assembly for a Stewart platform. All required files are provided with your SimMechanics installation.

Check Import Files

To import the CAD assembly, you must have access to the SimMechanics Import XML and STL files for this assembly. Check that you have these files before proceeding.

  1. Navigate to directory

    <matlabroot>/toolbox/physmod/sm/smdemos/...
    ...import/stewart_platform
  2. Check that the following files exist.

    FileQuantityDescription
    SimMechanics Import XMLOneProvides model structure and parameters
    STLMultipleProvides part geometry

Import Model

If you have access to the import files, you can import the model. To do this, at the MATLAB® command line enter smimport('stewart_platform.xml'). SimMechanics automatically generates a Stewart platform model. This model replicates the original CAD assembly.

Visualize and Simulate Robot Assembly

You can now simulate the model that you imported. On the Simulink® tool bar, click the Run button. Alternatively, press Ctrl+T. Mechanics Explorer opens with a dynamic display of your model.

By default, Mechanics Explorer uses a Z axis up view convention. This convention differs from that which most CAD platforms use—Y axis up. The different view conventions cause the Stewart platform to appear sideways in the visualization pane. To fix this issue, change the Mechanics Explorer view convention to Y axis up:

  • On the Mechanics Explorer tool bar, in the View Convention drop-down list, select Y Up (XY Front).

To refresh the visualization pane using the new view convention, on the Mechanics Explorer tool bar, click any standard view button, e.g., Isometric View.

    Tip   Actuate the stewart_platform model with blocks from the Forces and Torques library. Then, simulate the model and analyze its dynamic behavior in Mechanics Explorer.

See Also

Related Examples

More About

Was this topic helpful?