Internal pull-up resistors are insufficient for I2C
joshmcguigan.com
Internal pull-up resistors are insufficient for I2C
1–10 of 11 posts
Re: Internal pull-up resistors are insufficient for I2C
#2This post compares the performance of the circuit using the internal pull-up resistors against external 1kohm resistors, including plots showing the improved signal quality.
Re: Internal pull-up resistors are insufficient for I2C
#3Re: Internal pull-up resistors are insufficient for I2C
#4I've gone back and forth on using external resistors for I2C and have read a lot of conflicting views on it. I think this is another to add to the pile, but I'm leaning towards putting them on PCB designs by default now..
I've only implemented i2c on esp32-s2, and left the pullup footprints unpopulated at first. Eventually I came to the same conclusion and put two 10k resistors on and called it a day. Cost was negligible.
Re: Internal pull-up resistors are insufficient for I2C
#5So 1kΩ is safe, but might be a bit on the aggressive side. At 3.3V, 1KΩ to ground burns 3.3mA, and there are two pull-ups per I2C bus.
Re: Internal pull-up resistors are insufficient for I2C
#6Reading the datasheets for both devices would probably avoid the problem.
Re: Internal pull-up resistors are insufficient for I2C
#7Anecdata: seems like internal pullups are usually 10s of kΩs, maybe 20-50kΩ. Most sensor boards that I see use 4.7kΩ, and work with 400KHz-1MHz "fast-mode+". So 1kΩ is safe, but might be a bit on the aggressive side. At 3.3V, 1KΩ to ground burns 3.3mA, and there are two pull-ups per I2C bus.
If you're doing coin cell powered stuff, those brief 3.3 mA pulses can really chew up your battery life.
Re: Internal pull-up resistors are insufficient for I2C
#8I was using I2C for the first time, as part of a brushess ESC project, and had to learn the hard way that internal (to the mcu) pull-up resistors would not work at any reasonable (for my needs) communication speed. This post compares the performance of the circuit using the internal pull-up resistors against external 1kohm resistors, including plots showing the improved signal quality.
Re: Internal pull-up resistors are insufficient for I2C
#9Anecdata: seems like internal pullups are usually 10s of kΩs, maybe 20-50kΩ. Most sensor boards that I see use 4.7kΩ, and work with 400KHz-1MHz "fast-mode+". So 1kΩ is safe, but might be a bit on the aggressive side. At 3.3V, 1KΩ to ground burns 3.3mA, and there are two pull-ups per I2C bus.
The I2C specification is full of these kinds of ambiguities, which creates a lot more work for implementers. SMBus's physical layer is a subset of I2C that tightens these requirements and specifies pull-up current, making these calculations quite a bit easier.
Re: Internal pull-up resistors are insufficient for I2C
#10It seems that pulling up I2C pins with 4.7kOhm resistors is a way to go:
https://tronixstuff.com/2011/08/26/arduino-mcp23017-tutorial...