Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Is it possible to write isr in a user defined header file ?

Status
Not open for further replies.
depending on compiler , many of compiler like keil mdk allow you to write routine on separate file
 

You should read the XC8 User manual, I think you will find answers to your questions there. Normally you write code in .c files, and use the header file .h for references, macros and prototypes, in a multi source file project.
 

yes u can wriye ISR routine anywhere but after defibed controller's architecture.
 

it is usual to place code in .c files with function prototypes and variable declarations etc in header file.
placing actual code such as the definition of an isr (or any other function definition) in a header file could cause problems if you include the header files in more than one .c file in a project - you will get multiple definitions of a symbol at link time
 
yes horace1 is right. You can write in header file but there will headache later.
 

thanks for the reply horace1 and embpic.. :)
i wrote the program and the compiler accepted it as the header file but the o/p is different from what i expect.. :cry:
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top