Skip to content

5. Electronics production

This week I worked on an assignment with two parts. - Group assignment: Characterize the design rules for your PCB production process - Individual assignment: Make an in-circuit programmer by milling the PCB, program it, then optionally, trying other processes.

Machine characterization

- MODS

To start working with you have to select the machine and the task with it in order to work with. This image shows the steps to rout PCB with the Roland Modela MX-20.

Once you did the last procedure we need to select the PNG traces images to work. MODS works with PNG images because JPG is a compressed image format, so, does not have good quality in the boundaries of the traces. The image has to be in the highest resolution as possible to get the best result in the routing. Finally, you have to have two images, one for the traces and the other for cutting.

Before you start generating the toolpath, you have to select the tool type.

1. Is for mill traces, in other words, for routing. If you are working for the first time with this machine is fine to work with these parameters and the 1/64” end mill for tracing your PCB.

2. Is for cutting your traces outline. By selecting you can use the default parameters and the 1/32” end mill for cutting.

After you get used to using the machine and you want to change some parameters want or you just bought a millimetric end mill this is how you can change them. 1. Here you can change the end mill diameter, either in mm or in not both.

2. Here you can change the cut depth, either in mm or in not both. This is a very important parameter because this value can cause damage to your end mill.

3. Here you can change the max depth that means how deep your end mill goes through the material. The value of this parameter has to be the material thickness plus 0.2 mm if you want to cut your board, otherwise, it has to be less than the material thickness and more than the copper layer thickness.

4. Here you can change how much copper you want to removes of your traces. This parameter works very well by default using 4 to do traces and 1 for cutting. Choosing 0 as an offset you tell to the machine to remove all the copper except the traces, but you extend considerably the machining time.

5. Here you can change the offset step-over the standard value of 0.5 of the diameter work pretty well more than that you can damage the traces less than that it will improve the quality but the machining time it will grow.

6. Here you can choose the sense of the toolpath.

7. With this you generate the toolpath.

8. With this you can see a preview of the toolpath searching errors.

1. Here you can change the feed rate. This parameter is sensitive because a wrong number of this can cause end mill damage, you can increase this value depending on you end mill quality or type.

2. Here you choose the toolpath origin in the X-axis.

3. Here you choose the toolpath origin in the Y axis.

4. These parameters work fine by default.

1. Here shows you if the machine is connected or not.

2. With this button you send the toolpath file to the machine.

- Modela MDX-20

Here I show you the main parts of the Modela MDX-20.

1. This is the spindle, it has a fix RPM.

2. This is the end mill in the end mill holder.

3. This is the power button. After you press this button the machine makes home. Is recommended to turn on the machine before you start the MODS for assuring the connectivity.

4. This is the view button that moves the plate to the front if you want to check or fix on it a raw material before the machining.

5. With these buttons you set the Z-axis zero.

7. This is the plate where to fix the raw material.

Here I show you what we use for the characterization.

1. We used Double-sided foam tape to fix the copper board on the plate.

2. After fixing the board you have to check the right adherence of the board pressing it.

1. We started cutting the outline first in order to feel the machine working.

2. And the using the X, Y axis values we changed the origin and the cut again.

3. After cutting with different parameters and end mill diameters we achieve a great cutting using a feed rate of 2 mm/s and 0.05 mm of max depth for tracing. And the same feed rate for cutting but the cut depth that has to be of 0.3 mm with a 1.8 mm of max depth.

4. The result of the machining.

This is the end mill.

1. This is the tip of the end mill and its diameter determines how much material it will remove during its movement.

2. This is the body of the end mill and you attach to the end mill holder by this part. Its length depends on the end mill type.

Here I show you how to attach the end mill to the end mill holder.

1. Remove the screw using an ALLEN tool.

2. Put the end mill checking the length that is outside. And the adjust again the screw.

Files to characterizing the machine

Test for routing file

For cutting the test

ATtiny45 ISP Programmer building

- PCB machining

After I figure out how to proceed to the machining knowing the parameters I started with the traces of the ISP ATtiny45 programmer.

1. The dust of the board is much more than the dust if you just do the traces, so always take care of it.

2. The end mill I used was a 1/32”. According to my tries doing it, I suggest give a cut depth of 0.3, first of all, because you have to care to your end mill and also because the motor drivers for MODS does not work optimally to give it much power.

3. After the cutting process ends you have to check before you remove the PCB, in order to machine one more time with more depth. This is because the Modela MDX-20 does not have any kind of Z-axis homing.

Files for the machining

Traces

For cutting the traces

Faced problems and solutions making the PCB

Problems:
  1. I use the default cut depth using the V end mill.

  2. The board could not be optionally flat so this is what happens if you mill a not flat copper board.

  3. Here I show what happens if you use the V end mill like the standard one. The traces are too thin because the V end mill diameter grows with the depth.

  4. I used an end mill type V. Using it I realize that you have to be very accurate with the cut depth, otherwise you will screw the PCB up.

  1. I made a board with thin traces. Here is the result.

  1. I used 0 as an offset so the machining toke too much.
Solutions:
  1. The solution was reducing the cut depth from 0.1 mm to a range of 0.35-0.5 mm.

  2. I remake the PCB reducing the cut depth.

  3. I used 1 as an offset reducing the machining time and even the toolpath calculations.

- Welding the components

List of components

Component SMD Code Quantity
ATtiny45 or ATtiny85 TINY45 or TINY85 1
1kΩ resistor 1001 2
499Ω resistor 4990 2
49Ω resistor 49R9 2
3.3v zener diode W4 2
red LED NONE 1
green LED NONE 1
100nF capacitor NONE 1
2x3 pin header NONE 1

Faced problems and solutions welding the programmer

Problems:
  1. The ATtiny45 started heating up and the red LED did not bright well.
  2. The PCB buses are too thin.
Solutions:
  1. The ATtiny45 was welded in the wrong side.
  2. I tinned all the PCB to make the bus strong.

- Programming the Programmer

I used to program the ATMEL Small translucent blue programmer it shows in the number 2. The number 1 shows my board which is a board with the ATtiny45. I show the USB extension cable used in the programming process.

Steps to program the ISP ATtiny45 programmer

These steps are for Linux OS.

Step 1:

First of all, you have to install the avrdude gcc-avr avr-libc make library in order to make the follows processes.

sudo apt install avrdude gcc-avr avr-libc make
Step 2:

The follows step is to download the firmware source code and extract the zip file. Open your terminal program and cd into the source code directory.

Step 3:

Next, you have to open the Makefile and edit the parameters 1 and 2 depending on the case: 1. The microprocessor:

MCU = attiny44
MCU = attiny45
MCU = attiny85

  1. The kind of programmer
  2. Large translucent blue programmer:
PROGRAMMER ?= jtag2isp
  • Small translucent blue programmer:
PROGRAMMER ?= avrisp2
  • White box with a blue stripe:
PROGRAMMER ?= atmelice_isp
  • Any fabbed board with an ATtiny on it:
PROGRAMMER ?= usbtiny

Step 4:

Execute the command:

sudo make clean

This command erases all files that are not of the process of programming.

Step 5:

Execute the command:

sudo make flash

This command creates three new files main.o, fts_firmware.hex and fts_firmware.elf. These files will be used to program the programmer.

Step 6:

Execute the command:

sudo make fuses

Finally, this command loads the firmware to the ATtinyXX.

Faced problems and solutions programming the programmer

Problems:
  1. The microcontroller started to heat up.
  2. I tried to program using my laptop with Xubuntu, but some library was not compatible with the programming algorithm.
Solutions:
  1. The chip was welded in the wrong side,
  2. I changed the machine and I used the PC with Ubuntu that is in the Fab Lab.

Files for the programming

Building the programmer with a different method

  1. I decided to use copper wire to make the board.

  2. Then I started welding the wire by the components according to the schematic.

  3. After I finished the “board” I tested (Smoke test) using the USE extension cable.

  4. Once I finished the Smoke test I used adhesive tape to fix all the wires.

  5. Finally, it was time to program the new programmer with my usbtiny.

Faced problems and solutions building the programmer with a different method

Problems:
  1. I could not program the new usbtiny with the first one, because of pop-up un error.
Solutions:
  1. I am still working in the solution because my first programmer is detected fine by the OS.
  2. I will try to program one of the examples of inputs. I think in that way I will find the error.

What I learned this week?

I learned how the Makefile works.

I learned how to mantain the aspect ratio of my images using an template in Inkscape.

I started to read the SMD components codes using a manual.

I learn the existence of the CNC language called RML-1 that is for the Modela CNC and it is a proprietary language.