arm-none-eabi-gdb remote debug error

General questions regarding the usage of CodeLite
ndivner
CodeLite Enthusiast
Posts: 37
Joined: Sun Mar 16, 2008 12:49 pm
Contact:

Re: arm-none-eabi-gdb remote debug error

Post by ndivner »

Hi Eran et al,

I have made quite a bit of progress with the changes required for embedded debugging and to make any changes suitable for integration.
To be able to do that I timed out to refresh my knowledge of wxWidgets and familiarize myself with wxCrafter.
I wanted these changes to have CodeLite behavour as it is or be selectable to do Embedded Debugging as distinct from Remote Debugging.
First attempt at this is to have two checkboxes to switch between the debugging modes as follows :-
1 Move the existing m_checkBoxDbgRemote into a new horizontal FlexgridSizer.
2 Add a new m_checkBoxDbgEmbedded into the FlexgridSizer and label it "Debugging embedded target".
3 Rename the m_checkBoxDbgEmbedded Event Handler to be "OnCmdEvtEmbeddedToggle".
4 Rename the m_checkBoxDbgRemote Event Handler to be "OnCmdEvtRemoteToggle".
5 Generate the wxCrafter code.
6 Edit PSDebuggerPage::OnCmdEvtEmbeddedToggle in Codelite/LiteEditor/ps_debugger_page.cpp to be

Code: Select all

    m_dlg->SetIsDirty(true);
    if (event.IsChecked())
    {
        m_checkBoxDbgRemote->SetValue(false);
    }

7 Edit PSDebuggerPage::OnCmdEvtRemoteToggle in Codelite/LiteEditor/ps_debugger_page.cpp to be

Code: Select all

    m_dlg->SetIsDirty(true);
    if (event.IsChecked())
    {
        m_checkBoxDbgEmbedded->SetValue(false);
    }

8 Add code changes to mimic the code for the m_checkBoxDbgRemote by doing a search->find-in-files for all instances of "Remote".
9 add changes to Codelite/Debugger/debuggergdb.cpp as follows :-
at line approx 298

Code: Select all

        //  Embedded Debugging Changes
        if(GetIsEmbeddedDebugging()) {
            cmd << wxT(" -q --interpreter=mi ") << si.exeName << wxT(".elf");
        } else {
            cmd << wxT(" --interpreter=mi ") << si.exeName;
        }

at line 1156

Code: Select all

    //  Embedded Debugging CHanges
    if(!GetIsEmbeddedDebugging()) {
        if(FileUtils::WriteFileContent(clGdbInitFile, fileContent)) {
            m_observer->UpdateAddLine(wxString() << "Using gdbinit file: " << clGdbInitFile.GetFullPath());
            dbgExeName << " --command=\"" << clGdbInitFile.GetFullPath() << "\"";
        }
    }

10 Build CodeLite.

I am creating bash, Powershell and batch scripts to completely automate all configuration and setup for Arduino development and GDB debugging using CodeLite.
I have not finished testing yet but I am enclosing the patches for Linux. WSL (Windows Subststem for Linux) and Windows Msys2 and a PKGBUILD eexample script for msys2.
Some screenshots are also attached.
Cheers Noel

ndivner
CodeLite Enthusiast
Posts: 37
Joined: Sun Mar 16, 2008 12:49 pm
Contact:

Re: arm-none-eabi-gdb remote debug error

Post by ndivner »

attacments did not upload so here goes again

You do not have the required permissions to view the files attached to this post.
User avatar
eranif
CodeLite Plugin
Posts: 6367
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: arm-none-eabi-gdb remote debug error

Post by eranif »

its best posting this on GitHub issue tracker

Make sure you have read the HOW TO POST thread
ndivner
CodeLite Enthusiast
Posts: 37
Joined: Sun Mar 16, 2008 12:49 pm
Contact:

Re: arm-none-eabi-gdb remote debug error

Post by ndivner »

Hi Eran,
Ok I will move to the Github issue tracker as requested.
I am making steady but slow progress as it is quite a learning effort me.
Noel

Post Reply