AnsweredAssumed Answered

Disarmed vrf VEE issues...

Question asked by VRFuser on Apr 25, 2008
Jim,

 

I’ve seen this problem before.  Honestly for multithreaded operations, I convince my boss to let me use Microsoft Visual Studio.  This way I have control of each thread.  But if I must use VEE, I contract and do what I’m told; I will try to control the timing.

 

Your problem is making sure your homing object receives attention when your curve fitting is eating up time.  As you know VEE does not take advantage of multi-threads.  VEE does one thing at a time.  If you do your Acquisition first in a separate userobject, drop down into another userobject that has three userobjects with no control lines.  The first object will save your data, the second will find home for your motor, and the last will do your curve fit.

 

If the above does not give what you need, try sequencing the save, then the home, then the curve fit.

 

I solved a similar problem once before by using ON CYCLE.  For each object I controlled how much time each object could have.  Sort of like portioning the time for each object.  I’m not sure, but your case seems simpler, simply control what goes first.  But if you want them both at the same time, try ON CYCLE for each object and control how much time each gets.  You’ll need to capture when you’re done in each and then break or exit the object.

 

 

Rufus

 

  _____  

From: Jim McClymer [mailto:mcclymer@maine.edu]
Sent: Friday, April 25, 2008 10:46 AM
To: VRF
Cc: VRF
Subject: {Disarmed} Re: [vrf] VEE issues...

 

I have a similar problem and can use some advice. In my code I acquire some data and then want to do three things- save the file (fast), return a motor to the home position which requires monitoring position, and do some curev fitting which is involved and takes awhile.  I trigger these three threads when the data acquisition is compete and sometimes the motor return home happens right away, other times it waits until the curve fitting is complete.

Is there an (easy) way to  have both threads operate simultaneously so curve fitting is on going with the motor movement?
Thanks
Jim

Warren, Rufus wrote:

Doug,

 

I have seen this with programs I’ve had to fix.  How I make sure of program flow and make sure I have control of what is happening:

 

For each section of code, userobject, or function, I try to keep everything on one screen and keep the number of lines to a minimum.
I also make sure the control lines are top down whenever possible
I try to keep separate and independent threads within there own userobject
For my variable space I use local variables whenever possible
For globals, I build one global record, and place all my globals there
I am anal with control flow and make sure I use a control line for each object
Exceptions are counters and collectors or any other object with sensitivity to being pinged
Lastly I trap every error and decide on program flow, so I would have been able to tell my boss, “please make sure the GPIB is properly initialized.”

 

Rufus

 

PS For trapped errors, I usually simply send a text message to an alpha display in a simple panel.  Then choose program flow either before or after the message.

 

  _____  

From: Douglas Rudrow [mailto:drudrow@Aurora.com]
Sent: Thursday, April 24, 2008 7:22 PM
To: VRF
Subject: [vrf] VEE issues...

 

Greetings all,

 

I’ve got a dilemma. I wrote a very simple program to communicate with an optical polarization controller. While I was at lunch today, my boss copied it to a different computer. When he tried to run it, VEE threw an error that it couldn’t open the GPIB interface. When I got back from lunch, he had sent me this long e-mail about how he’s losing confidence in VEE and we need a robust platform in the lab. In this particular case, Windows had failed to configure the plug and play GPIB interface (NI USB-GPIB HS). Of course I explained that if the equipment is not connected to the computer, no language in the world can talk to it, VEE simply pointed out that there was no GPIB interface.

 

            The preface to this whole incident is: I have a much more complex test program that had worked for months on end with no problems, and then all of a sudden it stopped working with no changes to the test setup, the PC or the software. While troubleshooting this problem, I saw that the data and execution flow of the program was doing things I didn’t expect. Perhaps this is just a lack of true understanding of VEE program flow on my part, but I’ve been writing test code in VEE for over 13 years and I’d never seen this. In order to get the program running again, I had to revert back to a programming style I haven’t used since I was a rank amateur. I started using loads of variables instead of passing data through terminals. I know, it’s not efficient or elegant, but it’s working. My questions are: has anyone else run into problems like this? And has VEE program flow changed as operating systems and VEE have evolved?

 

Thanks in advance,

 

Doug

 

 

 

Douglas B. Rudrow

Systems Development Lab Technologist

Aurora Networks

2803 Mission College Blvd.

Santa Clara, California, 95054

U.S.A.

(408) 235-7000 Main

(408) 235 7084 Direct

HYPERLINK "mailto:rvilla@aurora.com"drudrow@aurora.com

 

 


---
You are currently subscribed to vrf as: HYPERLINK "mailto:Rufus.Warren@herley.com"Rufus.Warren@herley.com
To subscribe please send an email to: "HYPERLINK "mailto:vrf-request@lists.it.agilent.com"vrf-request@lists.it.agilent.com" with the word subscribe in the message body.
To unsubscribe send a blank email to HYPERLINK "mailto:leave-vrf@it.lists.it.agilent.com""leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list, email HYPERLINK "mailto:vrf@agilent.com""vrf@agilent.com".
If you need help with the mailing list send a message to
HYPERLINK "mailto:owner-vrf@it.lists.it.agilent.com""owner-vrf@it.lists.it.agilent.com".
Search the "unofficial vrf archive" at HYPERLINK "http://www.vrfarchive.com/vrf_archive"MailScanner has detected a possible fraud attempt from "www.vrfarchive.com" claiming to be "http://www.vrfarchive.com/vrf_archive".
Search the Agilent vrf archive at HYPERLINK "http://vee.engineering.agilent.com"MailScanner has detected a possible fraud attempt from "vee.engineering.agilent.com" claiming to be "http://vee.engineering.agilent.com".

  _____  

The information contained in this message may be confidential and legally privileged. If you are not the intended recipient of this email and its attachments, you must take no action based upon them, nor must you copy or show them to anyone.
Please contact the sender if you believe you have received this email in error.




---
You are currently subscribed to vrf as: HYPERLINK "mailto:mcclymer@maine.edu"mcclymer@maine.edu
To subscribe please send an email to: HYPERLINK "mailto:vrf-request@lists.it.agilent.com""vrf-request@lists.it.agilent.com" with the word subscribe in the message body.
To unsubscribe send a blank email to HYPERLINK "mailto:leave-vrf@it.lists.it.agilent.com""leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list, email HYPERLINK "mailto:vrf@agilent.com""vrf@agilent.com".
If you need help with the mailing list send a message to
HYPERLINK "mailto:owner-vrf@it.lists.it.agilent.com""owner-vrf@it.lists.it.agilent.com".
Search the "unofficial vrf archive" at HYPERLINK "http://www.vrfarchive.com/vrf_archive"MailScanner has detected a possible fraud attempt from "www.vrfarchive.com" claiming to be "http://www.vrfarchive.com/vrf_archive".
Search the Agilent vrf archive at HYPERLINK "http://vee.engineering.agilent.com"MailScanner has detected a possible fraud attempt from "vee.engineering.agilent.com" claiming to be "http://vee.engineering.agilent.com".


---
You are currently subscribed to vrf as: Rufus.Warren@herley.com
To subscribe please send an email to: "vrf-request@lists.it.agilent.com" with the word subscribe in the message body.
To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list, email "vrf@agilent.com".
If you need help with the mailing list send a message to
"owner-vrf@it.lists.it.agilent.com".
Search the "unofficial vrf archive" at "http://www.vrfarchive.com/vrf_archive".
Search the Agilent vrf archive at "http://vee.engineering.agilent.com".

  _____  

The information contained in this message may be confidential and legally privileged. If you are not the intended recipient of this email and its attachments, you must take no action based upon them, nor must you copy or show them to anyone.
Please contact the sender if you believe you have received this email in error.





---
You are currently subscribed to vrf as: ming_meng@agilent.com
To subscribe please send an email to: "vrf-request@lists.it.agilent.com" with the word subscribe in the message body.
To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list, email "vrf@agilent.com".
If you need help with the mailing list send a message to
"owner-vrf@it.lists.it.agilent.com".
Search the "unofficial vrf archive" at "http://www.vrfarchive.com/vrf_archive".
Search the Agilent vrf archive at "http://vee.engineering.agilent.com".  

Outcomes