Electronic – ATmega crystal setup and and power routing

atmegacrystal

I have finished designing my first circuit boards and am uncertain about a couple of things. First of all, I know that I should connect both sets of ground pins and +voltage pins on the chip. My question is is the way I have connected them on my two boards ok or was it unnecessary to have two separate cable runs for each one. Shall I just send one power cable to them and link them together.

My second question regards the layout of the crystals. Originally I had them laid out like in the first circuit (Backpack Board). But I am not sure if this is the correct way to do it. I then changed them to the layout in my second circuit(Utility Board). I believe this is the way Atmel suggest laying them out. It has a solid ground plane on the second layer. They are two layer boards. Should the ground plane below the crystals ground area be separated from the rest of the ground plane or not? And should I link it with vias? I'm not sure if it should be made separately as I don't want to create a ground loop in the ground plane. The board is going to be used near an RF module so I want to make it as rock solid as possible.

Thanks in advance for any help.

enter image description here

enter image description here

Best Answer

VCC/AVCC - one power run, and connect them under the chip. 0.1uF (100nF) next to VCC, AVCC, Aref. Do not connect Aref to VCC.

Crystal/caps. Layout 1 with crystal next to chip and the caps on the outside of the crystal. Don't separate the Gnd plane. Don't run any signals under the crystal/caps and their traces except Gnd. Static signals (like Reset, which rarely changes) are okay also. Best practice is no signals tho.