Scripted Drafting

Suppose you want to create a drawing for a simple part, like a typical tensile dogbone.

An “A” type tensile dogbone according to ASTM E345.

You could draw up this part according to specifications in a conventional drafting program. But parts like this often come in different sizes with different proportions, depending on the material and your testing needs. So for this kind of part, there’s a strong chance you would need to draft different versions to satisfy different specifications. When that need arises, your first impulse might be to draft a whole new part or modify an old one as needed, but there is a more efficient approach.

A dogbone drafted exactly according to E345.

The key is in recognizing that all of the dogbones you are making have the same basic features, and you can follow the same basic steps when drafting each one. Here is one possible workflow:

  • Draw a rectangle for the reduced middle section
  • Draw rectangles for the grips at the ends
  • Subtract out the rounded fillets

Regardless of how long, wide, or thick the dogbone is, you can make it following those same steps. All that changes are the measurements.

A dogbone that is half as wide, but four times as thick as the last one.

So if we approach our drafting project as a sequence of steps, we can draft practically every conceivable dogbone with the effort of drafting just one. It turns out that many software suites out there have some kind of scripting capability. For our example, there is a good free option: OpenSCAD.

Scripts on the left panel lay out the steps of drafting a part. The right panel shows a preview of the result.

OpenSCAD only lets you draft parts with scripts. Making an all-purpose dogbone-making script is simply a matter of setting up the variables which describe the part dimensions up at the beginning of the script.

Note how I decided to build in a little math for the grip lengths so they do not need to be defined separately.

Then, when it comes time to create the part, the same set of steps are followed every time.

The steps to creating a “dogbone” part are always the same. Only the measurements change.

So now you only need to change the numbers at the beginning of the script any time you want to draft a dogbone with new dimensions. This concept of simple, scripted drafting should work with a variety of parts. Keep an eye out situations where:

  • You are designing simple parts
  • The parts’ interrelated measurements that can be handled algebraically
  • Any part can be made by repeating the same set of steps
  • You will need to draft multiple versions of the part

If you use scripted drafting, you can save yourself the trouble of having to go back and re-invent the part from scratch each time. All it takes is a little thought focusing on the steps it takes to make the part rather than just the end result.

A wide, thick dogbone made by simply changing a few numbers and re-rendering the part.

Author: Wade

Materials scientist, lab manager, and educator based in the Seattle area.

Leave a Reply

Your email address will not be published. Required fields are marked *