PCB Layout review

Hello -

I was hoping to get some feedback on my PCB design - this is my first attempt at having a PCB manufactured. I re-routed this board maybe 15 times and I hope I finally got it right! Also want to make sure i am not doing anything blatantly wrong. I did have to redo and shrink the layout a few times to get it to 10cm x 10cm for the PCB fab.

What it is - This will be my controller for my aquarium hood. * Atmega168 with arduino bootloader * MCP23008 GPIO controls 7 TIP120 transistors: 3 to turn on and off relays, the remaining 4 control 12VDC fans. The fan headers are on the right, each of the 4 circuits drives 900 mA. * DS1307 real time clock, also on the i2c bus * TLV2374 rail to rail op-amp attached to PWM pins from Arduino. These are for 3 0-10 VDC outputs which control the dimming of my T5 Ballasts. * 2 voltage divider circuits on the analog inputs with thermistors, to measure the temperature of the hood and the water. * the remaining pins of the arduino route to a header for buttons, encoders, LCD, etc. * input is regulated 12VDC, on the lower left of the board is the voltage regulator circuit.

i only had small breadboards, so my prototype is a bit of a mess, but it works.

Here is the prototype:

Here is a picture of the layout and links to the Eagle Schematic & Board layout http://dl.dropbox.com/u/57349766/Fish/LC.4.sch

http://dl.dropbox.com/u/57349766/Fish/LC.4.brd

I still need to complete putting labels on all the parts. Any feedback, comments, etc is appreciated.

Also, i wanted to ask, should i add decoupling caps to all the IC's or are the caps near the regulator circuit sufficient?

should i add decoupling caps to all the IC's

Yes.

First thought, if possible (and it seems that it is) I would align the mounting holes so they are square, currently they appear to be in random locations.


Rob

Should also add ground plane.

florinc: Should also add ground plane.

DONE - rerouted various traces. Question - there is a ground plane "island" that is connected to the rest of the plane by about a 50mil trace. The island has quite a few pins attached to it. To fix would require me to re-route about a quarter of the board - can you explain if this is an issue/what would the impact be?

Graynomad: First thought, if possible (and it seems that it is) I would align the mounting holes so they are square, currently they appear to be in random locations.


Rob

Fixed.. I dropped the mounting holes on so i wouldn't forget to put them on later, and then i never put them in the right spots - thanks for pointing that out! Posting new files soon.

there is a ground plane "island" that is connected to the rest of the plane by about a 50mil trace. The island has quite a few pins attached to it.

I doubt this is a problem if the pins are just logic, but if you have large amounts of power it might be. OTOH a 50mil trace is pretty big, so my gut feeling it that it would be OK unless all your transistors are getting their power through that trace.

Speaking of which, how much will all the transistor draw if all on?

How about a new pic.


Rob

If all 7 transistors are on

  • 3 relays @ 20mA each
  • 2 fan circuits have 2 fans wired in parallel @ 0.580 A, for 1.16 A on each transistor ← these two TIP120’s i have heatsinks on, they are hot to the touch w/o heatsink.
  • 2 fan circuits have 2 .140 A fans wired in parallel, .280 A each

Total current = 3A
Current in “normal” daytime condition = 60mA (relays) + 560mA (2 fan circuits)

The two high power fan circuits only turn on sporadically if the temperature rises above a threshold.

Updated pics coming shortly.

  • Added Ground Plane, removed a bunch of ground traces on the top layer that became unneccessary
  • Rerouted a few items on the bottom layer
  • Added bypass cap on MCP23008 and ATMEGA
  • Fixed mounting holes

Here is updated pic... THe eagle board/schematic link above in the first post has been refreshed Regards, David

I don't have Eagle installed so I can't see the schematics, but it looks to me like that 3A is required from the output of the regulator. If that's the case have you looked at the thermal issues there?


Rob

PS: I didn't want to sully my nice computer with the likes of Eagle but may install it to see this stuff :)

Is this gonna be in an enclosure? using a mosfet like the stp40nf12 would allow you to run cool a linear regulator is burning alot of heat, a switching one would save on that, but why do need regulated 12v? Fans aren't that picky if you just use something close from the external source

Ok I've got Eagle loaded now and I see that the transistors are low-side switches so ignore my previous post.


Rob

Graynomad: PS: I didn't want to sully my nice computer with the likes of Eagle but may install it to see this stuff :)

What CAD software do you use normally? The schematics on your website are very clean and easy to understand.

winner10920: Is this gonna be in an enclosure? using a mosfet like the stp40nf12 would allow you to run cool a linear regulator is burning alot of heat, a switching one would save on that, but why do need regulated 12v? Fans aren't that picky if you just use something close from the external source

the 12V input is regulated (not on the board) so the lights controlled by the op-amp don't flicker/change. The regulator on the board brings the 12V to VCC for everything else. Agreed about the fans :) (There is a VCC pin on the power header for testing purposes only)

winner10920: Is this gonna be in an enclosure? using a mosfet like the stp40nf12 would allow you to run cool

I have a handful FDP8860's handy let me review the datasheet and see if this is the same as the mosfet you quoted i beleive it is Is it correct to say the circuit would be the same as TIP120 but i need to pulldown the Gate to ground?

What CAD software do you use normally?

I use Altium, been using it on and off since I was an occasional beta tester for DOS version of Protel when the guys were in Tasmania.


Rob

The pulldown would ensure it doesn't start on while the outputs are high impedance, once they are set as outputs and either high or low it doesn't matter, you could probably get away without them but thereon almost always there how much draw on the 5v line are you using? Dropping ffrom 12v to 5v is basically wasting more than half the power as heat with a linear regulator

winner10920:
The pulldown would ensure it doesn’t start on while the outputs are high impedance, once they are set as outputs and either high or low it doesn’t matter, you could probably get away without them but thereon almost always there
how much draw on the 5v line are you using? Dropping ffrom 12v to 5v is basically wasting more than half the power as heat with a linear regulator

the 5v line draw is minimal - if i remove the status LED’s (or put them on the emitter side of the transistors) - the draw would be the Arduino, DS1307 & MCP23008 + the current draw on the transistor gates = i am guessing it is not using very much power but its not sipping power either… also there are a ton of pulldown/pullup resistors on the pins. The draw on the opamp is < 10ma. I was going to limit the LED draw to 140ma.

I have pretty much -0- experience with power supplies - i have always used a 9 or 12 v wallwart with LM7805 … having said that, my prototype circuit is using the L4931 regulator in a TO-92 (!) package - it is running a bit hot. I was planning on switching out the L4931 in the RBBB i am using for the prototype with a LM7805 but have not gotten around to doing it (desoldering is my least favorite activity)

If you have any power supply recommendations to improve the circuit, i would appreciate!

regards,
david

How about one of these little assemblies for 12V to 5v conversion?

http://www.digikey.com/product-detail/en/OKI-78SR-5%2F1.5-W36-C/811-2196-5-ND/2259781

Those seem perfect for your situation, simple replacement for twice the efficiency atleast and minimal heat,

I ordered the pcb from seeeed on Sunday! Will update with pics in due time.

CrossRoads:
How about one of these little assemblies for 12V to 5v conversion?

http://www.digikey.com/product-detail/en/OKI-78SR-5%2F1.5-W36-C/811-2196-5-ND/225978

This will be going into my next mouser order as well :slight_smile:

Thanks everyone for the feedback.

Something I noticed was the traces coming off the row of transistors up the top. If the through hole pads are on both sides, the trace from the middle pad gets VERY close to the right pad on some of them. Some of the other clearances look a bit tight too.

You can set up EAGLE to run DRC to check for minimum clearances etc, might be worth checking the specs of the fab house you're going to use and check your layout with those values.

Good luck!