mirror of
https://github.com/espressif/esp-idf
synced 2025-03-10 01:29:21 -04:00
esptool: add quotes to allow complicated serial port path
Especially for Windows COM format: \\\.\COMx, introduced in b00cea250f71c3d1167eb10f570e3abba6c19186
This commit is contained in:
parent
f7ca36513e
commit
862fa815ff
@ -15,7 +15,7 @@ PYTHON ?= $(call dequote,$(CONFIG_SDK_PYTHON))
|
||||
#
|
||||
ESPTOOLPY_SRC := $(COMPONENT_PATH)/esptool/esptool.py
|
||||
ESPTOOLPY := $(PYTHON) $(ESPTOOLPY_SRC) --chip esp32
|
||||
ESPTOOLPY_SERIAL := $(ESPTOOLPY) --port $(ESPPORT) --baud $(ESPBAUD) --before $(CONFIG_ESPTOOLPY_BEFORE) --after $(CONFIG_ESPTOOLPY_AFTER)
|
||||
ESPTOOLPY_SERIAL := $(ESPTOOLPY) --port '$(ESPPORT)' --baud $(ESPBAUD) --before $(CONFIG_ESPTOOLPY_BEFORE) --after $(CONFIG_ESPTOOLPY_AFTER)
|
||||
|
||||
# Supporting esptool command line tools
|
||||
ESPEFUSEPY := $(PYTHON) $(COMPONENT_PATH)/esptool/espefuse.py
|
||||
@ -89,7 +89,7 @@ endif
|
||||
ifdef CONFIG_SECURE_FLASH_ENCRYPTION_MODE_DEVELOPMENT
|
||||
encrypted-flash: all_binaries $(ESPTOOLPY_SRC) $(call prereq_if_explicit,erase_flash) partition_table_get_info | check_python_dependencies
|
||||
$(eval MONITOR_OPTS += --encrypted)
|
||||
@echo "Flashing binaries to serial port $(ESPPORT) (app at offset $(APP_OFFSET))..."
|
||||
@echo "Flashing binaries to serial port '$(ESPPORT)' (app at offset $(APP_OFFSET))..."
|
||||
ifdef CONFIG_SECURE_BOOT
|
||||
@echo "(Secure boot enabled, so bootloader not flashed automatically. See 'make bootloader' output)"
|
||||
endif
|
||||
@ -101,20 +101,20 @@ encrypted-flash:
|
||||
endif
|
||||
|
||||
flash: all_binaries $(ESPTOOLPY_SRC) $(call prereq_if_explicit,erase_flash) partition_table_get_info | check_python_dependencies
|
||||
@echo "Flashing binaries to serial port $(ESPPORT) (app at offset $(APP_OFFSET))..."
|
||||
@echo "Flashing binaries to serial port '$(ESPPORT)' (app at offset $(APP_OFFSET))..."
|
||||
ifdef CONFIG_SECURE_BOOT
|
||||
@echo "(Secure boot enabled, so bootloader not flashed automatically. See 'make bootloader' output)"
|
||||
endif
|
||||
$(ESPTOOLPY_WRITE_FLASH) $(ESPTOOL_ALL_FLASH_ARGS)
|
||||
|
||||
app-flash: $(APP_BIN) $(ESPTOOLPY_SRC) $(call prereq_if_explicit,erase_flash) partition_table_get_info | check_python_dependencies
|
||||
@echo "Flashing app to serial port $(ESPPORT), offset $(APP_OFFSET)..."
|
||||
@echo "Flashing app to serial port '$(ESPPORT)', offset $(APP_OFFSET)..."
|
||||
$(ESPTOOLPY_WRITE_FLASH) $(APP_OFFSET) $(APP_BIN)
|
||||
|
||||
ifdef CONFIG_SECURE_FLASH_ENCRYPTION_MODE_DEVELOPMENT
|
||||
encrypted-app-flash: $(APP_BIN) $(ESPTOOLPY_SRC) $(call prereq_if_explicit,erase_flash) partition_table_get_info | check_python_dependencies
|
||||
$(eval MONITOR_OPTS += --encrypted)
|
||||
@echo "Flashing encrypted app binary to serial port $(ESPPORT) (app at offset $(APP_OFFSET))..."
|
||||
@echo "Flashing encrypted app binary to serial port '$(ESPPORT)' (app at offset $(APP_OFFSET))..."
|
||||
$(ESPTOOLPY_WRITE_FLASH_ENCRYPT) $(APP_OFFSET) $(APP_BIN)
|
||||
else
|
||||
encrypted-app-flash:
|
||||
@ -144,7 +144,7 @@ endif
|
||||
# miniterm.py on the console. The '$(PYTHON) -m serial.tools.miniterm'
|
||||
# is to allow for the $(PYTHON) variable overriding the python path.
|
||||
simple_monitor: $(call prereq_if_explicit,%flash) | check_python_dependencies
|
||||
$(MONITOR_PYTHON) -m serial.tools.miniterm --rts 0 --dtr 0 --raw $(ESPPORT) $(MONITORBAUD)
|
||||
$(MONITOR_PYTHON) -m serial.tools.miniterm --rts 0 --dtr 0 --raw '$(ESPPORT)' $(MONITORBAUD)
|
||||
|
||||
PRINT_FILTER ?=
|
||||
|
||||
@ -154,7 +154,7 @@ ifneq ("$(MONITOR_CORE_DUMP_DECODE)","")
|
||||
MONITOR_CORE_DUMP_DECODE_ARG = --decode-coredumps $(MONITOR_CORE_DUMP_DECODE)
|
||||
endif
|
||||
|
||||
MONITOR_OPTS := --baud $(MONITORBAUD) --port $(ESPPORT) --toolchain-prefix $(CONFIG_SDK_TOOLPREFIX) --make "$(MAKE)" --print_filter "$(PRINT_FILTER)" $(MONITOR_CORE_DUMP_DECODE_ARG)
|
||||
MONITOR_OPTS := --baud $(MONITORBAUD) --port '$(ESPPORT)' --toolchain-prefix $(CONFIG_SDK_TOOLPREFIX) --make "$(MAKE)" --print_filter "$(PRINT_FILTER)" $(MONITOR_CORE_DUMP_DECODE_ARG)
|
||||
|
||||
monitor: $(call prereq_if_explicit,%flash) | check_python_dependencies
|
||||
$(summary) MONITOR
|
||||
|
Loading…
x
Reference in New Issue
Block a user