samd/pin_af: Simplify the pin-af-table handling.
Changes are: - The pin-af-table-SAMDxx.csv file are moved to the mcu directories with the name as pin-af-table.csv. - The handling in Makefile and pin_af.c is simplified.
This commit is contained in:
parent
20e7313453
commit
85fb8b8b02
@ -48,7 +48,7 @@ INC += -I$(TOP)/lib/asf4/$(MCU_SERIES_LOWER)/include/pio
|
||||
INC += -I$(TOP)/lib/tinyusb/src
|
||||
|
||||
MAKE_PIN_AF = boards/make-pin-af.py
|
||||
PIN_AF_TABLE_CSV = boards/pin-af-table-$(MCU_SERIES).csv
|
||||
PIN_AF_TABLE_CSV = mcu/$(MCU_SERIES_LOWER)/pin-af-table.csv
|
||||
GEN_PIN_AF = pin_af_table.c
|
||||
|
||||
MAKE_PINS = boards/make-pins.py
|
||||
@ -62,7 +62,6 @@ CFLAGS = $(INC) -Wall -Werror -std=c99 -nostdlib -mthumb $(CFLAGS_MCU_$(MCU_SERI
|
||||
CFLAGS += -DMCU_$(MCU_SERIES) -D__$(CMSIS_MCU)__
|
||||
CFLAGS += $(CFLAGS_MOD) $(CFLAGS_EXTRA)
|
||||
CFLAGS += -DMPCONFIG_MCU_H='<boards/mpconfig_$(MCU_SERIES_LOWER).h>'
|
||||
CFLAGS += -DPIN_AF_TABLE_C='<$(BUILD)/$(GEN_PIN_AF)>'
|
||||
|
||||
LDFLAGS = -nostdlib $(addprefix -T,$(LD_FILES)) -Map=$@.map --cref
|
||||
LDFLAGS += $(LDFLAGS_MOD)
|
||||
|
@ -59,7 +59,7 @@ pa30,10,,,12,10,
|
||||
pa31,11,,,13,11,
|
||||
pb30,14,,,50,00,12
|
||||
pb31,15,,,51,01,13
|
||||
pb00,0,,,52,70,
|
||||
pb01,1,,,53,71,
|
||||
pb02,2,,,50,60,
|
||||
pb03,3,,,51,61,
|
||||
pb00,0,8,,52,70,
|
||||
pb01,1,9,,53,71,
|
||||
pb02,2,10,,50,60,
|
||||
pb03,3,11,,51,61,
|
|
@ -38,7 +38,7 @@
|
||||
|
||||
extern const uint8_t tcc_channel_count[];
|
||||
|
||||
#include PIN_AF_TABLE_C
|
||||
#include "pin_af_table.c"
|
||||
|
||||
// Just look for an table entry for a given pin and raise an error
|
||||
// in case of no match (which should not happen).
|
||||
|
Loading…
x
Reference in New Issue
Block a user