How to prepare and import SOLIDWORKS Parts and Assemblies

We use the CAD-Line dialog-box | Solids tab to import SOLIDWORKS Part and Assembly documents.


Information-24

The correct Type-Library file must be in the MechDesigner installation directory before you can import documents from SOLIDWORKS.

In MD14 and later, the Type-Library files are installed automatically. If you use a different SOLIDWORKS release, MechDesigner automatically switches to the correct Type-Library when it start next time. To check that the Type-Library is the correct for the SOLIDWORKS release see the Help menu > About > Type Library tab.

Coordinate Systems in SOLIDWORKS and MechDesigner

This CAD-Line is automatically added with the Added-Part.

This CAD-Line is automatically added with the Added-Part.

CAD-Lines in MechDesigner

CAD-Lines are along the centre of all Added-Parts. You can add more Cad-Lines to al Parts with the Part-Editor, at any position, even over/above the existing CAD-Line along the centre of the Part.

CAD-Line Coordinate Systems

Origin of the Coordinate System: the start-Point of each CAD-Line is always its Origin
+X–axis of the Coordinate System: is along the CAD-Line, from its start-Point to end-Point
+Y–axis of the Coordinate System: is at +90º to the +Xaxis
The +X and +Yaxes are coplanar with the Mechanism Plane.
The +Zaxis is perpendicular[] to the Mechanism Plane. In the Front-View of the Mechanism-Editor, the +Z–axis is towards you, the viewer.

The image above shows the CAD-Line that is added automatically to an Added-Part, from its start-Point to its end-Point.

SolidWorks-CS3

The SOLIDWORKS Features

We must add a Coordinate System to the SolidWorks model. I usually do these steps:

1.Add a new Plane 1s-red

SOLIDWORKS > Insert menu > Reference Geometry > Reference Plane

It becomes the XY-Plane of the new Coordinate System.

2.Add a new Sketch2s to the new Plane1s-red:

Add two perpendicular[⊥] construction lines, that intersect.

3.Close the sketch
The directions of the Lines become the +X and the +Y–axes of the Coordinate System.
The intersection of the Lines becomes the Origin of the Coordinate System.
The perpendicular[⊥] to the Plane becomes the +Z–axis of the Coordinate System - using the Right-Hand Rule for Coordinate Systems.

Note that when the you load the SolidWorks Part onto a CAD-Line the +Z-axis will be towards.

Add Coordinate Syastem dialog in SOLIDWORKS

Add Coordinate Syastem dialog in SOLIDWORKS

4.Add the Coordinate System3s

SOLIDWORKS > Insert menu > Reference Geometry > Coordinate System

a.Click the Point at the intersection of the two Lines as the Origin
b.Click the construction line that you want to become the +X-axis
c.Click the construction line that you want to become the +Y–axis.

The +Z–axis automatically becomes normal to the Plane defined by the +X and +Y–axes and the Right-Hand-Rule.

The +Z–axis is towards you, the same direction as the +Z–axis direction as the CAD-Line in MechDesigner.


Procedures to import SOLIDWORKS Documents

tog_minusProcedure 1: Import one SOLIDWORKS Part onto one CAD-Line

SOLIDWORKS Add a new Coordinate System to the document in SOLIDWORKS (see above):

Useful Notes:

STEP 1: SOLIDWORKS > Insert menu > Reference Geometry > Reference Plane

Note 1: Frequently, I add a Plane as an offset to an existing Plane or feature, and very often to offset from the Front, Top or Right Planes in the SW model Part.

Then, if I need to move the Solid along the Z-axis of the CAD-Line, it is easy to do when I can edit the offset dimension of the Plane feature in SOLIDWORKS, and reimport the Solid.

Note 2: Frequently, I add the new Plane to be in-front of the Solid body in SOLIDWORKS

Then, the Solid will display 'behind' the Mechanism Plane in MechDesigner. Then the kinematic elements will show and they will be easier to edit.

STEP 2: SOLIDWORKS > Tools menu > Sketch Entities > Line (Construction Lines)

Note 3 Rather than use an edge feature in the SW Part, I most frequently draw two construction lines on the new Plane. It is easy to edit the sketch later, if necessary, which I reimport.

STEP 3: SOLIDWORKS > Insert menu > Add Reference Geometry menu > Reference Coordinate System

Note 3: Selections:

Take care to select the intersection of the new construction lines and, not say the SW Origin feature.
Make-sure the directions of the +X–axis and +Y–axis are correct, so that the +Z–axis is towards you.

MechDesigner:

Useful Notes:

Note 1: To show the Solid in the Mechanism-Editor that you will import from SOLIDWORKS

STEP 1: Do Visibility toolbar > Show model in Mechanism.
STEP 2: Edit the CAD-Line onto which you want to import the SOLIDWORKS® Part

The easiest way - Click the CAD-Line, then in the Selection-Window, right-click the CAD-Line, and in the contextual-menu click 'Edit element'

STEP 3: In the CAD-Line dialog-box:
1.In the SOLIDWORKS tab, open the 'Model Import from SOLIDWORKS' and the Display Options separators to show their parameters and buttons.
2.Click the Read button [middle button at the top]

Wait until the SOLIDWORKS Part, Configuration and Coordinate System show in the boxes below.

For a large model, this may take perhaps 10 seconds.

3.Click the Import Model button [right of two buttons of the main separator].

Wait until [under the Display Options separator] the Number-of-Vertices becomes a 'number'.

When the Number-of-Vertices is not zero...

STEP 4: Rename the CAD-Line to the same as the SOLIDWORKS Part.
1.Click the 'Rename CAD-Line' button [to the left of the Import Model button]
STEP 5: Edit the Colour of the Solid
1.Click the Colour button to edit the colour of the Solid in the graphic-area.
STEP 6: Does the Solid show 'ghost Lines?

See below

STEP 7: Is the Number-of-Vertices number too high?

See below

tog_minusProcedure 2: Import a SOLIDWORKS Sub-Assembly onto one CAD-Line

If the sub-assembly has many parts and features that are not necessary - for example washers, screws... - then in SOLIDWORKS, create a new Configuration.

In the new SOLIDWORKS configuration, suppress parts and features that you do not need to see in the MechDesigner model. Also, replace fillet with chamfer features from parts.

SOLIDWORKS®:

1.Make active the configuration in which you have suppressed parts and features.
2.Add a Plane and Coordinate System - see above.

MechDesigner

See Procedure 1 above

tog_minusProcedure 3: Many SOLIDWORKS Parts onto one MechDesigner Part

Often you may need to show different SolidWorks Part documents on one MechDesigner Part.

For example, 'tooling' is often rigidly attached to a 'bracket', and the two machine parts move together.

You can import the two parts onto two CAD-Lines, which are in the same MechDesigner Part.  You would edit their colours in MechDesigner to see them as different machine elements.

CAD-Lines in one Part:

In the SOLIDWORKS assembly of parts that move together

1.At the top level of the assembly, add a Plane. We call this the Master Reference Plane.
2.In the assembly: edit the Parts in Context [that is, do not leave the Assembly to edit the Part]
3.Add a Plane to the Part and make it coplanar with the Master Reference Plane
4.Add a sketch to the Planes in each Part, and then the Coordinate System.
5.Make sure the Coordinate Systems of all the parts are coincident in the assembly.

In MechDesigner:

1.Add a number of CAD-Lines to the one MechDesigner Part equal to the number of parts you will import from SOLIDWORKS
2.Make the start-Point of each CAD-Line coincident
3.Make the CAD-Lines collinear
4.Rename each CAD-Line to the same as each SOLIDWORKS Part [you can do this with a button in CAD-Line dialog].

CAD-Lines in different Parts:

In SOLIDWORKS

1.If necessary, add a Master Reference Plane at the top level of the assembly.
2.Add a Plane, that is coplanar with the Master Reference Plane, to each Part you will import from SOLIDWORKS
3.Add a sketch to the Plane in each Part and then a Coordinate System.
4.Make sure each sketch and Coordinate System aligns with the CAD-Line in the respective Parts.

In MechDesigner:

1.Typically, you will import the SOLIDWORKS Parts onto one or more CAD-Lines along the center of each Added-Part.
2.If necessary, if you also want to add more than one SW parts to a MD Part, add more CAD-Lines to the MD Part. As above, make the CAD-Lines co-linear and their start-Points coincident.
3.Rename each CAD-Line to the same as each SOLIDWORKS Part.

Then follow MechDesigner Procedure 1 - see above.

Do Procedure 1 again and again, with each CAD-Line and parts you want to import to MechDesigner from an assembly in SOLIDWORKS®.

tog_minus STL File Import 

When do you need to import import STL files?

When you do not have SolidWorks.
You have or can save a model as an STL file in your CAD software.

Notes: in your CAD software:

Save the STL file in Binary Format and in SI meters
The STL file cannot use a Coordinate System.

Thus, before you save the CAD part as an STL file:

oMove the original CAD part so that its Origin, X–axis, and Y–axis coincide with the Origin,  X-axis, and Y–axis of the CAD-Line in MechDesigner.
oMove the original CAD part along the Z-Axis, to move it relative to the Mechanism-Plane in MechDesigner

Dialog-CADLine-SW-STL

CAD-EdgeLine

To import an STL file onto the CAD-Line:

CAD-Line dialog > SolidWorks tab > STL file import separator:

1.Click the Browse button
2.Select an STL file (Binary)
3.Click the Import STL File Button:

Look at the model in MechDesigner.

Edge Angle Limit parameter and STL files.

We use the Edge Angle Limit parameter to remove 'ghost edges' from facets in the STL file.

If the angle between a facet in the STL file is less than the Edge Angle Limit parameter, then we do not show an 'edge'.

The Edge-Angle-Limit parameter value is a function of the Linear Deviation and Angular Deviation parameters in the 'Model Import from SOLIDWORKS' separator.

Note: I usually make the Edge-Angle-Limit parameter a small value above the Angular Deviation parameter value.


Compare the top image, to the left, with the bottom image.

 

 

 


 

CAD-EdgeLine-NoEdges

tog_minusNOTES: STL Vertices and File Size

Note: The number-of-vertices is not a function of the physical size of the CAD model. It is a function of the complexity of the CAD part and the Angular-Deviation and Chordal-Deviation parameters [see below].

Complex STL files [with too many Vertices] make MechDesigner less responsive. Thus, it is helpful to understand how to control the size of the STL files.


STL files render the surfaces of CAD models as a mesh of triangles, in a process called 'tessellation'. The number of triangles determine the accuracy of the STL file when compared to the original free-form CAD model.

The complexity of the original model and its tessellation accuracy determines the STL file size and ultimately how responsive is MechDesigner.

When you import many STL files, or the files are complex, or both, then MechDesigner can become less responsive.

You can employ two strategies to reduce the STL file size and keep MechDesigner is responsive.

Reduce the Complexity of the Original CAD Model

Model designs containing 'holes', 'gaps' and 'whiskers' adversely affect the quality of the model. Therefore, you should perform a geometry check of the model files before saving to STL.

Reduce STL file size, create a new configuration of the model in your CAD. In the new configuration:

Delete, or suspend, small fillets, especially if they do not have a real function.
Replace fillets with chamfers, if possible.
Remove all fasteners
Delete fastener holes and hole features.
Remove cosmetic details.

Reduce the accuracy of the STL file in MechDesigner.

We instruct SolidWorks to save the model as an STL file, which we then import with MechDesigner.

We use two parameters in MechDesigner to control the accuracy and thus size, of the STL file

These are in the Import from SolidWorks separator

Chordal Deviation:

 

The maximum distance between the surface of the original CAD model and the tessellated surface of the STL triangle.

Maximum Chordal Deviation is 0.5mm.

Angle Deviation:

 

The angular deviation allowed between adjacent triangles.

This setting enables you to increase tessellation for surfaces with small radii.

Maximum Angular Deviation is 30º.

If you save the model as an STL file from other CAD, then look for Angular, Linear or Chordal Deviation parameters, or similar options, before you save the STL file.

tog_minusTrouble-shooting: Active Document does not show in MechDesigner

Occasionally a Part, and more often an Assembly, does not import or show in MechDesigner:

In SOLIDWORKS Parts

Make sure there are not any:

small/tiny, but real, gaps between parts
small parts with complex details - for example, a set-screw.

In the MechDesigner CAD-Line dialog-box and SOLIDWORKS tab

1.Change the File-Quality to Custom, and edit the Linear-Parameter and Angular-Deviation parameters.
2.Re-import.

Experiment with the Linear Parameter and Angular Deviation parameters to import a Solid with 'fine' details, or with 'coarse' details.

Tutorial and Reference Help Files for MechDesigner and MotionDesigner 13.2 + © Machine, Mechanism, Motion and Cam Design Software by PSMotion Ltd