Re: FocalTech Touchpad (v2) PS/2 Reverse Engineering

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On 13-07-19 20:21, Hamza Farooq wrote:
Hello,

Implemented ABS_MT_TOUCH_MAJOR (Length, min 0, max 9)/MINOR (Width, min 0, max 14), finger touch values rangers form 1 to 5+ depending on area and palm values are also around 3 to 8+. These overlapping values make it hard to distinguish between both. Anyway, I don’t think I need those at all. because MAJOR/MINOR doesn’t change much (at least I didn’t notice something special). Also removed code related to Area/Pressure because peter said it wasn’t required(in his first reply).

Kinetic scrolling on other hand is something I cannot fix on my own (for each and every app), because developers need to add support for it. Most of GNOME apps support it, I tried GNOME Web (Epiphany) and it works fine. So nothing wrong with driver here.

Other than that pinch to zoom is not working anymore, I guess, it stopped working right after I fixed tap to click.

tired renaming focaltech.c to focaltech_v2.c, but renaming “CONFIG_MOUSE_PS2_FOCALTECH” (focaltech_v2.c, focaltech_v2.h, psmouse-base.c, Makefile) to  “CONFIG_MOUSE_PS2_FOCALTECH_V2” make the device fallback to Logitech driver (single touch, standard mode). Not sure what i’m missing here. I am attaching .zip that are working for me right now. I would like this to be merged in future kernel, I wanted to create a dkms module for those who want to use/test it right now. I can’t get it working for both FocalTech device versions, so I guess I have to publish that is working for me and wait for a fix.

Renaming CONFIG_MOUSE_PS2_FOCALTECH will not work because that will disable the focaltech
entry in the psmouse_protocols array in drivers/input/mouse/psmouse-base.c:

#ifdef CONFIG_MOUSE_PS2_FOCALTECH
        {
                .type           = PSMOUSE_FOCALTECH,
                .name           = "FocalTechPS/2",
                .alias          = "focaltech",
                .detect         = focaltech_detect,
                .init           = focaltech_init,
        },
#endif

What you should do instead is add an new CONFIG_MOUSE_PS2_FOCALTECH_V2 in
drivers/input/mouse/Kconfig and then in the psmouse_protocols array have:

#ifdef CONFIG_MOUSE_PS2_FOCALTECH
        {
                .type           = PSMOUSE_FOCALTECH,
                .name           = "FocalTechPS/2",
                .alias          = "focaltech",
                .detect         = focaltech_detect,
                .init           = focaltech_init,
        },
#endif
#ifdef CONFIG_MOUSE_PS2_FOCALTECH_V2
        {
                .type           = PSMOUSE_FOCALTECH_V2,
                .name           = "FocalTechPS/2",
                .alias          = "focaltechv2",
                .detect         = focaltech_v2_detect,
                .init           = focaltech_v2_init,
        },
#endif

And rename the focaltech_detect in your focaltech_v2.c to
focaltech_v2_detect and the same for focaltech_init.

You will also need to add focaltech_v2.c to the
psmouse-objs line in drivers/input/mouse/Makefile

Regards,

Hans


p.s.

I do not think that building this as a DKMS module is possible since it
requires changes to the core drivers/input/mouse/psmouse-base.c file.




[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux