GPIO documentation

Hi, where is GPIO documentation?
python code, tutorials etc

I would like to setup a fan controller…

The only project that I found is this.

The pinout of the router is in the official documentation.

There are no tutorials yet, but since all GPIOs and other buses are exposed to the Linux kernel, you can use any tutorial or library for linux GPIO, for instance those for Raspberry Pi.

Is someone detection works on the bus i2c-6 devices connected to the router GPIO ?

I plug in OLED i2c, BME280 and not working!

root@Turris:/# i2cdetect -y 6 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 60: -- -- -- -- 64 -- -- -- -- -- -- -- -- -- -- -- 70: UU -- -- -- -- -- -- --
0x70 and 0x64 it was before

Software I2C works:

root@Turris:/# /dev/i2c-
i2c-0  i2c-1  i2c-2  i2c-3  i2c-4  i2c-5  i2c-6  i2c-7  i2c-8

root@Turris:/# insmod i2c-gpio-custom.ko bus0=9,51,56
root@Turris:/# dmesg |grep gpio
[  449.447073] i2c-gpio i2c-gpio.9: using pins 51 (SDA) and 56 (SCL)


root@Turris:/# lsmod |grep i2c
i2c_gpio                3135  0
i2c_gpio_custom         1132  0
regmap_i2c              2789  0

root@Turris:/# i2cdetect -y 9
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- 57 -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- 68 -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

root@Turris:/# /dev/i2c-
i2c-0  i2c-1  i2c-2  i2c-3  i2c-4  i2c-5  i2c-6  i2c-7  i2c-8  i2c-9

connected RTC DS3231

Why does not work the hardware i2c?

I think you are off-by-one. There should be nothing connected to the I2C bus that is connected to the pinheader. You should see only used address 0x70, which is the I2C multiplexer PCA9547PW.

My guess is that 0x64 is ATSHA204A cryptochip, so you are actually scanning bus I2C5. There are 9 I2C buses visible from the OS. My guess is that number 0 is the actual physical I2C master and buses 1 to 8 are multiplexer outputs 0 to 7 respectivelly. So for accessing the I2C header connected to the pinheader – I2C6, you should scan bus number 7.

Thanks, it works.

Description pins i2c as “I2C6-SDA” & “I2C6-SCL” it is very misleading, because you think that you should scan the bus 6.

Okay, now how to use PWM on OpenWRT?
I do not know whether this document is up to date: https://wiki.openwrt.org/doc/hardware/port.gpio/pwm
Has anyone experimented with PWM?

Will service WiringPi?