On 10/08/2015 10:06 PM, Rick Mann wrote:
> What would it take to get libiio:
> 
>       https://wiki.analog.com/resources/tools-software/linux-software/libiio
> 
> Into the BBB kernels? I think this would be amazing.

Hi Rick,

the linux kernel supports IIO (industrial input output) for quite some
time and the BBB ADC has a IIO driver. You will have to enable the ADC
pins in the device tree.

I just started using the libiio on the BBB to read all 8 ADC channels. I
initially tried it with the latest 4.2.x-bone linux kernel, but ran into
issues enabling buffer continuous mode, so reverted back to 4.1.5-ti-r10
(ubuntu 15.10). Didn't investigate further what makes it different, will
do whenever have the opportunity.

I'm also investigating the low sample rates I'm getting...when creating
the buffer the library complains: "WARNING: High-speed mode not
enabled". The full source code is available and the documentation has
reasonable quality, so it's just a matter of putting some time and
effort improving it.

Just for reference, here's the list of loaded modules after enabling the
ADC through the device tree:

~$ lsmod
Module                  Size  Used by
ti_am335x_adc           5984  0
kfifo_buf               3524  1 ti_am335x_adc
industrialio           52301  2 ti_am335x_adc,kfifo_buf
omap_rng                5254  0
rng_core                8737  1 omap_rng
ti_am335x_tsc           6048  0
ti_am335x_tscadc        6199  2 ti_am335x_adc,ti_am335x_tsc
uio_pdrv_genirq         3745  0
uio                    10395  1 uio_pdrv_genirq
tilcdc                 32944  0

~$ uname -r
4.1.5-ti-r10

~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu Wily Werewolf (development branch)
Release:        15.10
Codename:       wily

regards,
Nuno

-- 

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beagleboard+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to