I have been working on an expansion board for the BBB that includes a resistive LCD touchscreen. The problem that we are having is that our ESD protection diodes seem to break the break the touch input.
We are using a 4 wire touch interface on AN0, AN1, AN2, and AN3. The symptom we are seeing is that when the diode is connected to the touch interrupt seems to be triggered inconsistently.
When checking the signals with a scope, it shows that the interrupt seems to work fine until an application that uses touch is run then it becomes inconsistent. This does not happen if the ESD diode is removed. The apps we are running are the Qt calibration and Qt touch test. Looking at the raw data from the touch device from within Linux on the BBB we see a steady stream of data before a touch app is run, then inconsistent data streams once a touch app is running AND after the app closes. Again this symptom does not happen with the diode removed.
My question is 2 parts:
1)What could be happening that would make the touch interrupt inconsistent only when that diode is present AND one of these applications is run?
- Do we really need additional ESD protection? Does Anyone have any experience with a BBB and a heavy usage resistive touch screen, that is not have additional ESD protection? In the two cape examples I looked at additional ESD protection is not used.
This is the ESD part that we are using: http://www.comchiptech.com/cms/UserFiles/CPDT6-5V4U%20RevD364097.pdf
I hope, you have solved the problem. If not, I’m hurry with the answer!
- I had to connect a 10 inch resistive touchscreen, and go t the same issue.
- The explanation is capacitance of the touch screen, which is a bit bigger then anything, the driver author had to deal with. BTW, quite surprising that they have not taken this to account, I’ll explain in next point.
- If you look in the ti_am335x_tsc driver, there is a “charge” phase, which load charge into touchscreen surfaces, which if not touched are like capacitor. This capacitor needs time to charge, so if the charging time is too short, the false touch is detected. Adding ESD protection increases capacitance!
- The driver sets the charging time to 1 clock tick! That’s, in my opinion a huge bug. Just ignorance of the topic knowledge.
- In order to fix the issue, you need to recompile ti_am335x_tsc driver, before do two modifications:
#define CHARGEDLY_OPENDLY CHARGEDLY_OPEN(100)
also, I have increased sampling time, not sure if needed:
#define STEPCONIG_SAMPLEDLY STEPDELAY_SMAPLE(10)
"linux-dev/KERNEL/drivers/input/touchscreen/ti_am335x_tsc.c: (line around 276)
z /= z2; → z/=z1;
(another silly bug)
Let me know if this helped.
I have send some time before I have figure out that if cope configuration is loaded as overlayed, the driver shall be “modproed” after loading the cape config. This is not the case when cape configuration is discovered using EEPROM. So, I have also made this driver a module.
W dniu środa, 5 lutego 2014 17:09:05 UTC+1 użytkownik moore.cyril napisał: