Week 05

Electronics Production


Group Assignment

Individual assignment

Learning outcomes:

Have you:


This week I will be making a ISP (In-system programming) or in-circuit programmer.

I chose to do Brian's ISP. I chose it for its simplicity and cost as it is striped down to a bare minimum of components.

image from Brian's ISP's page

image from Brian's ISP's page

The process will be split in phases, Milling, Stuffing/Populating, De-buging, Programing:

Milling

On this phase I will be using the following:

Fab Modules

- I started by downloading the Traces (1000 dpi) and Outline Cutout (1000 dpi) of the circuit provided at Brian's tutorial.

image from Brian's ISP's page

image from Brian's ISP's page

- At Fab modules

I selected the option "image (.jpg)"

image capture from my computer

I choose the image file

image capture from my computer

Once image is loaded I selected "output format" and then "G-codes (.nc)"

image capture from my computer

On Process I selected "PCB traces (1/64)"

image capture from my computer

Before calculating I changed the cut depth to 0.05, half of the default value as I was being a bit cautious on it.

image capture from my computer

Then pressed calculate

image capture from my computer

After calculation I proceed with an inspection of the tool path to make sure that all traces were covered. By holding left mouse key I was able to move the image and with the wheel button I could zoom the image to better check the tool path.

image capture from my computer

By holding right mouse key I was able to even see it with a different perspective.

image capture from my computer

Last I saved the file for the milling process.

image capture from my computer

image capture from my computer

To outline I followed the same steps as before except I chose to "PCB outline (1/32)" instead of traces.

image capture from my computer

2. Mach3

I started the preparation of the cnc by milling a pocket the size of the blank PCB (76x50x1.5mm)

image capture from my computer

Milling the pocket

photo of my cnc making a pocket for the blank pcb

Finished pocket

photo of my cnc finishing pocket

Gluing double face tape on the FR1 board

back of blank pcb

The end result is this.

finishing the outside of the ISP

Milling the cutout of one of the ISP's

image capture from my computer

Removing the PCB from the pocket.

image capture from my computer

I used a blade and sandpaper to remove shavings left from the milling process.

image capture from my computer

Removed the double face tape from behind the pcb.

capture from my computer

3. Stuffing

Basing on Brian's ISP's page tutorial I started by creating a spreadsheet with the components and its positions.

image capture from my computer

image from Brian's ISP's page

BOM

Components

Location

Digikey or Mouser

Part number

Manufacture Part #

- ATtiny45 or ATtiny85

U1

ATTINY45V-10SU-ND

ATTINY45V-10SUR

- 2x 1kΩ resistors

R1, R6

311-1.00KFRCT-ND

RC1206FR-071KL

- 2x 499Ω resistors

R2, R5

311-499FRCT-ND

RC1206FR-07499RL

- 2x 49Ω resistors

R3, R4

311-49.9FRCT-ND

RC1206FR-0749R9L

- 2x 3.3v zener diodes

D1, D2

BZT52C3V3-FDICT-ND

BZT52C3V3-7-F

- 1x red LED

D4

160-1167-1-ND

LTST-C150CKT

- 1x green LED

D3

160-1889-1-ND

LTST-C230TBKT

- 1x 100nF/0.1uF capacitor

C1

399-4674-1-ND

C1206C104KARACTU

- 1x 2x3 pin header

ISP

649-95278-101A06LF

71600-006LF

After that I proceed soldering all components in place.

-3 Pre-Debugging

I started with a visual inspection.

photo of my semi-finished ISP

OK I need to clean a bit more

That's when I realised I forgot to solder the jumper wire. That made me remove the shrink tube I had installed prior.

photo of my semi-finished ISP

With the multimeter I looked for shorts and nothing was detected especially between Vcc and GND.

Overall the board seemed fine so I proceed with the programing. And now programing...

Programming

Under Ubuntu for Windows 10. Started by installing the programing environment

capture of my computer screen

With the prior command the programs got downloaded.

capture of my computer screen

I then downloaded the firmware source to a directory. Following that I run the command

make

capture of my computer screen

Using Sublime-text I edited the makefile file and replaced the entry "PROGRAMMER ?= usbtiny" with "PROGRAMMER ?= usbasp".

capture of my computer screen

I then run

make flash

capture of my computer screen

But not success. So I run

lsusb

and I get a message “unable to initialize libusb: -99

capture of my computer screen

After a quick search on stackoverflow I find out there is no support for usb under windows 10 ubuntu shel yet! Argh!

capture of my computer screen on stackoverflow

Then I gave up on Ubuntu bash for windows 10 and run a copy of Ubuntu under VMware player. At ubuntu I run:

sudo apt install avrdude gcc-avr avr-libc make

capture of my computer screen

This time after running lsusb I can see that device is present.

I run

make

in order to compile the firmware.

capture of my computer screen

I then run

make flash

But again I got an error message.

I end up finding out that my ISP has to have a jumper installed in order to program the Attiny45. So I do it!

And it works!

capture of my computer screen

Next I run

make fuses

capture of my computer screen

After having the firmware uploaded and fuses burnt my new ASP would not be recognised.

So back to debugging…

I end up measuring each resistor value, and replacing the attiny with a new one. With a multimeter I found out that the R1 1K resistor was not working, replaced and voila. Board detected!!! Oh also I decided to install a usb connector I cutted from an old cable and after some washing that's how it looks.

photo of my tiny ISP without cover

photo of my tiny ISP with cover and programing

Final command make rstdisbl and this tiny can't be programmed again.

capture of my computer screen

It worked now I remove jumper!

capture of my computer screen

It works!

-4 Final Test

Loading the driver on windows I use the tool "Zadig_2.2.exe"

capture of my computer screen

After the driver installation I tested under windows the burning of my 3D printer board's firmware.

capture of my computer screen

All working!