2018-10-24 17:55:23 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2018 Inria
|
2019-06-04 12:59:59 +02:00
|
|
|
* 2019 Freie Universität Berlin
|
2018-10-24 17:55:23 +02:00
|
|
|
*
|
|
|
|
* 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
|
2019-06-04 12:59:59 +02:00
|
|
|
* @brief Shared default RTT configuration for nRF51-based boards
|
2018-10-24 17:55:23 +02:00
|
|
|
*
|
|
|
|
* @author Alexandre Abadie <alexandre.abadie@inria.fr>
|
2019-06-04 12:59:59 +02:00
|
|
|
* @author Hauke Petersen <hauke.petersen@fu-berlin.de>
|
2018-10-24 17:55:23 +02:00
|
|
|
*/
|
|
|
|
|
2019-06-04 12:59:59 +02:00
|
|
|
#ifndef CFG_RTT_DEFAULT_H
|
|
|
|
#define CFG_RTT_DEFAULT_H
|
2018-10-24 17:55:23 +02:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
2019-06-04 12:59:59 +02:00
|
|
|
extern "C" {
|
2018-10-24 17:55:23 +02:00
|
|
|
#endif
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @name Real time counter configuration
|
|
|
|
* @{
|
|
|
|
*/
|
2020-05-05 14:50:33 +02:00
|
|
|
#ifndef RTT_DEV
|
|
|
|
#define RTT_DEV (1) /* NRF_RTC1 */
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#define RTT_MAX_VALUE (0x00ffffff) /* 24bit */
|
|
|
|
#define RTT_MAX_FREQUENCY (32768U) /* in Hz */
|
|
|
|
#define RTT_MIN_FREQUENCY (8U) /* in Hz */
|
|
|
|
#define RTT_CLOCK_FREQUENCY (32768U) /* in Hz, LFCLK*/
|
|
|
|
|
|
|
|
#ifndef RTT_FREQUENCY
|
|
|
|
#define RTT_FREQUENCY (1024U) /* in Hz */
|
|
|
|
#endif
|
2018-10-24 17:55:23 +02:00
|
|
|
/** @} */
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
} /* end extern "C" */
|
|
|
|
#endif
|
|
|
|
|
2019-06-04 12:59:59 +02:00
|
|
|
#endif /* CFG_RTT_DEFAULT_H */
|
2022-08-11 16:24:37 +02:00
|
|
|
/** @} */
|