Updated I2C Interrupt Driver Trashing Memory

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

Updated I2C Interrupt Driver Trashing Memory

412 Views
myke_predko
Senior Contributor III

I guess this is for Martin and Robert,

I've been using the driver code you provided as the reply to my question of April 19, 2013 (https://community.freescale.com/message/325472#325472) and it has worked quite well except that periodically it trashes memory in the system. 

When I say "trashes memory" the application locks up to external inputs.  I can still pause execution and when I look at the task summary, the task names after "_mqx_idle_task" are written over with random strings - and the data values, for the most part are randomized (ie the TaskIDs). 

When it does this, it seems to be in circumstances of heavy activity on the bus (primarily to the OLED display in my system).  It does happen randomly (there is no sequence which repeatedly causes the problem).  I have commented out the calls to the new I2C driver calls and I cannot reproduce this problem, which is why I believe the problem is with the I2C Driver. 

Please let me know if you require any additional information from me. 

Thanx guys - any suggestions would be appreciated.

mkye

0 Kudos
2 Replies

198 Views
Martin_
NXP Employee
NXP Employee

Hi Myke,

have you used AN4652 or the patched I2C driver in https://community.freescale.com/message/325704#325704 ?

In other words, the problem is with the "ii2c0fb:" or with "ii2c0:" ?

0 Kudos

198 Views
myke_predko
Senior Contributor III

Hi Martin,

Yes, I am using the patched I2C driver in https://community.freescale.com/message/325704#325704.

And it’s “ii2c0fb:”.

The problem seems to occur when two (or more) I2C writes to the OLED take place (each “write” consists of four packets consisting of a page set up of 2 data bytes, two column set up packets and a data packet of 133 bytes).

Thanx,

myke

0 Kudos