TI RSLK Library  0.2.0
RSLK_Pins.h
Go to the documentation of this file.
1 
3 #ifndef RSLKPins_h
4 #define RSLKPins_h
5 
6 #if defined(USING_RSLK_CLASSIC)
7  /* QTR-8RC Reflectance Sensor Array Pins (https://www.pololu.com/product/961)
8  * Below shows how the line sensor pins are mapped to the MSP-EXP432P401R */
9 
10  #define TOTAL_LINE_SENSORS 8
11  #define QTR_EMITTER_PIN 61 // <- Energia Pin # Launchpad Pin -> P5.3
12  #define QTR_0 65 // <- Energia Pin # Launchpad Pin -> P7.0
13  #define QTR_1 48 // <- Energia Pin # Launchpad Pin -> P7.1
14  #define QTR_2 64 // <- Energia Pin # Launchpad Pin -> P7.2
15  #define QTR_3 47 // <- Energia Pin # Launchpad Pin -> P7.3
16  #define QTR_4 52 // <- Energia Pin # Launchpad Pin -> P7.4
17  #define QTR_5 68 // <- Energia Pin # Launchpad Pin -> P7.5
18  #define QTR_6 53 // <- Energia Pin # Launchpad Pin -> P7.6
19  #define QTR_7 69 // <- Energia Pin # Launchpad Pin -> P7.7
20 
21  /* Pololu Snap-Action Switches (https://www.pololu.com/product/1404)
22  * Robot utilizes 6 of these switches.
23  * Switches' common pin is connected to ground.
24  * NO (normally open) is connected to Launchpad
25  */
26  #define TOTAL_BP_SWITCHES 6
27  #define BP_SW_PIN_0 51 // <- Energia Pin # Launchpad Pin -> P8.0
28  #define BP_SW_PIN_1 60 // <- Energia Pin # Launchpad Pin -> P8.3
29  #define BP_SW_PIN_2 43 // <- Energia Pin # Launchpad Pin -> P8.4
30  #define BP_SW_PIN_3 41 // <- Energia Pin # Launchpad Pin -> P8.5
31  #define BP_SW_PIN_4 57 // <- Energia Pin # Launchpad Pin -> P8.6
32  #define BP_SW_PIN_5 58 // <- Energia Pin # Launchpad Pin -> P8.7
33 
34  /* Motor Driver and Power Distribution Board (https://www.pololu.com/product/3543)
35  * Pin configuration for the left and right motor's sleep, direction and pwm pin
36  */
37  #define MOTOR_L_SLP_PIN 24 // <- Energia Pin # Launchpad Pin -> P4.0
38  #define MOTOR_L_DIR_PIN 25 // <- Energia Pin # Launchpad Pin -> P4.2
39  #define MOTOR_L_PWM_PIN 11 // <- Energia Pin # Launchpad Pin -> P3.6
40  #define MOTOR_R_SLP_PIN 26 // <- Energia Pin # Launchpad Pin -> P4.4
41  #define MOTOR_R_DIR_PIN 27 // <- Energia Pin # Launchpad Pin -> P4.5
42  #define MOTOR_R_PWM_PIN 35 // <- Energia Pin # Launchpad Pin -> P6.4
43 
44  /* Sharp GP2Y0A21YK0F Analog Distance Sensor (https://www.pololu.com/product/136)
45  * Robot utilizes three of these sensors
46  */
47  #define SHRP_DIST_L_PIN 59 // <- Energia Pin # Launchpad Pin -> P9.1
48  #define SHRP_DIST_C_PIN 23 // <- Energia Pin # Launchpad Pin -> P6.1
49  #define SHRP_DIST_R_PIN 42 // <- Energia Pin # Launchpad Pin -> P9.0
50 
51  /* Romi Encoder Pair Kit, 12 CPR, 3.5-18V (https://www.pololu.com/product/3542)
52  * Robot utilizes two encoders. One for the left wheel and one for the right wheel
53  */
54  #define ENCODER_ERA_PIN 10 // <- Energia Pin # Launchpad Pin -> P6.4
55  #define ENCODER_ERB_PIN 30 // <- Energia Pin # Launchpad Pin -> P5.5
56  #define ENCODER_ELA_PIN 17 // <- Energia Pin # Launchpad Pin -> P5.7
57  #define ENCODER_ELB_PIN 38 // <- Energia Pin # Launchpad Pin -> P2.4
58 
59 #else
60  /* QTR-8RC Reflectance Sensor Array Pins (https://www.pololu.com/product/961)
61  * Below shows how the line sensor pins are mapped to the MSP-EXP432P401R */
65  #define QTR_0 65 // <- Energia Pin # Launchpad Pin -> P7.0
66 
69  #define QTR_1 48 // <- Energia Pin # Launchpad Pin -> P7.1
70 
73  #define QTR_2 64 // <- Energia Pin # Launchpad Pin -> P7.2
74 
77  #define QTR_3 47 // <- Energia Pin # Launchpad Pin -> P7.3
78 
81  #define QTR_4 52 // <- Energia Pin # Launchpad Pin -> P7.4
82 
85  #define QTR_5 68 // <- Energia Pin # Launchpad Pin -> P7.5
86 
89  #define QTR_6 53 // <- Energia Pin # Launchpad Pin -> P7.6
90 
93  #define QTR_7 69 // <- Energia Pin # Launchpad Pin -> P7.7
94 
97  #define QTR_EMITTER_PIN_EVEN 61 // <- Energia Pin # Launchpad Pin -> P5.3
98 
101  #define QTR_EMITTER_PIN_ODD 45 // <- Energia Pin # Launchpad Pin -> P9.2
102 
103  /* Pololu Snap-Action Switches (https://www.pololu.com/product/1404)
104  * Robot utilizes 6 of these switches.
105  * Switches' common pin is connected to ground.
106  * NO (normally open) is connected to Launchpad
107  */
111  #define BP_SW_PIN_0 24 // <- Energia Pin # Launchpad Pin -> P4.0
112 
115  #define BP_SW_PIN_1 25 // <- Energia Pin # Launchpad Pin -> P4.2
116 
119  #define BP_SW_PIN_2 6 // <- Energia Pin # Launchpad Pin -> P4.3
120 
123  #define BP_SW_PIN_3 27 // <- Energia Pin # Launchpad Pin -> P4.5
124 
127  #define BP_SW_PIN_4 8 // <- Energia Pin # Launchpad Pin -> P4.6
128 
132  #define BP_SW_PIN_5 28 // <- Energia Pin # Launchpad Pin -> P4.7
133 
134  /* Motor Driver and Power Distribution Board (https://www.pololu.com/product/3543)
135  * Pin configuration for the left and right motor's sleep, direction and pwm pin
136  */
137 
141  #define MOTOR_L_SLP_PIN 31 // <- Energia Pin # Launchpad Pin -> P3.7
142 
146  #define MOTOR_L_DIR_PIN 29 // <- Energia Pin # Launchpad Pin -> P5.4
147 
151  #define MOTOR_L_PWM_PIN 40 // <- Energia Pin # Launchpad Pin -> P2.7
152 
156  #define MOTOR_R_SLP_PIN 11 // <- Energia Pin # Launchpad Pin -> P3.6
157 
160  #define MOTOR_R_DIR_PIN 30 // <- Energia Pin # Launchpad Pin -> P5.5
161 
165  #define MOTOR_R_PWM_PIN 39 // <- Energia Pin # Launchpad Pin -> P.2.6
166 
167  /* Sharp GP2Y0A21YK0F Analog Distance Sensor (https://www.pololu.com/product/136)
168  * Robot utilizes three of these sensors
169  */
170 
174  #define SHRP_DIST_L_PIN 59 // <- Energia Pin # Launchpad Pin -> P9.1
175 
178  #define SHRP_DIST_C_PIN 23 // <- Energia Pin # Launchpad Pin -> P6.1
179 
182  #define SHRP_DIST_R_PIN 42 // <- Energia Pin # Launchpad Pin -> P9.0
183 
184  /* Romi Encoder Pair Kit, 12 CPR, 3.5-18V (https://www.pololu.com/product/3542)
185  * Robot utilizes two encoders. One for the left wheel and one for the right wheel
186  */
190  #define ENCODER_ELB_PIN 12 // <- Energia Pin # Launchpad Pin -> P5.2
191 
194  #define ENCODER_ERB_PIN 13 // <- Energia Pin # Launchpad Pin -> P5.0
195 
198  #define ENCODER_ELA_PIN 72 // <- Energia Pin # Launchpad Pin -> P10.5
199 
202  #define ENCODER_ERA_PIN 56 // <- Energia Pin # Launchpad Pin -> P10.4
203 
207  #define SRV_0 38 // <- Energia Pin # Launchpad Pin -> P2.4
208 
212  #define SRV_1 32 // <- Energia Pin # Launchpad Pin -> P3.5
213 
217  #define SRV_2 17 // <- Energia Pin # Launchpad Pin -> P5.7
218 
222  #define SRV_FB0 43 // <- Energia Pin # Launchpad Pin -> P8.4
223 
227  #define SRV_FB1 60 // <- Energia Pin # Launchpad Pin -> P8.3
228 
231  #define SRV_FB2 44 // <- Energia Pin # Launchpad Pin -> P8.2
232 
236  #define LCD_SCLK 66 // <- Energia Pin # Launchpad Pin -> P9.5
237 
240  #define LCD_MOSI 67 // <- Energia Pin # Launchpad Pin -> P9.7
241 
244  #define LCD_RST 62 // <- Energia Pin # Launchpad Pin -> P9.3
245 
248  #define LCD_CS 49 // <- Energia Pin # Launchpad Pin -> P9.4
249 
252  #define LCD_DC 50 // <- Energia Pin # Launchpad Pin -> P9.6
253 
254 #endif
255 
256 #endif