Skip to main content
Graduate II
January 25, 2024
Question

I2C Digital Filter use case

  • January 25, 2024
  • 1 reply
  • 2745 views

Hello Community,

I am planning to use I2C operating at 1kHz maximum on STM32G4 & STM32G0 series for measuring temperature from Digital Temperature sensors placed at 2m distance from the main board in an industrial environment using CAT6 (STP) Cables with SCL & SDA paired with Grounds. I have options to operate this I2C bus at 3.3V or at 5V. The Temperature sensor has an inbulit hysteresis of 600mV.

  1. I want to understand the use & any feedback based on experince of the community members on the I2C Digital Filters
    (I can set the I2C-CLK to 4Mhz & then configure the Coefficient of the Digital filter to a value of 10-15 to maximimize the glitch filtering)
  2. Can I simply interface a 5V I2C bus signal directly to the MCU pins (assuming 5V tolerant inputs)? I will be using TVS diodes on I2C connectors on the PCB for ESD & EFT protection.

We will be measuring temperature less frequently (probably once every one hour) & I2C based temperature sensing shall never be initiated at the starting or wake up time of the MCU from any state.

Kindly guide with your experience based insights.

Regards.

    This topic has been closed for replies.

    1 reply

    Explorer
    November 26, 2024

    Hey, I didn't confirmed it yet, but looks like digital filter makes measure X times and averaging value which allow to skip falce calls, example:
    you chose value 3, and your device measuring 3 times state of SDA pin per one SCL cycle, if it reads 0, 1, 1 it will decide that that bit have logic 1. 

    ... I'm not sure about it, but it's how I understand it :)

     

    Regarding 5 V - you answered your question by yourself, if your Master and slave have 5V tollerant pins, than yes. if no use voltage devider. or make pullup from 3.3V net