Connecting a Wacom I2C touchscreen to the Framework 13 motherboard (prototype)

Goal:
My long term goal is to build my own 2 in 1 laptop around the framework 13 motherboard. As a first step for that project, I need to get a touch screen with stylus support working through the framework’s eDP connector. A USB C display is not a good option as it will take up ¼ of the IO on the motherboard and would be more difficult to integrate into the final design.

Progress so far:
First, I tested to make sure a display from a Lenovo 2 in 1 (the 4k flex 5 15) would work with the framework 13 motherboard. I connected it using the normal framework 13 display cable and it booted and displayed correctly, including showing the correct resolution in software

With the display portion working, I then managed to reverse engineer the pinout for the Wacom touch screen controller (the same controller is used across a few computers, including the flex 5 and yoga 720)

The pins are connected to the motherboard as follows. The breadboard in the photo is a usb scope that I use for debugging.
3.3v → J302 (power jumper lower right of the motherboard)
gnd → ground (eDP connector)
reset → TS_RST_Q (eDP connector)
interrupt → TS_INT (eDP connector)
I2C sda →I2C_SDA_TP (trackpad test point)
I2C scl → I2C_SCL_TP (trackpad test point)

These connections were enough to get the touch screen controller to show up on the i2c bus in Linux, but the driver was not loaded so it was not usefull

In order to make it work I had to extract and decompile the ACPI tables on both the framework and my Lenovo yoga 720-15ikb. I then found the entry for the touch screen in the 720’s table and copped it into the decompiled framework’s table, making the necessary changes to the name of the I2C bus, setting the interrupt to the trackpad interrupt, and commenting out the trackpad. I then set grub to override the default ACPI table with my modified version

modifications made to the framework ACPI table

As long as trackpad interrupt is pulled low ether by connecting it to ground or by touching the trackpad during boot, the computer will communicate with the touch screen controller, load the driver, and work, at least on Linux. The screen I am using for testing is from a broken yoga 720-13ikb but, while its inverted because the replacement touch controller connected to it is from ebay and for slightly different machine, both the touch and stylus work corectly.

short demo video

Next steps:
First of all, I need to get the TS_INT pin on the eDP connector working so that I can still use the trackpad. I have looked through the schematic, embedded firmware, and decompiled ACPI table but I have not found any indication of what GPIO pin it is connected to. Furthermore, the I2C and 3VS_TS lines on the eDP connector seem to be non-functional. They go to 3.3V for about 2 seconds when the motherboard is turning on and then drop back to 0V. The reset and interrupt pins do not show this behavior and stay at 3.3V. I have tried connecting the TS_EN pin to ground and to 3VS_TS to no effect. Looking in the embedded firmware i2c definitions I don’t see an I2C port defined for the touch screen, leading me to believe that the pins are unconfigured or intentionally configured to turn off. If its feasible, I would like to make the pins work so that I would not need to solder to the motherboard and trackpad in the finished project. Once I figure out the eDP pins I will make a breakout board for the edp connector so that I can connect the display and touch controller simultaneously.

If you have any questions feel free to ask. If you know what the GPIO pin for TS_INT is, have any ideas for where to look for that information, or any idea how to get the TS I2C and 3VS pins to stay on, let me know.

10 Likes

I came onto the forum to make a post asking if anyone had tried something like this, awesome to see your progress so far! If you manage to figure something out in the end I’d love to try and build my own.

1 Like

I had some time this weekend and I managed to get the touch screen and trackpad working simultaneously. I was able to determine what GPIO pin TS_INT was connected to by connecting a square wave generator to the TS_INT pin and set it to produce a 0 to 3 V signal at 2 HZ. I then wrote a simple bash script that used the libgpiod utils to go through all 256 GPIO lines and, one at a time, print the state 10 times over 1 second. I watched it run and on GPIO line 12 I saw the square wave.

Further testing confirmed that pin 12 was in fact connected to the TS_INT pin on the eDP connector.

With this information I modified the ACPI table to re-enable the track pad and to change the touch screen interrupt to pin 12. Rebooting with the new table yielded a working trackpad and touch screen.

I still have no ideas for how to get the TS I2C pins on the eDP connector to work but now that the TS interrupt pin is enabled the trackpad and touch screen sharing an I2C bus, while not ideal, seems to work ok.

While I had everything powered on I also took the opportunity to look at the power provided on the eDP connector. The lower red plot is the 3VS_TS pin and the upper yellow plot is 3VS_EDP.

The 3VS_TS only comes on (and not even to 3.3v) for a few seconds when the computer is first powered on, so it is not usable for powering the touch screen, but the 3VS_EDP power seams to be on for the duration of the boot and only shuts off near the end of Linux booting so presumably when a display is connected it will stay at 3.3V for the entire time the computer is on.

I think the next step is to design and build a breakout board that will connect to the eDP connector on the motherboard and break out touch screen pins while passing through the display connections so that I can connect the display and touch controller at the same time.

3 Likes

Awesome project and writeup!

Looking forward to seeing your progress.