cc26x0/include/periph_cpu.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2016 Leon George
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
19 #ifndef PERIPH_CPU_H
20 #define PERIPH_CPU_H
21 
22 #include "cpu.h"
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27 
31 #define CPUID_ADDR (&FCFG->MAC_BLE_0)
32 
35 #define CPUID_LEN (16U)
36 
37 #ifndef DOXYGEN
38 
41 #define HAVE_GPIO_MODE_T
42 typedef enum {
43  GPIO_IN = (IOCFG_INPUT_ENABLE | IOCFG_PULLCTL_OFF),
44  GPIO_IN_PD = (IOCFG_INPUT_ENABLE | IOCFG_PULLCTL_DOWN),
45  GPIO_IN_PU = (IOCFG_INPUT_ENABLE | IOCFG_PULLCTL_UP),
49 } gpio_mode_t;
50 
54 #define HAVE_GPIO_FLANK_T
55 typedef enum {
59 } gpio_flank_t;
60 #endif /* ndef DOXYGEN */
61 
68 typedef struct {
69  uint8_t cfg;
70  uint8_t chn;
71 } timer_conf_t;
72 
73 #ifdef __cplusplus
74 }
75 #endif
76 
77 #endif /* PERIPH_CPU_H */
78 
#define IOCFG_IOMODE_OPEN_DRAIN
open drain
Definition: cc26x0_ioc.h:120
emit interrupt on rising flank
Definition: gpio.h:114
uint8_t cfg
timer config [16,32 Bit]
#define IOCFG_PULLCTL_UP
pull up
Definition: cc26x0_ioc.h:110
#define IOCFG_PULLCTL_DOWN
pull down
Definition: cc26x0_ioc.h:111
emit interrupt on both flanks
Definition: gpio.h:115
gpio_flank_t
Definition of possible active flanks for external interrupt mode.
Definition: gpio.h:112
emit interrupt on falling flank
Definition: gpio.h:113
#define IOCFG_PULLCTL_OFF
no IO pull
Definition: cc26x0_ioc.h:109
#define IOCFG_EDGEDET_BOTH
edge detection on both edges
Definition: cc26x0_ioc.h:115
input, no pull
#define IOCFG_EDGEDET_RISING
edge detection on rising edge
Definition: cc26x0_ioc.h:114
not supported
input, pull-down
Timer configuration data.
#define IOCFG_EDGEDET_FALLING
edge detection on falling edge
Definition: cc26x0_ioc.h:113
uint8_t chn
number of channels [1,2]