boards/pca10005/include/periph_conf.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2014 Freie Universit├Ąt Berlin
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser General
5  * Public License v2.1. See the file LICENSE in the top level directory for more
6  * details.
7  */
8 
21 #ifndef PERIPH_CONF_H
22 #define PERIPH_CONF_H
23 
24 #include "periph_cpu.h"
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29 
37 #define CLOCK_HFCLK (16U) /* set to 0: internal RC oscillator
38  16: 16MHz crystal
39  32: 32MHz crystal */
40 #define CLOCK_LFCLK (0) /* set to 0: internal RC oscillator
41  * 1: 32.768 kHz crystal
42  * 2: derived from HFCLK */
43 
49 static const timer_conf_t timer_config[] = {
50  /* dev, channels, width */
51  { NRF_TIMER0, 3, TIMER_BITMODE_BITMODE_24Bit, TIMER0_IRQn }
52 };
53 
54 #define TIMER_0_ISR isr_timer0
55 
56 #define TIMER_NUMOF (sizeof(timer_config) / sizeof(timer_config[0]))
57 
63 #define UART_NUMOF (1U)
64 /* UART pin configuration */
65 #define UART_PIN_RX 11
66 #define UART_PIN_TX 9
67 
73 #define RTT_NUMOF (1U)
74 #define RTT_DEV (1) /* NRF_RTC1 */
75 #define RTT_MAX_VALUE (0x00ffffff)
76 #define RTT_FREQUENCY (1024)
77 
83 static const spi_conf_t spi_config[] = {
84  {
85  .dev = NRF_SPI0,
86  .sclk = 19,
87  .mosi = 17,
88  .miso = 18
89  },
90  {
91  .dev = NRF_SPI1,
92  .sclk = 22,
93  .mosi = 20,
94  .miso = 21
95  }
96 };
97 
98 #define SPI_NUMOF (sizeof(spi_config) / sizeof(spi_config[0]))
99 
107 #define ADC_CONFIG {0, 1, 2, 3}
108 #define ADC_NUMOF (4)
109 
118 #define RADIO_IRQ_PRIO 1
119 
121 #ifdef __cplusplus
122 }
123 #endif
124 
125 #endif /* PERIPH_CONF_H */
SPI module configuration options.
Timer configuration.
cc2538_ssi_t * dev
SSI device.