Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

image acquisition FGPA C Api and NI-1473R-LX110

Solved!
Go to solution

Hello NI Community,

I am working on a project that requires image acquisition in a C/C++ application while using the NI-1473R board. Hence I am relying on FGPA C Api generator to access the image data sent to FIFO.

If I generate the header file from the 10-tap 8-bit example file, I see that I have access to Camera Serial port and Acquisition controls and indicators. I can also read from the FIFO, using 'Host DMA U8' VI. 

My questions are:

1- Do I just use a FIFO method function (NiFpga_ConfigureFifo2) with a certain Depth to acquire a single image in the host? Because that is basically done in the HOST VI in the example.

2- I can't seem to find a good example for such purpose? FPGA C Interface comes with simple examples, but I rather have a more in-depth example (related to image processing) to look at.

 

Best,

Mehmet

 

 

0 Kudos
Message 1 of 3
(2,442 Views)
Solution
Accepted by topic author mesolmaz

Hey Mehmet,

 

1- You need to configure the buffer for a size that will not cause it to be a bottleneck for your system hardware.  Ideally, you have an image of size x that grabs images at rate y and you can have a buffer of x and your computer will grab them from the buffer at rate y.  But, if you are on a PC and not on a real time system, you may need to increase the buffer size if the rate is too fast for the PC speed.  You are correct though, set a buffer size and the host will pull from that buffer.

 

2- You may have to combo two examples.  As far as the examples go, they are usually demonstrating one feature/concept.  Maybe give us an example of pseudo code you want to implement and a community member can give it a shot!

 

-Bear

Regards,

Ben Johnson
ʕง•ᴥ•ʔง
Message 2 of 3
(2,393 Views)

Thank you, I think I figured it out. I was confused about the FIFO size, overflow. The host C code just uses the buffer to continuously pull from. 

0 Kudos
Message 3 of 3
(2,345 Views)