Skip to main content
Associate
April 30, 2024
Question

I2C channels as pull-up in STM32F103C8T6

  • April 30, 2024
  • 4 replies
  • 2644 views

Hello everyone,

I want to configurate the I2C channels as pull-up in STM32CubeIDE for STM32F103C8T6, but I couldn't set it. 

It looks like in the attached image. It just shows n/a in configuration.

How I set it as pull-up? 

Please inform me. Thanks.

 

hdhdhd_0-1714481859079.png

 

    This topic has been closed for replies.

    4 replies

    Andrew Neil
    Super User
    April 30, 2024

    The internal pull-ups are not suitable for use as I2C bus pull-ups - you need to use external pullups.

     

    EDIT:

    See this post for the effect of too-high and too-low pullups:

    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.
    ST Technical Moderator
    April 30, 2024

    Hi @hdhdhd 

    Internal pull-ups are not recommended for I2C. Pull-ups must be adapted to the I2C bus speed and to the bus load.

    To give better visibility on the answered topics, please click on "Best answer" on the reply which solved your issue or answered your question.Best regards,FBL
    AScha.3
    Super User
    April 30, 2024

    Hi,

    i just tried , yes, on F103 no pullups to set , only n/a .

     

    But on F401 i tried also, here pullups possible :

    AScha3_0-1714494422254.png

    So for pullups - take another cpu . :)

     

    If you feel a post has answered your question, please click on " Best Answer ".
    Andrew Neil
    Super User
    April 30, 2024

    @AScha.3 wrote:

    So for pullups - take another cpu . :)


    Or just use the proper external pullups - the internal ones (when available) are likely to be too large.

    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.