Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request]: Flash via JTAG _without_ serial (VSC-1575) #1411

Open
karlp opened this issue Jan 23, 2025 · 0 comments
Open

[Feature Request]: Flash via JTAG _without_ serial (VSC-1575) #1411

karlp opened this issue Jan 23, 2025 · 0 comments
Labels
Feature / Enhancement Request Request for Feature/ Enhancement

Comments

@karlp
Copy link

karlp commented Jan 23, 2025

Is your feature request related to a problem? Please describe.
I have a board that has only a jtag header. (2x5pin, I'm not talking about Using command line tools, I can flash and debug, using openocd, and "mon program_esp ...."
However, if I try and flash in vscode, it always attempts to open a serial port with esptool. This is despite having "flash method JTAG" set ("idf.flashType": "JTAG")

It seems that #183 really only applies to flashing via the built in usb-jtag? at least, it certainly doesn't seem to help

It's perhaps demonstrated by this diagram: https://docs.espressif.com/projects/vscode-esp-idf-extension/en/latest/debugproject.html#debugging-process-overview where it shows that flashing is always via the uart.

I very much want to avoid having to use a second cable, just for vscode.

Describe alternatives you've considered
Adding a serial connection jsut for flashing does work, but... seriously?

I've tried using the explist tasks "ESP-IDF:Flash (with jtag)" option as well, both with and without openocd started before hand.

Additional context
maybe I'm just missing how to configure this?

I'm not very good at reading typescript, but it almost appears as if the jtag code got detached somewhere. flashcmd.ts will error if a port isn't set, and in flashtask, https://github.com/espressif/vscode-esp-idf-extension/blob/master/src/flash/flashTask.ts#L111-L119 it seems to just... not handle the jtag case?

My openocd.cfg file

source [find interface/cmsis-dap.cfg]
adapter speed 8000
transport select jtag
bindto 0.0.0.0
set ESP32_FLASH_VOLTAGE 3.3
# Source the ESP32 configuration file
source [find target/esp32.cfg]

My settings.json

{
        "C_Cpp.intelliSenseEngine": "default",
        "idf.espIdfPath": "/home/karlp/src/esp-idf",
        "idf.toolsPath": "/home/karlp/tools/esp-idf",
        "idf.openOcdConfigs": [
                "openocd.cfg",
        ],
        "idf.openOcdDebugLevel": "3",
        "idf.flashType": "JTAG"
}

ESP-IDF plugin version: 1.9.0

@karlp karlp added the Feature / Enhancement Request Request for Feature/ Enhancement label Jan 23, 2025
@github-actions github-actions bot changed the title [Feature Request]: Flash via JTAG _without_ serial [Feature Request]: Flash via JTAG _without_ serial (VSC-1575) Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature / Enhancement Request Request for Feature/ Enhancement
Projects
None yet
Development

No branches or pull requests

1 participant