Contiki-NG
Main Page
Modules
Data Structures
Files
File List
Globals
arch
platform
srf06-cc26xx
sensortag
cc2650
board.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2014, Texas Instruments Incorporated - http://www.ti.com/
3
* All rights reserved.
4
*
5
* Redistribution and use in source and binary forms, with or without
6
* modification, are permitted provided that the following conditions
7
* are met:
8
* 1. Redistributions of source code must retain the above copyright
9
* notice, this list of conditions and the following disclaimer.
10
* 2. Redistributions in binary form must reproduce the above copyright
11
* notice, this list of conditions and the following disclaimer in the
12
* documentation and/or other materials provided with the distribution.
13
* 3. Neither the name of the copyright holder nor the names of its
14
* contributors may be used to endorse or promote products derived
15
* from this software without specific prior written permission.
16
*
17
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
18
* ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
19
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
20
* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
21
* COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
22
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
23
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
24
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
26
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
28
* OF THE POSSIBILITY OF SUCH DAMAGE.
29
*/
30
/*---------------------------------------------------------------------------*/
31
/** \addtogroup cc26xx-srf-tag
32
* @{
33
*
34
* \defgroup sensortag-cc26xx-specific CC2650 Sensortag Peripherals
35
*
36
* Defines related to the CC2650 Sensortag
37
*
38
* This file provides connectivity information on LEDs, Buttons, UART and
39
* other peripherals
40
*
41
* This file can be used as the basis to configure other boards using the
42
* CC13xx/CC26xx code as their basis.
43
*
44
* This file is not meant to be modified by the user.
45
* @{
46
*
47
* \file
48
* Header file with definitions related to the I/O connections on the TI
49
* Sensortag
50
*
51
* \note Do not include this file directly. It gets included by contiki-conf
52
* after all relevant directives have been set.
53
*/
54
/*---------------------------------------------------------------------------*/
55
#ifndef BOARD_H_
56
#define BOARD_H_
57
/*---------------------------------------------------------------------------*/
58
#include "
ioc.h
"
59
/*---------------------------------------------------------------------------*/
60
/**
61
* \name LED HAL configuration
62
*
63
* Those values are not meant to be modified by the user
64
* @{
65
*/
66
#define LEDS_CONF_COUNT 2
67
#define LEDS_CONF_RED 1
68
#define LEDS_CONF_GREEN 2
69
/** @} */
70
/*---------------------------------------------------------------------------*/
71
/**
72
* \name LED IOID mappings
73
*
74
* Those values are not meant to be modified by the user
75
* @{
76
*/
77
#define BOARD_IOID_LED_1 IOID_10
78
#define BOARD_IOID_LED_2 IOID_15
79
/** @} */
80
/*---------------------------------------------------------------------------*/
81
/**
82
* \name UART IOID mapping
83
*
84
* Those values are not meant to be modified by the user
85
* @{
86
*/
87
#define BOARD_IOID_DP4_UARTRX IOID_28
88
#define BOARD_IOID_DP5_UARTTX IOID_29
89
90
#if BOARD_CONF_DEBUGGER_DEVPACK
91
#define BOARD_IOID_UART_RX BOARD_IOID_DP4_UARTRX
92
#define BOARD_IOID_UART_TX BOARD_IOID_DP5_UARTTX
93
#else
94
#define BOARD_IOID_UART_RX IOID_17
95
#define BOARD_IOID_UART_TX IOID_16
96
#endif
97
98
#define BOARD_IOID_UART_CTS IOID_UNUSED
99
#define BOARD_IOID_UART_RTS IOID_UNUSED
100
#define BOARD_UART_RX (1 << BOARD_IOID_UART_RX)
101
#define BOARD_UART_TX (1 << BOARD_IOID_UART_TX)
102
#define BOARD_UART_CTS (1 << BOARD_IOID_UART_CTS)
103
#define BOARD_UART_RTS (1 << BOARD_IOID_UART_RTS)
104
/** @} */
105
/*---------------------------------------------------------------------------*/
106
/**
107
* \name Button IOID mapping
108
*
109
* Those values are not meant to be modified by the user
110
* @{
111
*/
112
#define BOARD_IOID_KEY_LEFT IOID_0
113
#define BOARD_IOID_KEY_RIGHT IOID_4
114
#define BOARD_KEY_LEFT (1 << BOARD_IOID_KEY_LEFT)
115
#define BOARD_KEY_RIGHT (1 << BOARD_IOID_KEY_RIGHT)
116
/** @} */
117
/*---------------------------------------------------------------------------*/
118
/**
119
* \name Buzzer configuration
120
* @{
121
*/
122
#define BOARD_IOID_BUZZER IOID_21
/**< Buzzer Pin */
123
/** @} */
124
/*---------------------------------------------------------------------------*/
125
/**
126
* \name Reed Relay IOID mapping
127
*
128
* Those values are not meant to be modified by the user
129
* @{
130
*/
131
#define BOARD_IOID_REED_RELAY IOID_3
132
/** @} */
133
/*---------------------------------------------------------------------------*/
134
/**
135
* \name External flash IOID mapping
136
*
137
* Those values are not meant to be modified by the user
138
* @{
139
*/
140
#define EXT_FLASH_SPI_CONTROLLER SPI_CONTROLLER_SPI0
141
142
#define BOARD_IOID_FLASH_SCK IOID_17
143
#define BOARD_IOID_FLASH_MOSI IOID_19
144
#define BOARD_IOID_FLASH_MISO IOID_18
145
#define BOARD_IOID_FLASH_CS IOID_14
146
147
#define EXT_FLASH_SPI_PIN_SCK 17
148
#define EXT_FLASH_SPI_PIN_MOSI 19
149
#define EXT_FLASH_SPI_PIN_MISO 18
150
#define EXT_FLASH_SPI_PIN_CS 14
151
152
#if SENSORTAG_CC2650_REV_1_2_0
153
#define EXT_FLASH_DEVICE_ID 0x12
154
#define EXT_FLASH_MID 0xEF
155
#else
156
#define EXT_FLASH_DEVICE_ID 0x14
157
#define EXT_FLASH_MID 0xC2
158
#endif
159
160
#define EXT_FLASH_PROGRAM_PAGE_SIZE 256
161
#define EXT_FLASH_ERASE_SECTOR_SIZE 4096
162
/** @} */
163
/*---------------------------------------------------------------------------*/
164
/**
165
* \brief I2C IOID mappings
166
*
167
* Those values are not meant to be modified by the user
168
* @{
169
*/
170
#define BOARD_IOID_SDA IOID_5
/**< Interface 0 SDA: All sensors bar MPU */
171
#define BOARD_IOID_SCL IOID_6
/**< Interface 0 SCL: All sensors bar MPU */
172
#define BOARD_IOID_SDA_HP IOID_8
/**< Interface 1 SDA: MPU */
173
#define BOARD_IOID_SCL_HP IOID_9
/**< Interface 1 SCL: MPU */
174
/** @} */
175
/*---------------------------------------------------------------------------*/
176
/**
177
* \brief MPU IOID mappings
178
*
179
* Those values are not meant to be modified by the user
180
* @{
181
*/
182
#define BOARD_IOID_MPU_INT IOID_7
183
#define BOARD_IOID_MPU_POWER IOID_12
184
#define BOARD_MPU_INT (1 << BOARD_IOID_MPU_INT)
185
#define BOARD_MPU_POWER (1 << BOARD_IOID_MPU_POWER)
186
/** @} */
187
/*---------------------------------------------------------------------------*/
188
/**
189
* \brief Board devpack IOID mappings (LCD etc.)
190
*
191
* Those values are not meant to be modified by the user
192
* @{
193
*/
194
#define BOARD_IOID_AUDIOFS_TDO IOID_16
195
#define BOARD_IOID_DEVPACK_CS IOID_20
196
#define BOARD_IOID_DEVPK_LCD_EXTCOMIN IOID_22
197
#define BOARD_IOID_AUDIODO IOID_22
198
#define BOARD_IOID_DP2 IOID_23
199
#define BOARD_IOID_DP1 IOID_24
200
#define BOARD_IOID_DP0 IOID_25
201
#define BOARD_IOID_DP3 IOID_27
202
#define BOARD_IOID_DEVPK_ID IOID_30
203
#define BOARD_DEVPACK_CS (1 << BOARD_IOID_DEVPACK_CS)
204
/** @} */
205
/*---------------------------------------------------------------------------*/
206
/**
207
* \brief TMP Sensor
208
*
209
* Those values are not meant to be modified by the user
210
* @{
211
*/
212
#define BOARD_IOID_TMP_RDY IOID_1
213
/** @} */
214
/*---------------------------------------------------------------------------*/
215
/**
216
* \brief Digital Microphone
217
*
218
* Those values are not meant to be modified by the user
219
* @{
220
*/
221
#define BOARD_IOID_MIC_POWER IOID_13
222
#define BOARD_IOID_AUDIO_DI IOID_2
223
#define BOARD_IOID_AUDIO_CLK IOID_11
224
/** @} */
225
/*---------------------------------------------------------------------------*/
226
/**
227
* \brief Board indices for the button HAL
228
*
229
* Those values are not meant to be modified by the user
230
* @{
231
*/
232
#define BOARD_BUTTON_HAL_INDEX_KEY_LEFT 0x00
233
#define BOARD_BUTTON_HAL_INDEX_KEY_RIGHT 0x01
234
#define BOARD_BUTTON_HAL_INDEX_REED_RELAY 0xFF
235
/** @} */
236
/*---------------------------------------------------------------------------*/
237
/**
238
* \name Device string used on startup
239
* @{
240
*/
241
#define BOARD_STRING "TI CC2650 SensorTag"
242
243
/** @} */
244
/*---------------------------------------------------------------------------*/
245
#endif
/* BOARD_H_ */
246
/*---------------------------------------------------------------------------*/
247
/**
248
* @}
249
* @}
250
*/
ioc.h
Header file with declarations for the I/O Control module.
Generated on Tue Jun 5 2018 21:07:17 for Contiki-NG by
1.8.11