diff options
author | Damien George <damien.p.george@gmail.com> | 2014-11-28 10:22:01 +0000 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-11-28 10:22:01 +0000 |
commit | 5f100657188c3f6e53db9d90f7ceebc4753bf44b (patch) | |
tree | 185c73b80da0312cec0032f3c9cca50fa38d66b6 | |
parent | 1bbc389d67932e2afa0699848422b944d0ca759e (diff) |
esp8266: Provide sensible default ESP_SDK; deploy 2 the images together.
-rw-r--r-- | esp8266/Makefile | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/esp8266/Makefile b/esp8266/Makefile index 28f5ce13d..1e5555a3a 100644 --- a/esp8266/Makefile +++ b/esp8266/Makefile @@ -6,12 +6,9 @@ QSTR_DEFS = qstrdefsport.h #$(BUILD)/pins_qstr.h # include py core make definitions include ../py/py.mk -ifeq ($(ESP_SDK),) -$(error ESP_SDK must be set) -endif - PORT = /dev/ttyACM0 CROSS_COMPILE = xtensa-lx106-elf- +ESP_SDK = $(shell $(CC) -print-sysroot)/.. INC = -I. INC += -I$(PY_SRC) @@ -73,9 +70,8 @@ all: $(BUILD)/firmware-combined.bin deploy: $(BUILD)/firmware-combined.bin $(ECHO) "Writing $< to the board" - $(Q)esptool.py --port $(PORT) write_flash 0 $< - #$(Q)esptool.py --port $(PORT) write_flash 0 $(BUILD)/firmware.elf-0x00000.bin - #$(Q)esptool.py --port $(PORT) write_flash 0x10000 $(BUILD)/firmware.elf-0x10000.bin + #$(Q)esptool.py --port $(PORT) write_flash 0 $< + $(Q)esptool.py --port $(PORT) write_flash 0 $(BUILD)/firmware.elf-0x00000.bin 0x10000 $(BUILD)/firmware.elf-0x10000.bin $(BUILD)/firmware-combined.bin: $(BUILD)/firmware.elf $(ECHO) "Create $@" |