On Mon, Aug 4, 2014 at 10:50 PM, Lars-Peter Clausen <lars@xxxxxxxxxx> wrote: > On 08/04/2014 05:11 PM, Aniroop Mathur wrote: >> >> On Mon, Aug 4, 2014 at 12:48 PM, Lars-Peter Clausen <lars@xxxxxxxxxx> >> wrote: >>> >>> On 08/03/2014 11:32 AM, Aniroop Mathur wrote: >>>> >>>> >>>> On Sun, Aug 3, 2014 at 1:41 PM, Lars-Peter Clausen <lars@xxxxxxxxxx> >>>> wrote: >>>>> >>>>> >>>>> On 08/02/2014 06:57 PM, Jonathan Cameron wrote: >>>>> [...] >>>>> >>>>>>> So, even after opening iio device node, >>>>>>> can we write the data to IIO device node from user space ? >>>>>>> (I do not see write function in below fileops) >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> Indeed. Lars was working on some buffered support for DACs but hasn't >>>>>> yet submitted it for mainline inclusion. Lars how is the buffered >>>>>> output >>>>>> stuff coming along? >>>>> >>>>> >>>>> >>>>> >>>>> I still need to do the re-write you wanted me to do, otherwise its >>>>> working >>>>> fine ;) >>>>> >>>> >>>> Great :) >>>> So, it is possible to write data to iio fd ? >>> >>> >>> >>> No you can't. At least not with the upstream code. What exactly is it >>> that >>> you want to do with this? >>> >> >> Okay :) >> Actually, I am working on IIO device simulator android application. >> This simulator will record the sensor data first and then replay it again. >> For recording, we can read the data from iio device node and store it some >> file. >> And for replay, we need to write the recorded data back to iio device >> node. >> But as you said, from hal/application we cannot write the data to iio >> device node >> and therefore i am stuck how to replay back the recorded data. >> >> In normal input device node, we can both read and write data, >> so simulator is working fine for this case. >> I was hoping to do the same with IIO device node. >> >> Is there any scope this facility will be included in future for IIO ? :) > > > Injection of data into the output stream of a IIO device is something that's > not planed at the moment I think. The writing support Jonathan referred to > is for writing data to actual hardware (e.g. a DAC). If you think it will be > useful to have support for injecting data into a abitrary IIO datastream > rather than e.g. having dummy loopback device you can submit a patch which > adds support for this. > > - Lars > Okay :) I will try to add the write feature and submit the patch soon for review. Thank you so much for your support ! :) -- Aniroop -- To unsubscribe from this list: send the line "unsubscribe linux-iio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html