Closed anguselheimStudios closed 9 months ago
It looks like it was implemented in a very confusing way, but apparently necessary due to various versions of the same board.
If you type ls /dev/i2c*
, what do you see? It appears there was no error handling added for the section, so it's expecting 2 I2C ports and not seeing that.
There are two ports:
angus@odroidn2:~$ ls /dev/i2c*
/dev/i2c-0 /dev/i2c-1
Yeah, Hardkernel kind of sort of treat the n2 and the n2+ as the same thing kind of maybe a little, but not always. It's a little strange.
I think a good solution will be to add a check to see if the structure of i2cPorts matches what the code expects.
This is my first time reporting an issue, so please let me know if I'm sharing to much or little, or whatever other faux pas I may be making.
Running python without sudo I get a "permission denied" message when I try to import board.
Running python as sudo I get this:
My system info:
I went through the same install steps as I did with my Libre Computer AML-S905X-CC "Le Potato", which worked successfully on that board. Edit: I run Ubuntu 22.04 with the Mate Desktop on that board.
I have also successfully run a simple blink script using gpiod directly in python3, so I'm pretty sure libgpiod is OK.