• AVR Freaks

Hot!MPLABX 5.30 Ghost Breakpoints

Page: 12 > Showing page 1 of 2
Author
JeffADI
Starting Member
  • Total Posts : 34
  • Reward points : 0
  • Joined: 2018/08/24 17:24:38
  • Location: 0
  • Status: offline
2019/11/08 05:02:08 (permalink)
5 (1)

MPLABX 5.30 Ghost Breakpoints

I'm having a problem with the debugger stopping at deleted breakpoints.
Anyone else see this?
If so, do you have a fix?
#1

25 Replies Related Threads

    NKurzman
    A Guy on the Net
    • Total Posts : 18908
    • Reward points : 0
    • Joined: 2008/01/16 19:33:48
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/08 06:54:48 (permalink)
    +1 (1)
    Right click on the breakpoint field and select delete all breakpoints.
    Or close MPLabX and reopen it.
    #2
    JeffADI
    Starting Member
    • Total Posts : 34
    • Reward points : 0
    • Joined: 2018/08/24 17:24:38
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/08 08:22:34 (permalink)
    +1 (1)
    Deleting all breakpoints does not work (for me)
    It is quite annoying to have to restart MPLABX everytime I delete a breakpoint.
    Thanks for the reply
    #3
    NKurzman
    A Guy on the Net
    • Total Posts : 18908
    • Reward points : 0
    • Joined: 2008/01/16 19:33:48
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/08 08:41:18 (permalink)
    +1 (1)
    If this is happening all the time then it’s probably more serious.
    What pic and which debugger ?
    #4
    JeffADI
    Starting Member
    • Total Posts : 34
    • Reward points : 0
    • Joined: 2018/08/24 17:24:38
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/08 08:44:34 (permalink)
    0
    MPLABX 5.52 on Win10
    PICKit4
    PIC16LF1936 and PIC16LF19155
     
    Not saying it happens everytime, but often enough to raise my BP.
    #5
    GeorgePauley
    Moderator
    • Total Posts : 1268
    • Reward points : 0
    • Joined: 2009/12/01 13:59:30
    • Location: Chandler AZ
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/08 09:49:23 (permalink)
    +1 (3)
    Don't have a solution, but perhaps a few suggestions.

    Software Breakpoints:  Are implemented by replacing user opcodes with special "halt" instruction in the device flash memory.  So if a "halt" instruction is "stuck" in flash, a re-programming of the flash should fix this.
     
    Hardware Breakpoints:  Are implemented via special debug registers on the device.  A power-on-reset will erase any values in these registers.
    #6
    JeffADI
    Starting Member
    • Total Posts : 34
    • Reward points : 0
    • Joined: 2018/08/24 17:24:38
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/08 10:37:48 (permalink)
    0
    Thanks George, I'll keep that in mind.
     
    #7
    user2x
    Super Member
    • Total Posts : 414
    • Reward points : 0
    • Joined: 2011/02/10 20:43:36
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/11 02:29:07 (permalink)
    +1 (1)
    GeorgePauley  ...So if a "halt" instruction is "stuck" in flash, a re-programming of the flash should fix this.


     
    I thought the Flash re-prorams on every debug session. ?
     
    #8
    JeffADI
    Starting Member
    • Total Posts : 34
    • Reward points : 0
    • Joined: 2018/08/24 17:24:38
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/11 04:33:02 (permalink)
    0
    Everytime you start a debugging session it will re-Flash the chip. 
    But I think what George is saying is that when you set a software breakpoint, it rights a HALT instruction at the address of the breakpoint. When you remove the breakpoint, the HALT stays.
    #9
    GeorgePauley
    Moderator
    • Total Posts : 1268
    • Reward points : 0
    • Joined: 2009/12/01 13:59:30
    • Location: Chandler AZ
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/11 08:32:32 (permalink)
    +1 (1)
    JeffADI
    But I think what George is saying is that when you set a software breakpoint, it rights a HALT instruction at the address of the breakpoint. When you remove the breakpoint, the HALT stays.



    Well, it's not supposed to stay... mr green: mr green
    #10
    JeffADI
    Starting Member
    • Total Posts : 34
    • Reward points : 0
    • Joined: 2018/08/24 17:24:38
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/11 08:33:51 (permalink)
    +1 (1)
    Should I open an official ticket to put it on the bug list?
    #11
    GeorgePauley
    Moderator
    • Total Posts : 1268
    • Reward points : 0
    • Joined: 2009/12/01 13:59:30
    • Location: Chandler AZ
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/11/11 08:36:54 (permalink)
    +2 (2)
    If you have a (hopefully simple) and (necessarily) repeatable issue, then yes please open a ticket!
    #12
    DominusT
    Super Member
    • Total Posts : 1425
    • Reward points : 0
    • Joined: 2005/07/22 08:31:18
    • Status: online
    Wieschebrock
    Super Member
    • Total Posts : 229
    • Reward points : 0
    • Joined: 2005/01/22 07:57:44
    • Location: Germany
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2019/12/02 02:07:30 (permalink)
    +2 (2)
    I have this problem with every MPLABX versions I can remember. Not on all debug sessions, but very often. Closing and reopening the project works for me, but it is very annoying.
    #14
    Neiwiertz
    Super Member
    • Total Posts : 2125
    • Reward points : 0
    • Joined: 2004/09/01 02:58:52
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2020/08/03 03:05:10 (permalink)
    +1 (1)
    @Wieschebrock
    i faced exactly the same and its identical behavior as you described

    today i was facing the same trouble.. in progress of setup and develop a new project
    for a particular c file.. the set of the breakpoint went fine it shows up red, but after debug programming it automatically gets grayed out to become a ghost breakpoint,

    i tried your method but this time no dice, the valid breakpoint.. automatically gets grayed out by mplabx
    it cost me full day to find a workaround,

    first i tried to clear the cache folder at appdata default_cachedir and for the userdir i deleted the var folder
    but no dice, i even cleared all output files of the project like the elf or cof or list file..
    therefore mplabx could not pre load it but no dice, i tried this in the past before and even tried other mplabx
    version or clean install of the current version still the no dice, but the actual c file builds fine and is valid

    today i minimized the project and suddenly the breakpoint become to be alife and works as expected
    it turns out the include order.. sequence the c and or h files.. is to be important at file nbproject configuration.xml
    first close all files, next close project or all projects at mplabx, then modify this configuration.xml
    and open the project again

    anybody can clarify what is the appropriate include order.. sequence the c and or h files.. at the nbproject configuration.xml or any additional info is very welcome :)

    Flying With --|Explorer 16|HardWare|SoftWare|-- Fav(s) Gallery Lists
    #15
    Neiwiertz
    Super Member
    • Total Posts : 2125
    • Reward points : 0
    • Joined: 2004/09/01 02:58:52
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2020/08/03 03:31:55 (permalink)
    +1 (1)
    i came across the change the include order of files.. from project perspective of nbproject configuration.xml
    due when debug Step into the c file with the broken breakpoint this did not work also, and mplabx opened an other project file, therefore i think mplabx could not setup.. interconnect breakpoint with the c file, due to an incorrect include order of files.. at nbproject configuration.xml setup by me

    update
    the order of include is important, had the same behavior again for particular code module which is used in a thread kind of main module, move this particular code module to be included firstly and then the thread module, fixes the broken grayed out breakpoint, i try always to maintain first to include the global, drivers users and at last the thread and or main module but for large project this can be fastly setup incorrectly without notice

    therefore info and advice about the way how to setup the include order of files..
    sequence of how to add them correctly to mplabx project is very welcome
    maybe this can be enhanced by introduce a hierarchy mplabx build Tag at the first line of the code module
    therefore mplabx can pick this up due when a user module is added after a thread module then this behavior can show up
     
    very cool tool https://www.sourcetrail.com/
    i try to retrieve and verify the include order in myFiles vs the include at the nbproject configuration.xml
    therefore both to match up for c and h files

    anybody uses simular kind of code viewing tools
    post edited by Neiwiertz - 2020/08/03 06:51:15

    Flying With --|Explorer 16|HardWare|SoftWare|-- Fav(s) Gallery Lists
    #16
    Neiwiertz
    Super Member
    • Total Posts : 2125
    • Reward points : 0
    • Joined: 2004/09/01 02:58:52
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2020/08/05 06:58:51 (permalink)
    +1 (1)
    cost me again a full day to make it work and get rid of this automatic grayed out of a valid breakpoint after programming, due turns out the mplabx could not resolve and open wrong c file, it is un-related to userdir or cachdir, i deleted cachedir and recreated userdir by merging in my compiler preferences and custom build line(s) etc

    it turn out the include order sequence  of h files and or c files is key at the nbproject configuration.xml

    so why does mplabx rely on this include sequence  of h files and or c files at the nbproject configuration.xml
    to open the desired file when performing a step into from a higher breakpoint, better to statically retrieve the #include order sequence or the mplabx perform internal a file search to figure out which file to open

    so what are the requirement for the include order sequence  of h files and or c files is key at the nbproject configuration.xml, in speaking of terms when you have a large project

    Flying With --|Explorer 16|HardWare|SoftWare|-- Fav(s) Gallery Lists
    #17
    jms7805
    New Member
    • Total Posts : 2
    • Reward points : 0
    • Joined: 2020/05/27 17:00:12
    • Location: 0
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2020/08/05 08:53:43 (permalink)
    0
    1. Yes, the order of the tool-chain compilation is important. How it applies to ghosting breakpoints, I don't know. As for myself and break-point issues, I couldn't get them to work consistently--ghosting and sometimes not even breaking; like it was mad at me. (Two days of confusion.) I have a PICkit-4 here at work and one at home. The one at work (my issues were here) has some Chinese writing on it. Brought the one from home, no writing, and all the break-point issues went away, uh-uh. Put the bad one back on, toggled the voltage menu, and speed, a couple times,  took a coffee break and it worked okay--it was hot, think it had a fever. Using a PIC16F1619 that comes with Curiosity.  
     
    2. I read alot in the nbproject/netbeans material etc. how the tool-chain works and got tired. My best experience (about a day and half) is has been to order them as listed in the X IDE top down, don't excluded files in the Project Properties/File Inclusion/Exclusion feature thingy. Still use pre-complier directive guards. Keep all the headers .h's and code .c's together of course. Cast functions in the first .h file, even though it doesn't make for a true .h file. The internal order of some .h files for my project bugged me and acted up for a while, inconsistently of course--sorry. 
     
    3. Still, just mostly a hobbyist for now, been away from PIC's for about 5-6 years. More proficient as a Visual Studio C and Basic programmer. I am amazed how far Microchip has come in just a short time. The features in the current chips are just marvelous, speeds, and consistency are incredible. Climbing over the re-learning X IDE curve is tough, I'm still going. (Having terrible issues with the Forum today for some reason only can use one "special" computer to login.)  
    #18
    Neiwiertz
    Super Member
    • Total Posts : 2125
    • Reward points : 0
    • Joined: 2004/09/01 02:58:52
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2020/08/07 02:00:31 (permalink)
    -1 (1)
    ###
    1. Yes, the order of the tool-chain compilation is important. How it applies to ghosting breakpoints, I don't know. As for myself and break-point issues, I couldn't get them to work consistently--ghosting and sometimes not even breaking; like it was mad at me. (Two days of confusion.)
    ###
    as of my research try and error :) i feel with an ~incorrect~ order of the tool-chain compilation therefore mplabx
    it will halt at a function call but next when perform step into it opens a incorrect c or h file
    swapping modify the order of the tool-chain compilation at nbproject configuration.xml file will solve this
     
    yeah mplabx does use this order therefore microchip would be very nice if it could explain within the user guide
    and here at the forum board how to correctly setup such order certain when we have many c and h files :)

    ###
    took a coffee break and it worked okay--it was hot, think it had a fever
    ###
    Lol :)

    ###
    The features in the current chips are just marvelous, speeds, and consistency are incredible.
    ###
    yep therefore those little microchips are the coolest to get started

    ###
    Climbing over the re-learning X IDE curve is tough
    ###
    yeah certain when those ghost grayed out breakpoints shows up
    otherwise i am using it fine, i like those xml project files that real cool
    always ask here in the forum boards, and for login trouble maybe delete those damn cookies by using ccleaner could help
    post edited by Neiwiertz - 2020/08/07 02:16:07

    Flying With --|Explorer 16|HardWare|SoftWare|-- Fav(s) Gallery Lists
    #19
    Neiwiertz
    Super Member
    • Total Posts : 2125
    • Reward points : 0
    • Joined: 2004/09/01 02:58:52
    • Status: offline
    Re: MPLABX 5.30 Ghost Breakpoints 2020/09/09 06:26:43 (permalink)
    0
    Again automatically from red to greyed-out broken breakpoint, the large project builds fine
    now need the re-adjust the include order and hope to find a working cherry include order
    if microchip would shine a light on this for example best pratice for setup include order
    that would be awesome
     

    Flying With --|Explorer 16|HardWare|SoftWare|-- Fav(s) Gallery Lists
    #20
    Page: 12 > Showing page 1 of 2
    Jump to:
    © 2020 APG vNext Commercial Version 4.5