diff options
author | Nick Brassel <nick@tzarc.org> | 2020-05-19 10:34:00 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-19 10:34:00 +1000 |
commit | 54b04d96651a166088477ccf513fa534b30b2132 (patch) | |
tree | bace05e50e18069f269d6826800dd82dc2d8afbb /common_features.mk | |
parent | 4604c70c4c1a0cb2cebc010dba34b04e902bd982 (diff) | |
download | qmk_firmware-54b04d96651a166088477ccf513fa534b30b2132.tar.gz |
Add SPI 25xx EEPROM support. (#8780)
Diffstat (limited to 'common_features.mk')
-rw-r--r-- | common_features.mk | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/common_features.mk b/common_features.mk index 50b1127dc..bdc6f883e 100644 --- a/common_features.mk +++ b/common_features.mk @@ -70,7 +70,7 @@ ifeq ($(strip $(POINTING_DEVICE_ENABLE)), yes) SRC += $(QUANTUM_DIR)/pointing_device.c endif -VALID_EEPROM_DRIVER_TYPES := vendor custom transient i2c +VALID_EEPROM_DRIVER_TYPES := vendor custom transient i2c spi EEPROM_DRIVER ?= vendor ifeq ($(filter $(EEPROM_DRIVER),$(VALID_EEPROM_DRIVER_TYPES)),) $(error EEPROM_DRIVER="$(EEPROM_DRIVER)" is not a valid EEPROM driver) @@ -85,6 +85,11 @@ else COMMON_VPATH += $(DRIVER_PATH)/eeprom QUANTUM_LIB_SRC += i2c_master.c SRC += eeprom_driver.c eeprom_i2c.c + else ifeq ($(strip $(EEPROM_DRIVER)), spi) + OPT_DEFS += -DEEPROM_DRIVER -DEEPROM_SPI + COMMON_VPATH += $(DRIVER_PATH)/eeprom + QUANTUM_LIB_SRC += spi_master.c + SRC += eeprom_driver.c eeprom_spi.c else ifeq ($(strip $(EEPROM_DRIVER)), transient) OPT_DEFS += -DEEPROM_DRIVER -DEEPROM_TRANSIENT COMMON_VPATH += $(DRIVER_PATH)/eeprom |