[Mini210s] S700 capacitive screen under Linux

Screwface
Hi,

Did someone manage to get capacitive touchscreen working under Linux with
mini210s, I mean S700? The touchscreen driver is Goodix gt801. I tried to
understand why it works with Androïd and not Linux as the kernel is quite
the same (3.0.8). The thing I do not understand is located in the
drivers\input\touchscreen\Makefile file. At the end of this file, we can
see this lines bloc :

ifneq ($(wildcard drivers/input/touchscreen/goodix_touch.c),)
ifeq ($(FA),1)
obj-$(CONFIG_TOUCHSCREEN_GOODIX)  += goodix_touch.o
else
obj-m += goodix_touch.o
endif  #FA
endif

But I found no goodix_touch.c file in any directory. All that I found is
the *.h file.

¤ So I wonder how is the touchscreen working under Android as there no
driver source for the touchscreen (I found the file googling a bit, for
Android tablets mainly)

¤ What is different between Android and Linux which could explain
touchscreen is working for Android and not Linux?

Thanks for your explanations if any!

Screwface
I tried to use Android kernel which runs fine (touchscreen OK) in Debian
linux distro. No touchscreen then. Furthermore, there is also no sound and
no WiFi. I don't know why as zImage is the same!

If you have any suggestion, feel free

Tomasz Myrta
It seems the capacitive screen works only with Android. I wasn't also able
to find goodix_touch.c compatible with Linux kernel.

Reggie
did you look for the goodix_touch.so file in the android images?

or google for good_touch.c?

first link will find you the file.

https://bitbucket.org/paulobrien/android_kernel_andypad/src/4c6b4f4c48d1...

This looks like a reasonable resource too:

http://translate.google.co.uk/translate?hl=en&sl=zh-CN&u=http://...

for some reason I can't get to the www.goodix.com website directly.

Tomasz Myrta
I tried good_touch.c without success (incompatible with 2.6.35 kernel).

Quick investigation over kernel sources gave me:
1. You can find usage of "ctp" boot parameter in:
arch/arm/mach-s5pv210/mini210-lcds.c
2. i2c touchscreen types are enumerated in:
arch/arm/plat-samsung/include/plat/ctouch.h
however - "CTP_GT80X" value isn't used in any .c file.
3. i2c registers gt80x device, you can see it in dmesg:
i2c i2c-2: client [gt80x-ts] registered with bus id 2-0055.
4. "gt80x-ts" name is defined in:
arm/mach-s5pv210/mach-mini210.c

My conclusion is - either the driver is hidden in closed-source kernel
binaries and it's broken or it's just missing sources for the most
important part - communication via i2c.


I found also "goodix-gt80x.c" file in archos repository, it compiles and
loads properly, but it also doesn't work:
i2c-core: driver [goodix-gt801] registered

Reggie
how do you mean it doesn't work?  In general you have tslib and run
something like ts_calibrate the very first time you boot the machine.

Tomasz Myrta
I guess there is no special device /dev/touchscreen-1wire as when using
resistance touchscreen, so I expect touchscreen available in
/proc/bus/input/devices. And I suppose hexdump /dev/input/event0-9 retuns
some data when pressing the screen.
Am I wrong?

Android doesn't use extra calibration - the screen is already calibrated to
800x480 resolution.

Reggie
Unfortunately I'm running the 210S with a 4.3" resistive screen so I can
only give suggestions based on what I'd look at to fix it up but with no
way of testing at all I can't check any further.

my only other thought would be to pull the goodix_touch.o from the android
ICS image if it's available.

I also found out that the s5p-tv driver (deals with hdmi) doesn't exist in
kernel 3.0.8 but does exist in kernel 3.1.x so I wonder if a kernel bump
would help, although as I understand things we would then be without an mlc
nand driver (it's pre-built for the 3.0.8 kernel sources).

Screwface
I remember I made a "cat /dev/input/eventx" (with x=4 if I remember
correctly) with supplied ICS image, and I got some data pressing the
screen. But I was not able to get this file using 3.0.8 kernel or Linux
2.6.35 kernel.
All that I found is drivers are not compiled as built natively in the
kernel but they are modules. That's also why no soundcard is detected by
the kernel. Sound module is called by /etc/init.d/rcS script. I guess it is
the same for the touchscreen module with Android.

I think finding how Andoid calls the driver and doing the same with linux
could be a try.

Anyway, I think it would be nice to have an up to date kernel with
everything supported directly, like mini2440 one (I don't know mini6410).
But I'm not good enough, I'm too noob to do that. I asked Juergen, but
nothing is planned on Pengutronix side :-( It would have been a great help!

I'm also looking for a barebox / uboot port for the mini210 but seems there
is nothing for the moment. Just a chinese version I didn't try for the
moment.

Ilian Tsachev
I try to use FT5306 I2C capacitive TSP with MINI6410. Did somebody managed
to run any capacitive TSP to this machine ?