10-20-2006 07:23 AM - edited 10-20-2006 07:23 AM
Please review Dennis' earlier comments and refer to the attached diagram.
I hope this helps,
Ben
Message Edited by Ben on 10-20-2006 07:24 AM
10-20-2006 09:32 AM
10-20-2006 09:38 AM
10-20-2006 10:20 AM - edited 10-20-2006 10:20 AM
Message Edited by Dennis Knutson on 10-20-2006 09:20 AM
10-20-2006 10:58 AM
10-23-2006 08:32 AM
11-02-2006 10:39 AM
Hello DFGray,
I'm sorry. This is the first time I'm reading your reply. All you have told me it's new for me, so I'll have to study how queues and other resources work. Give me some days to do that, and I'll tell you if I success. Also, I'm going to show you in a video file the final performance.
One of you told me it is not necessary to show "N" pop-ups at the same time to the operator, and that's true. One thing I'm going to do is create a maximun limit to the showed graphs. So, I don't know if it is worthwhile to change all the architecture. Despite that thing, I'm going to try because I want the best performance for my application.
My best regards,
Alfonso.
11-07-2006 05:02 AM
Hi DFGray, Here are my answers of your comments:
Queues are your friend. They make this sort of thing easy.
I'm sure about it, my friend.
Popups are only used to display a 60samples array of aquired data. The property node is only use at the begining when the pop-up is launched. After that moment, no property node is used.
You can use queues to get data back from the pop-ups as well. This allows you to do such things as deteremine when the pop-up has finished initializing. Once again, create the queue before you start the pop-up and pass the reference to it.
It is not planned to be data exchange between a popup and the main application, except the reading of the array that is going to be displayed. I pass the reference to the popup to simplify the tasks of the main application. If the reference is passed, then the main application doesn't to worry about "wait until the popup finished" and it can continue doing other things.
Use of queues means you don't have to worry about creating a bunch of uniquely named global variables. It also almost eliminates the need to pass control references around. There are other methods (e.g. notifiers, events) that can be used in a similar fashion. I urge you to take a look at them.
I understand what you meant, but if I want to use queues I'll have to use other resources to notify that there is a new element in the queue, to syncronize the writting and reading of the temporal and data arrays. (who are passed to the graph). Is it worth to use queues+notifiers instead of globals?
You recommended me not to use global variables because they can't be created or destroyed programmatically. The thing is, in my application, they have to be used continously, not only at one time.
Now, here is my question. Global variables are used in my application to keep the last 5min values of each signal. When the operator wants, He can launch a popup, and display the acquired signal. Do you think change using queues and notifiers (events, semaphores) instead of globals is worth?
Thanks in advance for your interesting and help.
Alfonso
11-07-2006 08:03 AM