For the sake of experimentation, I decided to make a cube model using an open-source software: OpenSCAD. The software presents the advantage over previously mentioned Fusion 360 as it is mentained by the open source community and their entire documentation is published online, as well as the software is open to use for anyone.
The way OpenScad is structured, it has a code that is visually displaying the elements. This can be viewed in the interface on the left side, while on the right we can see directly the visual output in the three dimensions.
To see the dependency between the code and the visual output, we will load an example.
Here we can notice three objects, which are generated using two objects:
This gives us the understanding that the software operates like a programming environment, each object can be directly defined and influnced using the code. Now, let's create our own shapes.
First, to keep in mind all the necessary cheatsheet functions and operations can be found here.
We start by producing one square, like a box basically. For that we write
This time we want to create another face of the box, however touching only one margin. We use the
We will continue doing this for the rest of the sides, adding lines of code for each of the faces, tilting at the right axes and with necessary degree.
However we can't continue in the same fashion, some faces need to be moved accordingly using the same distance as the length of the side. For that we use the
We are left with top face. In this case, we use the translation function in the Z axis only by moving it with the same distance as the size.
To make this design parametrical, we need to make sure that changing the size of one face is replicated accross all of them. For that we create a new variable that can replace all the size variables accross all the faces,
Changing the cubeSize variable quickly shows the mistake in the code. Some faces are not scaled since they are static.
To improve that, we replace the variable of the translate function with the cubeSize variable.
Now, by changing the cubeSize variable we can quickly get a change in the size of the overall cube.
As an assignment for this week, the goal was to experiment both with a 2D and 3D software that will represent a sketch of a project. Having this in mind, I decided to work towards my final project and as a tool, use the ubiquitous tool provided by Autodesk, Fusion 360.
The idea is to create a model that represents the physical built of the final project. This implies modeling the entire object in 3D, parts of which will be extracted for 2D use later on in the process. That way accomplishing the needs of the assignment.
Fusion comes handy in creating 2D designs which the software defines as sketches. The name "sketch" is quite intuitive, as one creates a 2D digital sketch, with all the necessary measurements and parameters he/she can later on rely in order to "extrude" the 3D objects. The sketch is easily accomplished in the "Sketch" tab, by selecting the necessary tool to work with.
Since the concept of the final project is to have a modular cube, we will create a 2D square by choosing the right tool and indicating the right sizes of the corners, in our case
By using the constraints in the
This sketching tool will be used quite often to create parts of the model in 2D which will later be transformed to 3D. Coming back to these sketches gives us the control of the final 3D design, since changing the parameters of th 2D dsign directly impacts the final model in 3D.
By using the hand
In order to build on top of the current design, it is handy to create a new
On top of this we will construct another sketch, which will include the models of the electronic components. In this case, the model of the Attiny84 microcontroller.
We continue by creating the model of the
Then on top of that same 3D cylinder, another
And extruded to the size of the LED.
To create a roundy edge,
Our 3mm LED is succesfully created, we can take and reposition it in the desired way. For that all the bodies created are selected, and using second-click we choose
The end design will have 2 LEDs on each side of the cube. We would like to space them evenly. For that we need to create cross-planes, using which we can mirror the created objects. By going to
Now using the
In a similar way we create the coin battery.
As well as create a board on top of our battery.
The top PCB will have a matrix of LEDs on it in forms of the cubes. Using the intersection of mid planes we create the first LED cube.
Now using the
We apply the same technique to the same created cube leds, already in the Y direction.
As a result we obtain a beautiful matrix of LED that is evenly spaced on top of our PCB.
The current task is to create the case of our cube. The bottom lid will serve as an opening, having a circle using which the user can grab the lid and open it. For that, two other circles are created, one with smaller radius with about 2mm offest from the bottom pcb and the second with a bigger radius about 4mm ofset from the bottom pcb.
Using the
As a result we obtain this beautiful shape.
To seal the object, we extrude another Sketch, by using the
To create a good attachment of the bottom lid to the board, some corners are extruded.
In a similar fashion, these corners are positioned on each of the board's corner and negatively extruded, which creates a
We endup with a nice cover, which has PCB mounting on top and opening lid on the bottom.
It is time to creat the outside case. For that, another sketch is created on the bottom lid. Two squares, one matching the size of the cube face and another being 3mm wider. This creates an area in between these two squares which allows for the casing to be extruded.
As a result we extrude the side walls which are a bit higher than our overall construction.
To finalize, we create another sketch on top of the current walls, to seal the deal.
To make an even more interesting shape, a smaller square is created with an offset height from the top lid.
Then we use again the
As a result we obtain a rough model of the final project, with all the electronic components, casing and overall built.
In order to export the 3D model's skethces in 2D, we directly click on the object's face and select
In the new sketches created we second-click the file and select
This can then be imported in Eagle to create the dimension of the board
Similarly, bodies can be exported as