Snippet - TSC2046 Driver (very rough)

TSC2046 Driver (very rough)

The standard Microsoft TSC2046 driver (as found on the ChipworkX board) samples too early and thus results in spurious and false touches.

This is a rough driver I wrote a while back to test a custom resistive touchscreen and driver PCB.

The driver is not optimised, is not friendly to read and requires an external SPIManager reference (not available) and is hardcoded to an 800 x 480 screen (I know, I know…)

The system could be better driven through the use of the PEN_IRQ event used to then call the ProcessTouch() function.

It is posted for reference only. Suggestions on how to improve the driver will be gladly welcomed.

1 Like

Hi Michael,

I am trying to create a new touch driver for the TSC2046 as I too found the driver too noisy.

In your code there is a reference to SPI1Manager. I can’t seem to locate this in my ChipworkX references.

Any ideas where to look for this?

PS… I am adapting this to work with any size screen so I will give back the code to the forum once I have it working.

Cheers
Dave…

Rats, I just re-read your posting and saw the reference to the SPI manager.

Not much use posting a driver without access to the whole code? :frowning:

Where did the SPI manager come from? Is this commercially available? I am willing to provide code back in exchange for something that works :slight_smile: