you have to insert code which can do the debug of your code. With CCS-C Compiler, i just have to write ICD=TRUE on the #device line. -----Message d'origine----- De : pic microcontroller discussion list [mailto:PICLIST@MITVMA.MIT.EDU]De la part de Lennart Sundberg Envoyi : mardi 27 ao{t 2002 15:21 @ : PICLIST@MITVMA.MIT.EDU Objet : [PIC]: ICD Problem I am trying to run the ICD for the first time to check out how well the ICD function. I have assembled a very simple program and downloaded it to a PIC16F877. The program lights a few LED's when I push a switch. I can program the chip with ICD and the program works fine in stand alone mode. The problem is that when I select debug mode I can single step and do animate stepping only with the fastest Upload Option: Minimum (FSR, W, Status, PCLATH) (Very Fast) and with Minimum and watch windows, other upload options gives communication errors. And if I try to run with the ICD without any breakpoints the processor halts directly? Also after a reset the programcounter is set to pc:0x16 shouldn't it be zero or 0x05 where my program starts? Have I missed something or have I problem with my serial port on my computer? Please give me a hint. /Lennart -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details. -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.