I2C Potentiometer AD5245
-
On my board, I made an adjustable power supply for external devices.
It is connected to I2C bus of Omega2S+, and I could see it's present correctly.
root@OpenWrt:~# i2cdetect -y 0 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 20: -- -- -- -- -- -- -- -- -- -- -- -- 2c -- -- -- 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 70: -- -- -- -- -- -- -- -- root@OpenWrt:~#
On the Analog Devices Wiki post, there's insturctins how to setup the driver.
I ranmake kernel_menuconfig
and customized the kernel for supporting AD's I2C potentiometer devices.Device Drivers ---> [*] Misc devices ---> <*> Analog Devices Digital Potentiometers <*> support I2C bus connection < > support SPI bus connection
After compiling and flashing I expected that I could see the three EEPROM setting devices as AD's wiki says.
# ls /sys/bus/i2c/devices/ 0-0022 0-0027 0-002f
But I could only see this.
root@OpenWrt:~# ls /sys/bus/i2c/devices/ i2c-0 root@OpenWrt:~#
Controlling AD5245 by I2C commands is not that complex, and it won't be much difficult to port some Arduino or MicroPython library into a small Python lib for Omega2.
But it would be great if I can use the native Linux driver.
What am I missing in configuration?
-
This post is deleted!