ejensen Posted April 9, 2009 Report Share Posted April 9, 2009 I have a UI with 2 graph indicators. Both graphs worked fine, and autoscaling functioned normally, but they were updating out of sync. I added defer panel updates property nodes before and after the values are written to the graphs. Now when I run the VI, the top graph functions as it always has and autoscales properly. The bottom graph doesn't autoscale at all, despite autoscaling being selected. They both update simultaneously now, but the 2nd graph indicator refuses to autoscale. Have I missed something? Is this a bug? Quote Link to comment
Grampa_of_Oliva_n_Eden Posted April 9, 2009 Report Share Posted April 9, 2009 QUOTE (ejensen @ Apr 8 2009, 11:03 AM) I have a UI with 2 graph indicators. Both graphs worked fine, and autoscaling functioned normally, but they were updating out of sync. I added defer panel updates property nodes before and after the values are written to the graphs. Now when I run the VI, the top graph functions as it always has and autoscales properly. The bottom graph doesn't autoscale at all, despite autoscaling being selected. They both update simultaneously now, but the 2nd graph indicator refuses to autoscale. Have I missed something? Is this a bug? http://lavag.org/old_files/monthly_04_2009/post-13866-1239202925.png' target="_blank"> Try putting both therminals in a seq frame that completes before the "undefer". AS written now there is no guarentee that the data will be presented to the graph before the undefer happens. Ben Quote Link to comment
ejensen Posted April 9, 2009 Author Report Share Posted April 9, 2009 I'm not able to test it immediately, but I see your point. I initially had the indicators inside the case structure. I don't recall my reasoning for moving them outside, but I think putting them back inside will also fix the potential dataflow problems. Many thanks. Quote Link to comment
LAVA 1.0 Content Posted April 9, 2009 Report Share Posted April 9, 2009 Isn't there a 'Autoscale once' property/method? Yes there is. QUOTE Short Name: ScaleFit Installed With: Base Package Class: GraphScale Properties Fit scale to data: 0-Do not autoscale, 1-Autoscale once now, 2-Autoscale. This property applies only to the active X-scale or active Y-scale. This property is similar to the AutoScale items on the shortcut menu of an x- or y-scale. This property is similar to the Autoscale checkbox on the Scales page of the Properties dialog box. Ton Quote Link to comment
ejensen Posted April 10, 2009 Author Report Share Posted April 10, 2009 QUOTE (Ton @ Apr 8 2009, 03:57 PM) Isn't there a 'Autoscale once' property/method?Yes there http://zone.ni.com/reference/en-XX/help/371361E-01/lvprop/grphscl_scl_fit/' target="_blank">is. Ton I suppose I could use this, but shouldn't have to. The graph is set to autoscale and I shouldn't have to change that. One of the graphs was functioning properly as I had it, but the other was not. I tried moving the indicators inside my case structure thinking the data would be written to the indicator before data flow left the case structure. I got the same result as when they were outside the case structure, which is still a bit confusing unless I'm misunderstanding something with data flow. Shouldn't everything in the active case finish before leaving the case? I was able to use a sequence structure as Ben suggested, and it works as it should. Any ideas what I'm missing here? Quote Link to comment
Grampa_of_Oliva_n_Eden Posted April 10, 2009 Report Share Posted April 10, 2009 QUOTE (ejensen @ Apr 9 2009, 09:32 AM) I suppose I could use this, but shouldn't have to. The graph is set to autoscale and I shouldn't have to change that.One of the graphs was functioning properly as I had it, but the other was not. I tried moving the indicators inside my case structure thinking the data would be written to the indicator before data flow left the case structure. I got the same result as when they were outside the case structure, which is still a bit confusing unless I'm misunderstanding something with data flow. Shouldn't everything in the active case finish before leaving the case? I was able to use a sequence structure as Ben suggested, and it works as it should. Any ideas what I'm missing here? ? Set the graph/cahart as "syncronous" ? You did not mention which version of LV. I think it was LV 8.2 where I had a hell of a time trying to get the graphs to update properly. If I remeber correctly, NOT using defer FP update helped. In other version of LV if the chart/graph where on a non-selected tab page, I had to "jiggle the handle" (invoke node Get image) to get the image to update. Ben Quote Link to comment
ejensen Posted April 10, 2009 Author Report Share Posted April 10, 2009 QUOTE (neBulus @ Apr 9 2009, 08:35 AM) You did not mention which version of LV. 8.6 Thanks again for the suggestions. It's not a major concern since I got it working with your earlier advice. I was just hoping someone might be able to clear up why my fix didn't work. Quote Link to comment
Grampa_of_Oliva_n_Eden Posted April 14, 2009 Report Share Posted April 14, 2009 QUOTE (ejensen @ Apr 9 2009, 09:51 AM) 8.6Thanks again for the suggestions. It's not a major concern since I got it working with your earlier advice. I was just hoping someone might be able to clear up why my fix didn't work. I just stumbled across (what to me is new) a property for graphs called "AutoscaleDelay". Is controls how often a grph will Auto-scale. I have no idea in whcich version this was introduced. Ben Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.