PCB Roadblock: Using Surface Mount 168?

Hello,

Im working on a large-ish project (exhibition) that is made up of smaller individual works. Each work has a single control board (with microntroller, mosfets, diodes, and a few resistors) that controls a single unipolar stepper motor. The PCB Im working on will use mostly all surface mount components and as a result will be about the size of the Arduino Mini. I am also pretty new to SMT although have produced similar through hole pcbs for my work in the past. Heres a photo of the new in-progress board:

I will be having somewhere in the ball park of 30-50 of these boards produced. This means having the pcbs fabricated and parts placed through various means. I plan on using an Arduino-fied ATmega168 at the core of each board in the MLF32 package.

The problem is I am trying to keep this board as small as possible and am hitting my head against the wall about how many connectors I need to have. At the barest minimum I need the following pins: +5v, Gnd, PWM Out, and another Gnd. Id also like Rx & Tx so I can program it. Thats already 6 pins that Ill need to be bring out using pin headers. Thats assuming I dont need ICSP... which I dont see a way around as thats the only way to get the bootloader on there.

Here are some random questions I have: 1. Is there anyway to purchase a lot of ATmega168s with the bootloader already burned?

  1. I assume not so if I purchase from Mouser or Digi-Key how would bare MLF32 168s come shipped? (The board fabricators will only take parts on cut tape, tube, or waffle tray. If the chips came in a tray I could burn bootloaders on the chips prior to sending to the fabricator.)

  2. I guess the bigger question is how are the bootloaders on the Arduino Minis or LillyPad mass-produced?

Any other thoughts or suggestions? Am I just missing something? Thx, Brian

I think the bootloaders on the Mini and the LilyPad are burned after the board has been fabricated. The LilyPad has the holes for the 6 or 10 pin ICSP header; you can just stick some pins in the connector on your AVRISP and hold them against the holes. On the Mini, you can just use the pins corresponding to the ICSP header - since all the digital i/o lines are brought out already. Since you already have +5V, GND coming out you could probably get away with just adding holes or pins for the three SPI lines and the reset line. Or maybe someone else knows a good way to get the bootloader onto the SMD ATmega before mounting it on your board. It seems risky not to have an ICSP header (or equivalent) on the board, though.

I think I would just make sure I had pins for ICSP on the board. There’s nothing magical about the header, it’s just a convenient standard. You can easily make your own adapter to go between your board and whatever programmer you use.

If breaking out +5/GND/RESET/MISO/MOSI/SCK is too many pins, leave pads so that you can construct a bed of nails to access those pins. Remember MSIO/MOSI/SCK can be used as general purpose digital I/Os, so they may not exactly be “wasted”, depending on your application.

If you’ve got lots of them to build and plan to burn the bootloader beforehand, I would invest in an appropriate ZIF socket. Could be $150 or so for an SMT part, but worth it in the long run.

I have etched a minimal PCB with a crystal, power, and pads for the SMT 168, then simply held the 168 down on the pads while I programmed the device with the other hand. I do not recommend this, only mention it to show the extreme range of possibilities. :slight_smile:

-j

Another method is to leave holes in the board for the ICSP and jam a connector in. It's crude but will work for a few insertion of pins.

I've even seen it done wherever the engineer could find room for single pins, of course hooking it up took a cut up header with wires to a connector that the programmer could plug into. Dirty but it worked and if it failed you solder short pins in and use the other cable. ;)

You can have the chips preprogrammed. There are adapters available that will let it plug into a programmer I think atmel either has those or can point you to them. If you do that it would be best if you did the programming and shipped them to the board house. Per piece prices for that or ouchy if they can even do it.

For one board house a company I was at shipped all the programming stuff to them and had an engineer go there and teach their people. There were several thousand chips to do so it actually was cost effective. It was still about 50 cents a chip which is stiff if you're doing 10,000.

hey Brian,

card-edge connectors might save you some time. Look in the Digikey catalog- you could easily get 20 pins in the space of that 6 pin header, as there would be 10-12 pins at .05" spacing on each side. You can even ask the board house to do gold fingers for the board.

D