Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

ICSP on shared pins

Status
Not open for further replies.

Mosaic

Well-Known Member
On the matter of ICSP, it's kinds important to design for it with the surface mount packages.

16f882

I have a design which has a pushbutton with a 10k external pullup on the MCLR/vpp pin1.

MCLR is disabled in the fuses. The pickit2 doc shows a 470 ohm and a .1uf cap as well hanging from that MCLR/vpp pin. Why are those required?



Also, RB6,7 are for the ICSP dta & clk signals, these are also used as in-circuit data & clk OUTPUTS to a shift register. Do i need to do any isolation here?

The circuit pwr demands will exceed the 100mA of the USB, I plan to NOT use the Vdd from the pickit2, but use the Vss gnd tied to the circuit gnd.


To reduce crosstalk on the ICSP clk/signal lines, what size cap. is suggested at the application end? I need to make up an adapter cable with caps. to reduce crosstalk due to cable length of perhaps a couple feet.

The pickit2 doc does not show any conn. to the PGM pin , RB3. Do I need to place a pull down resistor on it?

How important is low ESR for caps. at the 1 MHz or less line clk speeds?

Thx much!
 
I have a design which has a pushbutton with a 10k external pullup on the MCLR/vpp pin1.
This is ok.

MCLR is disabled in the fuses. The pickit2 doc shows a 470 ohm and a .1uf cap as well hanging from that MCLR/vpp pin. Why are those required?
Not required

Also, RB6,7 are for the ICSP dta & clk signals, these are also used as in-circuit data & clk OUTPUTS to a shift register. Do i need to do any isolation here?
No


To reduce crosstalk on the ICSP clk/signal lines, what size cap. is suggested at the application end? I need to make up an adapter cable with caps. to reduce crosstalk due to cable length of perhaps a couple feet.
The Microchip ICD programmer is a very unreliable programmer with long leads.

The pickit2 doc does not show any conn. to the PGM pin , RB3. Do I need to place a pull down resistor on it?
no
 
The PGM pin is only used for Low Voltage Programming, The pickit2 is a high voltage programmer so you can use this pin as an IO pin.

One problem with the pickit2 cable is that the PGD and PGC (clock and data) are right next to each other in the cable. I have had some luck with splitting the cable on both end to move the clock away from the data line. With this I have been able to use 2 ft cables. YMMV

Take a look at the 18F chips. If I were to start today I would start with them.
 
Yes. 2.2k from the clk line to gnd and 2.2k from the signal line to gnd. This will make the lines low impedance.
 
Last edited:
Colin55 where do you get off sayin an ICD is hopeless using long leads. I've used my ICD2 clone now for about 5 years using a 1 metre cable I made and I NEVER had a problem. As far as using the PGD.PGC pins for other purposes if any of those pins are tied to 5 volts when you try to program you will blow some transistors on the ICD. What I do with ALL my circuit boards where I fit ICSP is put in a 3 way jumper block and when programming I move the jumper to the ICD line and all is sweet. When I did blow those 3 transistors the guys on the sparkfun forum were great and the guy from Olimex who made the ICD clone did mention about the jumpers.

Regards Bryan
 
I am not talking about ICD2 clone. Look on the web and see what troubles others have had with ICD "burner."
 
Last edited:
The OP mentioned the picKit2.

I used ICD2 clones extensively including teaching, but never tried using longer programming cables until I had switched to the picKit2 and clones.

The docs for the picKit2 state 6 inches (IIRC). At any rate I do not see where we need to get into a argument regarding this.
 
Last edited:
Isolation of RB7 & RB6 pins

Hi everyone...

I'm building a PCB for a PIC18f4520 smd packaging and want to know how to isolate PGD and PGC pins of the ICSP...

I know I have to do something here, 'cuz I had a previous board using a DIP PIC18F452 and had some troubles with the ICSP when using those two pins... Specially in two cases, when driving an LCD data lines and a parallel-in-serial-out register to drive a 7-segment display. In both cases, I had to disconect PGD and PGC lines to get a succesfull ICSP operation...

I've been reading and by now i've found two possible solutions, one mentioned here by colin55 who said that pulling down these two lines to ground with 2.2K resistors will fix this, and google came with another option on https://www.best-microcontroller-projects.com/pic-icsp.html where they use two serially connected 10K resistors...

any comment on this???

thanks in advance.
 
U can always use a pair of jumpers or dip switches if it is inconvenient to use resistors. in lieu of plug jumpers u can use an 8pin IC socket with wire jumpers across 2 pairs.
 
U can always use a pair of jumpers or dip switches if it is inconvenient to use resistors. in lieu of plug jumpers u can use an 8pin IC socket with wire jumpers across 2 pairs.

yeah, well the point of my interest on the resistors is not having to move those jumpers, i want to just leave the circuit alone and program it without having to modify it... i'm gonna try the 10K series resistor as i saw a diagram on the PICkit 2 documentation... i'll let you know how it goes...
 
Basically you just need to add resistance between the icsp pins and the rest of your circuit so that the programmer can wiggle the PGC and PCD lines in whatever way it needs to. It also needs to take the mclr/Vpp pin up to about 13 volts.

You also need to make sure that the rest of your circuit doesn't react in unpleasant ways during the programming operation.
 
Status
Not open for further replies.

Latest threads

Back
Top