Jump to content

I2C Frequency


Aaron.energy

Recommended Posts

I was wondering if anyone could help with the following issue,

 

We are working on a project utilized with an Orange Pi Lite, ALLWINNER H3 processor and Armbian stretch mainline kernel,

Now we are bundled a chip over GPIO, due to the chip frequency we looking for a library or setting file to modify and match I2C frequency with the chip,

 

BR,

Link to comment
Share on other sites

3 hours ago, Aaron.energy said:

it's possible to establish changes in a working armbian.

Yes ! you simply need to decompile device-tree DTBO into DTS source using "dtc" compiler, edit the DTS by adding "clock-frequency = <100000>;" in the i2c node, and then re-compile it into DTBO (after having take care of doing a backup of original DTBO).

 

Link to comment
Share on other sites

Tnx martin,
I found the the proper dtb file in /boot/dtb directory. According to my board version it was sun8i-h3-orangepi-lite.dtb which I recompiled it and successfully its i2c frequency changed.cd /boot/dtb
Following I insert my instructions maybe it can help some other people. :)
dtc -I dtb -O dts sun8i-h3-orangepi-lite.dtb -o sun8i-h3-orangepi-lite.dts
#modifiy dts file and set clock-frequency=0x009c40 in node i2c@01c2ac00
dtc -I dts -O dtb sun8i-h3-orangepi-lite.dts -o sun8i-h3-orangepi-lite.dtb
sudo reboot

Link to comment
Share on other sites

i found a more recent dtc compiler which might be shipped in a 'future' release of debian (it isn't in nightly) that has the dynamic overlay and symbol substitution features

it is actually a more recent version of dtc bundled with the linux kernel. Some how that recent version didn't get bundled with the recent kernels which uses those features

 

 

 

 

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines