IIC Bus Busy always active - how do I clear it?

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

IIC Bus Busy always active - how do I clear it?

799 Views
matthewreed
Contributor I

Whenever I enable the IIC module the Bus Busy bit is set.  I'm the only master on the line, the lines are pulled high.  No start signal has been generated.  Why is the bus busy?  How do I clear it?

 

Frustrated...

 

17474_17474.gifdestroy_iphone.gif

Ok, not always.  After a bit of messing with it the busy bit is not always set.

 

But - I can't set MST (master) bit.  This has always been true, I thought it was related to the busy bit.

 

Even in the debugger, I set the master bit and it immediately clears.

 

I don't get it?  Why would it not set?  I've set the pins to GPIO output and written to them, they work fine.  Why won't master work?

 

17476_17476.gifteemingcolddiplodocus.gif

 

-Matt

Labels (1)
0 Kudos
Reply
1 Reply

591 Views
matthewreed
Contributor I

I figured it out!!!

the IIC bus was not biased properly, as a result the processor would determine that the bus was busy (sometimes showing it, sometimes not).  You can't enter master mode when the bus is busy, only slave mode.

the solution was to properly bias the SDA anc SCL lines.

-Matt

0 Kudos
Reply