4
\$\begingroup\$

I'm designing a board (with EAGLE) for my first time and, before posting here, I've read some topics and documents on how to design a board, but I still need help since I'm a beginner.

My board should power and control 9 solenoids (12V, 2A) and a servo. I will use a board with two layers and 90um.

Two proportional solenoids use PWM at 120Hz. The oscillator for atmega328p is 16Mhz.

The board is powered by 12VDC with 12VDC, 200Ah AGM battery and I'm using an isolated power supply (+5VDC) to power up the microcontroller (atmega328p). The atmega328p isolation is made by optocouplers which drive the MOSFETs.

This is the schematics made in Eagle where GND5 is the ground for the 12V circuit and GND is the ground for 5V system (sorry if the schematics is not very clear, EAGLE does not allow me to remove some junction points).

I don't know if I need to create two ground planes (one for GND5 and another one for the GND) or if I only need to create a ground plane for the GND5. The +5V system powers only the atmega328p and a RC receiver, may be, it does not need a GND plane? So I can only create the GND5 plane?

It is better to put only the ground plane on a layer and all the other connections traces and +12V traces on the other layer?

Could it be a good idea to create a "+12V plane"? What are your suggestions for the designing of this board?

I'm following these guidelines:

  • place the decoupling capacitors C22, C23 very close to the microcontroller

  • place filter capacitors close to the drivers (MCP1406)

  • place diodes close to the connectors for the solenoids P_OUTx

  • large traces for +12V (or a +12 plane??)
  • only GND5 ground plane (??)

[EDIT: The schematics is now correct and clearer]

enter image description here


EDIT1: These are the board layout, the upper and the bottom layout. I placed a ground plane for GND5 (the ground for 12V) and a power plane for +12V. Do you think it is better to place also a ground plane for 5V?

enter image description here enter image description here enter image description here


EDIT2:

This is the second version of the layout. I separated the 5V circuit from the 12V circuit by using the optoisolator and the isolated power supply as a "moat". I also placed the ground plane for 12V at the bottom layer and the ground plane for the 5V circuit on the upper layer. Is it OK, now?

enter image description here enter image description here enter image description here


EDIT3

This is the third version of the board layout. I removed the +12V connector which was at the bottom of the board since it wasn't really useful and I tried to separate the two circuits (12V, 5V) in a better way. I also fixed the errors with some traces which were connected to a wrong source. Are they Ok, now? Anything to fix?

enter image description here enter image description here enter image description here


EDIT4

This is the version #4 for my board layout as suggested by @ThreePhaseEel. Now, I think all the traces are in the correct area and the optocouplers work as a "barrier" between the two circuits. I hope everthing is Ok, now! :)

enter image description here enter image description here enter image description here

**

VERSION WITH MOUNTING HOLES

** enter image description here


EDIT5

This is the version #5 with the diodes flipped and wider traces for the diodes. I also tried to remove the acute trace for the 12V connector. enter image description here enter image description here enter image description here

\$\endgroup\$
15
  • 1
    \$\begingroup\$ I don't really understand why you have 3 grounds and mixing them: for instance C16 and C17 are grounded to GND5 and connected to +12V and on the same part, C15 is grounded to GND-12. I think GND5 = GND-12 but please review your grounding and and study if you really need to isolate your powers. For the layout the best is to make a first try and then we will comment and help you to improve your work. Giving general statements doesn't make the layout as everyone understand and design his own way. \$\endgroup\$
    – zeqL
    Commented Nov 25, 2016 at 18:41
  • 1
    \$\begingroup\$ Very confusing for the ground for +12V to be called GND5. Why not call it GND12? Also, the schematic is not drawn very well. You've got extra connections (colored dots) shpwing up all over the place, like the second on near near C13, C8 etc., and all of the ones where a net is connected to a component (D5, virtually all the other diodes, resistors and caps). Usually this means overlapping nets. In any case, it is not a properly drawn schematic. Do an electrical rule check (ERC), \$\endgroup\$
    – tcrosley
    Commented Nov 26, 2016 at 16:06
  • 1
    \$\begingroup\$ No mounting holes? Always a good practise \$\endgroup\$ Commented Nov 29, 2016 at 11:58
  • 1
    \$\begingroup\$ If you rotate the diodes connected to the solenoid connectors 180º tracks will be shorter and that will improve the diode performance. As well, you can make those tracks a bit wider, plenty of room and not harm. \$\endgroup\$ Commented Nov 29, 2016 at 12:12
  • 1
    \$\begingroup\$ There is an acute angle close to the 12 V connector on bottom layer. Usually acute angles are avoided. (This could be a controversial point). Anyway, i think you can redesign a bit nicer without a acute angle \$\endgroup\$ Commented Nov 29, 2016 at 12:18

2 Answers 2

5
\$\begingroup\$

In this case, what you want to do is split the planes -- your 5V power grid/net and ground plane are exclusively in the digital logic section of the board, while the 12V power grid/net and ground plane are exclusively in the power section of the board. This means that there is a copper-free "moat" between the two sections of the board -- the only things that span the moat are the optocouplers and the isolated 5V supply "brick" module.

\$\endgroup\$
13
  • 1
    \$\begingroup\$ You'll probably have to rearrange the whole board -- start with the parts on the "moat" so to speak. \$\endgroup\$ Commented Nov 26, 2016 at 16:15
  • 1
    \$\begingroup\$ @MarcusBarnet -- it's a copper-free region that completely separates the 12V and 5V sections of the board \$\endgroup\$ Commented Nov 26, 2016 at 16:56
  • 1
    \$\begingroup\$ The optoisolators have one side in the 5v/digital region and their other side in the 12v/power region \$\endgroup\$ Commented Nov 27, 2016 at 0:01
  • 1
    \$\begingroup\$ You have the parts placed correctly now -- however, there are several traces that breach the isolation barrier. It looks like you have some things on the board connected to the wrong return/ground... \$\endgroup\$ Commented Nov 27, 2016 at 20:36
  • 1
    \$\begingroup\$ The trace connecting R49 to PC4 is a start. Also, RC12 looks to be on the wrong side of the board altogether (it should be on the 12V side of the board), and the cathodes of OK1-OK4 are connected to a trace on the 12V side of the board... \$\endgroup\$ Commented Nov 27, 2016 at 21:25
1
\$\begingroup\$

I use mixed MCU and circuits powered from different sources but I always use a common ground.

Here is a links to 'official' Arduino relay product with the schematics. And also other documentation : http://download.arduino.org/products/4RELAYSSHIELD/Arduino-4-Relays-Shield-V1_rd.zip

Why reinvent the wheel? Imitation (copying) is the sincerest form of flattery.

(Charles Caleb Colton)

\$\endgroup\$
1
  • 2
    \$\begingroup\$ You simply cannot pass PWM through relays. They are slow and will fail fast due to high switching rates and their mechanical nature. Though they probably will stay somewhere in mid-contact, which may or may not be an actual contact for the solenoid, and thus won't result in the desired effect. \$\endgroup\$ Commented Dec 27, 2016 at 16:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.