board.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2013, 2014 INRIA
3  * 2015 Freie Universität Berlin
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 
26 #ifndef BOARD_H
27 #define BOARD_H
28 
29 #include "cpu.h"
30 
31 #ifdef __cplusplus
32 extern "C" {
33 #endif
34 
38 #ifndef __MSP430F1611__
39 #define __MSP430F1611__
40 #endif
41 
46 #ifndef STDIO_UART_BAUDRATE
47 #define STDIO_UART_BAUDRATE (9600)
48 #endif
55 #define CONFIG_ZTIMER_USEC_WIDTH 16
59 #define CONFIG_ZTIMER_USEC_BASE_FREQ MHZ(1)
68 #define CONFIG_ZTIMER_PERIPH_TIMER_FORCE_CONVERSION 1
75 #define XTIMER_WIDTH (16)
76 #define XTIMER_BACKOFF (40)
83 #define LED0_PIN GPIO_PIN(4, 0)
84 #define LED1_PIN GPIO_PIN(4, 1)
85 #define LED2_PIN GPIO_PIN(4, 2)
86 
87 #define LED_OUT_REG P5OUT
88 #define LED0_MASK (0x10)
89 #define LED1_MASK (0x20)
90 #define LED2_MASK (0x40)
91 
92 #define LED0_ON (LED_OUT_REG &=~LED0_MASK)
93 #define LED0_OFF (LED_OUT_REG |= LED0_MASK)
94 #define LED0_TOGGLE (LED_OUT_REG ^= LED0_MASK)
95 
96 #define LED1_ON (LED_OUT_REG &=~LED1_MASK)
97 #define LED1_OFF (LED_OUT_REG |= LED1_MASK)
98 #define LED1_TOGGLE (LED_OUT_REG ^= LED1_MASK)
99 
100 #define LED2_ON (LED_OUT_REG &=~LED2_MASK)
101 #define LED2_OFF (LED_OUT_REG |= LED2_MASK)
102 #define LED2_TOGGLE (LED_OUT_REG ^= LED2_MASK)
109 #define CC2420_PARAM_SPI_CLK (SPI_CLK_1MHZ)
110 #define CC2420_PARAM_CS GPIO_PIN(P4, 2)
111 #define CC2420_PARAM_FIFO GPIO_PIN(P1, 3)
112 #define CC2420_PARAM_FIFOP GPIO_PIN(P1, 0)
113 #define CC2420_PARAM_CCA GPIO_PIN(P1, 4)
114 #define CC2420_PARAM_SFD GPIO_PIN(P4, 1)
115 #define CC2420_PARAM_VREFEN GPIO_PIN(P4, 5)
116 #define CC2420_PARAM_RESET GPIO_PIN(P4, 6)
119 #ifdef __cplusplus
120 }
121 #endif
122 
124 #endif /* BOARD_H */