03-07-2017 02:16 PM
Hello,
I´m new to LabView and I need it for my bachelorthesis.
I have constructed a two-mass system of a machine tool with control design and simulation module to see the deformation in real time in result of the measured machining force.
Now I want to compile my system for the use on a fpga. The system must be discrete and with fxp-data type, but how can I convert the system and compile for my fpga cRio-9082?
Do any one know how to solve my problem?
Thanks
Yanik
Solved! Go to Solution.
03-08-2017 03:17 PM - edited 03-08-2017 03:18 PM
well, you CAN use single precision floating point on FPGA. The cRIO 9082 also has a big FPGA. So you might just try doing your FPGA code using single precision float and see how much resources it uses-- from the apparent size of your program I think you can do it. Try it. The only thing that gives me pause is those gains on the order of 10E^7 , I wonder if you start losing precision there multiplying small by big numbers. Maybe think about scaling things different if it's a problem.
So gain is just a multiplication, you have that in FPGA. For doing the integrals you may have to "roll your own" using the old feedback node accumulator technique. basically you store the running integral in a feedback node (or shift register), each iter add the current value scaled by timestep. You could also use the discrete normalized integrator in FPGA-- scaling the input appropriately to a -1 to 1 range.
03-08-2017 03:22 PM - edited 03-08-2017 03:27 PM
oh yeah and use the FPGA simulation mode if you don't know about that. You will have to create a new VI under an fpga target and basically re-write that simulation code
03-09-2017 03:41 AM
thanks for your answer.
Now it runs on my fpga.