diff --git a/boards/same54-xpro/Makefile.dep b/boards/same54-xpro/Makefile.dep index 3c35960fac..e8d751a43b 100644 --- a/boards/same54-xpro/Makefile.dep +++ b/boards/same54-xpro/Makefile.dep @@ -10,3 +10,8 @@ ifneq (,$(filter mtd,$(USEMODULE))) FEATURES_REQUIRED += periph_spi_on_qspi USEMODULE += mtd_spi_nor endif + +# enables sam0_eth as default network device +ifneq (,$(filter netdev_default,$(USEMODULE))) + USEMODULE += sam0_eth +endif diff --git a/boards/same54-xpro/Makefile.features b/boards/same54-xpro/Makefile.features index 7bf9dac809..3d0b725045 100644 --- a/boards/same54-xpro/Makefile.features +++ b/boards/same54-xpro/Makefile.features @@ -3,6 +3,7 @@ CPU_MODEL = same54p20a # Put defined MCU peripherals here (in alphabetical order) FEATURES_PROVIDED += periph_dac +FEATURES_PROVIDED += periph_eth FEATURES_PROVIDED += periph_i2c FEATURES_PROVIDED += periph_rtc FEATURES_PROVIDED += periph_rtt diff --git a/boards/same54-xpro/include/periph_conf.h b/boards/same54-xpro/include/periph_conf.h index 301b1da5e8..10aad210c7 100644 --- a/boards/same54-xpro/include/periph_conf.h +++ b/boards/same54-xpro/include/periph_conf.h @@ -361,6 +361,28 @@ static const adc_conf_chan_t adc_channels[] = { #define DAC_VREF DAC_CTRLB_REFSEL_VREFPU /** @} */ +/** + * @name Ethernet peripheral configuration + * @{ + */ +static const sam0_common_gmac_config_t sam_gmac_config[] = { + { + .dev = GMAC, + .refclk = GPIO_PIN(PA, 14), + .txen = GPIO_PIN(PA, 17), + .txd0 = GPIO_PIN(PA, 18), + .txd1 = GPIO_PIN(PA, 19), + .crsdv = GPIO_PIN(PC, 20), + .rxd0 = GPIO_PIN(PA, 13), + .rxd1 = GPIO_PIN(PA, 12), + .rxer = GPIO_PIN(PA, 15), + .mdc = GPIO_PIN(PC, 11), + .mdio = GPIO_PIN(PC, 12), + .rst_pin = GPIO_PIN(PC, 21), + .int_pin = GPIO_PIN(PD, 12), + } +}; + #ifdef __cplusplus } #endif