2 * Copyright © 2010 Keith Packard <keithp@keithp.com>
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; version 2 of the License.
8 * This program is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 * General Public License for more details.
13 * You should have received a copy of the GNU General Public License along
14 * with this program; if not, write to the Free Software Foundation, Inc.,
15 * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
21 #if defined(TELEMETRUM_V_1_0)
26 #define HAS_SERIAL_1 1
28 #define USE_SERIAL_STDIN 0
30 #define USE_INTERNAL_FLASH 0
34 #define IGNITE_ON_P2 1
35 #define IGNITE_ON_P0 0
36 #define PACKET_HAS_MASTER 0
37 #define PACKET_HAS_SLAVE 1
40 #define LEDS_AVAILABLE (AO_LED_RED)
41 #define HAS_EXTERNAL_TEMP 0
42 #define HAS_ACCEL_REF 0
48 #if defined(TELEMETRUM_V_1_1)
53 #define HAS_SERIAL_1 1
54 #define USE_SERIAL_STDIN 0
57 #define USE_INTERNAL_FLASH 0
61 #define IGNITE_ON_P2 1
62 #define IGNITE_ON_P0 0
63 #define PACKET_HAS_MASTER 0
64 #define PACKET_HAS_SLAVE 1
67 #define LEDS_AVAILABLE (AO_LED_RED)
68 #define HAS_EXTERNAL_TEMP 0
69 #define HAS_ACCEL_REF 1
70 #define SPI_CS_ON_P1 1
71 #define SPI_CS_ON_P0 0
72 #define M25_CS_MASK 0x02 /* CS0 is P1_1 */
73 #define M25_MAX_CHIPS 1
79 #if defined(TELEDONGLE_V_0_2)
83 #define HAS_SERIAL_1 0
84 #define USE_SERIAL_STDIN 0
90 #define IGNITE_ON_P2 0
91 #define IGNITE_ON_P0 0
92 #define PACKET_HAS_MASTER 1
93 #define PACKET_HAS_SLAVE 0
95 #define AO_LED_GREEN 2
96 #define LEDS_AVAILABLE (AO_LED_RED|AO_LED_GREEN)
97 #define SPI_CS_ON_P1 1
98 #define SPI_CS_ON_P0 0
100 #define HAS_MONITOR 1
103 #if defined(TELEMINI_V_1_0)
108 #define HAS_SERIAL_1 0
109 #define USE_SERIAL_STDIN 0
112 #define USE_INTERNAL_FLASH 1
114 #define IGNITE_ON_P2 0
115 #define IGNITE_ON_P0 1
116 #define PACKET_HAS_MASTER 0
117 #define PACKET_HAS_SLAVE 1
118 #define USE_FAST_ASCENT_LOG 1
120 #define AO_LED_GREEN 1
122 #define LEDS_AVAILABLE (AO_LED_RED|AO_LED_GREEN)
123 #define HAS_EXTERNAL_TEMP 0
126 #define HAS_MONITOR 0
129 #if defined(TELENANO_V_0_1)
134 #define HAS_SERIAL_1 0
135 #define USE_SERIAL_STDIN 0
138 #define USE_INTERNAL_FLASH 1
140 #define IGNITE_ON_P2 0
141 #define IGNITE_ON_P0 1
142 #define PACKET_HAS_MASTER 0
143 #define PACKET_HAS_SLAVE 1
145 #define AO_LED_GREEN 1
147 #define LEDS_AVAILABLE (AO_LED_RED|AO_LED_GREEN)
148 #define HAS_EXTERNAL_TEMP 0
151 #define HAS_MONITOR 0
154 #if defined(TELEMETRUM_V_0_1)
159 #define HAS_SERIAL_1 1
160 #define USE_SERIAL_STDIN 0
164 #define USE_INTERNAL_FLASH 0
167 #define IGNITE_ON_P2 1
168 #define IGNITE_ON_P0 0
169 #define PACKET_HAS_MASTER 0
170 #define PACKET_HAS_SLAVE 1
172 #define AO_LED_GREEN 1
173 #define LEDS_AVAILABLE (AO_LED_RED|AO_LED_GREEN)
174 #define HAS_EXTERNAL_TEMP 1
175 #define HAS_ACCEL_REF 0
176 #define SPI_CS_ON_P1 1
177 #define SPI_CS_ON_P0 0
180 #define HAS_MONITOR 0
183 #if defined(TELEDONGLE_V_0_1)
187 #define HAS_SERIAL_1 0
188 #define USE_SERIAL_STDIN 0
194 #define IGNITE_ON_P2 0
195 #define IGNITE_ON_P0 0
196 #define PACKET_HAS_MASTER 1
197 #define PACKET_HAS_SLAVE 0
199 #define AO_LED_GREEN 1
200 #define LEDS_AVAILABLE (AO_LED_RED|AO_LED_GREEN)
201 #define SPI_CS_ON_P1 0
202 #define SPI_CS_ON_P0 1
204 #define HAS_MONITOR 1
207 #if defined(TIDONGLE)
211 #define HAS_SERIAL_1 0
212 #define USE_SERIAL_STDIN 0
218 #define IGNITE_ON_P2 0
219 #define IGNITE_ON_P0 0
220 #define PACKET_HAS_MASTER 1
221 #define PACKET_HAS_SLAVE 0
223 #define LEDS_AVAILABLE (AO_LED_RED)
224 #define SPI_CS_ON_P1 0
225 #define SPI_CS_ON_P0 1
227 #define HAS_MONITOR 1
230 #if defined(TELEBT_V_0_0)
234 #define HAS_SERIAL_1 1
235 #define USE_SERIAL_STDIN 1
242 #define IGNITE_ON_P2 0
243 #define IGNITE_ON_P0 0
244 #define PACKET_HAS_MASTER 1
245 #define PACKET_HAS_SLAVE 0
247 #define AO_LED_GREEN 1
248 #define LEDS_AVAILABLE (AO_LED_RED|AO_LED_GREEN)
249 #define SPI_CS_ON_P1 1
250 #define SPI_CS_ON_P0 0
252 #define BT_LINK_ON_P2 1
253 #define BT_LINK_ON_P1 0
254 #define BT_LINK_PIN_INDEX 7
255 #define BT_LINK_PIN P2_1
256 #define HAS_MONITOR 1
259 #if defined(TELEBT_V_0_1)
263 #define HAS_SERIAL_1 1
264 #define HAS_SERIAL_1_ALT_1 1
265 #define HAS_SERIAL_1_ALT_2 0
266 #define HAS_SERIAL_1_HW_FLOW 1
267 #define USE_SERIAL_STDIN 1
271 #define USE_INTERNAL_FLASH 0
275 #define IGNITE_ON_P2 0
276 #define IGNITE_ON_P0 0
277 #define PACKET_HAS_MASTER 1
278 #define PACKET_HAS_SLAVE 0
280 #define AO_LED_GREEN 2
281 #define LEDS_AVAILABLE (AO_LED_RED|AO_LED_GREEN)
282 #define SPI_CS_ON_P1 1
283 #define SPI_CS_ON_P0 0
284 #define M25_CS_MASK 0x04 /* CS0 is P1_2 */
285 #define M25_MAX_CHIPS 1
288 #define BT_LINK_ON_P2 0
289 #define BT_LINK_ON_P1 1
290 #define BT_LINK_PIN_INDEX 7
291 #define BT_LINK_PIN P1_7
292 #define HAS_MONITOR 1
297 #define DBG_CLOCK (1 << 4) /* mi0 */
298 #define DBG_DATA (1 << 5) /* mo0 */
299 #define DBG_RESET_N (1 << 3) /* c0 */
301 #define DBG_CLOCK_PIN (P1_4)
302 #define DBG_DATA_PIN (P1_5)
303 #define DBG_RESET_N_PIN (P1_3)
305 #define DBG_PORT_NUM 1
307 #define DBG_PORT_SEL P1SEL
308 #define DBG_PORT_INP P1INP
309 #define DBG_PORT_DIR P1DIR
311 #endif /* DBG_ON_P1 */
315 #define DBG_CLOCK (1 << 3)
316 #define DBG_DATA (1 << 4)
317 #define DBG_RESET_N (1 << 5)
319 #define DBG_CLOCK_PIN (P0_3)
320 #define DBG_DATA_PIN (P0_4)
321 #define DBG_RESET_N_PIN (P0_5)
323 #define DBG_PORT_NUM 0
325 #define DBG_PORT_SEL P0SEL
326 #define DBG_PORT_INP P0INP
327 #define DBG_PORT_DIR P0DIR
329 #endif /* DBG_ON_P0 */
332 #define SPI_CS_PORT P1
333 #define SPI_CS_SEL P1SEL
334 #define SPI_CS_DIR P1DIR
338 #define SPI_CS_PORT P0
339 #define SPI_CS_SEL P0SEL
340 #define SPI_CS_DIR P0DIR
344 #error Please define IGNITE_ON_P2
348 #error Please define IGNITE_ON_P0
352 #error Please define HAS_SERIAL_1
355 #ifndef USE_SERIAL_STDIN
356 #error Please define USE_SERIAL_STDIN
360 #error Please define HAS_ADC
364 #error Please define HAS_EEPROM
368 #ifndef USE_INTERNAL_FLASH
369 #error Please define USE_INTERNAL_FLASH
374 #error Please define HAS_DBG
378 #error Please define HAS_IGNITE
381 #ifndef PACKET_HAS_MASTER
382 #error Please define PACKET_HAS_MASTER
385 #ifndef PACKET_HAS_SLAVE
386 #error Please define PACKET_HAS_SLAVE
390 #error Please define HAS_MONITOR
392 #endif /* _AO_PINS_H_ */