I am curious to know that if you want to create your own header file for a particular MCU what would you put in the header file?
The header file contains information for the compiler. The compiler needs to know what MCU the code is for. Header files are very much compiler specific. Most MCU header files are already created and come with the compiler. In this case we do not need to create header file.
The header file is written first at the beginning of the program. In general, the header file contains the definitions declaration preprocessors.
If you have a datasheet of a particular microcontroller, What sorts of things should you put in header file?
update
The header file contains information for the compiler. The compiler needs to know what MCU the code is for. Header files are very much compiler specific. Most MCU header files are already created and come with the compiler. In this case we do not need to create header file.
The header file is written first at the beginning of the program. In general, the header file contains the definitions declaration preprocessors.
If you have a datasheet of a particular microcontroller, What sorts of things should you put in header file?
update
C:
#include<MCU.h>
void main (void)
{
while (1);
}
Last edited: