-
Notifications
You must be signed in to change notification settings - Fork 70
/
Makefile.mk
51 lines (38 loc) · 971 Bytes
/
Makefile.mk
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# mimas_a7 targets
ifneq ($(PLATFORM),mimas_a7)
$(error "Platform should be mimas_a7 when using this file!?")
endif
# Settings
DEFAULT_TARGET = base
TARGET ?= $(DEFAULT_TARGET)
PROG_PORT ?= /dev/ttyUSB1
COMM_PORT ?= /dev/ttyUSB0
BAUD ?= 115200
# Image
image-flash-$(PLATFORM): image-flash-py
@true
# Gateware
gateware-load-$(PLATFORM):
openocd -f board/numato_$(PLATFORM).cfg -c "init; pld load 0 $(TARGET_BUILD_DIR)/gateware/top.bit; exit"
gateware-flash-$(PLATFORM): gateware-flash-py
@true
# Firmware
firmware-load-$(PLATFORM):
flterm --port=$(COMM_PORT) --kernel=$(FIRMWARE_FILEBASE).bin --speed=$(BAUD)
firmware-flash-$(PLATFORM): firmwage-flash-py
@true
firmware-connect-$(PLATFORM):
flterm --port=$(COMM_PORT) --speed=$(BAUD)
firmware-clear-$(PLATFORM):
@echo "FIXME: Unsupported?."
@false
# Bios
bios-flash-$(PLATFORM):
@echo "Unsupported."
@false
# Extra commands
help-$(PLATFORM):
@true
reset-$(PLATFORM):
@echo "Unsupported."
@false