LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

problem displaying graph

Hi all,

I just started learning labview. Having problems displaying my graph, so not very sure if i did my program correctly.


The equation in the formula box calculates the value which is supposed to be displayed as the y-axis while the x-axis is suppose to display the time. There's no display and i cant seem to find the root of the problem.

Please help, any advice will be greatly appreciated.


regards
jan
0 Kudos
Message 1 of 5
(3,078 Views)
Data does not exit a while loop until it finishes. The while loop never ends because you have a constant wired to the termination terminal so data never gets passed to the graph or to your VISA Write. You need to put the while loop around all of the code. You also need to use a front panel Boolean to stop the loop. You also need to wire a False constant to the Build XY Graph reset input. The default is a True so every time the funcion is called, you would only get one point plotted even if it wha inside the loop.
Message 2 of 5
(3,063 Views)
Hi, Thanks for your help and I've managed to display the graph and to start running my pump.
Added some additional commads but was faced with a few problems:
1. I'm unable to stop the pump using the command string 1I\r\n.
2. I'm want to transfer the flowrate data calculated in the formula box to the pump. However, the pump do not seem to recieve the command and continues to deliever at its initial flowrate.
3. And I would like to be able to choose the case which I require in the front panel but I can't seem to do it.

PS: the peristaltic pump whch I'm using is Ismatec IPC-N.
Command to
- start : 1H\r\n
- stop : 1I\r\n
- run at 100% rpm : 1S0100\r\n
- run at 75% rpm : 1S0075\r\n

Please help. Thank you so much.
0 Kudos
Message 3 of 5
(2,996 Views)
Hi Jan,

you should try to add those \r\n (which is CR and LF) to your strings. To do so use the appropriate constant from string palette or make a string constant and set it to "\-codes display" before entering characters. You can do the same with your string controls!

To store values in controls permanently you can use "make current value default" in the  context menu of the control.

More hints:
In your case you don't need a sequence structure as the dataflow ensures execution order.
Are you sure you want a octal-formatted string for your device communication? Not a decimal formatted? Or even better using "Format to string" instead?

See changed attachment!
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 5
(2,988 Views)

Hi,

Sorry that I'm unable to rate msges as I'm still considered a new user.

But thanks for your reply. They were very helpful. 🙂 

0 Kudos
Message 5 of 5
(2,961 Views)