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

Command Build & Flash fail in monitor (IDFGH-6805) #8432

Closed
HiFiPhile opened this issue Feb 18, 2022 · 1 comment
Closed

Command Build & Flash fail in monitor (IDFGH-6805) #8432

HiFiPhile opened this issue Feb 18, 2022 · 1 comment
Assignees
Labels
Platform: Windows issues pertain to Windows Resolution: Done Issue is done internally Status: Done Issue is done internally

Comments

@HiFiPhile
Copy link
Contributor

HiFiPhile commented Feb 18, 2022

Environment

  • Development Kit: [ESP32-C3-DevKitM-1]
  • Kit version (for WroverKit/PicoKit/DevKitC): [v1]
  • IDF version (run git describe --tags to find it):
    v5.0-dev-1599-gb66cc63c41
  • Build System: [df.py]
  • Compiler version (run xtensa-esp32-elf-gcc --version to find it):
    (crosstool-NG esp-2021r2-patch2) 8.4.0
  • Operating System: [Windows]
  • (Windows only) environment type: [ESP Command Prompt].
  • Using an IDE?: [No]
  • Power Supply: [USB]

Problem Description

Both idf.py -p COM7 monitor and idf.py -p COM7 flash can be run succesfully.

Launch idf.py -p COM7 monitor, command Ctrl+F Build & flash project fail in monitor.

Running C:\Tool\esp-idf\python_env\idf5.0_py3.9_env\Scripts\python.exe E:\mcu\esp-idf\tools\idf.py -p COM7 flash...
Option "port" provided for "flash" is already defined to a different value. This option can appear at most once in the command line.
--- Build failed
--- Press Ctrl+] to exit monitor.
--- Press Ctrl+F to build & flash project.
--- Press Ctrl+A to build & flash app.
--- Press any other key to resume monitor (resets target).

Then I modified idf.py to print the value:

 if global_value != default and local_value != default and global_value != local_value:
                            raise FatalError(
                                'Option "%s" provided for "%s" is already defined to a different value. '
                                'Local : %s ; Global : %s '
                                'This option can appear at most once in the command line.' % (key, task.name, local_value, global_value))

Which get :

Option "port" provided for "flash" is already defined to a different value. Local : \\.\COM7 ; Global : COM7 This option can appear at most once in the command line.

Turns out \\.\ is not correctly handled inside the script.

@espressif-bot espressif-bot added the Status: Opened Issue is new label Feb 18, 2022
@github-actions github-actions bot changed the title Command Build & Flash fail in monitor Command Build & Flash fail in monitor (IDFGH-6805) Feb 18, 2022
@0xjakob 0xjakob added the Platform: Windows issues pertain to Windows label Feb 21, 2022
@dobairoland
Copy link
Collaborator

Thank you @HiFiPhile reporting this. We will fix this soon.

@espressif-bot espressif-bot added Status: In Progress Work is in progress Resolution: NA Issue resolution is unavailable Status: Done Issue is done internally Resolution: Done Issue is done internally and removed Status: Opened Issue is new Status: In Progress Work is in progress Resolution: NA Issue resolution is unavailable labels Feb 22, 2022
espressif-bot pushed a commit to espressif/esp-idf-monitor that referenced this issue Jan 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: Windows issues pertain to Windows Resolution: Done Issue is done internally Status: Done Issue is done internally
Projects
None yet
Development

No branches or pull requests

4 participants