mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-12 14:42:31 -05:00
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
This commit is contained in:
parent
86dd88c86e
commit
2b57fc434c
1 changed files with 11 additions and 4 deletions
|
|
@ -24,6 +24,7 @@
|
||||||
#include "adc-target.h"
|
#include "adc-target.h"
|
||||||
#include "kernel.h"
|
#include "kernel.h"
|
||||||
#include "tsc2100.h"
|
#include "tsc2100.h"
|
||||||
|
#include "system-target.h"
|
||||||
#include "button-target.h"
|
#include "button-target.h"
|
||||||
|
|
||||||
void adc_init(void)
|
void adc_init(void)
|
||||||
|
|
@ -32,10 +33,16 @@ void adc_init(void)
|
||||||
* touchscreen does not work, audio has not been tested, but it is
|
* touchscreen does not work, audio has not been tested, but it is
|
||||||
* expected that is will also not work when low.
|
* expected that is will also not work when low.
|
||||||
*/
|
*/
|
||||||
IO_GIO_DIR0 &= ~(1<<15); /* output */
|
|
||||||
IO_GIO_INV0 &= ~(1<<15); /* non-inverted */
|
/* Setup touchscreen (tsc2100) pins:
|
||||||
IO_GIO_FSEL0 &= ~(0x03<<12); /* normal pin */
|
* 14 - input, touchscreen irq
|
||||||
IO_GIO_BITSET0 = (1<<15);
|
* 15 - output, touchscreen nPWD? */
|
||||||
|
/* 14: input , non-inverted, irq, falling edge, no-chat, normal */
|
||||||
|
dm320_set_io(14, true, false, true, false, false, 0x00);
|
||||||
|
|
||||||
|
/* 15: output, non-inverted, no-irq, falling edge, no-chat, normal */
|
||||||
|
dm320_set_io(15, false, false, false, false, false, 0x00);
|
||||||
|
IO_GIO_BITSET0 = (1<<15); /* Turn on TSC2100 */
|
||||||
|
|
||||||
/* Initialize the touchscreen and the battery readout */
|
/* Initialize the touchscreen and the battery readout */
|
||||||
tsc2100_adc_init();
|
tsc2100_adc_init();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue