Em 10/02/2016 14:05, "vivek singh" <[email protected]>
escreveu:
>
> Hello,
>
> I want to use EPICS in my raspberry pi for beam
position measurement. I will be using 4 16-bit ADC's for
digitizing the output of the pickup electrodes. The ADC's
support serial and parallel interfaces. Since the Pi does not
have that many GPIOs, I will be using Serial Interface to get
the data. I have a few questions regarding that.
>
> 1. The ADC (AD7622) supports 2MSPS. I wrote a python code
to toggle a GPIO pin on a loop after some calculations and the
maximum switching frequency I could observe in the
> Oscilloscope was 500kHz. Is that the maximum speed I
can achieve using PI ?
If you need to acquire at 2 MSPS without skipping
data, the Raspberry PI GPIO is unsuitable for that, since you
won't be able to reliably acquire due to the OS and the hardware
interrupts. I'm assuming however that you don't need all the
data. In this case it doesn't really matter what's the maximum
speed, you'll have up to 10~100 ms of "blind" moments, when you
don't acquire any data while your application is preempted.
If you need any kind of number, a GPIO read reaches
10 MHz. See, for example:
https://www.raspberrypi.org/forums/viewtopic.php?f=44&t=26907
>
> 2. The Pi has a dedicated SPI interface, so what is the
maximum speed that can be achieved using it ?
It may reach 32 Mbps. See:
http://elinux.org/RPi_SPI
>
> Another query I had, was regarding multicore processing
capability of the Pi.
>
> 3. Is it possible to control individual cores, so that they
can each perform one task that I assign to them, at their
maximum capacity ?
If you're running standard linux, then your tasks
will always share and be interrupted by other parts of the OS.
You can still move each task to a different core by setting the
process affinity or using cpusets. See:
http://man7.org/linux/man-pages/man7/cpuset.7.html
>
>
> Any other suggestions you have regarding this setup would
be very
You should be doing this on a microcontroller without
an OS that is able to stream the data to a PC, or a storage
device. The Raspberry PI is not appropriate.
>
> Thank You,
>
>