CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

ICD-2 "Recommended Circuitry"

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Pete Smith



Joined: 17 Sep 2003
Posts: 55
Location: Chester, UK

View user's profile Send private message Visit poster's website MSN Messenger ICQ Number

ICD-2 "Recommended Circuitry"
PostPosted: Thu Jun 17, 2004 7:12 am     Reply with quote

Hi all.

I've been asked to take a look at someone elses circuit. They're using an ICD2 to program and debug the PIC (18F252).

I've looked at the ICSP guide, and the ICD2 guide. These say to use a pullup resistor and a capacitor to ground, and a diode between MCLR and the RC network (isolating Vdd from 13v), or just a resistor from MCLR to Vdd respectively.

I've never had any dealings with the ICD2 before.

Will the standard ICSP circuit work with the ICD2, or do I literally just need a resistor?

Thanks,

Pete.
Neutone



Joined: 08 Sep 2003
Posts: 839
Location: Houston

View user's profile Send private message

PostPosted: Thu Jun 17, 2004 7:47 am     Reply with quote

Just a resistor will do usually. The current across the pull up resistor will need to be less than the circuit draws. With a 10K pull up you have a resistor from 13V to the 5V supply. That is going to put 800uA on the 5V supply. If your circuit uses more than that you don't have a problem. You don't want to pull up the 5 volt supply.
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Thu Jun 17, 2004 11:14 am     Reply with quote

Quote:
I've looked at the ICSP guide, and the ICD2 guide. These say to
use a pullup resistor and a capacitor to ground, and a diode between
MCLR and the RC network (isolating Vdd from 13v), or just a resistor
from MCLR to Vdd respectively.


http://ww1.microchip.com/downloads/en/DeviceDoc/51265c.pdf
(This poster should have come in your ICD2 box).
AllanL5



Joined: 05 Apr 2004
Posts: 6

View user's profile Send private message

PostPosted: Thu Jun 17, 2004 2:26 pm     Reply with quote

Yes, you want ONLY a 10K ohm resistor between MCLR and +5 (VDD). The other lines must be connected directly to the ICD-2 connector.

NO capacitor on MCLR to ground -- this will muddy the program pulses.
NO diode on PG_Clk.
NO capacitor on PG_Data to ground.
Pete Smith



Joined: 17 Sep 2003
Posts: 55
Location: Chester, UK

View user's profile Send private message Visit poster's website MSN Messenger ICQ Number

PostPosted: Fri Jun 18, 2004 1:59 am     Reply with quote

PCM programmer wrote:
Quote:
I've looked at the ICSP guide, and the ICD2 guide. These say to
use a pullup resistor and a capacitor to ground, and a diode between
MCLR and the RC network (isolating Vdd from 13v), or just a resistor
from MCLR to Vdd respectively.


http://ww1.microchip.com/downloads/en/DeviceDoc/51265c.pdf
(This poster should have come in your ICD2 box).


It probaby did come with the box, but I've only worked at this place for about 5 weeks, and I've been thrown in at the deep end.

At present, there's a big fat capacitor (4.7uF) on MCLR to ground, and the hardware developers have had to wierd and wonderful things (namely removing the pull up resistor & replacing it with a short, and adding a 1k resistor between MCLR and the programming port.

I've been told to sort the problem.

Thanks for the link to the poster - this is the one file I _didn't_ download! I though "Why would I need a poster!" Smile

The other files suggest that just a resistor is needed, so this confirms it.

Thanks again,

Pete.
Pete Smith



Joined: 17 Sep 2003
Posts: 55
Location: Chester, UK

View user's profile Send private message Visit poster's website MSN Messenger ICQ Number

PostPosted: Fri Jun 18, 2004 2:54 am     Reply with quote

Neutone wrote:
Just a resistor will do usually. The current across the pull up resistor will need to be less than the circuit draws. With a 10K pull up you have a resistor from 13V to the 5V supply. That is going to put 800uA on the 5V supply. If your circuit uses more than that you don't have a problem. You don't want to pull up the 5 volt supply.


If the circuit takes less than 800uA, would it be possible (or "the done thing") to use a diode between the MCLR pin and the resistor, to stop the 13v flowing onto the 5v supply, but which would allow 5v (or 4.4v) onto the MCLR pin when running?

I actually don't know if the circuit draws more than 800uA or not.

Thanks,

Pete.
Neutone



Joined: 08 Sep 2003
Posts: 839
Location: Houston

View user's profile Send private message

PostPosted: Fri Jun 18, 2004 8:30 am     Reply with quote

Pete Smith wrote:
Neutone wrote:
Just a resistor will do usually. The current across the pull up resistor will need to be less than the circuit draws. With a 10K pull up you have a resistor from 13V to the 5V supply. That is going to put 800uA on the 5V supply. If your circuit uses more than that you don't have a problem. You don't want to pull up the 5 volt supply.


If the circuit takes less than 800uA, would it be possible (or "the done thing") to use a diode between the MCLR pin and the resistor, to stop the 13v flowing onto the 5v supply, but which would allow 5v (or 4.4v) onto the MCLR pin when running?

I actually don't know if the circuit draws more than 800uA or not.

Thanks,

Pete.


You could add a resistor from +5 to Ground to insure the circuit draws at least that much. The diode thing works too. Better yet measure current draw and find everything is ok.
valemike
Guest







PostPosted: Fri Jun 18, 2004 11:04 am     Reply with quote

http://www.ccsinfo.com/forum/viewtopic.php?t=19649

Look at today's recent thread which asks the same thing.

We have pulldown resistors on rb6 and rb7 to prevent floating pins during runtime. (You can also put small 1K pullups on rb6 and rb7 instead of the pulldowns, and it won't affect your programming despite the fact that the datasheet says not to put pullups). And of course you have to protect the 5v rail from getting injected with Vpp(12V) while you're programming the PIC.
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group