Manju, Do you have the variables defined as GLOBAL or LOCAL? If they are LOCAL, then the rest of the program won't see them, and you'll get such an error message. I don't know the 24F series very well, so I don't know whether this is possible or not. But it's something to keep in mind. Regards, Jim -----Original Message----- From: piclist-bounces@mit.edu [mailto:piclist-bounces@mit.edu] On Behalf Of Manju Bhargavi Sent: Thursday, August 14, 2008 11:41 AM To: piclist@mit.edu Subject: PIC -interrupts in PIC24F series Hi, I am working on PIC24F series micro controller. I have wrote all the interrupt handlers in a seperate file named interrupts.c. If i try use a variable which is defined ina any other file say uart.h it is throwing me an error saying that it is an undefined variable. I have made all the registers and baud rate setting required for the UART communication. I have used UART2 for the same illustration of the above expalined issue interrupt.c file -------------------- #include "uart.h" void __attribute__((__interrupt__, auto_psv)) _U2RXInterrupt(void) { IFS1bits.U2RXIF = 0; l_test_var_U8 = U2RXREG; } uart.c file ------------- char l_test_var_U8; uart.h file -------------- extern char l_test_var_U8; If i declare this variable in the interrupt.c file and use it then it is compling and working for me Could you please let me know what the issue could. Hope my question is undersatndable ::)) Thanks and Regards Manju Bhargavi -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist