View previous topic :: View next topic |
Author |
Message |
Guest
|
ICSP of 12F683 |
Posted: Sun Dec 20, 2009 9:12 am |
|
|
Want to make my board possible to ISCP.
Using a 12F683 and pin6 & pin7 is connected directly to 1Kohm variable resistor(Top = +5V / Button = Gnd / Middle to the PIC). I use the AD converter at pin6/7.
How to make the isolation to the ICSP? Maybe some 10K serial resistors? But the data sheet say there are 1Kohm in input impedance when using AD converter.
One solution can be to program the PIC before mounted. Or wait to mount the resistor to after the PIC is programmed.
Not good at all, the best is to make it possible to program the PIC after production of the board.
Some help? |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Sun Dec 20, 2009 2:48 pm |
|
|
You could use two jumpers on the board to isolate the trimpot and
and other external circuits from the PIC during ICSP programming.
See the schematic on page 4 of this Microchip ICSP document:
http://ww1.microchip.com/downloads/en/DeviceDoc/39530.pdf
It's possible that you might be able to use resistive isolation,
as shown on Figure 4 of this Microchip document:
http://ww1.microchip.com/downloads/en/DeviceDoc/51764b.pdf
If you turned the trimpot so the wiper is connected to ground,
and then used a series resistor (say, 4.7K), then during programming
you would have a 4.7K pull-down on one of the ICSP pins.
This might work. The ICD2 poster does not show that pull-downs
are prohibited. If you look at the diagram on the right side of
the ICD2 Poster, it has red X's through circuits that are not allowed
on PGC and PGD. Here is the ICD2 Poster:
http://ww1.microchip.com/downloads/en/DeviceDoc/51265e.pdf
During normal usage, having the 4.7K series resistor would increase
the input impedance going to the 12F683's A/D pin. But the 12D683
data sheet says the maximum input impedence is 10K ohms.
There is a gray-colored "caution" note block in this section of the
data sheet that says it's 10K:
Quote: | 9.2 A/D Acquisition Requirements |
The important thing is that:
1. You must test it. Look at the ICSP signals on your oscilloscope while
using the series resistor. Also see if the programmer gives any errors.
2. You must remember to set the trimpot to Ground before you
program the boards.
I haven't tried this. But I think it might work. |
|
|
Guest
|
|
Posted: Mon Dec 21, 2009 4:54 am |
|
|
Thanks for your nice explanation and link.
I will make some test on it, and report my result back. |
|
|
Guest
|
|
Posted: Mon Dec 28, 2009 7:38 am |
|
|
Status:
It work perfect with 4,7k in series to the other load, and using the pin directly with PICKIT2 programmer:-) |
|
|
|