In Vee Pro (Runtime of not) on Windows 7
1) Stop object only stops the thread it is in.
2) Raise error only object display an error message on the interface and will not kill the program
(I mean a unix like shure kill -9)
Thank you for your help
This is only occurs if your ThreadObjects have panels, so never use ThreadObjects for any kind of display or user interface. This is hinted at under "Display Objects" in the ThreadObject topic in VEE help.
The attached program has 256 ThreadObjects and stops instantly when when either F8 is pressed or the Stop button is clicked.
BTW, you'll get faster answers to your questions if post them on the VEE email reflector:
To subscribe please send an email to: "firstname.lastname@example.org" with the word subscribe in the message body (no long signatures and plain text only).
If I replace the code of one of the threads of the 256-threads-stopable.vee program by a single Stop object.
The program will not stop the program from running.
I usually abort a vee program when an instrument returns an error signal.
It does not appear to be possible to do that from within a ThreadObject.
Thank you for any clue.
Louis Lamarche B.Sc, B.Ing., M.Sc.A., ing.
Systèmes de mesure et d’information
Direction principale – Institut de recherche (IREQ)
VPE - Développement des affaires et planification stratégique
1800, boul. Lionel-Boulet, RC
Varennes, (Québec), J3X 1S1l
Tél. : 450 652-8077, interne 0-810-8077
De : WDrago
Envoyé : 21 mai 2016 07:26
À : Lamarche, Louis
Objet : Re: - How do we kill a multithreaded vee app ? Stop and Raise Err not working.
Courriel provenant de l’externe
ATTENTION, avant d’accéder à une pièce jointe ou à un lien de ce courriel, assurez-vous que celui-ci provient d’un tiers de confiance.
Keysight Community <https://community.keysight.com/?et=watches.email.thread>
How do we kill a multithreaded vee app ? Stop and Raise Err not working.
reply from WDrago<https://community.keysight.com/people/WDrago?et=watches.email.thread> in VEE Software - View the full discussion<https://community.keysight.com/message/75150?et=watches.email.thread#comment-75150>
I would not be using thread objects for instrument I/O. VEE will run regular user objects in parallel just like threads, although I'm not sure why you would be doing that anyway with instruments. Bottom line advice, convert your thread objects to user objects and I bet your program will run fine.
Please consider subcribing to the VRF. You'll get better support there. See below for instructions.
You'll get faster answers to your questions if post them on the VEE email reflector (VRF):
Well the measurement system involves two PCS communicating synchronously through
Sockets . Each PC as a set of instruments and four programs running simultaneously
over a LAN/GPIB gateways and communicating through sockets.
ThreadObject are usefull to implement different acquisition scripts, manage synchronisation,
manage sockets and prevent applications from freezing the user interface.
Every thing works correctly except that once per month or so, an instrument will return an
error code for an unknown reason. It would be nice if we could simply abort the program
involved with a STOP objet. For the moment we use Windows 7 WMI to make the kill but
this is not very “elegant”.
Thank you for your help !
Envoyé : 1 juin 2016 18:05
reply from WDrago<https://community.keysight.com/people/WDrago?et=watches.email.thread> in VEE Software - View the full discussion<https://community.keysight.com/message/75237?et=watches.email.thread#comment-75237>
Sounds like a very cool system. The only other thing I can suggest, and I'm sure you've thought of this already, is to have the thread object recover from the instrument error instead of stopping the program.
Retrieving data ...