Jump to content

FPGA Read/Write Control vs. DMA FIFO

Recommended Posts

Hello Everyone,

This is my first post in this community. I am also very new to labview. I apologize in advance for my elementary understanding. I am currently writing a program in which I am using FPGA on my NI cRIO9045 to output analog signals (AO NI 9263) to a programmable pump. I am inputting very specific custom waveforms into the system and would like to output a voltage waveform to the pump corresponding to the input.

Currently, my Host VI sends over an excel waveform input as a double shared variable array to my RT VI. My RT VI isolates each individual value in the array and delays the output of the value to the FPGA based on the frequency desired for the waveform. I am currently using a timed loop in the RT. I am sending over the data points periodically to the FPGA using the Read/Write Control. Considering that latency and throughput both matter for my application, should I use this function or should I switch to DMA FIFO. The smallest wait time I am establishing on the RT between each data point is 500 microseconds.

Should I be concerned about using this function considering that my loop iteration time is 500 microseconds when I am using a 1MHz timed loop clock.

For data acquisition, would you recommend that I use DMA FIFO considering latency doesn't really matter?

I appreciate all your help!

Link to comment

Well the real answer is probably going to depend on what works for you.  The setup you have now is obviously easier than re-writing it to use a DMA FIFO.  But if you are worried about precision of the waveform you can put a scope on it and look at some transitions to see how different the waveform is from the expected output.

Years ago I did develop some code that allows for a table of times and voltages to be sent to the FPGA, and then in my case it would linear interpolate between the points, sending out the data timed by the FPGA.  The code could be improved a lot, but it might give you an idea of what is possible, and how to do some timing of a table output.  My situation was with a non repeating waveform that could be many hours long.  I initially tried doing this with DAQmx hardware, adding to a finite buffer as time went on.  But this became difficult to manage, and there were memory issues.  My wave also was discrete points, and not a sine wave.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

By using this site, you agree to our Terms of Use.