From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

simple pid controller help me!!

I want to design a simple pid closed loop.

I designed some labview topology but, it does not work. is anyone able to help me?

I attached the labview file.

Thank you.

 

pid.png

Download All
0 Kudos
Message 1 of 6
(3,449 Views)

Hello nim21kr,

 

Thank you for posting your code on the forum.

 

As your code successfully executes, could you please be more specific when you say that the VI does not work?

 

It looks like you are trying to implement a combined PID/transfer function system. What part of this system are you looking to evaluate?

 

The PID Design for Second Order Continuous System.vi example walks through the process of determining the appropriate PID controls for a given system and then validates the system using a combined PID/transfer function simulation loop. To access this example, please open the NI Example Finder by navigating to Help»Find Examples… in LabVIEW. Once you have opened the Example Finder, please navigate to Toolkits and Modules»Control and Simulation»Simulation»Optimal Control Design»PID Design for Second Order Continuous System.vi .

 

For simple transfer function programs, I recommend looking at the SimEx transfer function.vi in the Control Design & Simulation LabVIEW examples (Toolkits and Modules»Control and Simulation»Simulation»Continuous Linear»SimEx transfer function.vi).

Cameron
Message 2 of 6
(3,396 Views)

You are trying to control a stable transfer function, but one with a non-minimum phase response - just inspect the transfer function alone without the controller. So if you make the controller gains too high it can go unstable when you put it in closed loop. Just to test it is working - turn off both integral and derivative actions (Ti = very large, Td = 0) and start with a small Kc (<1 in your case).

 

 

Consultant Control Engineer
www-isc-ltd.com
Message 3 of 6
(3,360 Views)

Dear FrisbeeArrays,

 

 

Thank you for your reply. but, I could not find your directions as below.

 

"Toolkits and Modules»Control and Simulation»Simulation»Optimal Control Design»PID Design for Second Order Continuous System.vi "

 

So, I tried to download from my labview install CD and NI website for it. However, I could not find it. Could you please let me know the link for download of modules related with controls?

 

I think my laview was not installed fully about control module.

 

Thank you for your consideration and supports.

0 Kudos
Message 4 of 6
(3,323 Views)
Dear AndyClegg
 

Thank you for your advice.

 Could you please explain me about the "non-minimum phase response - just inspect the transfer function alone without the controller" much detailly? so, you mean that controller gain should be bery low in the closed loop? Could you explain me the reason little bit more specifically? Thank you.

 

0 Kudos
Message 5 of 6
(3,319 Views)

Sorry my mistake. I read the transfer function wrong - it is NOT a non-minimum phase (its related to the zeros of the transfer function - plenty of stuff on internet that describes this if you are want to learn more). Still my advice about starting with low gain proportional only controller still applies, just that it should be easier to get some working gains.

 

Consultant Control Engineer
www-isc-ltd.com
0 Kudos
Message 6 of 6
(3,298 Views)