Kconfig: Replace WANT_GPIO_BITBANGING with individual options
Support setting individual options instead of one global option ( WANT_BUTTONS, WANT_TMCUART, WANT_NEOPIXEL, WANT_PULSE_COUNTER, WANT_HX71X). Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
31
src/Kconfig
31
src/Kconfig
@@ -88,7 +88,19 @@ config USB_SERIAL_NUMBER
|
||||
endmenu
|
||||
|
||||
# Optional features that can be disabled (for devices with small flash sizes)
|
||||
config WANT_GPIO_BITBANGING
|
||||
config WANT_BUTTONS
|
||||
bool
|
||||
depends on HAVE_GPIO
|
||||
default y
|
||||
config WANT_TMCUART
|
||||
bool
|
||||
depends on HAVE_GPIO
|
||||
default y
|
||||
config WANT_NEOPIXEL
|
||||
bool
|
||||
depends on HAVE_GPIO
|
||||
default y
|
||||
config WANT_PULSE_COUNTER
|
||||
bool
|
||||
depends on HAVE_GPIO
|
||||
default y
|
||||
@@ -118,7 +130,7 @@ config WANT_ICM20948
|
||||
default y
|
||||
config WANT_HX71X
|
||||
bool
|
||||
depends on WANT_GPIO_BITBANGING
|
||||
depends on HAVE_GPIO
|
||||
default y
|
||||
config WANT_ADS1220
|
||||
bool
|
||||
@@ -147,8 +159,17 @@ config NEED_SENSOR_BULK
|
||||
default y
|
||||
menu "Optional features (to reduce code size)"
|
||||
depends on HAVE_LIMITED_CODE_SIZE
|
||||
config WANT_GPIO_BITBANGING
|
||||
bool "Support GPIO \"bit-banging\" devices"
|
||||
config WANT_BUTTONS
|
||||
bool "Support GPIO based button reading"
|
||||
depends on HAVE_GPIO
|
||||
config WANT_TMCUART
|
||||
bool "Support Trinamic stepper motor driver UART communication"
|
||||
depends on HAVE_GPIO
|
||||
config WANT_NEOPIXEL
|
||||
bool "Support 'neopixel' type LED control"
|
||||
depends on HAVE_GPIO
|
||||
config WANT_PULSE_COUNTER
|
||||
bool "Support measuring fan tachometer GPIO pins"
|
||||
depends on HAVE_GPIO
|
||||
config WANT_DISPLAYS
|
||||
bool "Support LCD devices"
|
||||
@@ -170,7 +191,7 @@ config WANT_ICM20948
|
||||
depends on HAVE_GPIO_I2C
|
||||
config WANT_HX71X
|
||||
bool "Support HX711 and HX717 ADC chips"
|
||||
depends on WANT_GPIO_BITBANGING
|
||||
depends on HAVE_GPIO
|
||||
config WANT_ADS1220
|
||||
bool "Support ADS 1220 ADC chip"
|
||||
depends on HAVE_GPIO_SPI
|
||||
|
||||
@@ -9,8 +9,10 @@ src-$(CONFIG_HAVE_GPIO_SDIO) += sdiocmds.c
|
||||
src-$(CONFIG_HAVE_GPIO_I2C) += i2ccmds.c
|
||||
src-$(CONFIG_HAVE_GPIO_HARD_PWM) += pwmcmds.c
|
||||
|
||||
src-$(CONFIG_WANT_GPIO_BITBANGING) += buttons.c tmcuart.c neopixel.c \
|
||||
pulse_counter.c
|
||||
src-$(CONFIG_WANT_BUTTONS) += buttons.c
|
||||
src-$(CONFIG_WANT_TMCUART) += tmcuart.c
|
||||
src-$(CONFIG_WANT_NEOPIXEL) += neopixel.c
|
||||
src-$(CONFIG_WANT_PULSE_COUNTER) += pulse_counter.c
|
||||
src-$(CONFIG_WANT_DISPLAYS) += lcd_st7920.c lcd_hd44780.c
|
||||
src-$(CONFIG_WANT_SOFTWARE_SPI) += spi_software.c
|
||||
src-$(CONFIG_WANT_SOFTWARE_I2C) += i2c_software.c
|
||||
|
||||
Reference in New Issue
Block a user