LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Who can help me with a PID VI?

I need a PID control routine in labview, does anyone have one that works?
 
I have the PID toolkit, and have tried implementing there sub VI's but they just flat out don't work. Mostly because they are SLOW AS MOLASSES.
 
Here is what i want to do. I have a shaker, and an LVDT on the shaker.
 
The shakers input is power, not displacement. So i need to control the displacement of the shaker by using feedback from the lvdt as the error signal. I will be using a complex displacement waveform which i have represented as a displacement table in excel.
 
So in essence, i prescribe the displacement, the pid controller outpus some "power" out and adjusts that power signal to closely follow the displacement table?
 
How would i go about doing this? Im using MX.
0 Kudos
Message 1 of 13
(3,324 Views)
The PID routines are as fast as the computer will allow them to run.  The settings have a huge effect on the output response of the system.  You should be able to us them, but it just needs to be tuned.
0 Kudos
Message 2 of 13
(3,319 Views)

"Vr6Fidelity" <x@no.email> wrote in message
news:1155849011855-405552@exchange.ni.com...
> I need a PID control routine in labview, does anyone have one that works?
> &nbsp;
> I have the PID toolkit, and have tried implementing there sub VI's but
they just flat out don't work. Mostly because they are SLOW AS MOLASSES.
> &nbsp;
> Here is what i want to do. I have a shaker, and an LVDT on the shaker.
> &nbsp;
> The shakers input is power, not displacement. So i need to control the
displacement of the shaker by using feedback from the lvdt as the error
signal. I will be using a complex displacement waveform which i have
represented as a displacement table in excel.
> &nbsp;
> So in essence, i prescribe the displacement, the pid controller outpus
some "power" out and adjusts that power signal to closely follow the
displacement table?
> &nbsp;
> How would i go about doing this? Im using MX.



--
Posted via a free Usenet account from http://www.teranews.com

0 Kudos
Message 3 of 13
(3,312 Views)
So how do i make it work correctly is my question? Can someone help me out ?
0 Kudos
Message 4 of 13
(3,302 Views)
Please post your VI. It is much easier to suggest improvements if we can see what you have tried. Also give some specifications: How fast do you need to update the power setting? How often do you read the LVDT? Are there other things happening which might consume CPU cycles?

Lynn
0 Kudos
Message 5 of 13
(3,296 Views)
Basically, the LVDT is the process value, your setpoint is from motion profile you generate elsewhere, and the output of the PID moves the shaker table.  Start slowly by just moving the shaker table between 2 setpoints.  You can use the autotune VI to get some decent PID values.  Once it is tuned, then start feeding the other setpoints to it.
0 Kudos
Message 6 of 13
(3,292 Views)
Here is the Vi i am currently working with. It has no problems and no PID.  (The PL V4 Mean.vi)
 
Here is my attempt at implementing PID feedback: (The PL V5 PID.vi)
 
Drive signal is the output, LVDT is the feedback control signal.
 
 
 
Download All
0 Kudos
Message 7 of 13
(3,291 Views)
You have 3 DAQ assistants. Are they all talking to different boards?
0 Kudos
Message 8 of 13
(3,284 Views)
No i only have one board but couldnt figure out how to do it all with one assistant.
0 Kudos
Message 9 of 13
(3,282 Views)
I don't use those little guys (DAQ assistants) myself. However it looks to me like you have 3 tasks trying to run on one board. So it's either going to run very slow or produce error messages everywhere. What do you see for the error clusters?
0 Kudos
Message 10 of 13
(3,267 Views)