|
by Phil Anderson
Start ı Humble
Beginnings ı Application Circuit Example
ı The End Result ı Sources
and PDF
APPLICATION CIRCUIT EXAMPLE
Letıs look at a real-life example. Keep
in mind that some application circuits can get pretty complicated
and it can be hard to isolate the chip from the circuit. In those
cases, you may have to use an ICP interface that can supply sufficient
current to the full application circuit. My example is simple, so
you can focus on the question at hand.
The circuit consists of the ı16F873 microcontroller,
some switches, a crystal circuit, supply leads, and the ICP SIP connector
(see Figure 1). Assume that all of the other I/O lines are attached
to circuitry. Note that the ICP SIP connector has five pins. These
match with the five signals called for in the partıs datasheet for
socket or ICP programming (ground, VDD, VPP,
clock, and data).
| Figure
1ıThe ICP application circuit includes the target 16F873
microcontroller, diode and jumper to isolate the circuit, and
SIP connector for the chip programmer. |
The ICP SIP is simply a connector between
the same pins on the in-circuit chip and the required pins of the
programmer ZIF socket. The programmer ground attaches to VSS
of the chip, which is pin 19. VDD attaches to the supply
lead (pin 20), and VPP attaches to pin 1. The programmerıs
clock line attaches to RB6/PGC (pin 27), and the data line connects
to RB7/PGD (pin 28).
If you look at the circuit carefully,
youıll notice that the five signals required for programming are,
or can be, isolated from the rest of the circuitry. In this way, the
circuit does not load down the chip programmer (in my case, the PICSTART
Plus).
VPP drives MCLR high to 13
V, but diode D1, added to the circuitry, prevents VPP from
feeding back into the application circuit. When the programmer is
removed, the diode doesnıt affect circuit operation.
To isolate the circuit from the programmerıs
VDD line, remove jumper J1. After programming, reinsert
J1, restoring the application circuit. With regard to the programming
clock and data lines, the application circuit shares B7 and B6. However,
because the switches are normally open, their load is isolated during
programming.
PREVIOUS
NEXT
Circuit Cellar provides up-to-date information for engineers. Visit
www.circuitcellar.com for
more information and additional articles.
For subscription information, call (860) 875-2199, subscribe@circuitcellar.com
or subscribe online.
ıCircuit Cellar, the Magazine for Computer Applications. Posted with
permission. |