Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Preventing noise on I2C line on 2 layer board

Status
Not open for further replies.

blapcb

Full Member level 3
Joined
Jan 7, 2007
Messages
188
Helped
2
Reputation
4
Reaction score
0
Trophy points
1,296
Location
Planet earth (most of the time)
Activity points
2,766
I have a double layer board with a microcontroller and two peripherals connected by I2C. There is a sporadic and infrequent (yet persistent) issue of the I2C hanging and I suspect noise. What practices should I follow in order to minimize the noise in this case? The only thing on the line other than the master and two slaves are the two pull-up resistors.

I have attached the relevant section of the layout (with and without stencil). The uC pins are down there at the lower right and the other ICs are U8 and U9. I have indicated the I2C path with red arrows/circles.

Apart from possibly a better routing/design, I also added a connector (CN5) in order to aid in connecting the logic analyzer probes. Would this induce more noise, either when the connector (a berg stick) is populated or even without?

Thanks for your inputs!
 

Attachments

  • I2C with stencil.jpg
    I2C with stencil.jpg
    94 KB · Views: 80
  • I2C without stencil.jpg
    I2C without stencil.jpg
    69 KB · Views: 83

Layout could have been definitely much better. I did not like the side-entry of the signal into the pad (the one on the right side of the two signals). And the second signal also seems to be improperly routed. However this may not be the reason for I2C to hang.

Please be aware that I2C bus have a load limitation of 400pF that includes all devices plus the PCB trace. Check the pull-up resistance that you have placed on the bus. Use a 4.7K ohm resistor closer to I2C slave device.

I still suspect that issue could be in your I2C driver or the Microcontroller Code and not the CAD because this is a slow bus and CAD may not be directly impacting the performance of this interface.
 

Please be aware that I2C bus have a load limitation of 400pF that includes all devices plus the PCB trace. Check the pull-up resistance that you have placed on the bus. Use a 4.7K ohm resistor closer to I2C slave device.

I still suspect that issue could be in your I2C driver or the Microcontroller Code and not the CAD because this is a slow bus and CAD may not be directly impacting the performance of this interface.

Yes there are two 4.7K resistors next to U8 (just to the right of C26).

Well, I also would not rule out software it's just that presently I am trying all aspects/options.
I have a thread going on the software aspect and I would greatly appreciate your comments there also.
https://www.edaboard.com/threads/229643/

I have Googled a lot about this issue (i.e. I2C lockups) and several folks have also had trouble with it. Since my board is in advanced field trials, I regret I can't change anything and have to find a solution.... :-(
 

Hi, I had a quick look at this thread... I am pretty sure the Bus crashing issue in this case is definitely not PCB related.... In a recent design I used exactly same devices (EEPROM and RTC), but on a different PIC. And that worked perfectly fine for me. Let me try to go through your code and see if I can be of some help....
 

Hi, I had a quick look at this thread... I am pretty sure the Bus crashing issue in this case is definitely not PCB related.... In a recent design I used exactly same devices (EEPROM and RTC), but on a different PIC. And that worked perfectly fine for me. Let me try to go through your code and see if I can be of some help....

I have posted my entire I2C driver code to that thread

Thanks!
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top