Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2019-04-04 Thread hovercraft
Hi all! john3909: Sir! Your post in this topic halped me a lot and pointed me into right direction, but I still cannot figure out how to properly load my own version of this BB-ADC-00A0 overlay. Should I put

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2019-04-04 Thread hovercraft
Hi all! john3909: Sir! Your post in this topic halped me a lot and pointed me into right direction, but I still cannot figure out how to properly load my own version of this BB-ADC-00A0 overlay . Should I

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-05-18 Thread John Syne
BTW, you can run iiod on your BBB and then use IIO Oscilloscope on you desktop which can connect to your BBB and display the waveforms. https://wiki.analog.com/resources/tools-software/linux-software/iio_oscilloscope

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-05-18 Thread John Syne
If you are using the latest kernel, you must use u-boot overlays as the kernel capemanager as discussed in that article is no longer available. Regards, John > On May 18, 2018, at 4:57 PM, pierrick.ra...@gadz.org wrote: > > > John, > I am still working on this project. I have studied the

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-04-17 Thread pierrick . rauby
Yes, sorry, my mistake I was looking to section 12.3.3 in the TRM instead on looking to the STEPCONFIG register description sections. Le mardi 17 avril 2018 00:19:16 UTC-4, john3909 a écrit : > > > > On Apr 16, 2018, at 3:40 PM, pierric...@gadz.org wrote: > > Hi John, > Thanks a lot for this

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-04-16 Thread John Syne
> On Apr 16, 2018, at 3:40 PM, pierrick.ra...@gadz.org wrote: > > Hi John, > Thanks a lot for this very complete answer ! I think I understand it now, the > last point I am not sure about is: > > ti,chan-step-avg = <1 1 1 1 1 1 1 1> /* 2 sample average */ > > I went through 12.3.3 of the

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-04-16 Thread pierrick . rauby
Hi John, Thanks a lot for this very complete answer ! I think I understand it now, the last point I am not sure about is: ti,chan-step-avg = <1 1 1 1 1 1 1 1> /* 2 sample average */ I went through 12.3.3 of the AM3358 Technical Reference Manual and it seems that the setting the averaging

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-04-12 Thread Robert Nelson
Thanks John! > Looking at this a little more, there is a mistake in the ADC DT file > BB-ADC-0A00.dts. The maximum averaging is 16, not 0x16. > > The line > ti,chan-step-avg = <0x16 0x16 0x16 0x16 0x16 0x16 0x16 0x16> > > should be changed to > ti,chan-step-avg = <16 16 16 16 16 16 16 16> >

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-04-11 Thread John Syne
> On Apr 11, 2018, at 6:04 AM, pierrick.ra...@gadz.org wrote: > > Hi John, > Thanks for the help, I looked into the iio_generic_buffer.c example and i > patched it to disable the hardware triggers thanks to the patch presented on > this page :

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-04-11 Thread John Syne
> On Apr 11, 2018, at 6:04 AM, pierrick.ra...@gadz.org wrote: > > Hi John, > Thanks for the help, I looked into the iio_generic_buffer.c example and i > patched it to disable the hardware triggers thanks to the patch presented on > this page :

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-04-11 Thread pierrick . rauby
Hi John, Thanks for the help, I looked into the iio_generic_buffer.c example and i patched it to disable the hardware triggers thanks to the patch presented on this page : https://www.teachmemicro.com/beaglebone-black-adc/ I am now able to reader a buffer from the different channel. However I

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-03-27 Thread John Syne
Look at the kernel source under tools/iio for examples on how to use IIO. Regards, John > On Mar 27, 2018, at 12:10 PM, pierrick.ra...@gadz.org wrote: > > Hi John, > > Sorry for the late answer, I had hard time using the PRUs and I am now going > to use the IIO ADC driver, I am able to

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-03-27 Thread pierrick . rauby
Hi John, Sorry for the late answer, I had hard time using the PRUs and I am now going to use the IIO ADC driver, I am able to read the sample with the cat command in /sys/bus/iio/devices/iio:device0/in_voltage3_raw However I am not able to use Libiio in order to read data from a user space

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-26 Thread John Syne
The IIO ADC driver can run at 800K samples per second. Here is the patch that made that possible. https://patchwork.kernel.org/patch/9391487/ I can confirm that I have tested the driver at 800Ksps and it works fine as long as you have a proper low impedance source for each ADC channel. CPU

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-26 Thread pierrick . rauby
Thanks John, I am now working with the starterware_PRU but I did not find examples for using the McSPI with the PRU, do you think it will be hard to adapt the initial code to the PRU ? Thanks Pierrick Le lundi 19 février 2018 23:15:50 UTC-5, john3909 a écrit : > > Like I said, it was

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-26 Thread pierrick . rauby
Thanks John, I am now working with the starterware_PRU but i did not find examples for using the McSPI with the PRU, do you think it will be hard to adapt the initial code to the PRU ? By the way, looking to the IIO driver documentation, it seems that for the AM335x chip the max sampling

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-19 Thread John Syne
Like I said, it was based on Starterware, so search Github for starterware and you will see a project starterware_PRU. It does use the mcspi, so it is not a bitbang implementation. Regards, John > On Feb 19, 2018, at 7:33 PM, pierrick.ra...@gadz.org wrote: > > Thanks John for you answer,

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-19 Thread pierrick . rauby
Thanks John for you answer, I was quit busy last week so I worked on this during the Weekend. Unfortunately, I was not able to find a project that is using the SPI and I2C interface with the PRU, I only found this one :

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-13 Thread John Syne
> On Feb 13, 2018, at 1:55 PM, pierrick.ra...@gadz.org wrote: > > Thank you for your quick answerJohn! > > So if I understand well, I can use the PRUs with the on-board SPI and I2C > interface ? I have not found any similar project that can help me on this. > Is it done using the L2 and L3

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-13 Thread pierrick . rauby
Thank you for your quick answerJohn! So if I understand well, I can use the PRUs with the on-board SPI and I2C interface ? I have not found any similar project that can help me on this. Is it done using the L2 and L3 interconnect ? I am highly interested by using those on board interface

Re: [beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-13 Thread John Syne
> On Feb 13, 2018, at 9:49 AM, pierrick.ra...@gadz.org wrote: > > Hi all, > > I am trying to use the PRUs for real time data acquisition on the Beaglebone > black (Linux debian 4.9.45-ti-r57). I have set up the PRU with remoteproc and > RPMsg; everything is working fine. > The first time,

[beagleboard] PRUs realtime data acquisition, I2C bus and ADC

2018-02-13 Thread pierrick . rauby
Hi all, I am trying to use the PRUs for real time data acquisition on the Beaglebone black (Linux debian 4.9.45-ti-r57). I have set up the PRU with remoteproc and RPMsg; everything is working fine. The first time, I successfully captured data with the PRU using the SPI protocol and bit