Jump to content

Recommended Posts

Posted

Hi,

I tried to enable the i2c in u-boot by using the config flags shown in the Readme. But I had no success.

What do I miss?

Posted
49 minutes ago, rlu said:

I tried to enable the i2c in u-boot

Do you mean adding DT overlays in /boot/armbianEnv.txt ?

Simply add a line "overlays=i2c0 i2c1" in /boot/armbianEnv.txt

 

Posted

I’ve done this and in Linux I can access the i2c0, but I want to access it in u-boot.

And i'm stuck there.

I added the following code into the sun50i-h5-nanopi-neo2.dts, but now I see the i2c bus, but it is shown as Bus -1 and I can't access it

&i2c0 {
	pinctrl-names = "default";
	pinctrl-0 = <&i2c0_pins>;
	status = "okay";
};

 

Posted
16 minutes ago, rlu said:

but I want to access it in u-boot

Why do you need i2c0 in u-boot itself ?

You will need to compile a u-boot yourself with CONFIG_I2C0_ENABLE=y in the board defconfig.

 

EDIT : In the current v2018.05, I'm only seeing 2 boards that have it :

cache/sources/u-boot/v2018.05/configs/Colombus_defconfig:CONFIG_I2C0_ENABLE=y
cache/sources/u-boot/v2018.05/configs/Cubietruck_plus_defconfig:CONFIG_I2C0_ENABLE=y

 

Posted

I compiled u-boot myself and added the CONFIG_I2C0_ENABLE=y to the defconfig.

After that I wasn't able to see the i2c0 in u-boot.

then I added the code above and now I see the i2c bus. But I can't access it, because it is shown as Bus -1.

 

At the moment it is only an exercise to get common with u-boot. Later I want to get dual boot via u-boot

Posted
2 hours ago, rlu said:

At the moment it is only an exercise to get common with u-boot. Later I want to get dual boot via u-boot

But in what dual boot requires I2C ?

Posted

The I2C is for enabling a Bakebit Oled for Boot, so that I later can select which OS I want to use from my dual boot

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

Important Information

Terms of Use - Privacy Policy - Guidelines