LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

FPGA: reusable VI

Is there  a way to create a library of reusable host VI for that can communicate with different FPGA VI?  For different FPGA VIs, I meant vi with different controls, DMA, and memory.  I believe the FPGA reference is the issue.  Using dynamic mode will not solve the problem, since the FPGA have different controls and DMA, etc.

------------------------------------------------------------------

Kudos and Accepted as Solution are welcome!
0 Kudos
Message 1 of 4
(2,827 Views)

The host interface refnum implementation is name-based. If the names and data types for each of resources are the same between the different VIs it is possible to reuse host VIs. If not, then no, there is no easy way to reuse the code.

 

There are tricks you can do by passing the host interface wire around with the methods removed and then when there are FPGA vi-specific differences you will have to upcast the reference to the correct refnum and perform the operation. If you do this, I would highly recommend uses classes to hide the specific workarounds where you have a child strategy class that maps to each specific FPGA compilation.

Message 2 of 4
(2,825 Views)

I've never used it personally, but some people have had success with the LabVIEW FPGA Advanced Interface Tools. Just another option if you wan't to try to use something pre-built.

Cheers!

TJ G
Message 3 of 4
(2,821 Views)

 

I use a Strict Type Def control for the FPGA Ref.  When I move to a different FPGA I just change the type def but leave it the same relative location. I also set the FPGA code to separate the source and compiled code so I don't get the dirty dot.

 

I now have a bank of Refs for different FPGAs.

 

Regards

0 Kudos
Message 4 of 4
(2,739 Views)