Quantcast
Channel: Forums - Recent Threads
Viewing all articles
Browse latest Browse all 262198

Can someone help me troubleshoot my 28035 I2C code?

$
0
0

Hi there, I've been trying to get some I2C devices to work with my 28035, but I get stuck because the I2C peripheral won't clear the STP bit.  It gets hung up on a while loop I created to wait for the message to finish transmitting.

Here is my initialization code: https://dl.dropboxusercontent.com/u/13579266/code_part1.txt

And here is the function I use to send the message:  https://dl.dropboxusercontent.com/u/13579266/code_part2.txt

I've run some debugs and found that the program can't seem to make it past the expression "while(I2caRegs.I2CMDR.bit.STP == 1);"  It just hangs there forever.

Any ideas?


Viewing all articles
Browse latest Browse all 262198

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>