Jona Noah Breitenbach - Fab Academy 2024

2. Computer Aided design

This week I try some CAD-tools to model parts of my final project. On this site you will find information about the tools I used and what I did with them. The model parts for my final project you can see here

3D Tools

OpenSCAD

OpenSCAD is not like the usual CAD tools with very visual, point-and-click tools. It is a programming language for geometry, so I can keep my hands on the keyboard and define what my parts look like.

OpenSCAD's user interface with a simple cube example. The left part of the window shows the source code, the right part shows a rendering of the model.

Looking at the models turned out to be one of the harder parts, as turning them with a mouse can be a hit and miss and seems really anti-intuitive to me. Also, the preview renderings are fast, but sometimes incomplete.

I started modelling a rough idea of my final project, and stayed with that for all of the evening. And the night. Until I had a representation of what my foot-trackball should look like when it's complete. The parts are at the Final Page, with just the actual trackball part here as a teaser:

Source code

To build something in OpenSCAD, you have to put it together from basic geometric parts like cubes or spheres. Those parts can be configured to have a specific size, either from variables (as in the first example above) or just numbers. To put the basic parts at a specific place you define a new coordinate system, which can be shifted to a new place, and tilted to any angle:


Source code

The parts can then be put together (with everything from them being there), one removed from the other, or other kinds of interactions:


Source code
Source code

Any form could (theoretically) be represented this way, but it can of course get complicated, mostly when things are round. To make things easier there is a good cheat sheet so you don't have to memorize all the commands.

Fusion 360

One of my instructors gave me a really interesting introduction to Fusion. It is used a lot at our Fablab, freely available to us and it works on my Macbook, so it is an interesting tool to look at.

It was obvious Fusion can do almost anything, making it a powerful, but also complicated tool. So complicated that I did not get very far in designing something of my own in it, as I couldn't find my way back to the right functions and how they work.

I will have to take another look at Fusion when I have the time (and someone who knows) to really find my way in there and to make a map of where to go. For now, this is not the way to go for me, as I prefer numbers and calculations over mouse clicks in filled up screens.

Some weeks later, Yassine tried to explain the basics of Fusion 360. I feel like I start to understand a little bit more of it. So here is the result:

Try to make something in Fusion.
Source file

ChatGPT

When there is an absolutely different-to-everything tool I have to check it out. The mention of ChatGPT being able to program models in OpenSCAD made me curious, so I had to try. I tried to define what my final project trackball should look like, and ChatGPT delivered working OpenSCAD code:

Source code

While the code works, the results are a bit off from what I had intended. A floating trackball would be super cool, but would probably use more power than the laptop it is connected to.

BlocksCAD 3D

After I had used scratch and turtle stitch to teach programming to students form the schools around in courses I was pleased to find BlocksCad 3D. It is an online tool, you can make an account and have your models on their server and use them from anywhere, but you can not save them to your computer directly.

There is a lot of help and demo projects, and the user interface is relatively intuitive and offers lots of information on what different parts do. You can program it by putting blocks of code onto the workspace, configuring them and coupling them together.

A test part in BlocksCAD, with the tree structure of the source at the left, and a rendering of the model at the right, showing the bottom half of a ball with a cube cut from its center.

Learning to make some little things in 3D and also in 2D is easy. Making complex things needs a lot of work arounds, which makes it unnecessary complicated. What I like is that BlocksCad shows you the OpenSCAD code of the things you build. It seems to be a good program to learn how CAD works and how programs can be structured even if programming is new to you.

Screenshot of a somewhat more complex model, adding a ball on four legs to the half-ball.
Exported OpenSCAD source

Exported OpenSCAD code works fine in OpenSCAD, the models can be exported directly from BlocksCAD (in some different formats, even directly uploading them to thingiverse or Makerbot) or using OpenSCAD. This could also be used to keep local copies of your designs.

CADQuery

As CADQuery claims to be a way better alternative to OpenSCAD, and I fell into OpenSCAD for a whole evening, I had to check this.

Installation is a time-consuming procedure working from a manual that explains nothing. There is a graphical IDE for working with CADQuery, CQ-Editor, that can be installed at the same time.

CADQuery is a library for Python, so the model is Python code. And while Python is evil in itself, CADQuery is a masterpiece in being anti-intuitive. With Python's object oriented parts, each model (or part of a model) is an object, any modifications to the shape are done using methods of that object. The source code quickly gets either very long or becomes incredibly hard to read. Useless documentation and empty error messages do not help.

It is still an interesting approach, as it can do more than OpenSCAD (inner fillets...) and it can output STEP files directly. I did a test model in it:

Source code

As you can imaged after the short introduction to CADQuery, this tool is not something I wanted to use again. And if you are not really good in programming in python I would strongly recommend to keep away from it.

2D Tools

OpenSCAD

As I had a lot of fun with OpenSCAD, I also hat to try its 2D capabilities. They are not that different from the 3D parts, and allow you to program your models instead of clicking them together. The only really brainfucky thing is that you need a 3D rotation (around Z!) to rotate 2D objects on their plane.


Sourcecode

BlocksCAD 2D

Designing something in 2D is not that different from the 3D parts. In the beginning it can be a little bit confusing that the blocks are almost the same and the z-parameter only disappears if a 2D object is used in the same section.

Screenshot of a 2D mosaic in BlocksCAD.
Exported OpenSCAD-Source

Affinity Designer

I have done some design work with Affinity Designer in the past, like front panels for a measurement device. That worked well, so Affinity will have to be mentioned here.

Affinity Designer is a design tool, not really meant for CAD. It can import most graphics formats, and export a lot of them, so including existing drawings or things like logos, warning signs or cat pictures is easy. It can be used for relatively trivial CAD tasks like the front panels, as it can do vector graphics to precise coordinates.

Affinity Designer with a measurement device front panel opened.

There are videos online of people claiming to use it for more complex CAD tasks, but that will run into serious problems as Affinity just does not have the tools for that. Working with the measurements tool to precisely place things is not efficient in any way, and it can neither do relative coordinates nor parametric design of any kind.

Source file