This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/TSC2003: erroneous X coordinate

Part Number: TSC2003
Other Parts Discussed in Thread: TSC2007

Tool/software: Linux

Hi everybody

We designed custom hardware including the TSC2003 controller. We are dealing with the following problem. Occasionally, the TSC2003 reports an erroneous press. When this happens, the X coordinate is wrong, while the Y coordinate is correct.

We noticed that when the reported X coordinate is erroneous, the z1 value is 0. This is the code that implements the conversions following a touch event.

    /* y- still on; turn on only y+ (and ADC) */
    tsc2007_xfer(tsc, ACTIVATE_YN);
    tc->y = tsc2007_xfer(tsc, READ_Y);

    /* turn y- off, x+ on, then leave in lowpower */
    tsc2007_xfer(tsc, ACTIVATE_XN);
    tc->x = tsc2007_xfer(tsc, READ_X);

    /* turn y+ off, x- on; we'll use formula #1 */
    tsc2007_xfer(tsc, ACTIVATE_YP_XN);
    tc->z1 = tsc2007_xfer(tsc, READ_Z1);
    tc->z2 = tsc2007_xfer(tsc, READ_Z2);

    /* Prepare for next touch reading - power down ADC, enable PENIRQ */
    tsc2007_xfer(tsc, PWRDOWN);

If we understand correctly, z1=0 is inconsistent in the sense that z1 should never be 0. Is it possible that z1=0 is due to a hardware problem? In general, what could explain such an inconsistent value?

Thank you in advance.