03-15-2018 08:27 AM
I am developing code for the FPGA on a cRIO-9081. In it there are 4 places that I want to wait different amount of time depending on what I am doing, the wait time are 8.3, 10.0, 53, and 200 seconds. I don't want to use the WAIT VI, instead I want to use two TICK VIs and a WAIT VI that only wait 5 mSec to measure the elapsed time. I created a Sub VI, see attachment that takes the seconds as inputs.
This got me started thinking about how the FPGA would implement the code. Would it create 4 identical structures in the hardware or one structure with a switch to switch the inputs.
I think it would create 4 identical structures in the hardware, whereas Sub VIs in LabVIEW FPGA are not true subroutines that the code "jumps" to.
Can anyone tell me for sure?
Solved! Go to Solution.
03-15-2018 08:34 AM
It actually depends on your reentrancy setting for the VI. If you have it set up to be non-reentrant, then it will be a shared fabric with mutexes added. If you have it set up to be reentrant, which is the default for VIs made in the FPGA context, then the fabric will be duplicated for each call of that VI.
03-15-2018 09:01 AM
Thanks