cancel
Showing results for 
Search instead for 
Did you mean: 

STM32U5A5QJI6Q (BGA Package): How to solve missing I2C Pull-Up ?

Sakthi_IND
Associate III

Hi Team,

We are currently working on a design using the STM32U5A5QJI6Q microcontroller in a BGA package, implemented on a 4-layer PCB. During the hardware development phase, we inadvertently omitted the external pull-up resistors on the I2C lines, specifically on PB6 (A5) and PB9 (A4), which are configured for I2C_SCL and I2C_SDA respectively.

Our software team has informed us that there is no option to enable internal pull-up resistors for these specific pins through software configuration. Given the constraints of the BGA package and the complexity of reworking inner-layer routing, we are seeking your expert guidance on the following:

  1. Is it possible to enable internal pull-up resistors on PB6 and PB9 via software or alternate configuration?
  2. If not, what are the recommended rework strategies for adding external pull-ups in a BGA-based 4-layer PCB design?
  3. Any best practices or application notes that could assist in resolving this issue without a complete board redesign would be greatly appreciated.

We would be grateful for your support in helping us resolve this issue efficiently.

Thank you for your time and assistance.

Best regards,
Sathiya

7 REPLIES 7
TDK
Super User

You can use the internal ~40 kOhm pullup resistors with reduced I2C clock rate, maybe 10 kHz, and it'll work just fine.

TDK_0-1750949671887.png

I'd put a scope on SDA/SCL to verify edges are sufficiently fast for the clock rate you choose.

 

It's not ideal because your bus will be floating before the pins are initialized, but this will likely not be a problem. If it is and slaves are holding SDA low, SCL can be toggled to free up slaves.

If you feel a post has answered your question, please click "Accept as Solution".
Andrew Neil
Super User

Internal pullups are not suitable as I2C pullups - much too high resistance.

Does the I2C slave device(s) have accessible pins?

Are there testpoints on the I2C lines? Vias?

 

Nothing specific to STM32 here - this is just general prototype/rework stuff.

 
 

AndrewNeil_2-1750949838692.png

Image credit: https://www.circuitrework.com/services/circuit-board-modification.html

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.

Hi,

Thanks for the detailed explanation!  You mentioned  detail for STM32U5A5QJI6Q (BGA package).  we used STM32U5A5QJI6Q (BGA package) and using PB6 (A5) and PB9 (A4) as I2C lines for interfacing with a battery charger IC and fuel gauge chip. Since the I2C lines are routed internally without vias, you're unable to add external pull-up resistors, and we wondering:

  1. Can pull-ups be enabled via STM32CubeIDE or firmware?
  2. Can we switch to software I2C if needed?

Is Possible to configure the  PB6 (A5) and PB9 (A4)  pin to Software I2C, if is possible how to change ?

 

Regards,

Sathiya

 

Thank you for your response. Unfortunately, we cannot rework the board because it is very small, and there are no vias or external pads available to add a pull-up resistor.

If possible, we would like to use the same pin for software I²C with the internal pull-up resistor enabled. Could you please confirm if this is feasible?

As TDK has pointed out, You can enable the internal week pullup (worst case is 50K Ohm) this is about 10 times the resistor value normaly used on I2C. So this is only a work around for the prototype (You have to modify the schematics / PCB for a stable product), and requires that You reduce the I2C clock!


@Sakthi_IND wrote:

If possible, we would like to use the same pin for software I²C with the internal pull-up resistor enabled. Could you please confirm if this is feasible?


Whether you use software or hardware I2C is irrelevant - a resistor is a resistor!

As @TDK and @MHoll.2 explained, the internal pullup is "weak" - so you will have to severely limit the I2C speed.

It'll also be more prone to noise.

So, yes, it can "work" - but it is far from ideal.

You really need to re-spin the board to correct this fundamental error.

See this article for the effects of too-high pullup resistance:

https://electronics.stackexchange.com/a/473799 

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.

 

Hi, thank you for your response.

Is it possible to configure a pin PB6 (A5) and PB9 (A4) as a GPIO with an internal pull-up resistor through code and 
can PB6 (A5) and PB9 (A4) be used for software I2C implementation?

The I2C is only used to set the charging current limit of the charger IC and to monitor the battery voltage. So, high-speed communication is not required.

 

Regards,

Sathiya