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 CCS Technical Support

Re: ICSP design issue encountered...

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Benoit St-Jean
Guest







ICSP design issue encountered...
PostPosted: Tue Dec 10, 2002 8:38 pm     Reply with quote

Hi,

I'm trying to implement an ICSP interface to my circuit. It's quite simple actually but I've encountered a small problem. I'm currently using a 3PDT ON OFF ON switch to go from PROGRAMMING mode to NORMAL mode (the off position is simply OFF).

The switch itself is expensive and is about the only alternative I have so far. I use the switch to disconnect and re-route signals to the proper pins on the PIC so it can be programmed while in-circuit. I'll be using either the /PT or /PQ PIC package types, so this is why it needs to be re-programmable.

But the situation here is that one of the "switch sets" in that 3PDT switch disconnects the main supply from the whole circuit when in program mode. The second set of "switch" in the 3PDT switch re-routes the RB6 pin from a sensor to the CLOCK signal on my programming connector. The third "switch" from the 3PDT switch disconnects the +5V contacts coming from the 5V regulator that powers the whole device and connects to the programmer's VCC.

The problem is that the PIC has 2 Vdd's. When I connect the supply Vdd pin 32, there's 5V coming out of Vdd pin 11.... this then goes to my main supply and re-powers the circuit!! I could use an ultra low-voltage schottky diode to prevent the 5V out of pin 11 to get back into the main Vcc rail on the circuit and re-power it, but I then loose about 0.3V when the switch is set to NORMAL mode (Vcc +5V goes through the diode and on the other side, there's about 4.7V... this is lower than Vdd pin 32... I think both supply rails should be the same. Or do I absolutely need to use both Vdd pins? I'll use the 4mHz device, not the 20mHz.

Other than using a 4PDT switch to disconnect Vdd pin 11 when programming, does anyone has any other idea? The end-product is a commercial product so I can't do half-assed things. A switch looks nice, but the price goes with it... I need to cut the cost but still look nice.

A 3PDT switch is about 12-14$ (CAN) and a 4PDT is above 20$ (CAN).... this is like the most expensive part of the circuit and it's rediculous to put this in there.... it's almost half the cost of the entire circuit without the switch!!

Any idea, drawings, links etc. that can point in a direction I'm looking for will be gladly appreciated.

Thanks,

Benoit
___________________________
This message was ported from CCS's old forum
Original Post ID: 9963
Benoit St-Jean
Guest







Re: ICSP design issue encountered...
PostPosted: Tue Dec 10, 2002 9:51 pm     Reply with quote

I think I just solved my own problem. Actually, the PROGRAMMING voltage on Vdd 32 can be either applied on Vdd pin 32 or Vdd pin 11. I simply connected Vdd pin 32 to Vdd pin 11. Both of them are now going through my switch. When in programming mode, the Vdd's are completely isolated from the circuit since they go through the switch, thus supply for programming the PIC now comes only from the programmer. The main supply is re-established when the switch is flipped to NORMAL mode. This re-applies the main 9V supply to the regulator, which comes out as 5V out of the regulator, goes to the main VCC rail on the circuit. The Vdd voltage coming from the programmer has now been isolated since the switch is flipped to normal mode, thus the Vcc from the circuit now goes through the switch and to both Vdd's on the PIC!

As easy as 1-2-3!!

Hope you understand, but I did solve my problem!

Benoit
___________________________
This message was ported from CCS's old forum
Original Post ID: 9964
v8power
Guest







Re: ICSP design issue encountered...
PostPosted: Thu Dec 12, 2002 11:52 am     Reply with quote

Why dont you just use a diode to feed the PICs VCC and VPP then when the programmer is on the power wont back feed to your cct.

or what i have done in the past is just us a jumper to isolate the chip.

Microchips website has some good app notes on this
___________________________
This message was ported from CCS's old forum
Original Post ID: 10004
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