Subversion Repositories DevTools

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2850 dpurdie 1
/******************************************************************************/
2
/* Legacy Header File                                                         */
3
/* Not recommended for use in new projects.                                   */
4
/* Please use the msp430.h file or the device specific header file            */
5
/******************************************************************************/
6
 
7
/********************************************************************
8
*
9
* Standard register and bit definitions for the Texas Instruments
10
* MSP430 microcontroller.
11
*
12
* This file supports assembler and C development for
13
* MSP430x415 and MSP430x417 devices.
14
*
15
* Texas Instruments, Version 1.4
16
*
17
* Rev. 1.0, -
18
* Rev. 1.1, Removed unused def of TASSEL2
19
* Rev. 1.2, Added VLD bits in SVS module
20
* Rev. 1.3, Removed definitions for BTRESET
21
* Rev. 1.4, added definitions for Interrupt Vectors xxIV
22
*
23
********************************************************************/
24
 
25
#ifndef __msp430x41x
26
#define __msp430x41x
27
 
28
#ifdef __cplusplus
29
extern "C" {
30
#endif
31
 
32
 
33
/*----------------------------------------------------------------------------*/
34
/* PERIPHERAL FILE MAP                                                        */
35
/*----------------------------------------------------------------------------*/
36
 
37
/* External references resolved by a device-specific linker command file */
38
#define SFR_8BIT(address)   extern volatile unsigned char address
39
#define SFR_16BIT(address)  extern volatile unsigned int address
40
 
41
 
42
/************************************************************
43
* STANDARD BITS
44
************************************************************/
45
 
46
#define BIT0                   (0x0001)
47
#define BIT1                   (0x0002)
48
#define BIT2                   (0x0004)
49
#define BIT3                   (0x0008)
50
#define BIT4                   (0x0010)
51
#define BIT5                   (0x0020)
52
#define BIT6                   (0x0040)
53
#define BIT7                   (0x0080)
54
#define BIT8                   (0x0100)
55
#define BIT9                   (0x0200)
56
#define BITA                   (0x0400)
57
#define BITB                   (0x0800)
58
#define BITC                   (0x1000)
59
#define BITD                   (0x2000)
60
#define BITE                   (0x4000)
61
#define BITF                   (0x8000)
62
 
63
/************************************************************
64
* STATUS REGISTER BITS
65
************************************************************/
66
 
67
#define C                      (0x0001)
68
#define Z                      (0x0002)
69
#define N                      (0x0004)
70
#define V                      (0x0100)
71
#define GIE                    (0x0008)
72
#define CPUOFF                 (0x0010)
73
#define OSCOFF                 (0x0020)
74
#define SCG0                   (0x0040)
75
#define SCG1                   (0x0080)
76
 
77
/* Low Power Modes coded with Bits 4-7 in SR */
78
 
79
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
80
#define LPM0                   (CPUOFF)
81
#define LPM1                   (SCG0+CPUOFF)
82
#define LPM2                   (SCG1+CPUOFF)
83
#define LPM3                   (SCG1+SCG0+CPUOFF)
84
#define LPM4                   (SCG1+SCG0+OSCOFF+CPUOFF)
85
/* End #defines for assembler */
86
 
87
#else /* Begin #defines for C */
88
#define LPM0_bits              (CPUOFF)
89
#define LPM1_bits              (SCG0+CPUOFF)
90
#define LPM2_bits              (SCG1+CPUOFF)
91
#define LPM3_bits              (SCG1+SCG0+CPUOFF)
92
#define LPM4_bits              (SCG1+SCG0+OSCOFF+CPUOFF)
93
 
94
#include "in430.h"
95
 
96
#define LPM0         _bis_SR_register(LPM0_bits)         /* Enter Low Power Mode 0 */
97
#define LPM0_EXIT    _bic_SR_register_on_exit(LPM0_bits) /* Exit Low Power Mode 0 */
98
#define LPM1         _bis_SR_register(LPM1_bits)         /* Enter Low Power Mode 1 */
99
#define LPM1_EXIT    _bic_SR_register_on_exit(LPM1_bits) /* Exit Low Power Mode 1 */
100
#define LPM2         _bis_SR_register(LPM2_bits)         /* Enter Low Power Mode 2 */
101
#define LPM2_EXIT    _bic_SR_register_on_exit(LPM2_bits) /* Exit Low Power Mode 2 */
102
#define LPM3         _bis_SR_register(LPM3_bits)         /* Enter Low Power Mode 3 */
103
#define LPM3_EXIT    _bic_SR_register_on_exit(LPM3_bits) /* Exit Low Power Mode 3 */
104
#define LPM4         _bis_SR_register(LPM4_bits)         /* Enter Low Power Mode 4 */
105
#define LPM4_EXIT    _bic_SR_register_on_exit(LPM4_bits) /* Exit Low Power Mode 4 */
106
#endif /* End #defines for C */
107
 
108
/************************************************************
109
* PERIPHERAL FILE MAP
110
************************************************************/
111
 
112
/************************************************************
113
* SPECIAL FUNCTION REGISTER ADDRESSES + CONTROL BITS
114
************************************************************/
115
 
116
SFR_8BIT(IE1);                                /* Interrupt Enable 1 */
117
#define WDTIE                  (0x01)
118
#define OFIE                   (0x02)
119
#define NMIIE                  (0x10)
120
#define ACCVIE                 (0x20)
121
 
122
SFR_8BIT(IFG1);                               /* Interrupt Flag 1 */
123
#define WDTIFG                 (0x01)
124
#define OFIFG                  (0x02)
125
#define NMIIFG                 (0x10)
126
 
127
SFR_8BIT(IE2);                                /* Interrupt Enable 2 */
128
#define BTIE                   (0x80)
129
 
130
SFR_8BIT(IFG2);                               /* Interrupt Flag 2 */
131
#define BTIFG                  (0x80)
132
 
133
/************************************************************
134
* WATCHDOG TIMER
135
************************************************************/
136
#define __MSP430_HAS_WDT__                    /* Definition to show that Module is available */
137
 
138
SFR_16BIT(WDTCTL);                            /* Watchdog Timer Control */
139
/* The bit names have been prefixed with "WDT" */
140
#define WDTIS0                 (0x0001)
141
#define WDTIS1                 (0x0002)
142
#define WDTSSEL                (0x0004)
143
#define WDTCNTCL               (0x0008)
144
#define WDTTMSEL               (0x0010)
145
#define WDTNMI                 (0x0020)
146
#define WDTNMIES               (0x0040)
147
#define WDTHOLD                (0x0080)
148
 
149
#define WDTPW                  (0x5A00)
150
 
151
/* WDT-interval times [1ms] coded with Bits 0-2 */
152
/* WDT is clocked by fSMCLK (assumed 1MHz) */
153
#define WDT_MDLY_32         (WDTPW+WDTTMSEL+WDTCNTCL)                         /* 32ms interval (default) */
154
#define WDT_MDLY_8          (WDTPW+WDTTMSEL+WDTCNTCL+WDTIS0)                  /* 8ms     " */
155
#define WDT_MDLY_0_5        (WDTPW+WDTTMSEL+WDTCNTCL+WDTIS1)                  /* 0.5ms   " */
156
#define WDT_MDLY_0_064      (WDTPW+WDTTMSEL+WDTCNTCL+WDTIS1+WDTIS0)           /* 0.064ms " */
157
/* WDT is clocked by fACLK (assumed 32KHz) */
158
#define WDT_ADLY_1000       (WDTPW+WDTTMSEL+WDTCNTCL+WDTSSEL)                 /* 1000ms  " */
159
#define WDT_ADLY_250        (WDTPW+WDTTMSEL+WDTCNTCL+WDTSSEL+WDTIS0)          /* 250ms   " */
160
#define WDT_ADLY_16         (WDTPW+WDTTMSEL+WDTCNTCL+WDTSSEL+WDTIS1)          /* 16ms    " */
161
#define WDT_ADLY_1_9        (WDTPW+WDTTMSEL+WDTCNTCL+WDTSSEL+WDTIS1+WDTIS0)   /* 1.9ms   " */
162
/* Watchdog mode -> reset after expired time */
163
/* WDT is clocked by fSMCLK (assumed 1MHz) */
164
#define WDT_MRST_32         (WDTPW+WDTCNTCL)                                  /* 32ms interval (default) */
165
#define WDT_MRST_8          (WDTPW+WDTCNTCL+WDTIS0)                           /* 8ms     " */
166
#define WDT_MRST_0_5        (WDTPW+WDTCNTCL+WDTIS1)                           /* 0.5ms   " */
167
#define WDT_MRST_0_064      (WDTPW+WDTCNTCL+WDTIS1+WDTIS0)                    /* 0.064ms " */
168
/* WDT is clocked by fACLK (assumed 32KHz) */
169
#define WDT_ARST_1000       (WDTPW+WDTCNTCL+WDTSSEL)                          /* 1000ms  " */
170
#define WDT_ARST_250        (WDTPW+WDTCNTCL+WDTSSEL+WDTIS0)                   /* 250ms   " */
171
#define WDT_ARST_16         (WDTPW+WDTCNTCL+WDTSSEL+WDTIS1)                   /* 16ms    " */
172
#define WDT_ARST_1_9        (WDTPW+WDTCNTCL+WDTSSEL+WDTIS1+WDTIS0)            /* 1.9ms   " */
173
 
174
/* INTERRUPT CONTROL */
175
/* These two bits are defined in the Special Function Registers */
176
/* #define WDTIE               0x01 */
177
/* #define WDTIFG              0x01 */
178
 
179
/************************************************************
180
* DIGITAL I/O Port1/2
181
************************************************************/
182
#define __MSP430_HAS_PORT1__                  /* Definition to show that Module is available */
183
#define __MSP430_HAS_PORT2__                  /* Definition to show that Module is available */
184
 
185
SFR_8BIT(P1IN);                               /* Port 1 Input */
186
SFR_8BIT(P1OUT);                              /* Port 1 Output */
187
SFR_8BIT(P1DIR);                              /* Port 1 Direction */
188
SFR_8BIT(P1IFG);                              /* Port 1 Interrupt Flag */
189
SFR_8BIT(P1IES);                              /* Port 1 Interrupt Edge Select */
190
SFR_8BIT(P1IE);                               /* Port 1 Interrupt Enable */
191
SFR_8BIT(P1SEL);                              /* Port 1 Selection */
192
 
193
SFR_8BIT(P2IN);                               /* Port 2 Input */
194
SFR_8BIT(P2OUT);                              /* Port 2 Output */
195
SFR_8BIT(P2DIR);                              /* Port 2 Direction */
196
SFR_8BIT(P2IFG);                              /* Port 2 Interrupt Flag */
197
SFR_8BIT(P2IES);                              /* Port 2 Interrupt Edge Select */
198
SFR_8BIT(P2IE);                               /* Port 2 Interrupt Enable */
199
SFR_8BIT(P2SEL);                              /* Port 2 Selection */
200
 
201
/************************************************************
202
* DIGITAL I/O Port3/4
203
************************************************************/
204
#define __MSP430_HAS_PORT3__                  /* Definition to show that Module is available */
205
#define __MSP430_HAS_PORT4__                  /* Definition to show that Module is available */
206
 
207
SFR_8BIT(P3IN);                               /* Port 3 Input */
208
SFR_8BIT(P3OUT);                              /* Port 3 Output */
209
SFR_8BIT(P3DIR);                              /* Port 3 Direction */
210
SFR_8BIT(P3SEL);                              /* Port 3 Selection */
211
 
212
SFR_8BIT(P4IN);                               /* Port 4 Input */
213
SFR_8BIT(P4OUT);                              /* Port 4 Output */
214
SFR_8BIT(P4DIR);                              /* Port 4 Direction */
215
SFR_8BIT(P4SEL);                              /* Port 4 Selection */
216
 
217
/************************************************************
218
* DIGITAL I/O Port5/6
219
************************************************************/
220
#define __MSP430_HAS_PORT5__                  /* Definition to show that Module is available */
221
#define __MSP430_HAS_PORT6__                  /* Definition to show that Module is available */
222
 
223
SFR_8BIT(P5IN);                               /* Port 5 Input */
224
SFR_8BIT(P5OUT);                              /* Port 5 Output */
225
SFR_8BIT(P5DIR);                              /* Port 5 Direction */
226
SFR_8BIT(P5SEL);                              /* Port 5 Selection */
227
 
228
SFR_8BIT(P6IN);                               /* Port 6 Input */
229
SFR_8BIT(P6OUT);                              /* Port 6 Output */
230
SFR_8BIT(P6DIR);                              /* Port 6 Direction */
231
SFR_8BIT(P6SEL);                              /* Port 6 Selection */
232
 
233
/************************************************************
234
* BASIC TIMER
235
************************************************************/
236
#define __MSP430_HAS_BT__                     /* Definition to show that Module is available */
237
 
238
SFR_8BIT(BTCTL);                              /* Basic Timer Control */
239
/* The bit names have been prefixed with "BT" */
240
#define BTIP0                  (0x01)
241
#define BTIP1                  (0x02)
242
#define BTIP2                  (0x04)
243
#define BTFRFQ0                (0x08)
244
#define BTFRFQ1                (0x10)
245
#define BTDIV                  (0x20)         /* fCLK2 = ACLK:256 */
246
#define BTHOLD                 (0x40)         /* BT1 is held if this bit is set */
247
#define BTSSEL                 (0x80)         /* fBT = fMCLK (main clock) */
248
 
249
SFR_8BIT(BTCNT1);                             /* Basic Timer Count 1 */
250
SFR_8BIT(BTCNT2);                             /* Basic Timer Count 2 */
251
 
252
/* Frequency of the BTCNT2 coded with Bit 5 and 7 in BTCTL */
253
#define BT_fCLK2_ACLK          (0x00)
254
#define BT_fCLK2_ACLK_DIV256   (BTDIV)
255
#define BT_fCLK2_MCLK          (BTSSEL)
256
 
257
/* Interrupt interval time fINT coded with Bits 0-2 in BTCTL */
258
#define BT_fCLK2_DIV2          (0x00)         /* fINT = fCLK2:2 (default) */
259
#define BT_fCLK2_DIV4          (BTIP0)        /* fINT = fCLK2:4 */
260
#define BT_fCLK2_DIV8          (BTIP1)        /* fINT = fCLK2:8 */
261
#define BT_fCLK2_DIV16         (BTIP1+BTIP0)  /* fINT = fCLK2:16 */
262
#define BT_fCLK2_DIV32         (BTIP2)        /* fINT = fCLK2:32 */
263
#define BT_fCLK2_DIV64         (BTIP2+BTIP0)  /* fINT = fCLK2:64 */
264
#define BT_fCLK2_DIV128        (BTIP2+BTIP1)  /* fINT = fCLK2:128 */
265
#define BT_fCLK2_DIV256     (BTIP2+BTIP1+BTIP0)       /* fINT = fCLK2:256 */
266
/* Frequency of LCD coded with Bits 3-4 */
267
#define BT_fLCD_DIV32          (0x00)         /* fLCD = fACLK:32 (default) */
268
#define BT_fLCD_DIV64          (BTFRFQ0)      /* fLCD = fACLK:64 */
269
#define BT_fLCD_DIV128         (BTFRFQ1)      /* fLCD = fACLK:128 */
270
#define BT_fLCD_DIV256      (BTFRFQ1+BTFRFQ0)         /* fLCD = fACLK:256 */
271
/* LCD frequency values with fBT=fACLK */
272
#define BT_fLCD_1K             (0x00)         /* fACLK:32 (default) */
273
#define BT_fLCD_512            (BTFRFQ0)      /* fACLK:64 */
274
#define BT_fLCD_256            (BTFRFQ1)      /* fACLK:128 */
275
#define BT_fLCD_128         (BTFRFQ1+BTFRFQ0)         /* fACLK:256 */
276
/* LCD frequency values with fBT=fMCLK */
277
#define BT_fLCD_31K            (BTSSEL)       /* fMCLK:32 */
278
#define BT_fLCD_15_5K       (BTSSEL+BTFRFQ0)          /* fMCLK:64 */
279
#define BT_fLCD_7_8K        (BTSSEL+BTFRFQ1+BTFRFQ0)  /* fMCLK:256 */
280
/* with assumed vlues of fACLK=32KHz, fMCLK=1MHz */
281
/* fBT=fACLK is thought for longer interval times */
282
#define BT_ADLY_0_064          (0x00)         /* 0.064ms interval (default) */
283
#define BT_ADLY_0_125          (BTIP0)        /* 0.125ms    " */
284
#define BT_ADLY_0_25           (BTIP1)        /* 0.25ms     " */
285
#define BT_ADLY_0_5            (BTIP1+BTIP0)  /* 0.5ms      " */
286
#define BT_ADLY_1              (BTIP2)        /* 1ms        " */
287
#define BT_ADLY_2              (BTIP2+BTIP0)  /* 2ms        " */
288
#define BT_ADLY_4              (BTIP2+BTIP1)  /* 4ms        " */
289
#define BT_ADLY_8           (BTIP2+BTIP1+BTIP0)       /* 8ms        " */
290
#define BT_ADLY_16             (BTDIV)        /* 16ms       " */
291
#define BT_ADLY_32             (BTDIV+BTIP0)  /* 32ms       " */
292
#define BT_ADLY_64             (BTDIV+BTIP1)  /* 64ms       " */
293
#define BT_ADLY_125         (BTDIV+BTIP1+BTIP0)       /* 125ms      " */
294
#define BT_ADLY_250            (BTDIV+BTIP2)  /* 250ms      " */
295
#define BT_ADLY_500         (BTDIV+BTIP2+BTIP0)       /* 500ms      " */
296
#define BT_ADLY_1000        (BTDIV+BTIP2+BTIP1)       /* 1000ms     " */
297
#define BT_ADLY_2000        (BTDIV+BTIP2+BTIP1+BTIP0) /* 2000ms     " */
298
/* fCLK2=fMCLK (1MHz) is thought for short interval times */
299
/* the timing for short intervals is more precise than ACLK */
300
/* NOTE */
301
/* Be sure that the SCFQCTL-Register is set to 01Fh so that fMCLK=1MHz */
302
/* Too low interval time results in interrupts too frequent for the processor to handle! */
303
#define BT_MDLY_0_002          (BTSSEL)       /* 0.002ms interval       *** interval times */
304
#define BT_MDLY_0_004          (BTSSEL+BTIP0) /* 0.004ms    "           *** too short for */
305
#define BT_MDLY_0_008          (BTSSEL+BTIP1) /* 0.008ms    "           *** interrupt */
306
#define BT_MDLY_0_016       (BTSSEL+BTIP1+BTIP0)      /* 0.016ms    "           *** handling */
307
#define BT_MDLY_0_032          (BTSSEL+BTIP2) /* 0.032ms    " */
308
#define BT_MDLY_0_064       (BTSSEL+BTIP2+BTIP0)      /* 0.064ms    " */
309
#define BT_MDLY_0_125       (BTSSEL+BTIP2+BTIP1)      /* 0.125ms    " */
310
#define BT_MDLY_0_25        (BTSSEL+BTIP2+BTIP1+BTIP0)/* 0.25ms     " */
311
 
312
/* Reset/Hold coded with Bits 6-7 in BT(1)CTL */
313
/* this is for BT */
314
//#define BTRESET_CNT1        (BTRESET)           /* BTCNT1 is reset while BTRESET is set */
315
//#define BTRESET_CNT1_2      (BTRESET+BTDIV)     /* BTCNT1 .AND. BTCNT2 are reset while ~ is set */
316
/* this is for BT1 */
317
#define BTHOLD_CNT1            (BTHOLD)       /* BTCNT1 is held while BTHOLD is set */
318
#define BTHOLD_CNT1_2          (BTHOLD+BTDIV) /* BT1CNT1 .AND. BT1CNT2 are held while ~ is set */
319
 
320
/* INTERRUPT CONTROL BITS */
321
/* #define BTIE                0x80 */
322
/* #define BTIFG               0x80 */
323
 
324
/************************************************************
325
* SYSTEM CLOCK, FLL+ (x41x)
326
************************************************************/
327
#define __MSP430_HAS_FLLPLUS_SMALL__                /* Definition to show that Module is available */
328
 
329
SFR_8BIT(SCFI0);                              /* System Clock Frequency Integrator 0 */
330
#define FN_2                   (0x04)         /* fDCOCLK =   1.4-12MHz*/
331
#define FN_3                   (0x08)         /* fDCOCLK =   2.2-17Mhz*/
332
#define FN_4                   (0x10)         /* fDCOCLK =   3.2-25Mhz*/
333
#define FN_8                   (0x20)         /* fDCOCLK =     5-40Mhz*/
334
#define FLLD0                  (0x40)         /* Loop Divider Bit : 0 */
335
#define FLLD1                  (0x80)         /* Loop Divider Bit : 1 */
336
 
337
#define FLLD_1                 (0x00)         /* Multiply Selected Loop Freq. By 1 */
338
#define FLLD_2                 (0x40)         /* Multiply Selected Loop Freq. By 2 */
339
#define FLLD_4                 (0x80)         /* Multiply Selected Loop Freq. By 4 */
340
#define FLLD_8                 (0xC0)         /* Multiply Selected Loop Freq. By 8 */
341
 
342
SFR_8BIT(SCFI1);                              /* System Clock Frequency Integrator 1 */
343
SFR_8BIT(SCFQCTL);                            /* System Clock Frequency Control */
344
/* System clock frequency values fMCLK coded with Bits 0-6 in SCFQCTL */
345
/* #define SCFQ_32K            0x00                        fMCLK=1*fACLK       only a range from */
346
#define SCFQ_64K               (0x01)         /* fMCLK=2*fACLK          1+1 to 127+1 is possible */
347
#define SCFQ_128K              (0x03)         /* fMCLK=4*fACLK */
348
#define SCFQ_256K              (0x07)         /* fMCLK=8*fACLK */
349
#define SCFQ_512K              (0x0F)         /* fMCLK=16*fACLK */
350
#define SCFQ_1M                (0x1F)         /* fMCLK=32*fACLK */
351
#define SCFQ_2M                (0x3F)         /* fMCLK=64*fACLK */
352
#define SCFQ_4M                (0x7F)         /* fMCLK=128*fACLK */
353
#define SCFQ_M                 (0x80)         /* Modulation Disable */
354
 
355
SFR_8BIT(FLL_CTL0);                           /* FLL+ Control 0 */
356
#define DCOF                   (0x01)         /* DCO Fault Flag */
357
#define LFOF                   (0x02)         /* Low Frequency Oscillator Fault Flag */
358
#define XT1OF                  (0x04)         /* High Frequency Oscillator Fault Flag */
359
#define OSCCAP0                (0x10)         /* XIN/XOUT Cap 0 */
360
#define OSCCAP1                (0x20)         /* XIN/XOUT Cap 1 */
361
#define XTS_FLL                (0x40)         /* 1: Selects high-freq. oscillator */
362
#define DCOPLUS                (0x80)         /* DCO+ Enable */
363
 
364
#define XCAP0PF                (0x00)         /* XIN Cap = XOUT Cap = 0pf */
365
#define XCAP10PF               (0x10)         /* XIN Cap = XOUT Cap = 10pf */
366
#define XCAP14PF               (0x20)         /* XIN Cap = XOUT Cap = 14pf */
367
#define XCAP18PF               (0x30)         /* XIN Cap = XOUT Cap = 18pf */
368
#define OSCCAP_0               (0x00)         /* XIN Cap = XOUT Cap = 0pf */
369
#define OSCCAP_1               (0x10)         /* XIN Cap = XOUT Cap = 10pf */
370
#define OSCCAP_2               (0x20)         /* XIN Cap = XOUT Cap = 14pf */
371
#define OSCCAP_3               (0x30)         /* XIN Cap = XOUT Cap = 18pf */
372
 
373
SFR_8BIT(FLL_CTL1);                           /* FLL+ Control 1 */
374
#define FLL_DIV0               (0x01)         /* FLL+ Divide Px.x/ACLK 0 */
375
#define FLL_DIV1               (0x02)         /* FLL+ Divide Px.x/ACLK 1 */
376
 
377
#define FLL_DIV_1              (0x00)         /* FLL+ Divide Px.x/ACLK By 1 */
378
#define FLL_DIV_2              (0x01)         /* FLL+ Divide Px.x/ACLK By 2 */
379
#define FLL_DIV_4              (0x02)         /* FLL+ Divide Px.x/ACLK By 4 */
380
#define FLL_DIV_8              (0x03)         /* FLL+ Divide Px.x/ACLK By 8 */
381
 
382
/* INTERRUPT CONTROL BITS */
383
/* These two bits are defined in the Special Function Registers */
384
/* #define OFIFG               0x02 */
385
/* #define OFIE                0x02 */
386
 
387
/************************************************************
388
* Brown-Out, Supply Voltage Supervision (SVS)
389
************************************************************/
390
#define __MSP430_HAS_SVS__                    /* Definition to show that Module is available */
391
 
392
SFR_8BIT(SVSCTL);                             /* SVS Control */
393
#define SVSFG                  (0x01)         /* SVS Flag */
394
#define SVSOP                  (0x02)         /* SVS output (read only) */
395
#define SVSON                  (0x04)         /* Switches the SVS on/off */
396
#define PORON                  (0x08)         /* Enable POR Generation if Low Voltage */
397
#define VLD0                   (0x10)
398
#define VLD1                   (0x20)
399
#define VLD2                   (0x40)
400
#define VLD3                   (0x80)
401
 
402
#define VLDON                  (0x10)
403
#define VLDOFF                 (0x00)
404
#define VLD_1_8V               (0x10)
405
 
406
/************************************************************
407
* LCD
408
************************************************************/
409
#define __MSP430_HAS_LCD4__                   /* Definition to show that Module is available */
410
 
411
SFR_8BIT(LCDCTL);                             /* LCD Control */
412
/* the names of the mode bits are different from the spec */
413
#define LCDON                  (0x01)
414
//#define LCDLOWR             (0x02)
415
#define LCDSON                 (0x04)
416
#define LCDMX0                 (0x08)
417
#define LCDMX1                 (0x10)
418
#define LCDP0                  (0x20)
419
#define LCDP1                  (0x40)
420
#define LCDP2                  (0x80)
421
/* Display modes coded with Bits 2-4 */
422
#define LCDSTATIC              (LCDSON)
423
#define LCD2MUX                (LCDMX0+LCDSON)
424
#define LCD3MUX                (LCDMX1+LCDSON)
425
#define LCD4MUX                (LCDMX1+LCDMX0+LCDSON)
426
/* Group select code with Bits 5-7                     Seg.lines   Dig.output */
427
#define LCDSG0                 (0x00)         /* ---------   Port Only (default) */
428
#define LCDSG0_1               (LCDP0)        /* S0  - S15   see Datasheet */
429
#define LCDSG0_2               (LCDP1)        /* S0  - S19   see Datasheet */
430
#define LCDSG0_3               (LCDP1+LCDP0)  /* S0  - S23   see Datasheet */
431
#define LCDSG0_4               (LCDP2)        /* S0  - S27   see Datasheet */
432
#define LCDSG0_5               (LCDP2+LCDP0)  /* S0  - S31   see Datasheet */
433
#define LCDSG0_6               (LCDP2+LCDP1)  /* S0  - S35   see Datasheet */
434
#define LCDSG0_7            (LCDP2+LCDP1+LCDP0)       /* S0  - S39   see Datasheet */
435
/* NOTE: YOU CAN ONLY USE THE 'S' OR 'G' DECLARATIONS FOR A COMMAND */
436
/* MOV  #LCDSG0_3+LCDOG2_7,&LCDCTL ACTUALY MEANS MOV  #LCDP1,&LCDCTL! */
437
#define LCDOG1_7               (0x00)         /* ---------   Port Only (default) */
438
#define LCDOG2_7               (LCDP0)        /* S0  - S15   see Datasheet */
439
#define LCDOG3_7               (LCDP1)        /* S0  - S19   see Datasheet */
440
#define LCDOG4_7               (LCDP1+LCDP0)  /* S0  - S23   see Datasheet */
441
#define LCDOG5_7               (LCDP2)        /* S0  - S27   see Datasheet */
442
#define LCDOG6_7               (LCDP2+LCDP0)  /* S0  - S31   see Datasheet */
443
#define LCDOG7                 (LCDP2+LCDP1)  /* S0  - S35   see Datasheet */
444
#define LCDOGOFF            (LCDP2+LCDP1+LCDP0)       /* S0  - S39   see Datasheet */
445
 
446
#define LCDMEM_                (0x0091)       /* LCD Memory */
447
#ifdef __ASM_HEADER__
448
#define LCDMEM                 (LCDMEM_)      /* LCD Memory (for assembler) */
449
#else
450
#define LCDMEM                 ((char*)       LCDMEM_) /* LCD Memory (for C) */
451
#endif
452
SFR_8BIT(LCDM1);                              /* LCD Memory 1 */
453
SFR_8BIT(LCDM2);                              /* LCD Memory 2 */
454
SFR_8BIT(LCDM3);                              /* LCD Memory 3 */
455
SFR_8BIT(LCDM4);                              /* LCD Memory 4 */
456
SFR_8BIT(LCDM5);                              /* LCD Memory 5 */
457
SFR_8BIT(LCDM6);                              /* LCD Memory 6 */
458
SFR_8BIT(LCDM7);                              /* LCD Memory 7 */
459
SFR_8BIT(LCDM8);                              /* LCD Memory 8 */
460
SFR_8BIT(LCDM9);                              /* LCD Memory 9 */
461
SFR_8BIT(LCDM10);                             /* LCD Memory 10 */
462
SFR_8BIT(LCDM11);                             /* LCD Memory 11 */
463
SFR_8BIT(LCDM12);                             /* LCD Memory 12 */
464
SFR_8BIT(LCDM13);                             /* LCD Memory 13 */
465
SFR_8BIT(LCDM14);                             /* LCD Memory 14 */
466
SFR_8BIT(LCDM15);                             /* LCD Memory 15 */
467
SFR_8BIT(LCDM16);                             /* LCD Memory 16 */
468
SFR_8BIT(LCDM17);                             /* LCD Memory 17 */
469
SFR_8BIT(LCDM18);                             /* LCD Memory 18 */
470
SFR_8BIT(LCDM19);                             /* LCD Memory 19 */
471
SFR_8BIT(LCDM20);                             /* LCD Memory 20 */
472
 
473
#define LCDMA                  (LCDM10)       /* LCD Memory A */
474
#define LCDMB                  (LCDM11)       /* LCD Memory B */
475
#define LCDMC                  (LCDM12)       /* LCD Memory C */
476
#define LCDMD                  (LCDM13)       /* LCD Memory D */
477
#define LCDME                  (LCDM14)       /* LCD Memory E */
478
#define LCDMF                  (LCDM15)       /* LCD Memory F */
479
 
480
/************************************************************
481
* Timer0_A3
482
************************************************************/
483
#define __MSP430_HAS_TA3__                    /* Definition to show that Module is available */
484
 
485
SFR_16BIT(TA0IV);                             /* Timer0_A3 Interrupt Vector Word */
486
SFR_16BIT(TA0CTL);                            /* Timer0_A3 Control */
487
SFR_16BIT(TA0CCTL0);                          /* Timer0_A3 Capture/Compare Control 0 */
488
SFR_16BIT(TA0CCTL1);                          /* Timer0_A3 Capture/Compare Control 1 */
489
SFR_16BIT(TA0CCTL2);                          /* Timer0_A3 Capture/Compare Control 2 */
490
SFR_16BIT(TA0R);                              /* Timer0_A3 */
491
SFR_16BIT(TA0CCR0);                           /* Timer0_A3 Capture/Compare 0 */
492
SFR_16BIT(TA0CCR1);                           /* Timer0_A3 Capture/Compare 1 */
493
SFR_16BIT(TA0CCR2);                           /* Timer0_A3 Capture/Compare 2 */
494
 
495
/* Alternate register names */
496
#define TAIV                   TA0IV          /* Timer A Interrupt Vector Word */
497
#define TACTL                  TA0CTL         /* Timer A Control */
498
#define TACCTL0                TA0CCTL0       /* Timer A Capture/Compare Control 0 */
499
#define TACCTL1                TA0CCTL1       /* Timer A Capture/Compare Control 1 */
500
#define TACCTL2                TA0CCTL2       /* Timer A Capture/Compare Control 2 */
501
#define TAR                    TA0R           /* Timer A */
502
#define TACCR0                 TA0CCR0        /* Timer A Capture/Compare 0 */
503
#define TACCR1                 TA0CCR1        /* Timer A Capture/Compare 1 */
504
#define TACCR2                 TA0CCR2        /* Timer A Capture/Compare 2 */
505
#define TAIV_                  TA0IV_         /* Timer A Interrupt Vector Word */
506
#define TACTL_                 TA0CTL_        /* Timer A Control */
507
#define TACCTL0_               TA0CCTL0_      /* Timer A Capture/Compare Control 0 */
508
#define TACCTL1_               TA0CCTL1_      /* Timer A Capture/Compare Control 1 */
509
#define TACCTL2_               TA0CCTL2_      /* Timer A Capture/Compare Control 2 */
510
#define TAR_                   TA0R_          /* Timer A */
511
#define TACCR0_                TA0CCR0_       /* Timer A Capture/Compare 0 */
512
#define TACCR1_                TA0CCR1_       /* Timer A Capture/Compare 1 */
513
#define TACCR2_                TA0CCR2_       /* Timer A Capture/Compare 2 */
514
 
515
/* Alternate register names 2 */
516
#define CCTL0                  TACCTL0        /* Timer A Capture/Compare Control 0 */
517
#define CCTL1                  TACCTL1        /* Timer A Capture/Compare Control 1 */
518
#define CCTL2                  TACCTL2        /* Timer A Capture/Compare Control 2 */
519
#define CCR0                   TACCR0         /* Timer A Capture/Compare 0 */
520
#define CCR1                   TACCR1         /* Timer A Capture/Compare 1 */
521
#define CCR2                   TACCR2         /* Timer A Capture/Compare 2 */
522
#define CCTL0_                 TACCTL0_       /* Timer A Capture/Compare Control 0 */
523
#define CCTL1_                 TACCTL1_       /* Timer A Capture/Compare Control 1 */
524
#define CCTL2_                 TACCTL2_       /* Timer A Capture/Compare Control 2 */
525
#define CCR0_                  TACCR0_        /* Timer A Capture/Compare 0 */
526
#define CCR1_                  TACCR1_        /* Timer A Capture/Compare 1 */
527
#define CCR2_                  TACCR2_        /* Timer A Capture/Compare 2 */
528
 
529
#define TASSEL1                (0x0200)       /* Timer A clock source select 0 */
530
#define TASSEL0                (0x0100)       /* Timer A clock source select 1 */
531
#define ID1                    (0x0080)       /* Timer A clock input divider 1 */
532
#define ID0                    (0x0040)       /* Timer A clock input divider 0 */
533
#define MC1                    (0x0020)       /* Timer A mode control 1 */
534
#define MC0                    (0x0010)       /* Timer A mode control 0 */
535
#define TACLR                  (0x0004)       /* Timer A counter clear */
536
#define TAIE                   (0x0002)       /* Timer A counter interrupt enable */
537
#define TAIFG                  (0x0001)       /* Timer A counter interrupt flag */
538
 
539
#define MC_0                   (0*0x10u)      /* Timer A mode control: 0 - Stop */
540
#define MC_1                   (1*0x10u)      /* Timer A mode control: 1 - Up to CCR0 */
541
#define MC_2                   (2*0x10u)      /* Timer A mode control: 2 - Continous up */
542
#define MC_3                   (3*0x10u)      /* Timer A mode control: 3 - Up/Down */
543
#define ID_0                   (0*0x40u)      /* Timer A input divider: 0 - /1 */
544
#define ID_1                   (1*0x40u)      /* Timer A input divider: 1 - /2 */
545
#define ID_2                   (2*0x40u)      /* Timer A input divider: 2 - /4 */
546
#define ID_3                   (3*0x40u)      /* Timer A input divider: 3 - /8 */
547
#define TASSEL_0               (0*0x100u)     /* Timer A clock source select: 0 - TACLK */
548
#define TASSEL_1               (1*0x100u)     /* Timer A clock source select: 1 - ACLK  */
549
#define TASSEL_2               (2*0x100u)     /* Timer A clock source select: 2 - SMCLK */
550
#define TASSEL_3               (3*0x100u)     /* Timer A clock source select: 3 - INCLK */
551
 
552
#define CM1                    (0x8000)       /* Capture mode 1 */
553
#define CM0                    (0x4000)       /* Capture mode 0 */
554
#define CCIS1                  (0x2000)       /* Capture input select 1 */
555
#define CCIS0                  (0x1000)       /* Capture input select 0 */
556
#define SCS                    (0x0800)       /* Capture sychronize */
557
#define SCCI                   (0x0400)       /* Latched capture signal (read) */
558
#define CAP                    (0x0100)       /* Capture mode: 1 /Compare mode : 0 */
559
#define OUTMOD2                (0x0080)       /* Output mode 2 */
560
#define OUTMOD1                (0x0040)       /* Output mode 1 */
561
#define OUTMOD0                (0x0020)       /* Output mode 0 */
562
#define CCIE                   (0x0010)       /* Capture/compare interrupt enable */
563
#define CCI                    (0x0008)       /* Capture input signal (read) */
564
#define OUT                    (0x0004)       /* PWM Output signal if output mode 0 */
565
#define COV                    (0x0002)       /* Capture/compare overflow flag */
566
#define CCIFG                  (0x0001)       /* Capture/compare interrupt flag */
567
 
568
#define OUTMOD_0               (0*0x20u)      /* PWM output mode: 0 - output only */
569
#define OUTMOD_1               (1*0x20u)      /* PWM output mode: 1 - set */
570
#define OUTMOD_2               (2*0x20u)      /* PWM output mode: 2 - PWM toggle/reset */
571
#define OUTMOD_3               (3*0x20u)      /* PWM output mode: 3 - PWM set/reset */
572
#define OUTMOD_4               (4*0x20u)      /* PWM output mode: 4 - toggle */
573
#define OUTMOD_5               (5*0x20u)      /* PWM output mode: 5 - Reset */
574
#define OUTMOD_6               (6*0x20u)      /* PWM output mode: 6 - PWM toggle/set */
575
#define OUTMOD_7               (7*0x20u)      /* PWM output mode: 7 - PWM reset/set */
576
#define CCIS_0                 (0*0x1000u)    /* Capture input select: 0 - CCIxA */
577
#define CCIS_1                 (1*0x1000u)    /* Capture input select: 1 - CCIxB */
578
#define CCIS_2                 (2*0x1000u)    /* Capture input select: 2 - GND */
579
#define CCIS_3                 (3*0x1000u)    /* Capture input select: 3 - Vcc */
580
#define CM_0                   (0*0x4000u)    /* Capture mode: 0 - disabled */
581
#define CM_1                   (1*0x4000u)    /* Capture mode: 1 - pos. edge */
582
#define CM_2                   (2*0x4000u)    /* Capture mode: 1 - neg. edge */
583
#define CM_3                   (3*0x4000u)    /* Capture mode: 1 - both edges */
584
 
585
/* T0_A3IV Definitions */
586
#define TA0IV_NONE             (0x0000)       /* No Interrupt pending */
587
#define TA0IV_TACCR1           (0x0002)       /* TA0CCR1_CCIFG */
588
#define TA0IV_TACCR2           (0x0004)       /* TA0CCR2_CCIFG */
589
#define TA0IV_6                (0x0006)       /* Reserved */
590
#define TA0IV_8                (0x0008)       /* Reserved */
591
#define TA0IV_TAIFG            (0x000A)       /* TA0IFG */
592
 
593
/************************************************************
594
* Timer1_A5
595
************************************************************/
596
#define __MSP430_HAS_T1A5__                   /* Definition to show that Module is available */
597
 
598
SFR_16BIT(TA1IV);                             /* Timer1_A5 Interrupt Vector Word */
599
SFR_16BIT(TA1CTL);                            /* Timer1_A5 Control */
600
SFR_16BIT(TA1CCTL0);                          /* Timer1_A5 Capture/Compare Control 0 */
601
SFR_16BIT(TA1CCTL1);                          /* Timer1_A5 Capture/Compare Control 1 */
602
SFR_16BIT(TA1CCTL2);                          /* Timer1_A5 Capture/Compare Control 2 */
603
SFR_16BIT(TA1CCTL3);                          /* Timer1_A5 Capture/Compare Control 3 */
604
SFR_16BIT(TA1CCTL4);                          /* Timer1_A5 Capture/Compare Control 4 */
605
SFR_16BIT(TA1R);                              /* Timer1_A5 */
606
SFR_16BIT(TA1CCR0);                           /* Timer1_A5 Capture/Compare 0 */
607
SFR_16BIT(TA1CCR1);                           /* Timer1_A5 Capture/Compare 1 */
608
SFR_16BIT(TA1CCR2);                           /* Timer1_A5 Capture/Compare 2 */
609
SFR_16BIT(TA1CCR3);                           /* Timer1_A5 Capture/Compare 3 */
610
SFR_16BIT(TA1CCR4);                           /* Timer1_A5 Capture/Compare 4 */
611
 
612
/* Bits are already defined within the Timer0_Ax */
613
 
614
/* T1_A5IV Definitions */
615
#define TA1IV_NONE             (0x0000)       /* No Interrupt pending */
616
#define TA1IV_TACCR1           (0x0002)       /* TA1CCR1_CCIFG */
617
#define TA1IV_TACCR2           (0x0004)       /* TA1CCR2_CCIFG */
618
#define TA1IV_TACCR3           (0x0006)       /* TA1CCR3_CCIFG */
619
#define TA1IV_TACCR4           (0x0008)       /* TA1CCR4_CCIFG */
620
#define TA1IV_TAIFG            (0x000A)       /* TA1IFG */
621
 
622
/*************************************************************
623
* Flash Memory
624
*************************************************************/
625
#define __MSP430_HAS_FLASH__                  /* Definition to show that Module is available */
626
 
627
SFR_16BIT(FCTL1);                             /* FLASH Control 1 */
628
SFR_16BIT(FCTL2);                             /* FLASH Control 2 */
629
SFR_16BIT(FCTL3);                             /* FLASH Control 3 */
630
 
631
#define FRKEY                  (0x9600)       /* Flash key returned by read */
632
#define FWKEY                  (0xA500)       /* Flash key for write */
633
#define FXKEY                  (0x3300)       /* for use with XOR instruction */
634
 
635
#define ERASE                  (0x0002)       /* Enable bit for Flash segment erase */
636
#define MERAS                  (0x0004)       /* Enable bit for Flash mass erase */
637
#define WRT                    (0x0040)       /* Enable bit for Flash write */
638
#define BLKWRT                 (0x0080)       /* Enable bit for Flash segment write */
639
#define SEGWRT                 (0x0080)       /* old definition */ /* Enable bit for Flash segment write */
640
 
641
#define FN0                    (0x0001)       /* Divide Flash clock by 1 to 64 using FN0 to FN5 according to: */
642
#define FN1                    (0x0002)       /*  32*FN5 + 16*FN4 + 8*FN3 + 4*FN2 + 2*FN1 + FN0 + 1 */
643
#ifndef FN2
644
#define FN2                    (0x0004)
645
#endif
646
#ifndef FN3
647
#define FN3                    (0x0008)
648
#endif
649
#ifndef FN4
650
#define FN4                    (0x0010)
651
#endif
652
#define FN5                    (0x0020)
653
#define FSSEL0                 (0x0040)       /* Flash clock select 0 */        /* to distinguish from USART SSELx */
654
#define FSSEL1                 (0x0080)       /* Flash clock select 1 */
655
 
656
#define FSSEL_0                (0x0000)       /* Flash clock select: 0 - ACLK */
657
#define FSSEL_1                (0x0040)       /* Flash clock select: 1 - MCLK */
658
#define FSSEL_2                (0x0080)       /* Flash clock select: 2 - SMCLK */
659
#define FSSEL_3                (0x00C0)       /* Flash clock select: 3 - SMCLK */
660
 
661
#define BUSY                   (0x0001)       /* Flash busy: 1 */
662
#define KEYV                   (0x0002)       /* Flash Key violation flag */
663
#define ACCVIFG                (0x0004)       /* Flash Access violation flag */
664
#define WAIT                   (0x0008)       /* Wait flag for segment write */
665
#define LOCK                   (0x0010)       /* Lock bit: 1 - Flash is locked (read only) */
666
#define EMEX                   (0x0020)       /* Flash Emergency Exit */
667
 
668
/************************************************************
669
* Comparator A
670
************************************************************/
671
#define __MSP430_HAS_COMPA__                  /* Definition to show that Module is available */
672
 
673
SFR_8BIT(CACTL1);                             /* Comparator A Control 1 */
674
SFR_8BIT(CACTL2);                             /* Comparator A Control 2 */
675
SFR_8BIT(CAPD);                               /* Comparator A Port Disable */
676
 
677
#define CAIFG                  (0x01)         /* Comp. A Interrupt Flag */
678
#define CAIE                   (0x02)         /* Comp. A Interrupt Enable */
679
#define CAIES                  (0x04)         /* Comp. A Int. Edge Select: 0:rising / 1:falling */
680
#define CAON                   (0x08)         /* Comp. A enable */
681
#define CAREF0                 (0x10)         /* Comp. A Internal Reference Select 0 */
682
#define CAREF1                 (0x20)         /* Comp. A Internal Reference Select 1 */
683
#define CARSEL                 (0x40)         /* Comp. A Internal Reference Enable */
684
#define CAEX                   (0x80)         /* Comp. A Exchange Inputs */
685
 
686
#define CAREF_0                (0x00)         /* Comp. A Int. Ref. Select 0 : Off */
687
#define CAREF_1                (0x10)         /* Comp. A Int. Ref. Select 1 : 0.25*Vcc */
688
#define CAREF_2                (0x20)         /* Comp. A Int. Ref. Select 2 : 0.5*Vcc */
689
#define CAREF_3                (0x30)         /* Comp. A Int. Ref. Select 3 : Vt*/
690
 
691
#define CAOUT                  (0x01)         /* Comp. A Output */
692
#define CAF                    (0x02)         /* Comp. A Enable Output Filter */
693
#define P2CA0                  (0x04)         /* Comp. A Connect External Signal to CA0 : 1 */
694
#define P2CA1                  (0x08)         /* Comp. A Connect External Signal to CA1 : 1 */
695
#define CACTL24                (0x10)
696
#define CACTL25                (0x20)
697
#define CACTL26                (0x40)
698
#define CACTL27                (0x80)
699
 
700
#define CAPD0                  (0x01)         /* Comp. A Disable Input Buffer of Port Register .0 */
701
#define CAPD1                  (0x02)         /* Comp. A Disable Input Buffer of Port Register .1 */
702
#define CAPD2                  (0x04)         /* Comp. A Disable Input Buffer of Port Register .2 */
703
#define CAPD3                  (0x08)         /* Comp. A Disable Input Buffer of Port Register .3 */
704
#define CAPD4                  (0x10)         /* Comp. A Disable Input Buffer of Port Register .4 */
705
#define CAPD5                  (0x20)         /* Comp. A Disable Input Buffer of Port Register .5 */
706
#define CAPD6                  (0x40)         /* Comp. A Disable Input Buffer of Port Register .6 */
707
#define CAPD7                  (0x80)         /* Comp. A Disable Input Buffer of Port Register .7 */
708
 
709
/************************************************************
710
* Interrupt Vectors (offset from 0xFFE0)
711
************************************************************/
712
 
713
#define VECTOR_NAME(name)       name##_ptr
714
#define EMIT_PRAGMA(x)          _Pragma(#x)
715
#define CREATE_VECTOR(name)     void (* const VECTOR_NAME(name))(void) = &name
716
#define PLACE_VECTOR(vector,section) EMIT_PRAGMA(DATA_SECTION(vector,section))
717
#define ISR_VECTOR(func,offset) CREATE_VECTOR(func); \
718
                                PLACE_VECTOR(VECTOR_NAME(func), offset)
719
 
720
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
721
#define BASICTIMER_VECTOR       ".int00"                    /* 0xFFE0 Basic Timer */
722
#else
723
#define BASICTIMER_VECTOR       (0 * 1u)                     /* 0xFFE0 Basic Timer */
724
/*#define BASICTIMER_ISR(func)    ISR_VECTOR(func, ".int00")  */ /* 0xFFE0 Basic Timer */ /* CCE V2 Style */
725
#endif
726
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
727
#define PORT2_VECTOR            ".int01"                    /* 0xFFE2 Port 2 */
728
#else
729
#define PORT2_VECTOR            (1 * 1u)                     /* 0xFFE2 Port 2 */
730
/*#define PORT2_ISR(func)         ISR_VECTOR(func, ".int01")  */ /* 0xFFE2 Port 2 */ /* CCE V2 Style */
731
#endif
732
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
733
#define PORT1_VECTOR            ".int04"                    /* 0xFFE8 Port 1 */
734
#else
735
#define PORT1_VECTOR            (4 * 1u)                     /* 0xFFE8 Port 1 */
736
/*#define PORT1_ISR(func)         ISR_VECTOR(func, ".int04")  */ /* 0xFFE8 Port 1 */ /* CCE V2 Style */
737
#endif
738
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
739
#define TIMER0_A1_VECTOR        ".int05"                    /* 0xFFEA Timer0_A CC1-2, TA0 */
740
#else
741
#define TIMER0_A1_VECTOR        (5 * 1u)                     /* 0xFFEA Timer0_A CC1-2, TA0 */
742
/*#define TIMER0_A1_ISR(func)     ISR_VECTOR(func, ".int05")  */ /* 0xFFEA Timer0_A CC1-2, TA0 */ /* CCE V2 Style */
743
#endif
744
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
745
#define TIMER0_A0_VECTOR        ".int06"                    /* 0xFFEC Timer0_A CC0 */
746
#else
747
#define TIMER0_A0_VECTOR        (6 * 1u)                     /* 0xFFEC Timer0_A CC0 */
748
/*#define TIMER0_A0_ISR(func)     ISR_VECTOR(func, ".int06")  */ /* 0xFFEC Timer0_A CC0 */ /* CCE V2 Style */
749
#endif
750
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
751
#define WDT_VECTOR              ".int10"                    /* 0xFFF4 Watchdog Timer */
752
#else
753
#define WDT_VECTOR              (10 * 1u)                    /* 0xFFF4 Watchdog Timer */
754
/*#define WDT_ISR(func)           ISR_VECTOR(func, ".int10")  */ /* 0xFFF4 Watchdog Timer */ /* CCE V2 Style */
755
#endif
756
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
757
#define COMPARATORA_VECTOR      ".int11"                    /* 0xFFF6 Comparator A */
758
#else
759
#define COMPARATORA_VECTOR      (11 * 1u)                    /* 0xFFF6 Comparator A */
760
/*#define COMPARATORA_ISR(func)   ISR_VECTOR(func, ".int11")  */ /* 0xFFF6 Comparator A */ /* CCE V2 Style */
761
#endif
762
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
763
#define TIMER1_A1_VECTOR        ".int12"                    /* 0xFFF8 Timer1_A CC1-4, TA1 */
764
#else
765
#define TIMER1_A1_VECTOR        (12 * 1u)                    /* 0xFFF8 Timer1_A CC1-4, TA1 */
766
/*#define TIMER1_A1_ISR(func)     ISR_VECTOR(func, ".int12")  */ /* 0xFFF8 Timer1_A CC1-4, TA1 */ /* CCE V2 Style */
767
#endif
768
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
769
#define TIMER1_A0_VECTOR        ".int13"                    /* 0xFFFA Timer1_A CC0 */
770
#else
771
#define TIMER1_A0_VECTOR        (13 * 1u)                    /* 0xFFFA Timer1_A CC0 */
772
/*#define TIMER1_A0_ISR(func)     ISR_VECTOR(func, ".int13")  */ /* 0xFFFA Timer1_A CC0 */ /* CCE V2 Style */
773
#endif
774
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
775
#define NMI_VECTOR              ".int14"                    /* 0xFFFC Non-maskable */
776
#else
777
#define NMI_VECTOR              (14 * 1u)                    /* 0xFFFC Non-maskable */
778
/*#define NMI_ISR(func)           ISR_VECTOR(func, ".int14")  */ /* 0xFFFC Non-maskable */ /* CCE V2 Style */
779
#endif
780
#ifdef __ASM_HEADER__ /* Begin #defines for assembler */
781
#define RESET_VECTOR            ".reset"                    /* 0xFFFE Reset [Highest Priority] */
782
#else
783
#define RESET_VECTOR            (15 * 1u)                    /* 0xFFFE Reset [Highest Priority] */
784
/*#define RESET_ISR(func)         ISR_VECTOR(func, ".int15")  */ /* 0xFFFE Reset [Highest Priority] */ /* CCE V2 Style */
785
#endif
786
 
787
/* Alternate Names */
788
 
789
/************************************************************
790
* End of Modules
791
************************************************************/
792
 
793
#ifdef __cplusplus
794
}
795
#endif /* extern "C" */
796
 
797
#endif /* #ifndef __msp430x41x */
798