Hi,
I'm having an issue getting KCONFIG to work with multiple board revisions. I have defined a custom board. It has all the files needed and we can build product code on that. We are now making some hardware changes and want to have a C flag defined in the newer board versions. I have tried defining the flag in different places but build still seems to fail.
I want to have a flag like #define APP_TOUCH_PT8041. The code works when I do this in a C code file. I check the flag with a macro like this COND_CODE_1(CONFIG_APP_TOUCH_PT8041, (), (iqs323_sleep();)). Now what I want to do is have this flag defined in KCONFIG instead of doing it in the C code files. And what I really want is to use the board revision files to define this flag. So lets say my board is called plank. I have a lot of things defined in plank.defconfig but for each revision of my board there are two files (plank_1_0_0.overlay and plank_1_0_0.conf) - my understanding is that I can use the plank_1_0_0.conf file to define flags specific to that board revision. But whatever I do I can't seem to get the build system to accept my flag like this. I have tried putting the following thing in many different places but so far it has not worked.
config APP_TOUCH_PT8041 bool "Board version using the older PT8041 touch chip" default n
I want this flag to be defined and default to "n" in all versions of my board except for specific ones where I put CONFIG_APP_TOUCH_PT8041 = y in the board revision conf file.
Is this possible or or should I just check the revision information in a code file and do the definition there. I think this would be kind of ugly but that seems to work.
Tiit