I will not be surprised if this function can not run in background :) If so, with a baudrate of 9600 and such a string (CCP_1: %lu\n\r) , you can wait up to 15ms before the printf ended Regards, Nicolas > The rate if the USART is 9600. The prinf() function does work within the > interrupt, but I'm not sure if it's causing some edges to not be detected. > This would explain why there would only be 5 edges instead of more. > > I will try to set up my code so it buffers up the incoming data and then > prints it to the serial port at a later time (ie outside the interrupt > routine). > -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads