/* * Copyright (C) 2018 Inria * * This file is subject to the terms and conditions of the GNU Lesser * General Public License v2.1. See the file LICENSE in the top level * directory for more details. */ /** * @ingroup boards_common_nrf51 * @{ * * @file * @brief Common peripheral MCU configuration for some nrf51 based boards * * @author Alexandre Abadie */ #ifndef PERIPH_CONF_COMMON_H #define PERIPH_CONF_COMMON_H #include "periph_cpu.h" #ifdef __cplusplus extern "C" { #endif /** * @name Timer configuration * @{ */ static const timer_conf_t timer_config[] = { /* dev, channels, width */ { NRF_TIMER0, 3, TIMER_BITMODE_BITMODE_24Bit, TIMER0_IRQn } }; #define TIMER_0_ISR isr_timer0 #define TIMER_NUMOF (sizeof(timer_config) / sizeof(timer_config[0])) /** @} */ /** * @name Real time counter configuration * @{ */ #define RTT_NUMOF (1U) #define RTT_DEV (1) /* NRF_RTC1 */ #define RTT_MAX_VALUE (0x00ffffff) #define RTT_FREQUENCY (1024) /** @} */ #ifdef __cplusplus } /* end extern "C" */ #endif #endif /* PERIPH_CONF_COMMON_H */