-
Notifications
You must be signed in to change notification settings - Fork 24
Expand file tree
/
Copy pathMakefile
More file actions
27 lines (19 loc) · 695 Bytes
/
Makefile
File metadata and controls
27 lines (19 loc) · 695 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
BUILD_DIR = ../build
BOARD = esp8266:esp8266:d1_mini
# Serial uploads
UPLOAD_PORT = /dev/ttyUSB0
TARGET_FLAGS += -b $(BOARD)
ESPOTA = $(HOME)/.arduino15/packages/esp8266/hardware/esp8266/3.0.2/tools/espota.py
JARVISDESK = jarvis.local
# Note: can specify another target with
# make upload JARVISDESK=192.168.1.179
COMPILE_FLAGS = --build-cache-path $(BUILD_DIR) --output-dir $(BUILD_DIR)
COMPILE_FLAGS += $(TARGET_FLAGS) --warnings default
.PHONY: all build upload
all: upload
build:
arduino-cli compile $(COMPILE_FLAGS) .
upload: build
$(ESPOTA) -i $(JARVISDESK) -p 8266 -f $(BUILD_DIR)/Jarvis.ino.bin
upload-serial: build
arduino-cli upload --port $(UPLOAD_PORT) $(TARGET_FLAGS) .