LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Implementing state variable feedback gains in a controller

Hello,

 

I am trying to recreate a controller that I found in a paper. The plant I am using is a servo motor with an encoder for feedback. I want to control position. The controller uses state variable feedback gains to move the poles. I have two states and thus, two gains. I have done the math and simulated in MATLAB. I know what my gains are but do not know how to add them to my controller in LabVIEW. This is not a model. The controller will actually be turning a real motor. I am not very seasoned in LabVIEW and do not know how to add these gains. All I need to do is include these gains on this simple controller and it should be good to go (at least theoretically that is). Please help. I am attaching a snip of my design. There is a gain block where I want to include the gains. This gain block is only there for refrence. I realize it will have to be replaced with something else in the final design.

0 Kudos
Message 1 of 6
(2,737 Views)

I'm not even looking at a picture of code (how would you like it if I sent you a picture of a 400-line Matlab routine?).  Attach your VI (or VIs -- you can compress the folder that contains your work if you've got more than 2-3 VIs and attach the resulting .zip file).

 

Bob Schor

0 Kudos
Message 2 of 6
(2,734 Views)

Hi Bob,

 

Thanks for taking time to reply. The attachment I included is all I have. It is a snip of the VI I am creating.

0 Kudos
Message 3 of 6
(2,729 Views)

So attach the VI as it stands!  A VI can be tested, we can determine the version of LabVIEW you are using, we can edit it, etc.  Attach your VI, please.

 

Bob Schor

0 Kudos
Message 4 of 6
(2,719 Views)

I see. I didn't realize you were looking for the actual file. Here it is.

0 Kudos
Message 5 of 6
(2,712 Views)

Thank you!  That was extremely helpful.  Now I can see you are developing something using LabVIEW 2019's Control Design and Simulation Module, and it involves the Elvis III platform.  

 

I'm not very familiar with the CDS Module, but now that others can see and know this is part of the question, one of my colleagues might be able to help.  There is also a Forum for the Elvis platform -- possibly someone there has asked similar questions.

 

Bob Schor

0 Kudos
Message 6 of 6
(2,682 Views)