LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

pda graph redraws every time when cursor is moved

Hi,

I use PDA Module 8.2 and Windows Mobile 5 OS on PDA.
I have a problem that every time I move cursor on graph control plot is being redrawn, so it realy annoying when you have 5000 or more points and you have to wait a second while plot is being redrawn.
You can test this in attached vi.
Is there any way to aviod this?

Thanks,
andrej
0 Kudos
Message 1 of 7
(9,064 Views)
What resolution does your PDA screen have?  I've heard of no model with a 5000 pixel screen. 😉

Try modifying the amount of data to fit something approaching the physical display size.  This will really speed things up.

Shane.
Using LV 6.1 and 8.2.1 on W2k (SP4) and WXP (SP2)
0 Kudos
Message 2 of 7
(9,063 Views)
Hi,

thanks for your help Shane.
I ment 5000 elements in 1D array that is plotted.
What I'm looking for is property or setting that disable redrawing when cursor is moved.

andrej
0 Kudos
Message 3 of 7
(9,056 Views)
When is a cursor being moved? Programatically?

If you are controlling the cursor via code, then you can disable front panel updates before moving and re-enable them afterwards.

You need a reference to the front panel (available via current VI reference) to set this property.  Whatever you do, don't forget to set it back, otherwise your screen will freeze even though the program is still running.......

If you need to react to user-interaction it'll be very hard because you can't really detect when the move is finished.

Shane.
Using LV 6.1 and 8.2.1 on W2k (SP4) and WXP (SP2)
0 Kudos
Message 4 of 7
(9,054 Views)
I need to react user-interaction.
I will resize data and plot it, but processing will be done on original data.

Thanks again,

andrej
0 Kudos
Message 5 of 7
(9,053 Views)
That's what I would do too.

Separating displayed data from raw data can be a really rewarding exercise sometimes.  Always bear this in mind.

Shane.
Using LV 6.1 and 8.2.1 on W2k (SP4) and WXP (SP2)
0 Kudos
Message 6 of 7
(9,048 Views)


@andrej wrote:
I need to react user-interaction.
I will resize data and plot it, but processing will be done on original data.

OK, that's not just a "cursor move", if the cursor movements causes resizing and processing of the displayed data. Most likely, the processed data looks different so a redraw is needed anyway.

Reducing the displayed data as suggested by others is certainly a good thing. However, 5000 points are not that many, so maybe you are doing things very inefficiently and wasteful. For example, currently you don't have a small wait inside your loop, so the While loop alone will consume all available CPU, strongly competing with the graph redraw operations for CPU resources.

Why don't you show us the real code that modifies the display/data when the cursor is moved?

Also, if the data is manipulated via cursors, it is generally a really bad idea to have the axes set to autoscale.

0 Kudos
Message 7 of 7
(9,042 Views)