diff options
author | Damien George <damien@micropython.org> | 2023-06-14 12:45:46 +1000 |
---|---|---|
committer | Damien George <damien@micropython.org> | 2023-06-23 15:34:37 +1000 |
commit | 717060447f7ba7e71a7f40b19c1e977e4e444f12 (patch) | |
tree | f0c7cbec53972cba562c947407c24e846b651a83 | |
parent | bccbaa92b1fc6237f0f49a7f07cc194835fbf4e3 (diff) | |
download | micropython-717060447f7ba7e71a7f40b19c1e977e4e444f12.tar.gz micropython-717060447f7ba7e71a7f40b19c1e977e4e444f12.zip |
esp32/Makefile: Provide more IDF shortcuts.
And change erase_flash to erase-flash, because the former is deprecated
since IDF 4.4.
Signed-off-by: Damien George <damien@micropython.org>
-rw-r--r-- | ports/esp32/Makefile | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/ports/esp32/Makefile b/ports/esp32/Makefile index 0b33fa6e5a..7c8c225dfb 100644 --- a/ports/esp32/Makefile +++ b/ports/esp32/Makefile @@ -48,6 +48,10 @@ endif HELP_BUILD_ERROR ?= "See \033[1;31mhttps://github.com/micropython/micropython/wiki/Build-Troubleshooting\033[0m" +define RUN_IDF_PY + idf.py $(IDFPY_FLAGS) -p $(PORT) -b $(BAUD) $(1) +endef + all: idf.py $(IDFPY_FLAGS) build || (echo -e $(HELP_BUILD_ERROR); false) @$(PYTHON) makeimg.py \ @@ -61,13 +65,25 @@ all: $(BUILD)/bootloader/bootloader.bin $(BUILD)/partition_table/partition-table.bin $(BUILD)/micropython.bin: FORCE clean: - idf.py $(IDFPY_FLAGS) fullclean + $(call RUN_IDF_PY,fullclean) deploy: - idf.py $(IDFPY_FLAGS) -p $(PORT) -b $(BAUD) flash + $(call RUN_IDF_PY,flash) erase: - idf.py $(IDFPY_FLAGS) -p $(PORT) -b $(BAUD) erase_flash + $(call RUN_IDF_PY,erase-flash) + +monitor: + $(call RUN_IDF_PY,monitor) + +size: + $(call RUN_IDF_PY,size) + +size-components: + $(call RUN_IDF_PY,size-components) + +size-files: + $(call RUN_IDF_PY,size-files) submodules: $(MAKE) -f ../../py/mkrules.mk GIT_SUBMODULES="$(GIT_SUBMODULES)" submodules |