This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS/TM4C123GE6PM: Understanding why a variable is invisible in my main.c

Part Number: TM4C123GE6PM

Tool/software: Code Composer Studio

Hello,

I was advised to ask this question here:

Why the problem never happens in the first place when I declare g_bMPU6050Done inside a .h 

but does happen when I declare it inside a .c file (which is added to my CCS project)...

  • To understand the best way to declare and define global variables, please see this FAQ (not from TI).  I am not certain what is going wrong in your case.  But I suspect you did not put a declaration of g_bMPU6050Done in a header file that is included by main.c

    Thanks and regards,

    -George