Introduction: Convert STL to DXF Using Open Source Tools

About: http://about.me/hemal_chevli

Background

I recently did an arduino workshop at Makers Asylum, I also took my DSO nano v3 to show how PWM works. Came back home and found the stand for the DSO was missing. Also the one that came with the DSO was not good. So I decided to make one. I thought of designing it my self from scratch, but before I did, I searched thingiverse for similar stands, luckily I found one(here), the design was robust and I just had to cut it out. I have a laser cutter,no 3d printer sadly. So had to convert the stl to dxf for my laser cutter.

I looked for some stuff online to convert it but it just didn't cut it.

Tools Used:

For those who want to go gungho, import the stl in blender, clean the file so that only the contours of the object remain, export it as DXF.

Before you begin make sure you have blender and Qcad installed and the stl file that needs to be converted.

Step 1: Import File in Blender

Start blender, you be show a cube a camera and a light source, press 'a' to select all and 'x' to delete it.

  1. Go to File>Import>STL
  2. Open up your stl, use scroll wheel to zoom out.
  3. Press tab to go in edit mode, now all the vertices will be selected. Press 'a' to deselect,
  4. Press '1' on NUMPAD to go to front view
  5. Press 'z' for skeleton view
  6. press 'b' for border select, click and drag so that all the upper vertices are selected. DO NOT SELECT THE FULL MODEL(refer the images)
  7. press 'x' to delete, a menu will pop up, asking what to delete, select vertices. Make sure you are in Edit mode, else the whole STL will be deleted.
  8. Now you should have a flat shape.

now its ready to be exported.

  1. Go to File>User preferences>Addon>Import-Export> check mark Export autocad dxf format. close the dialog
  2. Dxf should now be visible in the export options
  3. Go to FIle>export>autocad(.dxf)
  4. Save window will open up with some options on the left.
  5. Select projection as "TOP"
  6. Export mesh as "Polylines"

That is it, now your dxf is ready.

Step 2: Open in Qcad

Fire up Qcad and open the exported file.

In this example one small line was missing, so clean that up. now the tab size were 4mm thick so I had to reduce the size to 3mm, as I'm using 3mm acrylic for laser cutting.