Datasheet
© 2010 Microchip Technology Inc. DS70135G-page 163
dsPIC30F4011/4012
21.7 In-Circuit Debugger
When MPLAB
®
ICD 2 is selected as a debugger, the
in-circuit debugging functionality is enabled. This func-
tion allows simple debugging functions when used with
MPLAB IDE. When the device has this feature enabled,
some of the resources are not available for general
use. These resources include the first 80 bytes of data
RAM and two I/O pins.
one of four pairs of debug I/O pins may be selected by
the user using configuration options in MPLAB IDE.
These pin pairs are named EMUD/EMUC, EMUD1/
EMUC1, EMUD2/EMUC2 and EMUD3/EMUC3.
In each case, the selected EMUD pin is the emulation/
debug data line and the EMUC pin is the emulation/
debug clock line. These pins interface to the MPLAB
ICD 2 module available from Microchip. The selected
pair of debug I/O pins is used by MPLAB ICD 2 to send
commands and receive responses, as well as to send
and receive data. To use the in-circuit debugger func-
tion of the device, the design must implement ICSP
connections to MCLR
, VDD, VSS, PGC, PGD and the
selected EMUDx/EMUCx pin pair.
This gives rise to two possibilities:
1. If EMUD/EMUC is selected as the debug I/O pin
pair, then only a 5-pin interface is required as the
EMUD and EMUC pin functions are multiplexed
with the PGD and PGC pin functions in all
dsPIC30F devices.
2. If EMUD1/EMUC1, EMUD2/EMUC2 or EMUD3/
EMUC3 is selected as the debug I/O pin pair,
then a 7-pin interface is required as the EMUDx/
EMUCx pin functions (x = 1, 2 or 3) are not
multiplexed with the PGD and PGC pin
functions.