2022-05-11 20:25:50 +00:00
|
|
|
PORT ?= /dev/ttyACM0
|
|
|
|
BUILDDIR ?= build
|
|
|
|
IDF_PATH ?= $(shell pwd)/esp-idf
|
|
|
|
IDF_EXPORT_QUIET ?= 0
|
|
|
|
SHELL := /usr/bin/env bash
|
|
|
|
|
2022-06-16 18:59:40 +00:00
|
|
|
.PHONY: prepare clean build flash erase monitor menuconfig
|
2022-05-11 20:25:50 +00:00
|
|
|
|
2022-07-11 07:43:20 +00:00
|
|
|
all: install
|
2022-05-12 20:42:35 +00:00
|
|
|
|
2022-05-11 20:25:50 +00:00
|
|
|
prepare:
|
|
|
|
git submodule update --init --recursive
|
|
|
|
cd esp-idf; bash install.sh
|
|
|
|
|
|
|
|
clean:
|
2022-05-11 22:31:00 +00:00
|
|
|
rm -rf "$(BUILDDIR)"
|
2022-05-11 20:25:50 +00:00
|
|
|
|
|
|
|
build:
|
2022-05-11 22:31:00 +00:00
|
|
|
source "$(IDF_PATH)/export.sh" && idf.py build
|
2022-05-11 20:25:50 +00:00
|
|
|
|
2022-07-11 07:43:20 +00:00
|
|
|
install: build
|
2022-07-02 18:10:33 +00:00
|
|
|
python3 tools/webusb_push.py "Template App" build/main.bin --run
|
2022-05-11 20:25:50 +00:00
|
|
|
|
|
|
|
monitor:
|
2022-05-11 22:31:00 +00:00
|
|
|
source "$(IDF_PATH)/export.sh" && idf.py monitor -p $(PORT)
|
2022-05-11 20:25:50 +00:00
|
|
|
|
|
|
|
menuconfig:
|
2022-05-11 22:31:00 +00:00
|
|
|
source "$(IDF_PATH)/export.sh" && idf.py menuconfig
|