This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

ADC Access using TI SDK 7.0 on AM3352

Other Parts Discussed in Thread: AM3352

I am trying to get the analog inputs working on the AM3352.

In the Linux kernel, I have enabled the following:

Device Drivers  ---
           [*]  Industrial I/O support  --->  
           [*]  Enable buffer support within IIO
                  <*>    IIO callback buffer used for push in-kernel interfaces                                                   
                  < >     Industrial I/O buffering based on kfifo
                  -*-  Enable triggered sampling support                                                                      
                  (2)     Maximum number of consumers per trigger
                       Analog to digital converters  --->
                                <*>   TI's ADC driver

In the device tree, I have got

tscadc: tscadc@44e0d000{

status = "okay";

adc {

ti,adc-channels = <0 1 2 3 4 5 7>;

};

};

And I do have the sevent channels showing up under iio:device0:

root@LiteOn-SMC:~# ls -al /sys/bus/iio/devices/iio\:device0/
drwxr-xr-x 3 root root 0 Mar 17 15:25 .
drwxr-xr-x 4 root root 0 Mar 17 15:25 ..
-r--r--r-- 1 root root 4096 Mar 17 15:25 dev
-rw-r--r-- 1 root root 4096 Mar 17 15:25 in_voltage0_raw
-rw-r--r-- 1 root root 4096 Mar 17 15:25 in_voltage1_raw
-rw-r--r-- 1 root root 4096 Mar 17 15:25 in_voltage2_raw
-rw-r--r-- 1 root root 4096 Mar 17 15:25 in_voltage3_raw
-rw-r--r-- 1 root root 4096 Mar 17 15:25 in_voltage4_raw
-rw-r--r-- 1 root root 4096 Mar 17 15:25 in_voltage5_raw
-rw-r--r-- 1 root root 4096 Mar 17 15:25 in_voltage7_raw
-r--r--r-- 1 root root 4096 Mar 17 15:25 name
drwxr-xr-x 2 root root 0 Mar 17 15:25 power
lrwxrwxrwx 1 root root 0 Mar 17 15:25 subsystem -> ../../../../../bus/iio
-rw-r--r-- 1 root root 4096 Mar 17 15:25 uevent

However, mode, buffer and scan_elements are missing. How do I set the ADC to continuous mode?

Any help are greatly appreciated.