summaryrefslogtreecommitdiff
path: root/quantum/visualizer/visualizer.mk
diff options
context:
space:
mode:
authorAdam YH Lee <adam.yh.lee@gmail.com>2017-04-12 20:58:36 -0700
committerAdam YH Lee <adam.yh.lee@gmail.com>2017-04-12 20:58:36 -0700
commit73625a603afd14ee506d1562ef5f6a199eac62ce (patch)
tree669ed65bd1962936e13aec3f62ee375fbbe09df7 /quantum/visualizer/visualizer.mk
parent91b11bb4dd9a0c94fbc0feb6915acc4717357205 (diff)
parentd3301c0f8b0005738ab9aa2030d83739ffb5c4b6 (diff)
Merge branch 'master' into miuni32-OA
Diffstat (limited to 'quantum/visualizer/visualizer.mk')
-rw-r--r--quantum/visualizer/visualizer.mk21
1 files changed, 15 insertions, 6 deletions
diff --git a/quantum/visualizer/visualizer.mk b/quantum/visualizer/visualizer.mk
index 2f4a41d66f..5f710124bc 100644
--- a/quantum/visualizer/visualizer.mk
+++ b/quantum/visualizer/visualizer.mk
@@ -20,7 +20,8 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
-SRC += $(VISUALIZER_DIR)/visualizer.c
+SRC += $(VISUALIZER_DIR)/visualizer.c \
+ $(VISUALIZER_DIR)/visualizer_keyframes.c
EXTRAINCDIRS += $(GFXINC) $(VISUALIZER_DIR)
GFXLIB = $(LIB_PATH)/ugfx
VPATH += $(VISUALIZER_PATH)
@@ -32,25 +33,33 @@ OPT_DEFS += -DLCD_ENABLE
ULIBS += -lm
endif
-ifdef LCD_BACKLIGHT_ENABLE
+ifeq ($(strip $(LCD_ENABLE)), yes)
SRC += $(VISUALIZER_DIR)/lcd_backlight.c
+SRC += $(VISUALIZER_DIR)/lcd_keyframes.c
+SRC += $(VISUALIZER_DIR)/lcd_backlight_keyframes.c
+# Note, that the linker will strip out any resources that are not actually in use
+SRC += $(VISUALIZER_DIR)/resources/lcd_logo.c
OPT_DEFS += -DLCD_BACKLIGHT_ENABLE
endif
-ifdef LED_ENABLE
-SRC += $(VISUALIZER_DIR)/led_test.c
+ifeq ($(strip $(LED_ENABLE)), yes)
+SRC += $(VISUALIZER_DIR)/led_keyframes.c
OPT_DEFS += -DLED_ENABLE
endif
include $(GFXLIB)/gfx.mk
-SRC += $(patsubst $(TOP_DIR)/%,%,$(GFXSRC))
-OPT_DEFS += $(patsubst %,-D%,$(patsubst -D%,%,$(GFXDEFS)))
+GFXSRC := $(patsubst $(TOP_DIR)/%,%,$(GFXSRC))
+GFXDEFS := $(patsubst %,-D%,$(patsubst -D%,%,$(GFXDEFS)))
ifneq ("$(wildcard $(KEYMAP_PATH)/visualizer.c)","")
SRC += keyboards/$(KEYBOARD)/keymaps/$(KEYMAP)/visualizer.c
else
ifeq ("$(wildcard $(SUBPROJECT_PATH)/keymaps/$(KEYMAP)/visualizer.c)","")
+ ifeq ("$(wildcard $(SUBPROJECT_PATH)/visualizer.c)","")
$(error "$(KEYMAP_PATH)/visualizer.c" does not exist)
+ else
+ SRC += keyboards/$(KEYBOARD)/$(SUBPROJECT)/visualizer.c
+ endif
else
SRC += keyboards/$(KEYBOARD)/$(SUBPROJECT)/keymaps/$(KEYMAP)/visualizer.c
endif