mainsail-crew/MainsailOS

Raspberry Pi | i2c only partially enabled by default

ashthespy opened this issue · 0 comments

What happened

#196 seems to only partially enable i2c by default

$ i2cdetect -y 1
Error: Could not open file `/dev/i2c-1' or `/dev/i2c/1': No such file or directory

$ sudo raspi-config nonint get_i2c
0
$ lsmod | grep i2c
i2c_bcm2835            16384  0

What did you expect to happen

You also need to load i2c-dev for the actual devices to show up.

$ modprobe i2c-dev
$ i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:                         -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- 36 -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

How to reproduce

Current Mainsail OS install on a Raspberry pi 4

$ i2cdetect -y 1
Error: Could not open file `/dev/i2c-1' or `/dev/i2c/1': No such file or directory

Additional information

No response