VS Code debug is selecting the HEX file rather than the ELF

I'm trying to debug an application however there is no documentation on how to set up the debug. 
How come nRF connect is selecting the HEX file. I want it to select the ELF! 
{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: go.microsoft.com/.../
    "version": "0.2.0",
    "configurations": [
        {
            "type": "nrf-connect",
            "request": "launch",
            "name": "Launch active build configuration",
            "config": "${activeConfig}",
            "runToEntryPoint": "main"
        },
        {
            "name": "Launch build_opito_ns",
            "type": "nrf-connect",
            "request": "launch",
            "config": "c:\\opito\\zephyr\\opito_mqtt\\build_opito_ns",
            "runToEntryPoint": "main"
        }
    ]
}

Parents
  • For the avoidance of doubt the below is working when I don't use the nRF connect supplied debug. 

        {
                "name": "Debug not NRF Connect",
                "cwd": "${workspaceFolder}",
                "executable": "C:\\opito\\zephyr\\opito_mqtt\\build_opito_ns\\zephyr\\zephyr.elf",
                "request": "launch",
                "type": "cortex-debug",
                "runToEntryPoint": "main",
                "servertype": "jlink",
                "device": "nrf9160_xxAA",
                "interface": "swd",
                "armToolchainPath":"c:\\Users\\marsh\\.zephyrtools\\toolchain\\bin"
       }

  • Hi,

    The elf file is added as a symbol file, using the GDB command add-symbol-file, when debugging with the VS Code extension:

    For some reason this part seems to be lacking in the picture you attached. Can you add "showDevDebugOutput": true, to the configuration in launch.json to get verbose logging and upload the output here?

    Best regards,

    Marte

Reply Children
No Data
Related