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.

TCA8418 problem

Other Parts Discussed in Thread: TCA8418

I am using tca8418 keypad scan ic with linux 3.2 kernel, But problem is that after pressing key 20-30 times keypad is not responding and driver is not responding.

I have figured out one thing that by clearing and setting the register   "Configuration Register (Address 0×01) bit KE_IEN. The device is responding again.

what is the exact problem ?

  • Hello,

    1) When the keyboard is non functioning, can you check the configuration register (0x01) and see if bit 3 (OVR_FLOW_IEN) is enabled? If it is, please check INT_STAT (0x02) register and look at the status of the OVR_FLOW_INT bit.

    I suspect that the linux driver does not properly read the events from the TCA device, eventually causing an overflow condition. In an overflow condition, the default operation of the device is to ignore all further keyboard input until the FIFO has been read/cleared.

    Please look at the datasheet on page 22 at Section 8.4.2.4: Key Event Registers. This section explains that the user (in this case, your kernel/linux driver) should first check the INT_STAT register to see if there are interrupts, and if there are, check the KEY_LCK_EC register to see how many interrupts are stored. Then you should read the KEY_EVENT_A register until there are no more events left. ONce all events have been read, the key event count is at 0 and then you will need to clear the KE_INT bit by writing a '1' to it.

  • Thanks for your reply but my problem is already resolved.
  • I am glad to hear it.

    Would you mind stating what the solution was for anyone else who might have a similar problem?

  • I was not setting the 4 bit of configuration register (0x01) INT_CFG. So i was not able to clear interrupt line from software if i was continuously pressing the keypad say 20-30 times.Interrupt line was not responding.
    Interrupt line was only responding after reboot.
    After setting 4th bit my keypad is working properly.
    Driver provided by TI at the below link has this issue.
    gitorious.org/.../tca8418-keypad.c