Friday, March 1, 2013

From breadboard to protoboard

Programmer on breadboard
In my last post I assembled a USBtiny programmer on a breadboard. A programmer can be used to program the MCU´s directly or to put a bootloader on them like the Arduino bootloaders.

The buffer circuit from LadyAda schematics was left out since I was not totally sure that I bought the correct IC. I bought the 74HC125N and ladyada recommends a 74AHC125N. I could live with a missing "A" but the schematics says that "Only the 74AHC is compliant at lower VCC!". I tried to compare the datasheets but they where a bit different in their layout and I did not know what to look for. 

Last night I designed it the layout in Fritzing, printed it and the schematics and then I soldered it. 

The soldering went kind of OK, 
I´m really no expert in soldering and I consider it to be kind of messy when you are designing and making it up as you go. But it is fun kind of problem solving.

The soldered programmer, with female USB port

Instead of the Sparkfun MicroUSB I used on the breadboard I used the female USB header. Female type A headers are those mostly on USB-hosts like computer so putting a female type A header on a USB client is kind of weird, but hey I´m learning and I asked my wife to buy me a USB male to male cable. When she brought it home for work I was eager to test my circuit.

Kind of nervous I plugged in the USB cable without the ATtiny2313 chip in the circuit and spent a few minutes with the multimeter. Then I removed the USB and inserted the chip and plugged in the USB-cable again. The red LED should light up, but it remained black, so I quickly removed the power and started to search for an error... could not find any so I moved the ATtiny chip back to the breadboard, putting cables from the protoboard IC socket into the correct places on the ATtiny and it worked?! Moved the IC back to the protoboard and no light...

After 2 hours of searching for an error I just plugged it into the socked again and pressed it a little firmer into the socket and it the red LED lighted up, confirming correct USB connection!

I tested the board by programming the already wired up ATtiny85 that I think I will use in another USB project. Worked smoothly and without any problem.

My plan for the space left on the protoboard is to place a ZIF(Zero Insertion Force) socket so I can program new IC´s faster. I also plan to place male headers on the sides so I can select where I want the SCK, MISO, MOSI and RESET lines to go. If there is space I will also put in the buffer chip and a female header to put a crystal in. zif socket hm looks a bit wide?

Lessons learned:

  • Plan ahead before you solder
  • Buy proper USB sockets, that you have cables for
  • Firmly insert IC´s in sockets

1 comment:

  1. Update, the problem with the circuit not working returned after a while, after many attempts and hours trying to find the problem I realize it is the back metal of the USB socket that touches the D+ pin on the inside. I loosen the back of the USB casing and bend it a millimeter back, problem solved.