diff --git a/boards/stm32f030f4-demo/include/periph_conf.h b/boards/stm32f030f4-demo/include/periph_conf.h index 7944efc7d2..5b7fe9e528 100644 --- a/boards/stm32f030f4-demo/include/periph_conf.h +++ b/boards/stm32f030f4-demo/include/periph_conf.h @@ -152,16 +152,16 @@ static const spi_conf_t spi_config[] = { * @name ADC configuration * @{ */ -#define ADC_CONFIG { \ - { GPIO_PIN(PORT_A, 0), 0 }, \ - { GPIO_PIN(PORT_A, 1), 1 }, \ - { GPIO_PIN(PORT_A, 2), 2 }, \ - { GPIO_PIN(PORT_A, 3), 3 }, \ - { GPIO_PIN(PORT_A, 4), 4 },\ - { GPIO_PIN(PORT_A, 5), 5 } \ -} +static const adc_conf_t adc_config[] = { + { GPIO_PIN(PORT_A, 0), 0 }, + { GPIO_PIN(PORT_A, 1), 1 }, + { GPIO_PIN(PORT_A, 2), 2 }, + { GPIO_PIN(PORT_A, 3), 3 }, + { GPIO_PIN(PORT_A, 4), 4 }, + { GPIO_PIN(PORT_A, 5), 5 } +}; -#define ADC_NUMOF (6) +#define ADC_NUMOF ARRAY_SIZE(adc_config) /** @} */ #ifdef __cplusplus