Skip to main content
Graduate
January 12, 2024
Solved

Setting sensor hub master i2c clock speed

  • January 12, 2024
  • 6 replies
  • 2402 views

Hi @Federica Bossi , I need help with setting LSM6DSO sensor hub i2c master clock speed.

 

How do I set the master i2c clock speed between LSM6DSO and external sensor for sensor hub operation? Is there registers or something else on LSM6DSO that controls master i2c clock speed between external sensors?

 

If there is anything I am mistaken about, please do correct me.

Thanks,

    This topic has been closed for replies.
    Best answer by Federica Bossi

    Hi @el659 ,

    In LSM6DSO you can't modify the I2C clock of the sensorhub

    6 replies

    Technical Moderator
    January 12, 2024

    Hi @el659 ,

    It's all described in section 7 of AN5192, please refer to it.

    FedericaBossi_0-1705073026857.png

     

    el659Author
    Graduate
    January 12, 2024

    Hi @Federica Bossi,

    I have read through section 7 of AN5192 but I haven't found anything about master i2c clock speed between LSM6DSO and external sensor during sensor hub operation but SHUB_ODR[1:0] in MASTER_CONFIG, which is something you already replied in my previous post.

    el659_0-1705076724521.png

    i2c clock speed can be up to 400 khz but this number is never close 104 hz and seeing that it is SHUB_"ODR"_[1:0], this cannot be the i2c clock speed, right?

    el659Author
    Graduate
    January 12, 2024

    @jocktmpbd7 

    Ive read through the datasheet and couldn't find it. That's why I am asking the forum for help.

    Nothing but MASTER_CONFIG mentions master i2c configuration but even the bits in this register don't mention anything about "clock speed".
    Ive also read through other registers to see if I missed anything but I haven't found anything about clock speed. I could be wrong cuz my eyes are tired after reading the datasheet for hours.

    Super User
    January 12, 2024

    The datasheet does seem lacking here. Did you try it? I would bet it is fixed to either 100 kHz or 400 kHz internally without the option to change it.

    el659Author
    Graduate
    January 12, 2024

    I haven't checked it yet cuz I thought I would be able to change the clock speed through software, but now that you mention it, I think that could be very likely since AN5192 mentions external pull ups are optional for SDx and SCx pins. I will give it shot with oscilloscope and come back to it. In the meantime, I really hope someone has an answer for it.

    Thank you for your advice @TDK 

    Technical Moderator
    January 16, 2024

    Hi @el659 ,

    In LSM6DSO you can't modify the I2C clock of the sensorhub

    el659Author
    Graduate
    January 16, 2024

    Hi @Federica Bossi 

    Thank you for the valuable of information.

    Could you also tell me the fixed sensorhub's i2c clock speed, since it is also not on the datasheet?

    Technical Moderator
    January 19, 2024

    Hi @el659 ,

    It is about 100kHz.