LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Im creating a simple PID controller, however i cannot graph the output

I have created a simple PID controller but the output cannot be drawn on a graph as i have connected two different types. I have my file attached, Is any one able to assist me

 

 trial.png

0 Kudos
Message 1 of 7
(3,669 Views)

I'm using 2014 so I can't open your VI.  It looks like it's a simple data type mismatch.  Change the graph to be a double datatype.

 

Are you using an array of data from the PID? I thought it was a single scalar value.  In that case, you'd want a chart instead to keep updating your history as you go.  The graph won't maintain a history for you.

Message 2 of 7
(3,660 Views)

Well i am acquiring data from a data aquisition card, i will give that a try and see if it works, thank you

0 Kudos
Message 3 of 7
(3,613 Views)

Hi Fritz,

 

what does the context help tell you when you move the mouse over this broken wire?

 

Your PID probably outputs a scalar value. Graphs don't accept scalar values - as you can see in the context help!

Either create an array from your scalar PID outputs or use a chart instead…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 4 of 7
(3,600 Views)

How do i change the graph to double datatype? i cannot seem to figuyre this out. I have tried using the chart is the chart time dependant? i need my PID display a signal opposit to the input of the PID, and i am not that much concerned about the history.

0 Kudos
Message 5 of 7
(3,554 Views)

Hi Gerd

 

the contrext help tells me the following

" You have connected two terminals of different types. The type of the source is double[64-bit real(~15digit precision)]. the type of sink is waveform (DBL)."

 

As i asked earlier will the chart be time dependant?

0 Kudos
Message 6 of 7
(3,547 Views)

Hi Fritz,

 

will the chart be time dependant?

A sarcastic answer: yes, it is time dependent as it plots new data when you supply new data…

 

LabVIEW comes with a lot of example VIs. And I know there are examples explaining how to use charts and graphs!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 7
(3,537 Views)