This is the date sheet of atmega328p
On a breadboard everything works fine and as expected.
However upon assembling the circuit on a PCB, the AVR never comes out of sleep. For some reason the crystal is not oscillating
Can someone explain what is the right way to design the PCB as far the crystal is concerned to ensure correct operation (including selecting the capacitors). I have read about it here n there but never given much thought to it.
To remidy the issue, I tried the following but none of them worked:
Tried multiple crystals
Soldered the crystal directly to Atmega328P TOSC1/2 pins
Added 22pf/10pf caps connecting the crystal pins to GND
Here's a close up picture of the crystal attached to the PCB. I had to add some jumper wires because I broke off the traces trying out multiple crystals.