10-15-2021 01:40 PM
including a gif screenshot here of what I'd like to be able to do programmatically...
Is it not possible to have a chart with stacked plots increase in plot count while running? I even have to select overlay and then stack plots again between runs to get it to show up.
I have a dynamic number of events I want to monitor the "on and off" state of in a rolling chart fashion. If anyone know of any other way to do it that would be appreciated.
Solved! Go to Solution.
10-16-2021 10:17 AM
Based on the help document - I would assume this as an edit-time feature (available only through VI scripting), meaning only during an edit, it can script the placement of stacked charts.
10-16-2021 10:39 AM
You can use a picture indicator and some code to turn your data into the desired plots. Won't be easy, though. (Have a look at "xy mulitiplot" in the example finder for some basics.)
You can use a single chart and scale and offset the data of the various plots.
@p27 wrote:
I have a dynamic number of events I want to monitor the "on and off" state of in a rolling chart fashion. If anyone know of any other way to do it that would be appreciated.
What is an "event" and how does it look like? Maybe a digital graph would be something? Can you attach a more realistic example?
10-16-2021 11:13 PM - edited 10-16-2021 11:22 PM
The easiest option would probably be to hide the Y scale entirely and just shift your data up (e.g. plot one can be 0 or 1, plot 2 can be 1.1 or 2.1, etc.). You could draw a fake Y scale using the plot images properties and add plots with fills to serve as the separator bars if you want that too.
All that should be relatively easy with an XY graph. I'm not familiar enough with the differences for waveform charts to tell what would be required there, but you could definitely hold the data in a circular buffer (like a lossy queue) and build the graph.
Edit - or go with Altenbach's suggestion of a digital graph, which might be simpler and still do what you want.
10-18-2021 06:44 AM
thanks for the info and ideas- scripting occurred to me but I just assumed I'd get lost, I've only done some very simple scripting work before. I'm going to at leats look into it and see if it as complicated as I expect...
I'll take a look at XY multiplot and the possibility of using digital graph too- really all I need to show is the binary state of incoming "jobs"- basically just a plot that goes high while something is being worked on and goes low when its done. Having plots would be a nice way to see the actual timing of which "job" is started and finished in relation to others.
I didnt think of doing a multiplot with shifted data... that wouldnt be too hard...
I'll take a peek at digital plot first and see if that's the easiest option though...
thanks again!
10-18-2021 09:09 AM - edited 10-18-2021 09:18 AM
Ok here's what I cobbled together for a test (vi is 2018 64b)... seems to work but I'd like to get the 1/0 indicators off the graph if possible...
also is it possible to have it allow for scaling or vertical scrolling if the number of lines/plots goes off the chart?
10-18-2021 12:16 PM
10-18-2021 12:22 PM
Better result than mine and so much simpler!
thanks!