Kinetis I2C problem

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Kinetis I2C problem

Jump to solution
2,189 Views
Dilebo
Contributor III

Hello,

I'm trying to implement an I2C communication between a Kinetis K12 and a Kinetis KL16.

To sum up, it seems that the K12 does not see the signals coming from the KL16. Here is what makes me come to this conclusion:

1. First config: KL16 master - K12 slave

The master send a frame, but the slave does not detect anything, there is not any interrupt.

2. Second config: K12 master - KL16 slave

This one is more interesting.

The master send a frame. This frame is detected by the slave (KL16), the IAAS bit is set, the first byte (slave address) is followed by a ACK (SDA LOW on the 9th bit).

But the master (K12) does not see the ACK: I get an interrupt after the address byte is transmitted, but the RXAK bit is set, meaning that the ACK from the slave has not been detected by the master.

setup_9.png

Here, we can see the ACK from the slave, but the K12 can not.

There is a small glitch before the ACK.

Maybe the LOW level of the ACK to is too high to be detected. Though, it is ~1V, and from the K12 datasheet, input low voltage maximal value is 0.35*Vdd = ~1.15V.

So here are my questions:

- Do you think it is possible that the SDA LOW signal is too high to be detected ?

- Do you think the glitch before the ACK can affect the result ?

- May be I'm missing something else ?

Thank you for your help.

Labels (2)
1 Solution
1,013 Views
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Dilebo:

In the case of K12, you have to enable Open-Drain in the used pins (PORTx_PCRn[ODE] = 1).

With this the ACK bit should go low all the way.

Let us know your results.


Regards!,
Jorge Gonzalez

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

View solution in original post

2 Replies
1,014 Views
Jorge_Gonzalez
NXP Employee
NXP Employee

Hello Dilebo:

In the case of K12, you have to enable Open-Drain in the used pins (PORTx_PCRn[ODE] = 1).

With this the ACK bit should go low all the way.

Let us know your results.


Regards!,
Jorge Gonzalez

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

1,013 Views
Dilebo
Contributor III

Problem solved !

Thank you Jorge