AnsweredAssumed Answered

TWI Slave Transmit

Question asked by RKuipers on Mar 4, 2011

I'm trying to get a sharc 21369 to work as a twi slave connected to an xscale processor. Writing to the sharc works just fine, but as soon as I enable TWITXINT to send multiple bytes back to the master, things go haywire. With the TXINT enabled a read command doesn't seem to result in a actual interrupt, as the master only receives 0xFF's instead of the data I put in the FIFO in the isr. A second read command will hang the bus, with the slave acknowledging the start condition and the slave address byte but not acknowledging the first data byte.

 

Weirder still, issuing a write command (which functioned perfectly nice before) with TXINT enabled results in the same behavior: the first write is completely successful, on the second write the slave stalls at the first data byte.

 

Does anyone have a clue on what's happening here, or maybe has some example code on how to use the 21369 as a TWI slave?

 

Cheers, Reinier

Outcomes