cfg_timer_default.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2014-2016 Freie Universität Berlin
3  * 2015 Zolertia SL
4  *
5  * This file is subject to the terms and conditions of the GNU Lesser
6  * General Public License v2.1. See the file LICENSE in the top level
7  * directory for more details.
8  */
9 
10 #pragma once
11 
24 #include "periph_cpu.h"
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29 
38 static const timer_conf_t timer_config[] = {
39  {
40  .chn = 2,
41  .cfg = GPTMCFG_16_BIT_TIMER, /* required for XTIMER */
42  },
43  {
44  .chn = 2,
45  .cfg = GPTMCFG_16_BIT_TIMER,
46  },
47  {
48  .chn = 1,
49  .cfg = GPTMCFG_32_BIT_TIMER,
50  },
51  {
52  .chn = 1,
53  .cfg = GPTMCFG_32_BIT_TIMER,
54  },
55 };
56 
57 #define TIMER_NUMOF ARRAY_SIZE(timer_config)
58 
59 #define TIMER_IRQ_PRIO 1
62 #ifdef __cplusplus
63 } /* end extern "C" */
64 #endif
65 
@ GPTMCFG_32_BIT_TIMER
32-bit timer configuration
@ GPTMCFG_16_BIT_TIMER
16-bit timer configuration
static const timer_conf_t timer_config[]
Configuration of the exposed timers.
Timer device configuration.
Definition: periph_cpu.h:263
uint_fast8_t chn
number of channels
Definition: periph_cpu.h:310