1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/cpu/msp430/periph/Makefile
Marian Buschsieweke aef5b65244
cpu/msp430/f2xx: clean up periph_uart,periph_spi
This cleans up the USCI based UART and SPI implementations and allows
multiple instances of either interface to be configured by the
boards. In addition, it allows sharing the USCI peripherals to provide
multiple serial interfaces with the same hardware (round-robin).
2024-03-27 18:54:07 +01:00

26 lines
683 B
Makefile

MODULE = periph
# All supported MSP430 families use special serial IP block that implements
# various serial bus interfaces using the same hardware block. For the
# MSP430 x1xx family, the block is called USART. For the MSP430 F2xx/G2xx
# family it is the (incompatible) USCI.
ifeq (msp430_x1xx,$(CPU_FAM))
SERIAL_IP_BLOCK := usart
endif
ifeq (msp430_f2xx_g2xx,$(CPU_FAM))
SERIAL_IP_BLOCK := usci
endif
SRC += $(SERIAL_IP_BLOCK).c
# select family specific peripheral drivers.
ifneq (,$(filter periph_uart,$(USEMODULE)))
SRC += uart_$(SERIAL_IP_BLOCK).c
endif
ifneq (,$(filter periph_spi,$(USEMODULE)))
SRC += spi_$(SERIAL_IP_BLOCK).c
endif
include $(RIOTMAKE)/periph.mk