Wednesday, February 17, 2010

In the Final 10

I got the word on Feb 12th that I made it into the final round of the Atmel SMART design contest.  I was too excited to post about it right away.

I sent out my three PCB designs in a local group order.  Got a great price and quick turn around. The boards literally arrived the same day I heard I was in the final round.


As you can see, the quality is good.

One surprise was that the vendor printed all of the silkscreen text, even the very tiny component values I had left in the data but assumed the vendor would filter and not print.  It doesn't hurt anything, as the silkscreen isn't over sold pads, but having text smaller than the size of a 0603 part doesn't help me, either.  Moral: put what you want in the gerber outputs, nothing more or less.

My parts order arrived a couple days later.  I tried to time the parts to arrive with the boards, but the boards came faster than I thought.

At this point, I am hung up waiting for a part for my toaster oven based SMT soldering system.  The part I need is in the mail and should arrive this week.  But when it arrives, I need to calibrate my system.  I grabbed some scrap SMT PCB's from Surplus Gizmos to run tests.

SMT soldering is easier than many people think, but getting consistent quality of results is dependent on having control of your technique.  I'm using a infrared oven from Black and Decker.  It's 1500W will easily melt lead-free solder paste.  The oven will be controlled by PID code running on a micro-controller with a solid-state-relay controlling the heating elements and feedback from a K-type thermal probe.  Standard, well-proven techniques.  This gives me accurate temperature profiles and avoids thermal shock to the components.

Still, I plan to do the soldering out in the garage.  No use poisoning the house with flux vapors or stinking things up should a board somehow get over-heated.  Downside is that it is still winter here.  Typical high temperatures during the day are in the low 50s.  I am hoping the high power of the oven coupled with PID control will be able to handle whatever the ambient temperature happens to be.

While I was waiting for the boards and parts, I did more simulations on VMLAB.  I believe I've got the UI 100% tested.  I can't be too sure about the I2C interface, but it seems to be doing what I think it should.  The provided I2C simulation component helped me out.

There is no SPI simulation component available.  I looked into building my own, but the documentation and examples are lacking for someone with limited time budget.  If the I2C component source was available, I think I could tweak it, but it isn't.  I can see the SPI signals wiggling, but I can't easily control what data gets read, so I had to do some manual poking of values into memory.  That area of the code is not well tested.
 
An SPI write followed by a read.
PB3=MOSI, PB4=MISO, PB5=SCK, PB0=Enable

An odd thing happened with the clocking.  The MCU is set up to use its internal oscillator, and a 32KHz crystal on the external oscillator pins.  The MCU model doesn't seem to handle this quite right.  But in a couple (out of dozens) simulation runs, the timer interrupt routine started getting executed regularly.  So the timer code got checked out, but I'm not really sure what is going on there.  I hope it is the model, and not some crazy bug in my code.

I've written some stripped down test code to debug each module individually.  I plan to start with the timer code.  Either an LED will be blinking with a 1 second interval, or I'm afraid I'll be spending a lot of time debugging oscillator and timer initialization code.  The good news is that the LCD routines are debugged and look solid.  printf will be my friend once again.

1 comment:

Bill Owens said...

I know you can't reveal any more about the Project, but perhaps some more details on the PID control of the oven? From your recent tweets I'm guessing that this will be done with an Arduino and that 25A SSR, right?