This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

BQ76942: dealing with clock stretching

Part Number: BQ76942


Tool/software:

Hello,

I'm going to use BQ76942 IC relativelly far away from mCU, so I'm planning to use LT3960 I2C to CAN (physical) converter in between, to decrease negative effects which could occur on I2C bus instead. LT3960 slave unit would be placed near to the BQ76942 IC and LT3960 master unit near to the mCU. Problem is that BQ76942 IC performs clock stretching which is not supported by LT3960. I'm thinking about using another mCU between BQ76942 IC and LT3960 slave unit, which would work as a "I2C buffer" for BQ76942. So, main mCU would communicate with that additional mCU as it would communicate with BQ76942 directly (additional mCU would copy content of needed BQ76942 registers to its memory), but there would be no clock stretching, so there would be compatibility with LT3960. Is there any more simple solution that could be used instead of additional mCU, to "eliminate clock stretching" effect of BQ76942?

Many thanks, Kind regards, Dejan.

  • Hello Dejan,

    It is important to note that support for clock stretching is required to communicate properly with the BQ76942. 

    Best regards,

    Thomas Rainey

  • Hello Thomas,

    thanks for reply.
    Completly understood.

    Maybe it would be easier to explain my idea with schematic below:

    Point 1 shows normal situation - BQ76942 is connected and communicate with Main mCU directly
    Point 2 shows idea of using LT3960 (I2C to physical CAN converter), because distance between Main mCU and BQ76942 is too large for I2C interface. Problem is that LT3960 doesn't support clock stretching I2C devices.
    Point 3 shows my idea how to solve a problem I have. Idea is to put an Additional mCU between BQ76942 and LT3960. Additional mCU which supports clock stretching would read needed registers in BQ76942 and write values into its memory. On the other side, Main mCU would read these values from Additional mCU's memory directly without clock stretching.

    I know that this idea is a little bit complex, but is there any other suggestion how to overcome a problem I have?

    Many thanks,
    Kind regards,
    Dejan.

  • Hello Dejan,

    You would be able to replace the LT3960s in diagram 2 by using an MSP-M0 as an I2C to CAN bridge. This document explains the method of doing this and links to some example code to make development even easier.

    Best regards,

    Thomas Rainey