Skip to content

OpenOCD gdb_port command does not work for certain chips #149

@haneefdm

Description

@haneefdm

For OpenOCD, you have to typically run one or more tcl scripts to get it going. Some scripts require an 'init' function to be executed after which they can do additional configuration to get the debug target ready.

Problem is that our extension selects the port(s) automatically (nice) and passes it as the desired/required port to openocd as the last argument. But if the config scripts ever called 'init', then the last command line causes a stack trace in openocd and it quits.

There is nothing wrong with setting the port as the first argument instead of the last. It is just a global variable in openocd that is not used until 'init' is called and which is why you can't change after 'init' is called.

I have a simple fix in my sandbox but I want to hear opinions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions