I'm unravelling some fettucCini code and it would be nice if I could define a header file in a file and then get another file to see it but WITHOUT including the file where the file is defined.
Confused? So am I and I have to explain what I want to do. :?
I have split up the bare essential code for a GLCD driver chip from my GLCD code so that all I need to do is to just include in the project the .c file and the .h file for the chip in question.
The driver chip's header file has a definitition
#define GLCD_Header_file "R61505W.h (or whichever chip is being used)"
and one of the files that needs to know the chip used has
#include GLCD_Header_file // This file is defined in the header file for the driver chip
This works ok if I have the file defined within another header file which is used by the file that need to know the chip type. But this means that I need a list of possible header files which can be used and then comment out all of the ones I don't need. Or waste keyboard strokes and write the file name each time I use a different chip.
So I was hoping to automate this, there may be a way to say "extern headerfile_whatever" and then get the file name from the definition .h file of the chip used.