LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

PID control on FPGA - needs more memory to compile

Hello,

 

I am working on a PID controller on the FPGA module using cRIO-9076. The code is written using labview 2013 SP1.

I have used the Example project "Using Discrete PID - cRIO.lvproj" (labview\examples\control\pid\fpga.llb\CompactRIO) as a starting point, but for the host VI I replaced the plant simulator subVI with a discrete transfer function within a control & simulation loop (both found under control design & simulation module). I left everything else on the host VI and the FPGA vi pretty much the same, but somehow the host VI is not compiling because "labview needs more memory to compile VI". The code itself is pretty simple and there is plenty of memory available on the computer, so I don't understand what is causing this problem. Does anyone have any advice as to what I can do to decrease memory usage on the host VI?

 

Regards,

 

Shin

0 Kudos
Message 1 of 14
(3,562 Views)

Can you share the code (ideally all the related VIs, in a zipped file) that generates the error? Does the error occur when you try to run the host, or when you compile the FPGA?

0 Kudos
Message 2 of 14
(3,545 Views)

I'm sorry, but I'm not clear. When you say the "host", do you mean the cRIO, or the PC connected to the cRIO?

 

Mike...


Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 3 of 14
(3,540 Views)

Hello Nathan,

 

Thank you for the quick reply. The FPGA compiles fine, the error occurs when I compile the host VI.

Here is the zip file of all the related VI's.

0 Kudos
Message 4 of 14
(3,539 Views)

I'll have to look at it later, I'm still on LabVIEW 2012 here (have 2013 available elsewhere). But I'm confused about one thing - you should never need to compile the host VI. That happens automatically in the background when you edit or deploy the VI (depending if you're running it on your computer or on a remote RT target). If your host is actually under the FPGA target and you're right-clicking and compiling it, you're doing it wrong. If not, then exactly at what point does the error occur? When you click the Run arrow?

0 Kudos
Message 5 of 14
(3,533 Views)

Hello Mike,

 

In this project, the host VI is located under the cRIO target.

Attached is an image of the project explorer window.

0 Kudos
Message 6 of 14
(3,530 Views)

I actually meant to say that the host VI does not "run", meaning that the error occurs when I click the run arrow on the host VI. I am sorry for the confusion, I am still getting used to the terminology as I am relatively new to labview.

0 Kudos
Message 7 of 14
(3,526 Views)

Do you have a large amount of data stored in the host VI in some form - for example, a graph or an array control holding many values? Make sure those are cleared and not saved as default values, they can eat up a lot of memory. Again, sorry I can't actually look at your VI right now, which would let me answer the question myself.

0 Kudos
Message 8 of 14
(3,521 Views)

I have two waveform charts, one that plots the controller output and one that plots the setpoint and the process variable. Apart from that, I have a few controls but nothing too large. I will try running the host without the two charts. Thank you for the advice!

0 Kudos
Message 9 of 14
(3,516 Views)

Doesn't look to me like the charts are the problem. My next guess is there's some issue with the transfer function, but I haven't used the simulation toolkit and don't have it installed so there's nothing I can do to look at it, unfortunately.

0 Kudos
Message 10 of 14
(3,496 Views)