Using sfr26a.h causes redeclaration errors
Up to The Basement Workshop
Continuing to work on my project based on the qsk26a board, I got my graphics display working. I next have added UART0 code by creating a new c module with the uart code inside. I included “#include “sfr26a.h” “ in the c module (which the same include is in another module). When compiling I am getting redeclaration errors in the sfr26a.h file. I need the sfr26a.h in both modules, how do I keep the complier from trying to redeclare the items twice?
Thanks,
David
Check to make sure the header files themselves are not using the #include "sfr26a.h"...
It should only appear once per C file. If the header files include it too, you get errors.
Powered by
Ploneboard

