LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Max/Min Display

YES!  Thanks a lot.  It finally works.    I also now wired in max and min displays for the temperature as well.  But now every time I add one of these displays I need 2 shift registers and my block diagram is going to be a mess.  I think that is what you are talking about Dan.  How would I go about breaking it up into smaller VIs?  Do you wire them together and make a master display kind of thing?   I just found out that our purchasing department somehow forgot to order our DAS, so I guess I have some time to work on this. 

 

Thanks again,

 

Richard

0 Kudos
Message 21 of 31
(1,934 Views)

For avoiding your block diagram to be a mess, you can put all your variables in a cluster and this way you have only 1 wire and 1 shirt register.

 

For cluster your variables, use "bundle". (Variables must have a name, which you can handle by an initialization with a constant, and then put a label on the constant). Then for using one variable use "unbundle by name", and for storing again the value in the cluster, "bundle by name". This replace the value of the variable by the new value. Of course you can also bundle and unbundle multiple variables at once, by resizing the "unbundle by name", making appear new outputs, as you do with an array constant or with a time delay function to make other parameters appear

0 Kudos
Message 22 of 31
(1,930 Views)

Hi Richard,

 

Swiesser offered some great advice about using clusters, especially if you are using subVI's and you want to limit the number of input terminals you use. I would also consider using Feedback Nodes. I prefer Shift Registers because they are more intuitive, but Feedback Nodes do exactly the same thing as Shift Registers (and need to be initialized as such). You can place a Feedback Node right next to the functions within your main while loop and then that data wire won't sprawl across your whole VI. Just a thought...

 

Regards,

 

Dan Richards

Dan Richards
Certified LabVIEW Developer
Message 23 of 31
(1,918 Views)

Those feedback nodes are a godsend.  Now my max/min displays are working no problem.  And for some reason, adding them has seemed to synchronize all but 1 of my charts in terms of relative time (although they think it is 7:00pm for some reason).  My HRR chart has the right time, but if I want it in relative time, it starts at something like 3 million seconds.

 

Also, does anybody know how to label the columns in an output file?  They just come up as "DC" or "Formula result" and I want to customize that.

 

I've attached my VI again in case anybody wants to see the progress or wants to have a look at my time problem.

 

thanks again,

Richard

0 Kudos
Message 24 of 31
(1,909 Views)

Hi Richard,

 

Can you explain a little bit more about what you're looking for with the label renaming? If you were able to change "DC" and "Formula result" to something else, would that work for you?

 

If I were you, I would consider creating a new post for each individual issue. (Highly recommended!)

 

Regards,

 

Dan Richards

Dan Richards
Certified LabVIEW Developer
0 Kudos
Message 25 of 31
(1,891 Views)

Hello dear Labview folks!

 

I am trying to do the same, using shift register to compare measurements and get min & max.

 

I am working with an indexed 1 D Double array

 

I already can compare if the new measurement is bigger than the previous, but I am not able to store the absolute max

 

I am working with Labview 7.1 so I cant open the example. 

 

Can anyone pls be so kind and make an image or convert the vi for me to 7.1?

 

Thanks very much in advance!

 

Best regards

Thomas

 

 

 

 

 

0 Kudos
Message 26 of 31
(1,726 Views)

This thread was started in 2008.  You should start a new thread and state your problem.  You will get more responses that way.

 

- tbob

Inventor of the WORM Global
0 Kudos
Message 27 of 31
(1,720 Views)

Hello thomas

 

Maybe one of these two solutions.

 

Francis

0 Kudos
Message 28 of 31
(1,689 Views)

Yes it works! Thank you very much Francis!

 

The complicated version worked perfectly for me

 

I just had to delete the 0 constant, now I´ve got the max!

 

Greetz, Thomas

 

0 Kudos
Message 29 of 31
(1,661 Views)
Hi Thomas

One thing:

You can have problem if you do not use constant on your shift register outside the for loop. The shift regiser will use the last value that was store in it. To illustrate want I am talking, you can look at the two following picture. I run The VI (max value array was 6) then I change the array (new max value was 4) and I run the VI again. As you can see he was not able to detect the max value in the second array because the value of the first run was bigger. So to avoid that and if you know the range of your array value, I suggest to add a constant to the shift register. This constant should be the lower value you expected. It is use to ''reset'' the shift register. 

Or you could use this other method that I am just think right now. See fourth run picture. You compare with the first value of the array. So your are sur that you will get the max value. No mather the array range.

Hope it is not too confusing and this will help

Francis
Download All
0 Kudos
Message 30 of 31
(1,625 Views)