Proper I/O ports with new firmware.
[goodfet] / firmware / platforms / telosb.h
1 /*! \file telosb.h
2   \author Travis Goodspeed
3   \brief Port descriptions for the TelosB platform.
4   
5   This file defines the Telos B hardware, so that the GoodFET firmware
6   may be loaded onto it.  Adjustments include the !CS line of the CC2420
7   radio, the choice of serial port, and the LEDs.
8
9 */
10
11 #ifdef MSP430
12 #include <io.h>
13 #endif
14
15
16 //LED on P1.0
17 #define PLEDOUT P5OUT
18 #define PLEDDIR P5DIR
19 #define PLEDPIN BIT4
20
21
22 //Radio CS is P4.2
23 #define SETSS P4OUT|=BIT2
24 #define CLRSS P4OUT&=~BIT2
25 #define DIRSS P4DIR|=BIT2;
26
27
28 //CC2420 Chip Reset.  Need to document this.
29 #define SETCE P4OUT|=BIT6
30 #define CLRCE P4OUT&=~BIT6
31 #define DIRCE P4DIR|=BIT6