Post Go back to editing

Simple C code TWI/I2C   example for the BF537

Hi,

is it possible that some one  could let me have  a copy of a simple working C example demonstrating an I2C/TWI  transaction, Master to slave using polling  if possible, since these are very early Blackfin  days for me. If have used I2C a lot in the past on other platforms (8051,AVR and FPGAs) and have reasonable understanding of it. But when it comes to it on the Blackfin (BF537)  all the how to details  are gobbledygook to me, so need a working C  example I can paw over. The best I have  managed so far is the sending of 2 bytes of data and the slave address to a  24C32 I2C eprom, when I set DCNT to  more than two I get nothing. My test setup for this type of  thing is a Logic analyzer connected to I2C eprom being targeted as a slave, with the logic analyzer interpreting the I2C  transaction, I am using a ADZS BF537 EZLITE board. No assembly language examples please at this time, because that is even more  gobbledygook to me. My aim is to get to the point where I can create an  I2C transaction  like: S -> serial byte sequence -> S serial byte sequence -> P, where  S and P  are Start and Stop respectively.

Thanks in advance.

Harold.