Tool/software: Linux
Hello,
I have a question related to the topic that I mentioned some time ago: e2e.ti.com/.../
I have an AM335x CPU and I want to provide support for SMBus BlockRead, i.e. I2C_M_RECV_LEN flag in Linux environment.
I tried to use GPIO driver, but for some reason, my slave chip does not respond with ACK when I use GPIO driver for I2C. I temporarily connected two other slave devices on the same bus (pins) and they ACKed properly...
I also tried to implement polling mechanism into the i2c-omap.c driver in my Kernel (3.14.39), but I have few questions to TI experts about the requirements that I have to fulfill in order to get it working as expected.
1. At first, in the currently implemented IRQ-driven I2C transmission, the FIFOs are configured for a certain length. Please correct me if I am wrong, but the FIFO length cannot be changed in the middle of I2C transaction. Does this apply also when I want to use polling management?
2. Do I have to disable all interrupts, or is it enough if I just disable RRDY and ARDY interrupts and poll for them? In such approach, the NACK or any other interrupt would be handled as it is now, in the interrupt handler function. Is it correct, or should I also handle for example NACK interrupt in my polling loop?
3. Has TI tried to implement the polling mechanism in I2C Linux driver? If so, is it available somewhere?
Best regards,
Rafal Fabich