Hi Cobus,
Using the Beaglebone black and SDK 6.0 (PSP 04.06.00.11)able to see the ADC entries entry in the sys:
- I just followed the ADC drivers docs from the wiki below:
http://processors.wiki.ti.com/index.php/AM335x_ADC_Driver%27s_Guide
I added the below line in beagleboneblack_dev_cfg[] of the board-am335xevm.c:
{mfd_tscadc_init, DEV_ON_BASEBOARD, PROFILE_ALL}
See as well:
http://e2e.ti.com/support/arm/sitara_arm/f/791/p/260624/914357.aspx#914357
Apart from this I did not have to patch any code.
- On the target I just load the module:
root@am335x-evm:/lib/modules/3.2.0/kernel/drivers/staging/iio/adc# insmod ti_adc.ko
[ 182.737792] ti_adc: module is from the staging directory, the quality is unknown, you have been warned.
[ 182.749114] tiadc tiadc: attached adc driver
and get:
root@am335x-evm:/lib/modules/3.2.0/kernel/drivers/staging/iio/adc# ls -la /sys/bus/iio/devices/iio\:device0/
drwxr-xr-x 5 root root 0 Jun 26 19:12 .
drwxr-xr-x 4 root root 0 Jun 26 19:09 ..
drwxr-xr-x 2 root root 0 Jun 26 19:14 buffer
-r--r--r-- 1 root root 4096 Jun 26 19:14 dev
-r--r--r-- 1 root root 4096 Jun 26 19:14 in_voltage4_raw
-r--r--r-- 1 root root 4096 Jun 26 19:14 in_voltage5_raw
-r--r--r-- 1 root root 4096 Jun 26 19:14 in_voltage6_raw
-r--r--r-- 1 root root 4096 Jun 26 19:14 in_voltage7_raw
-rw-r--r-- 1 root root 4096 Jun 26 19:14 mode
-r--r--r-- 1 root root 4096 Jun 26 19:14 name
drwxr-xr-x 2 root root 0 Jun 26 19:14 power
drwxr-xr-x 2 root root 0 Jun 26 19:14 scan_elements
lrwxrwxrwx 1 root root 0 Jun 26 19:12 subsystem -> ../../../../../../bus/iio
-rw-r--r-- 1 root root 4096 Jun 26 19:12 uevent
Anthony