TI-RTOS for SimpleLink Wireless MCUs  2.14.02.22
GPIOMSP430.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2015, Texas Instruments Incorporated
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  *
9  * * Redistributions of source code must retain the above copyright
10  * notice, this list of conditions and the following disclaimer.
11  *
12  * * Redistributions in binary form must reproduce the above copyright
13  * notice, this list of conditions and the following disclaimer in the
14  * documentation and/or other materials provided with the distribution.
15  *
16  * * Neither the name of Texas Instruments Incorporated nor the names of
17  * its contributors may be used to endorse or promote products derived
18  * from this software without specific prior written permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
22  * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23  * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
24  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
25  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
26  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
27  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
29  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
30  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  */
162 #ifndef ti_drivers_GPIOMSP430__include
163 #define ti_drivers_GPIOMSP430__include
164 
165 #ifdef __cplusplus
166 extern "C" {
167 #endif
168 
169 #include <stdint.h>
170 
171 #include <ti/drivers/GPIO.h>
172 
176 typedef struct GPIOMSP430_Config {
179 
182 
185 
189 
196 #define GPIOMSP430_EMPTY_PIN 0x0000
197 
198 #define GPIOMSP430_P1_0 0x0101
199 #define GPIOMSP430_P1_1 0x0102
200 #define GPIOMSP430_P1_2 0x0104
201 #define GPIOMSP430_P1_3 0x0108
202 #define GPIOMSP430_P1_4 0x0110
203 #define GPIOMSP430_P1_5 0x0120
204 #define GPIOMSP430_P1_6 0x0140
205 #define GPIOMSP430_P1_7 0x0180
206 
207 #define GPIOMSP430_P2_0 0x0201
208 #define GPIOMSP430_P2_1 0x0202
209 #define GPIOMSP430_P2_2 0x0204
210 #define GPIOMSP430_P2_3 0x0208
211 #define GPIOMSP430_P2_4 0x0210
212 #define GPIOMSP430_P2_5 0x0220
213 #define GPIOMSP430_P2_6 0x0240
214 #define GPIOMSP430_P2_7 0x0280
215 
216 #define GPIOMSP430_P3_0 0x0301
217 #define GPIOMSP430_P3_1 0x0302
218 #define GPIOMSP430_P3_2 0x0304
219 #define GPIOMSP430_P3_3 0x0308
220 #define GPIOMSP430_P3_4 0x0310
221 #define GPIOMSP430_P3_5 0x0320
222 #define GPIOMSP430_P3_6 0x0340
223 #define GPIOMSP430_P3_7 0x0380
224 
225 #define GPIOMSP430_P4_0 0x0401
226 #define GPIOMSP430_P4_1 0x0402
227 #define GPIOMSP430_P4_2 0x0404
228 #define GPIOMSP430_P4_3 0x0408
229 #define GPIOMSP430_P4_4 0x0410
230 #define GPIOMSP430_P4_5 0x0420
231 #define GPIOMSP430_P4_6 0x0440
232 #define GPIOMSP430_P4_7 0x0480
233 
234 #define GPIOMSP430_P5_0 0x0501
235 #define GPIOMSP430_P5_1 0x0502
236 #define GPIOMSP430_P5_2 0x0504
237 #define GPIOMSP430_P5_3 0x0508
238 #define GPIOMSP430_P5_4 0x0510
239 #define GPIOMSP430_P5_5 0x0520
240 #define GPIOMSP430_P5_6 0x0540
241 #define GPIOMSP430_P5_7 0x0580
242 
243 #define GPIOMSP430_P6_0 0x0601
244 #define GPIOMSP430_P6_1 0x0602
245 #define GPIOMSP430_P6_2 0x0604
246 #define GPIOMSP430_P6_3 0x0608
247 #define GPIOMSP430_P6_4 0x0610
248 #define GPIOMSP430_P6_5 0x0620
249 #define GPIOMSP430_P6_6 0x0640
250 #define GPIOMSP430_P6_7 0x0680
251 
252 #define GPIOMSP430_P7_0 0x0701
253 #define GPIOMSP430_P7_1 0x0702
254 #define GPIOMSP430_P7_2 0x0704
255 #define GPIOMSP430_P7_3 0x0708
256 #define GPIOMSP430_P7_4 0x0710
257 #define GPIOMSP430_P7_5 0x0720
258 #define GPIOMSP430_P7_6 0x0740
259 #define GPIOMSP430_P7_7 0x0780
260 
261 #define GPIOMSP430_P8_0 0x0801
262 #define GPIOMSP430_P8_1 0x0802
263 #define GPIOMSP430_P8_2 0x0804
264 #define GPIOMSP430_P8_3 0x0808
265 #define GPIOMSP430_P8_4 0x0810
266 #define GPIOMSP430_P8_5 0x0820
267 #define GPIOMSP430_P8_6 0x0840
268 #define GPIOMSP430_P8_7 0x0880
269 
270 #define GPIOMSP430_P9_0 0x0901
271 #define GPIOMSP430_P9_1 0x0902
272 #define GPIOMSP430_P9_2 0x0904
273 #define GPIOMSP430_P9_3 0x0908
274 #define GPIOMSP430_P9_4 0x0910
275 #define GPIOMSP430_P9_5 0x0920
276 #define GPIOMSP430_P9_6 0x0940
277 #define GPIOMSP430_P9_7 0x0980
278 
279 #define GPIOMSP430_P10_0 0x0A01
280 #define GPIOMSP430_P10_1 0x0A02
281 #define GPIOMSP430_P10_2 0x0A04
282 #define GPIOMSP430_P10_3 0x0A08
283 #define GPIOMSP430_P10_4 0x0A10
284 #define GPIOMSP430_P10_5 0x0A20
285 #define GPIOMSP430_P10_6 0x0A40
286 #define GPIOMSP430_P10_7 0x0A80
287 
288 #define GPIOMSP430_P11_0 0x0B01
289 #define GPIOMSP430_P11_1 0x0B02
290 #define GPIOMSP430_P11_2 0x0B04
291 #define GPIOMSP430_P11_3 0x0B08
292 #define GPIOMSP430_P11_4 0x0B10
293 #define GPIOMSP430_P11_5 0x0B20
294 #define GPIOMSP430_P11_6 0x0B40
295 #define GPIOMSP430_P11_7 0x0B80
296 
297 /* Port J skips to 0xDxx because MSPWare defines port number to 13 (0xD) */
298 #define GPIOMSP430_PJ_0 0x0D01
299 #define GPIOMSP430_PJ_1 0x0D02
300 #define GPIOMSP430_PJ_2 0x0D04
301 #define GPIOMSP430_PJ_3 0x0D08
302 #define GPIOMSP430_PJ_4 0x0D10
303 #define GPIOMSP430_PJ_5 0x0D20
304 #define GPIOMSP430_PJ_6 0x0D40
305 #define GPIOMSP430_PJ_7 0x0D80
306 
307 #endif /* ti_drivers_GPIOMSP430__include */
struct GPIOMSP430_Config GPIOMSP430_Config
GPIO device specific driver configuration structure.
GPIO device specific driver configuration structure.
Definition: GPIOMSP430.h:176
uint32_t numberOfPinConfigs
Definition: GPIOMSP430.h:184
GPIO_PinConfig * pinConfigs
Definition: GPIOMSP430.h:178
uint32_t numberOfCallbacks
Definition: GPIOMSP430.h:187
uint32_t GPIO_PinConfig
GPIO pin configuration settings.
Definition: GPIO.h:84
GPIO driver.
void(* GPIO_CallbackFxn)(void)
GPIO callback function type.
Definition: GPIO.h:157
GPIO_CallbackFxn * callbacks
Definition: GPIOMSP430.h:181
Copyright 2015, Texas Instruments Incorporated