Skip to contentSkip to conversation

Cant read more than 2 bytes from triggered buffer 3.10

DISCUSSION Zubair Lutfullah : 1 participant 1 message Jul 21, 2013 IIO

lore
Share & tools
lore
#0 lore raw

I am running kernel version with the tag 3.10.

I am trying to read data from a triggered buffer I created for the ti-adc driver. Just wanted to read a counter back using generic_buffer.c and sysfs triggers.

But for some reason, I can only read 2 samples using generic_buffer.c

I tried a dozen printfs and lots of hours.
indio_dev->scan_bytes seems fixed at 8 or 4.
indio_dev->masklength is similar 8 or 4.

I use generic_buffer -n TI-am335x-adc -t sysfstrig1 -l 1024.

but only one sample output or two.

I enabled the simple dummy buffer and tried triggering it too. Only 1 sample..
no matter the buffer length.

Have spent a couple of hours messing over this. But I can't get my counter output from the driver.

If anyone wants to see the modified am335x adc driver

pastebin(.)com/1Zrw3KTt

Hope somebody can point out whats wrong..

Thanks
Zubair Lutfullah