blob: b14c3e8eb3066fc1abccd42ced05604efe0d5e36 (
plain)
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
52
53
54
55
56
57
58
|
AVR_TOOLS_DIR = /usr
ARDUINO_DIR = ./lib
ARDMK_DIR = /usr/share/arduino
ARDMK_VENDOR = arduino
ARCHITECTURE = avr
BOARD_TAG = model01
ALTERNATE_CORE = keyboardio
ARDUINO_SKETCHBOOK = ./lib
ARDUINO_VERSION = $(shell git --no-pager -C $(ARDUINO_DIR)/hardware/$(ARDMK_VENDOR)/$(ARCHITECTURE) tag --points-at HEAD | tr "." "0")
SOURCEDIR = ./src
OBJDIR = ./build
LOCAL_CPP_SRCS = $(wildcard $(SOURCEDIR)/*.cpp)
LOCAL_INO_SRCS = $(wildcard $(SOURCEDIR)/*.ino)
USER_LIB_PATH = $(ALTERNATE_CORE_PATH)/libraries
KALEIDOSCOPE_PLUGINS = Kaleidoscope-Colormap \
Kaleidoscope-EEPROM-Settings \
Kaleidoscope-Escape-OneShot \
Kaleidoscope-FocusSerial \
Kaleidoscope-Hardware-Model01 \
Kaleidoscope-Hardware-Keyboardio-Model01 \
Kaleidoscope-IdleLEDs \
Kaleidoscope-LED-ActiveModColor \
Kaleidoscope-LED-Palette-Theme \
Kaleidoscope-Macros \
Kaleidoscope-MagicCombo \
Kaleidoscope-MouseKeys \
Kaleidoscope-OneShot \
Kaleidoscope-OneShotMetaKeys \
Kaleidoscope-Ranges \
Kaleidoscope-TapDance
ARDUINO_LIBS = EEPROM Kaleidoscope KeyboardioHID \
$(addprefix Kaleidoscope/plugins/,$(KALEIDOSCOPE_PLUGINS))
# extra definitions from lib/hardware/keyboardio/avr/boards.txt
CXXFLAGS = -DARDUINO_AVR_MODEL01 \
-DUSB_MANUFACTURER="\"keyboardio\"" -DUSB_PRODUCT="\"Model 01\"" \
-DKALEIDOSCOPE_HARDWARE_H="\"Kaleidoscope-Hardware-Model01.h\""
# cf. lib/hardware/keyboardio/avr/platform.txt
CXXFLAGS_STD = -std=c++14 -fno-threadsafe-statics
ifeq ($(ENABLE_SERIAL),yes)
CXXFLAGS += -DENABLE_SERIAL
endif
AVRDUDE_OPTS = -q
AVRDUDE_CONF = /etc/avrdude.conf
#MONITOR_PORT = $(firstword $(wildcard /dev/serial/by-id/usb-keyboardio_Model_01_*))
include $(ARDMK_DIR)/Arduino.mk
apply-colormap: ./src/palette ./src/colormap.map
DEVICE=$(DEVICE_PATH) ./tools/apply-colormap $^
.PHONY: apply-colormap
|