The Pull-Up Window That Can Close
The Pull-Up Window That Can Close
Ada re-derives this chapter’s own numbers step by step, at full precision
ADA · CALCULATION AUDIT
The Pull-Up Window That Can Close
The chapter’s bill of materials stacks two BME280s, a BH1750 light sensor, a CCS811 air-quality sensor, and an SSD1306 OLED onto one I2C bus with 2.2kΩ pull-up resistors, and its own key lesson warns that an incorrect pull-up value causes intermittent failures that are hard to debug. This audit asks the question that warning invites: with the OLED’s capacitance dominating the bus, does that 2.2kΩ value actually open a valid pull-up window at 100 kHz, or does the same bus make 400 kHz impossible no matter what resistor is chosen?
Companion to the chapter Protocol Diagnostics and Bus Design — every number here comes from that chapter.
See the relationship before changing it
The figure reads from left to right. The blue card is i2c bus capacitance. The middle card applies this page's rule. The green card is 100 khz maximum pull-up. Walk the arrows once: set the input, apply the rule, then read the result with its unit.
The retained audit below checks several chapter fixtures. This model keeps those stated values fixed and changes only i2c bus capacitance, so the numeric fixture does not switch without explanation.
Derive the baseline in four named moves
- 1
Name the input. The chapter baseline is 500 pF.
- 2
Name the relationship. Rmax = 1,000 ns / (0.8473 x capacitance)
- 3
Substitute with units. 1,000 ns / (0.8473 x 500 pF) = 2,360 ohm
- 4
Read the result. Keep the unit beside the value. Use it only inside the technical boundary on this page.
Predict, then change i2c bus capacitance
Try Predict the direction of Rmax = 1,000 ns / (0.8473 x capacitance). Test another i2c bus capacitance, then compare 100 khz maximum pull-up.
Observe More bus capacitance slows the rise and pushes the maximum valid resistor downward. Reset i2c bus capacitance to 500 and compare 100 khz maximum pull-up.
Explain More bus capacitance slows the rise and pushes the maximum valid resistor downward.
Check yourself
What should you do before trusting a moved-control result?
What does this small model leave out?
Treat 500 pF bus capacitance with a 2.2 kOhm pull-up at 100 kHz as the fixed audit case; predict the rise-time verdict before selecting Check audit.
The valid resistor window appears as 967-2360 ohm at 100 kHz, but at 400 kHz Rmax collapses to 708.1 ohm below Rmin.
At 500 pF, capacitance slows the RC rise while sink-current limits prevent arbitrarily strong pull-ups, allowing the two constraints to eliminate every fast-mode resistor.
Ada: The worked example concludes that 400 kHz is impossible on this bus but 2.2 kohm works at 100 kHz. That verdict rests on two limits squeezing from opposite sides. Let me recompute the window with full precision.
- Bus capacitance:
60 + 20 + 10 + 10 + 400 = 500 pF, dominated by the OLED’s 400 pF. - Upper limit (rise time), fast mode 400 kHz:
R_max = 300 ns / (0.8473 x 500 pF) = 708.1 ohm. - Lower limit (3 mA sink at V_OL 0.4 V):
R_min = (3.3 - 0.4) / 0.003 = 966.7 ohm. - The window is inverted:
R_max (708) < R_min (967), so no resistor satisfies both and 400 kHz cannot close. Confirmed. - Relax to 100 kHz (rise-time budget 1000 ns):
R_max = 1000 ns / (0.8473 x 500 pF) = 2360 ohm, opening the window to967 to 2360 ohm. A common 4.7 kohm sits outside it:4700 x 500 pF x 0.8473 = 1991 ns > 1000 ns(fails), while 2.2 kohm gives2200 x 500 pF x 0.8473 = 932 ns(passes) at3.3 / 2200 = 1.5 mA.
The pull-up must be small enough to pull the line high before the clock edge and large enough not to exceed the sink-current limit – two ceilings that both move with bus capacitance. Load the bus with a high-capacitance device and the fast-mode window shrinks until it inverts; the fix is then not a cleverer resistor but less capacitance or a slower clock.
Every number above is taken from the chapter’s own material and re-derived step by step.
Technical boundaries: The lumped-capacitance I2C rise-time check omits trace inductance, distributed wiring, level shifters, device-specific sink curves, bus-voltage tolerance, ringing, leakage, and clock stretching.