LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Feedback control for ball and beam balancing

Hello everyone

 

i am a beginner for  labview. i need to do the ball and beam balancing project. by using state-space theory.

i have an example for control the system but they have use 2 sensors(distance sensor and angle sensor). however in my case i want to use observer theory instead angle sensor. and put all of value to feedback control (included K gain) and get control action for servo motor. BTW the gain value (K,G,L) will come from calculation by hand.

My question is for observer which vi i should use?

state estimate or discrete observer or etc..

if you guy have any suggestion, its would be great to let me know. 

0 Kudos
Message 1 of 6
(1,269 Views)

Attach the VI -- few of us want to try to reproduce your code (to test it out) from a picture.

 

Bob Schor

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

hello  Bob Schor

I am so sorry.

I don't have VI file.

btw from that picture can not apply to my project. because i want to use observer.

 

0 Kudos
Message 3 of 6
(1,231 Views)

@PSong wrote:

if you guy have any suggestion, its would be great to let me know. 


No matter what theory you are trying to use, you first need to eliminate all these glaring race conditions caused by blatant overuse of local variables. None are needed! Your top loop is full of disconnected code fragments, some writing to indicators and some reading from local variables of these indicators. Since there is no way to tell what happens first, the outcome is undefined. (Execution order is defined by dataflow, not by horizontal location on the diagram). What are the loop rates of the various loops? What is the purpose of the lower loop?

 

As Bob has already mentioned, we cannot debug images. It gets worse if the code contain express VIs and dynamic data, where there is absolutely no way to tell how things are configured. We also don't have your hardware (myrio?). Is there s way to can create a simulation that models the hardware in software?

0 Kudos
Message 4 of 6
(1,229 Views)

@altenbach wrote:

@PSong wrote:

if you guy have any suggestion, its would be great to let me know. 


We also don't have your hardware (myrio?).


Yes, I should have mentioned "What hardware are you using?".  If it is a myRIO, I connected to one via TCP/IP right now ...

 

Bob Schor

0 Kudos
Message 5 of 6
(1,206 Views)

First of all, Thank you for your suggestion altenbach.

I would like to honestly say that i just know Labview 2 weeks before assigned for this project.

currently, i am still reading how to use it.

and yes, i do use Myrio and IR sensor.

the lower loop is about to control servo motor.

 

therefore, i want to ask how to implemented state space theory and observer theory?

i want some hint or some guide to do the controller design.

 

Btw i alresdy got VI file.

 

Thank you again 

 

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