ICSP and 4 layer pcb Issue

Thread Starter


Joined Sep 15, 2016
Hello all!
I am running into a problem and need some help.

I have a 4 layer pcb that I have added ICSP to for the first time. I have programmed a simple light an led "hello world" prog to make sure all is
I have first done this with a breadboard and everything works fine.
I am using a PIC18F24K22 in a QFN 28 pin format at 5v .
My layer stack-up is signal layer on top and bottom layers, and ground layer as layer 2 and 5v power from a regulator on layer 3
I am using a Microchip PM3 to program the PIC18F24K22
On my 5 pin header I run the following:
(1) 5v to the power plane by way of a via which then gives the needed 5v to the PIC. I am not using the 5v regulator (when using ICSP) but should
I be?
I have no other power connected to the PIC. Should I have a direct trace to the PIC VDD pin from my 5v pin on the header?
(2) Ground to the power plane. Same as above I am using layer 2 as ground and tying in to get to the pic. I do not use a direct ground trace to
the PIC. Should I be?
(3) Direct trace to PGC pin on PIC
(4) Direct trace to PGD pin on PIC
(5) Direct trace to MCLR pin on PIC
I do not run any passive components between the header and the pic. I have never had issues programming w/ ICSP before and was wondering if there is something with a 4 layer board w/ ICSP that I am missing or doing incorrectly as this is the first time I have done this w/ a 4 layer pcb.

Thank you for your help.


Joined Jun 26, 2012
The PM3 should be able to drive the 5V Vdd through traces or planes with no problems. It's only good for about 500ma though. Anything more than that or loads that draw an inrush can cause it to Vdd-fail on programming. In that case you can power the board while programming. I've sometimes used a jumper to isolate the PIC from heavy current drawing stuff on the board so that the PM3 can power it. Consider the effect that placing voltage on the output of the power supply regulator as well.
Other than that, check the layout in the ICSP area for a proper wiring.
I've found the PM3 to be pretty tolerant of the boards I've programmed with it and have equipped several clients with it for programming completed production boards with no particular troubles.

Good luck!