FreeCAD Tutorial 1d: Design of an Electronic Box, Concluded

From Artisans Asylum Wiki
Revision as of 10:36, 16 August 2025 by Jfbredt (talk | contribs)

Link to: CAD Main Page

Link to: Tutorial 1c (prev)

Introduction

This tutorial concludes the sequence for designing a sample electronics box to demonstrate how to use FreeCAD.

In the previous tutorials, most of the basic tools have already been addressed. In the steps that follow, knowledge of these tools will be assumed. If you are unfamiliar with any of these tools, you may want to review the previous entries in this sequence.

In the series leading up to this one, we designed the E-box with a number of mounting features that permit a small circuit board to be mounted. The geometric constraints that were demonstrated allow for the dimensions and mounting features to be changed around to fit circuit boards of different sizes with different mounting footprints.

pic47a

One important feature that hasn't been placed yet is a pass-through to get wires in and out of the box. We will design this next. We will also design a raised-text label for the outside of the box.

We will also design a raised-text label for the box. This will use another segment of FreeCAD, called the Draft Workbench.

Cable Pass-Through

This feature uses tools that have already been introduced previously. Click on one of the longer side walls of the box. For this lesson we select the face whose normal vector points in the +Y direction.

pic54

Use the (FreeCAD sketch icon.jpg) "Sketch" tool to open a new sketch. Using the (FreeCAD circle icon.jpg) "Circle" tool define a 1/2" circular hole in the upper half of the box. Close the sketch.

Select the (FreeCAD pocket icon.jpg) "Pocket" tool to turn the circle into a hole. Make the depth of cut something deeper than the wall thickness.

pic56

Note: In the previous tutorial we mentioned a bug with the (FreeCAD 3D fillet icon.jpg) "3D Fillet" tool. If this bug were expressing itself, this hole wouldn't appear as shown above.

Select the same face and open a new sketch. Use the (FreeCAD extern geom icon.jpg) "External Geometry" tool to select the circle from before. You will need to create a second circle in this sketch identical to the first. After that, sketch another circle somewhat bigger in diameter. If you make it 0.7" then the wall thickness will match out standard wall thickness of 0.1".

pic57
pic58
thin strip

Close the sketch. Use the (FreeCAD pad icon.jpg) "Pad" tool to raise this sketch into a 1" long sleeve.

This pass-through isn't terribly sophisticated, but it would carry some wires in to the circuit board. In a future tutorial we will add more features to this pass-through to grip the wires more securely.

Raised-Text Label

Design the Text

FreeCAD is an application comprised of a group of smaller applications (called Workbenches) that are able to pass data between each other. To create a raised-text label for the box, we need to use the Draft workbench.

To keep things clean, open a new document from the "File" menu. Select the (FreeCAD draft icon.jpg) "Draft" workbench from the pull-down menu along the upper edge of the window.

pic59

Up to now we have only used the (FreeCAD part design icon.jpg) "Part Design" workbench and the (FreeCAD sketch icon.jpg) "Sketcher" workbench. This workbench contains tools that aren't duplicated in the other two.

You will see a new graphic window open that looks a little bit different from the previous ones. In the upper left of the window, there is a button that indicates the working plane, (XY) by default. Click on the button to select the (XZ) plane.

pic60

The reason we need this plane is because we seek to place a label on the face opposite the one where we placed the pass-through. This face is oriented perpendicular to the Y-axis, hence it is the (XZ) plane.

Select the (FreeCAD shapestring icon.jpg) "ShapeString" tool. This opens a window in the left margin of the window where you can place coordinates, a text string, and select a font.

pic61

The coordinates shown are chosen to place the label in the correct location on the box we have designed. You will be required to select a font for the label. Hit the (FreeCAD ellipsis icon.jpg) "..." button to open a file picker. Navigate to C:\Windows\Fonts\ and pick a font. For this project we select "arial.ttf".

You should see a preview of the text entity in the graphic window. Click the "OK" button to accept.

pic62

This file contains only the text string entity. Hit "CTRL-A" to select everything in the field. Hit "CTRL-C" to copy the entity into the Windows clipboard.

Paste the Text String into the Design

Pull down the "Window" menu from the tool bar at the top of the screen. Select the working document containing the box you are designing.

Hit "CTRL-V" to paste the text entity into the design.

pic63

You will see the text string appear in the design space for the E-box. A box displaying the entity's properties is displayed in the left margin. In the very likely event that you will need to adjust its position or size you can make the changes in this box.

Extrude the Text Entity

If you select the "ShapeString" entity and pick the (FreeCAD pad icon.jpg) "Pad" tool it is very likely that you will see the error message shown below. To cure the problem, click on the "ShapeString" entry in the feature list and drag it up over the "Body" entry in the list. You should see a minor change in the indentation of the "ShapeString" entity to indicate that it has been included in the E-box design.

pic64
pic65
thin strip

You should be able to use the (FreeCAD pad icon.jpg) "Pad" tool to extrude the text into the box wall. The properties chosen above creates a label 0.15 inches tall. Double-click on the "ShapesString" entry in the history list to adjust the properties of the entity and locate it in an appealing position.

pic66

Please note: If you change the width of the box from 2.5 inches to some other value, the raised text label will remain fixed in space and NOT move to the revised position of the box wall. IT is a bit of nuisance that the label must be positioned independently.

Fillet the Top Lugs

Now that the design is complete, it should be possible to add fillets to the lugs around the top edge of the box.

If you are unfamiliar with how to use the "3D Fillet" tool please review the item in an earlier tutorial.

pic67

Conclusion

This concludes FreeCAD Tutorial 1. At this point you should have all the skill necessary to design relatively simple parts. Designs you create with these tools will have an appearance as though they were carved from a brick. If you want to design parts that have a more freeform appearance, you will need to learn some additional tools such as rotational extrusions, lofts, and sweeps. These will be presented in a future tutorial.

FC1d-thumbnail.jpg