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/TM4C123GH6PM: identifier not found in the watch window

Part Number: TM4C123GH6PM
Other Parts Discussed in Thread: SEGGER

Tool/software: Code Composer Studio

I am just trying to run the example code - ADC temperature sensor for TM4C123GH6PM

I have included the path. The UART can work and display the results properly. But I can't see the results on my watch window.

I added 2 variables to my "Expressions" window, but it showed that "identifier not found".

Below is the problem that I am encountering.

Any advice would be appreciated.

  • Sorry, I forgot to mention: I turned off optimization as well
  • Would the values be function local by any chance?

    Robert
  • another problem I have is like every time I suspend the debugging, I got this little error window

  • Not sure that's an actual problem given that you are in an assembly view. Your C code is present on the display.

    My first question still stands.

    Robert
  • Hi Robert,

    I defined those 2 values outside of main function and I get get rid of the "identifier not found" error.
    I got another problem though. The values are not updating. I only got value for one time. Then, the values stay there and do not change but it's supposed to change.
  • I don't know about CCS but it's not unusual for debuggers to only show changed values when stopped. Segger has utilities for their JTAGs that allow such live viewing for at least some of their adapters.

    Robert
  • Tom,
    There's nothing wrong there.
    1) Your variables - under default settings - will only change value when you pause your debugging.
    2) If you pause inside a certain context, and the variable (or, as CCS is calling it, the identifier) is not known inside that context, it will show as not found.
    To see a variable, you need to pause your debugger inside the context where the variable is declared. Of course, a global variable will show up pretty much everywhere.
    Regards
    Bruno

  • Bruno Saraiva said:
    Tom,
    There's nothing wrong there.
    1) Your variables - under default settings - will only change value when you pause your debugging.

    Hi Bruno,

    Can it be "true" that, "Your variables will only change value when you pause your debugging?"     (you meant to write that such values may (potentially) reveal change - when "paused" - if they had (actually) changed value - between "pauses.")        That's a SEVERE Weakness - one I'm not so sure - has been allowed to continue (even w/in vendor's (so limited) system)...

    If that's (really) the case - I'd attach that IDE to a (large) rock - and journey to the nearest/highest cliff!

    IAR has (forever) - in association w/Segger (as Robert has mentioned) - proven ability to,  "MONITOR and DISPLAY"  MULTIPLE VARIABLES - ALL "LIVE" - WHILE THE PROGRAM IS RUNNING!      (i.e. when such variable knowledge - is BY FAR - MOST USEFUL & REQUIRED!)       (it is hoped that the "rope" binding (blind/limited) IDE to the rock - may be retrieved - and "recycled" - for those, "efficiency-seeking" users...)

  • Fellows: cb1_mobile has properly inquired me about my sentence: "Your variables will only change value when you pause your debugging"

    Well, that can be taken with a grain of salt.

    It is possible to monitor variable changes; you need to enable the "Continuous Refresh" feature on the Expressions watch. Image below (I would post a video, but take my word for it...)

    There are a few considerations: the refresh rate ain't huge, and (IF I'M NOT MISTAKEN) there is some sort of brief pause going on while CCS fetches the new value.

    Other breakpoint tricks can be explored, such as breaking when a certain memory location is written, or adding conditional watch expressions. There are probably documents teaching that somewhere, could be a useful toilet-time-reading - otherwise, just take that as the type of learning that fall into "there's gotta be a way to do that, and I'll find it out when I need"...

    Bruno

  • Here's another image inviting readers to explore some additional bells and whistles:

    I was able to get a decent refresh rate of 10Hz, and my brain won't be able to use anything faster than that anyway.

  • Well done Bruno - yet your (new) findings (somewhat) conflict  w/your earlier posting.      It is believed that your "follow-on" reports (substantially) improved upon your (perhaps rushed) earlier one.

    And - might you (properly) amend the post in which you attribute a "quote" to me - when in fact I have "directly" quoted you?      (that is never, "good form!")

    Attribution IS important - I do request that you remove or amend that, INCORRECTLY SOURCED, Quotation.

  • Good day cb1,
    I trust you will find my correction acceptable.
    Just to be clear, I had initially left your question mark at the end of the quote - the intention was to quote the fact that you ASKED such sentence, not stated it. No harm meant - as always!
    Cheers
  • And - good afternoon to you, Bruno.       (already LSD (Lake Shore Drive, Chicago ... Great Lake Michigan) traffic crawls @ 06:45!)

    Indeed - that's much better - the attribution issue well resolved - thank you, Bruno.

    And I (only now) note your use of the "question mark" - yet that proves so MINOR a detail - as to be (too easily) missed!      Your new writing clearly describes & corrects!

    In absence of your (arrived later) greatly additive reports - firm/I "acquired" multiple "marine-grade" LINES (never ropes!)   -   (to assist the "off the cliff" IDE exercises - which may now be, "postponed.")     Although some here - even via (protective/famed) "Ten Foot Pole" - would not touch (that) IDE...

  • Thanks Bruno for your tricks. I wonder if there is a way to change the refresh rate?
  • C'mon, Tom!
    You are not paying as good an attention as you can!
    One of the images I posted has a menu entry to "Continuous Refresh Interval..." settings! ;)
    It opens the CCS's general debug preferences, with that very one, as well as other preferences you can mess with.
    Bruno
  • Oops..my bad
    Thanks again