Difference between revisions of "TSC2102 Linux driver"
From ArmadeusWiki
Line 10: | Line 10: | ||
in 'device driver/hardware monitoring support' select 'hardware monitoring support' as module | in 'device driver/hardware monitoring support' select 'hardware monitoring support' as module | ||
− | + | install the touchscreen API <strong>[[tslib]]</strong> | |
==Architecture== | ==Architecture== | ||
Line 25: | Line 25: | ||
==Usage== | ==Usage== | ||
− | + | start the drivers: | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
# insmod /lib/modules/drivers/hwmon/hwmon.ko | # insmod /lib/modules/drivers/hwmon/hwmon.ko | ||
# insmod /lib/modules/drivers/spi/spi_imx.ko | # insmod /lib/modules/drivers/spi/spi_imx.ko |
Revision as of 16:11, 17 November 2007
Installation
$ make linux-menuconfig
in 'device driver/input device support' select 'event interface' as kernel part in 'device driver/input device support' select 'touchscreen ->tsc2102' as module
in 'device driver/spi support' select 'spi support ->freescale iMX spi' as module in 'device driver/spi support' select 'spi support ->TSC2102 codec' as module
in 'device driver/hardware monitoring support' select 'hardware monitoring support' as module
install the touchscreen API tslib
Architecture
Touchscreen (tsc2102_ts.ko) | HWmon | ALSA |
---|---|---|
TSC2102 Main driver (tsc2102.ko) | ||
Linux API |
Usage
start the drivers:
# insmod /lib/modules/drivers/hwmon/hwmon.ko # insmod /lib/modules/drivers/spi/spi_imx.ko # insmod /lib/modules/drivers/spi/tsc2102.ko # insmod /lib/modules/drivers/input/touchscreen/tsc2102_ts.ko
Then:
- get temperature and voltage with hwmon (Hardware Monitoring) interface
cat /sys/class/hwmon/hwmon0/device/in0_input
- play sounds through ALSA interface
Quick test
To quickly check driver fonctionnality, touch the screen and check that tsc2102 interrupts count is increasing:
# cat /proc/interrupts CPU0 26: 0 MPU IMX-uart 29: 17 MPU IMX-uart 30: 22 MPU IMX-uart 35: 12 MPU imx-mmc 39: 14 MPU I2C_IMX 40: 16 MPU imx-spi.2 41: 0 MPU imx-spi.1 59: 3682 MPU i.MX Timer Tick 60: 0 MPU DMA 61: 0 MPU DMA 110: 0 GPIO eth0 168: 0 GPIO tsc2102 Err: 0 #
Links
- http://source.mvista.com/git/gitweb.cgi?p=linux-omap-2.6.git;a=log;t=7 (search for TSC2102)
- http://osdir.com/ml/linux.ports.arm.omap/2006-08/msg00183.html
- Touchscreen usage on Blackfin
- Compiling TSlib
- http://www.opentom.org/Tslib
- http://www.openembedded.org/filebrowser/org.openembedded.packaged-staging/packages/tslib