• AVR Freaks

Hot!Watches: impossible to add (MPLAB 5.25/XC8 2.10/PIC18F46K22)

Author
goupil35000
New Member
  • Total Posts : 14
  • Reward points : 0
  • Joined: 2011/10/02 06:31:57
  • Location: 0
  • Status: offline
2019/09/04 03:24:51 (permalink)
0

Watches: impossible to add (MPLAB 5.25/XC8 2.10/PIC18F46K22)

Hi,
It seems impossible to add watches (or variables) to see them.
It's the same in Windows 10 and in Ubuntu.
The variables don't appear in Global Symbols, so it's impossible to add them.
 
Configuration: MPLAB 5.25 / XC2.10 / PIC18F46K22 / Simulator.
 
Thanks for reply
post edited by goupil35000 - 2019/09/04 07:17:31
#1

5 Replies Related Threads

    domble
    Senior Member
    • Total Posts : 130
    • Reward points : 0
    • Joined: 2007/01/25 04:11:53
    • Location: 0
    • Status: offline
    Re: Watches: impossible to add (MPLAB 5.25/XC2.10) 2019/09/04 06:26:00 (permalink)
    0
    What is XC2.10? 
    Debug, New Watch, type in its name, it appears in Variables window whether it exists or not. 
     
    dom
    #2
    ric
    Super Member
    • Total Posts : 24581
    • Reward points : 0
    • Joined: 2003/11/07 12:41:26
    • Location: Australia, Melbourne
    • Status: offline
    Re: Watches: impossible to add (MPLAB 5.25/XC2.10) 2019/09/04 06:39:04 (permalink)
    +1 (1)
    I'm guessing the OP means XC8 2.10
    If they had revealed which PIC device they are using, we'd have a better chance of guessing which compiler it is.

    I also post at: PicForum
    Links to useful PIC information: http://picforum.ric323.co...opic.php?f=59&t=15
    NEW USERS: Posting images, links and code - workaround for restrictions.
    To get a useful answer, always state which PIC you are using!
    #3
    pcbbc
    Super Member
    • Total Posts : 1381
    • Reward points : 0
    • Joined: 2014/03/27 07:04:41
    • Location: 0
    • Status: offline
    Re: Watches: impossible to add (MPLAB 5.25/XC2.10) 2019/09/04 06:57:12 (permalink)
    +1 (1)
    ricI'm guessing the OP means XC8 2.10

    Me also.
    If they had revealed which PIC device they are using, we'd have a better chance of guessing which compiler it is.

    Errr... PIC18F46K22 ?
    #4
    goupil35000
    New Member
    • Total Posts : 14
    • Reward points : 0
    • Joined: 2011/10/02 06:31:57
    • Location: 0
    • Status: offline
    Re: Watches: impossible to add (MPLAB 5.25/XC8 2.10/PIC18F46K22) 2019/09/04 07:24:54 (permalink)
    0
    Thanks domble, ric, pcbbc.
    I modified the title to correct for xc8 and define the PIC.
     
    And I confirm that I tried to add watches and variables with all possibilities:
    - selection of variable in the editor then right-click "New Watch";
    - in watches or variables window trying to add directly typing the name, or clicking to open the "New watch" window and typing the name -- clicking SFR or Global Symbols -- and the last method right-clicking in watches to select "New Watch".
     
    But what is new:
    - when I close MPLABX and reopen ... all the watches I defined are there and disappear when launching debugger;
    - I finally am able to add watches if and only if I declare the variables at the beginning of the main function and if I give them a default value. Examples (... is some lines of code):
    ------ in this example 1 I can get watch for a ---
    void main(void) {
    unsigned char a=0;
    ...
    }
     
    ------ in this example 2, I can't get watches ---
    void main(void) {
    unsigned char a;
    ...
    a=10;
    ...
    }
     
    ------ in this example 3, I can't get watches ---
    void main(void) {
    ...
    unsigned char a=10;
    ...
    }
     
    Thanks
     
    Goupil
    post edited by goupil35000 - 2019/09/04 09:39:55
    #5
    mbrowning
    USNA79
    • Total Posts : 1564
    • Reward points : 0
    • Joined: 2005/03/16 14:32:56
    • Location: Melbourne, FL
    • Status: offline
    Re: Watches: impossible to add (MPLAB 5.25/XC8 2.10/PIC18F46K22) 2019/09/04 13:30:26 (permalink)
    0
    I had trouble with watches when I briefly flirted with 2.10. I switched back to 2.05 and they worked as expected.

    Go Navy! Beat Army!
    #6
    Jump to:
    © 2019 APG vNext Commercial Version 4.5