TX2 NX i2c-0 bus clock speed

Hi all,

Hardware- TX2-NX
Kernel- 4.9.253tegra

I’m currently working on a project that requires the i2c-0 bus speed to be set to 100k for use with SMBUS devices. I’ve been able to change the speed in the following ways but have been unable to make the changes persist through multiple boots or an update.

Firstly I tried altering the bus clock rate file in /sys/bus/i2c/devices/i2c-0/bus_clk_rate
This works fine until reboot.

I found multiple references on the forums to editing this in the device tree binary and after a bit more digging I dumped the DTB decompiled to DTS found the i2c-0 clockrate in hex and edited it. I then recompiled to DTB and reflashed the TX2 NX module. This worked until I ran an update on the device to solve another issue and then the clock speed reverted to 400k.

How to I make this change persist permenantly?

Thanks, Jordan

Dump the dtb and modify it again after update.

That works, but its not a great long term solution.

After some more forum searching I found a nicer way of doing this to prevent having to reflash the TX2 NX every time I want to test a DTB change. I edited the extlinux.conf file and added a new entry with the FDT line to allow me to select a different DTB over serial on boot.


This means that I can test changes with a development option and if anything breaks I can revert to the standard DTB. One thing to note is that the version of L4T origianally on my device 32.6.1 caused the kernel to hang on boot and this had to be updated to a newer version before the extlinux.conf method would work.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.