avr: Split gpio.c into gpio.c, adc.c, hard_pwm.c, and spi.c

Split up gpio.c into multiple files in an effort to make the code a
little more understandable.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor
2018-11-20 11:39:42 -05:00
parent 2cc0313b72
commit bf92ffb5bf
6 changed files with 418 additions and 391 deletions

View File

@@ -8,7 +8,11 @@ dirs-y += src/avr src/generic
CFLAGS += -mmcu=$(CONFIG_MCU)
# Add avr source files
src-y += avr/main.c avr/timer.c avr/gpio.c
src-y += avr/main.c avr/timer.c
src-$(CONFIG_HAVE_GPIO) += avr/gpio.c
src-$(CONFIG_HAVE_GPIO_ADC) += avr/adc.c
src-$(CONFIG_HAVE_GPIO_SPI) += avr/spi.c
src-$(CONFIG_HAVE_GPIO_HARD_PWM) += avr/hard_pwm.c
src-$(CONFIG_AVR_WATCHDOG) += avr/watchdog.c
src-$(CONFIG_AVR_USBSERIAL) += avr/usbserial.c generic/usb_cdc.c
src-$(CONFIG_AVR_SERIAL) += avr/serial.c generic/serial_irq.c