summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Kurbjun <kkurbjun@gmail.com>2009-12-14 07:18:55 +0000
committerKarl Kurbjun <kkurbjun@gmail.com>2009-12-14 07:18:55 +0000
commit2b57fc434c4adfa996712e9d88779c9ccb0ecfab (patch)
tree9c0f71884520aae3ff386471cb145c98d3a5a096
parent86dd88c86e56d6ff92b311cdc1ce8f2047dd6425 (diff)
downloadrockbox-2b57fc434c4adfa996712e9d88779c9ccb0ecfab.tar.gz
rockbox-2b57fc434c4adfa996712e9d88779c9ccb0ecfab.zip
M:Robe 500: Initialize TSC2100 pins with pin setup function
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23989 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--firmware/target/arm/tms320dm320/mrobe-500/adc-mr500.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/firmware/target/arm/tms320dm320/mrobe-500/adc-mr500.c b/firmware/target/arm/tms320dm320/mrobe-500/adc-mr500.c
index 2acce7a695..11153f10d0 100644
--- a/firmware/target/arm/tms320dm320/mrobe-500/adc-mr500.c
+++ b/firmware/target/arm/tms320dm320/mrobe-500/adc-mr500.c
@@ -24,6 +24,7 @@
24#include "adc-target.h" 24#include "adc-target.h"
25#include "kernel.h" 25#include "kernel.h"
26#include "tsc2100.h" 26#include "tsc2100.h"
27#include "system-target.h"
27#include "button-target.h" 28#include "button-target.h"
28 29
29void adc_init(void) 30void adc_init(void)
@@ -32,10 +33,16 @@ void adc_init(void)
32 * touchscreen does not work, audio has not been tested, but it is 33 * touchscreen does not work, audio has not been tested, but it is
33 * expected that is will also not work when low. 34 * expected that is will also not work when low.
34 */ 35 */
35 IO_GIO_DIR0 &= ~(1<<15); /* output */ 36
36 IO_GIO_INV0 &= ~(1<<15); /* non-inverted */ 37 /* Setup touchscreen (tsc2100) pins:
37 IO_GIO_FSEL0 &= ~(0x03<<12); /* normal pin */ 38 * 14 - input, touchscreen irq
38 IO_GIO_BITSET0 = (1<<15); 39 * 15 - output, touchscreen nPWD? */
40 /* 14: input , non-inverted, irq, falling edge, no-chat, normal */
41 dm320_set_io(14, true, false, true, false, false, 0x00);
42
43 /* 15: output, non-inverted, no-irq, falling edge, no-chat, normal */
44 dm320_set_io(15, false, false, false, false, false, 0x00);
45 IO_GIO_BITSET0 = (1<<15); /* Turn on TSC2100 */
39 46
40 /* Initialize the touchscreen and the battery readout */ 47 /* Initialize the touchscreen and the battery readout */
41 tsc2100_adc_init(); 48 tsc2100_adc_init();