0
Peter Heß

Need help in understanding a i2c configuration effect

Recommended Posts

(edited)

Hello,

 

I configured 2 armbian on sd card and the configuration of the i2c is the same in armbianEnv.txt. Plattform Olimex-Lime2 A20

 

verbosity=1
logo=disabled
console=both
disp_mode=1280x1024p50
overlay_prefix=sun7i-a20
rootdev=UUID=194e9f9a-826b-4644-9f2f-4ef388277816
rootfstype=ext4
overlays=i2c1 i2c2 uart3
usbstoragequirks=0x2537:0x1066:u,0x2537:0x1068:u

as you see, I confiugred the overlays.

 

But on one image I get:

 

#image with desktop

sudo i2cdetect -l
i2c-3   i2c             mv64xxx_i2c adapter                     I2C adapter
i2c-1   i2c             mv64xxx_i2c adapter                     I2C adapter
i2c-2   i2c             mv64xxx_i2c adapter                     I2C adapter

and booting the other image I get

 

# headless image

sudo i2cdetect -l
i2c-3   i2c             mv64xxx_i2c adapter                     I2C adapter
i2c-1   i2c             mv64xxx_i2c adapter                     I2C adapter
i2c-2   i2c             mv64xxx_i2c adapter                     I2C adapter
i2c-0   i2c             sun4i_hdmi_i2c adapter                  I2C adapter

so I get an aditional device for i2c-0.

 

I don't understand what's happening. What could cause this effect? Or better: What must happen, that the i2c-0 does not appear in the list.

One more info: The first image has a runing desktop and the second one in headless. Maybe this has something to do with the issue?

Can someone give me a pointer to understand this. Btw. both versions work perfekt:

 

i2cdetect -y 2

     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: 20 21 -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- UU -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

 

i2cdetect -y 3

     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f

00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: 20 21 -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- UU -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

The 0x68 is a RTC which is configured. So everything is OK, but I drives me crazy not to understand what I've done "wrong". Can someone give me a pointer?

 

Thanks for all help.

Edited by Peter Heß
typo

Share this post


Link to post
Share on other sites
1 hour ago, Peter Heß said:

i2c-0 i2c sun4i_hdmi_i2c adapter I2C adapter

Probably one image is older than the other, and in the older one there is no "sun4i_hdmi_i2c" defined in DT ...

Share this post


Link to post
Share on other sites

its "de" in DT. you can comment/remove

&de {
	status = "okay";
};

in dt

so the i2c hdmi adapter will not be initialized

 

or you can use aliases to define i2c buses like

 

aliases {
    i2c0 = &i2c0;
    i2c1 = &i2c1;
	i2c2 = &i2c2;
	i2c3 = &i2c3;
  };

 

so the i2c hdmi adapter will be named i2c-4 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
0