Hi, i try to enable two channel sequential conversion in AD7192 Driver on linux but i cannot fint what to do.
there are any setting in actual driver to do?
or exist a new patch for this?
thanks in advance
Solved by myself..
after adding status byte in the response, i have add a virtual channel with bit 0 and bit 1 enabled.
i have named it "in_voltage1-voltage4_en", this work well.
if anyone needs this is the only solution i have found!
One way to do this is to use libiio with the iio_readdev command.
Link: iio_readdev [Analog Devices Wiki]
Regarding libiio, there are some details here:
About libiio [Analog Devices Wiki]
You could also go to sysfs directly and issue commands to enable capture of samples
The device should be at /sys/bus/devices/iio:deviceX
"echo 1 > /sys/bus/devices/iio:deviceX/scan_element/in_voltage0_en"
"echo 1 > /sys/bus/devices/iio:deviceX/scan_element/in_voltage1_en"
In essence libiio does this for you.
For more info/details checkout Analog Devices Wiki [Analog Devices Wiki] [ you can search for various information there ].
Specifically for AD7192, there's: AD7192 IIO High Precision ADC Linux Driver [Analog Devices Wiki]
Hope this helps.
Hi, thanks for answer,i have not implement iio_readdev in linux.
but i have try this on my driver:
but when i try to enable the second channel system say:
echo: write error: Invalid argument
seems to be blocked from the driver the selection of two channel at same time.
i have see that analog Devices have update the driver respect to mine, i will try with the new one.
I forgot to ask.
Which repository [or kernel version] are you using ?
We're trying to upstream stuff as fast as we can, but stuff gets into Linux only after a certain while.
i still using a driver of 2012-09-16, now we can add the possibility to use two or more channel sequentially read.
in next week i try to update our driver with the new Analog Devices Driver.
if i have any dubt i write here again.
I have try the last driver but i can only activate one channel at time,
i have enable in the driver the AD7192_MODE_DAT_STA for reading the converted channe number and this work.
now i need to enable ad7192 to read alternatively dual channel (CH1,CH2 and CH3,CH4).
i have do this in other uProcessor simply enabled bit 0 and bit 1 of mode register channel selection
in this driver i cannot do this, please help me
for more information about sequencer:
Retrieving data ...